PHP Class ManaPHP\Http\Session

Inheritance: extends ManaPHP\Component, implements ManaPHP\Http\SessionInterface, implements ArrayAccess
Datei anzeigen Open project: manaphp/manaphp

Public Properties

Property Type Description
$adapter ManaPHP\Http\Session\AdapterInterface

Public Methods

Method Description
__construct ( string | array | ManaPHP\Http\Session\AdapterInterface $options = [] ) Session constructor.
__debugInfo ( ) : array
__destruct ( )
clean ( ) : void
destroy ( ) : void Destroys the active session
get ( string $name = null, mixed $defaultValue = null ) : mixed Gets a session variable from an application context
getSessionId ( ) : string
has ( string $name ) : boolean Check whether a session variable is set in an application context
offsetExists ( mixed $offset ) : boolean
offsetGet ( mixed $offset ) : mixed
offsetSet ( mixed $offset, mixed $value )
offsetUnset ( mixed $offset )
remove ( string $name ) Removes a session variable from an application context
set ( string $name, mixed $value ) Sets a session variable in an application context
setDependencyInjector ( ManaPHP\DiInterface $dependencyInjector ) : static

Method Details

__construct() public method

Session constructor.
public __construct ( string | array | ManaPHP\Http\Session\AdapterInterface $options = [] )
$options string | array | ManaPHP\Http\Session\AdapterInterface

__debugInfo() public method

public __debugInfo ( ) : array
return array

__destruct() public method

public __destruct ( )

clean() public method

public clean ( ) : void
return void

destroy() public method

Destroys the active session
public destroy ( ) : void
return void

get() public method

Gets a session variable from an application context
public get ( string $name = null, mixed $defaultValue = null ) : mixed
$name string
$defaultValue mixed
return mixed

getSessionId() public method

public getSessionId ( ) : string
return string

has() public method

Check whether a session variable is set in an application context
public has ( string $name ) : boolean
$name string
return boolean

offsetExists() public method

public offsetExists ( mixed $offset ) : boolean
$offset mixed
return boolean

offsetGet() public method

public offsetGet ( mixed $offset ) : mixed
$offset mixed
return mixed

offsetSet() public method

public offsetSet ( mixed $offset, mixed $value )
$offset mixed
$value mixed

offsetUnset() public method

public offsetUnset ( mixed $offset )
$offset mixed

remove() public method

Removes a session variable from an application context
public remove ( string $name )
$name string

set() public method

Sets a session variable in an application context
public set ( string $name, mixed $value )
$name string
$value mixed

setDependencyInjector() public method

public setDependencyInjector ( ManaPHP\DiInterface $dependencyInjector ) : static
$dependencyInjector ManaPHP\DiInterface
return static

Property Details

$adapter public_oe property

public AdapterInterface,ManaPHP\Http\Session $adapter
return ManaPHP\Http\Session\AdapterInterface