public function Session::get

Returns an attribute.

@api

Parameters

string $name The attribute name:

mixed $default The default value if not found.:

Return value

mixed

Overrides SessionInterface::get

File

drupal/core/vendor/symfony/http-foundation/Symfony/Component/HttpFoundation/Session/Session.php, line 88

Class

Session
Session.

Namespace

Symfony\Component\HttpFoundation\Session

Code

public function get($name, $default = null) {
  return $this->storage
    ->getBag($this->attributeName)
    ->get($name, $default);
}