Method |
Description |
|
__construct ( mixed $id, string $name, integer | DateTime $lifetime, integer | null $maximumAge, string | null $domain, string $path, boolean $secure, boolean $httpOnly ) |
Constructor to initialize a newly created session. |
|
addTag ( string $tag ) : void |
Tags this session with the given tag. |
|
canBeResumed ( ) : boolean |
Returns TRUE if there is a session that can be resumed. |
|
checksum ( ) : string |
Returns the checksum for this session instance. |
|
destroy ( string $reason ) : void |
Explicitly destroys all session data. |
|
emptyInstance ( ) : AppserverIo\Psr\Servlet\ServletSessionInterface |
Creates a new and empty session instance. |
|
getData ( string $key ) : mixed |
Returns the data associated with the given key. |
|
getDomain ( ) : string | null |
Returns the host to which the user agent will send this cookie. |
|
getId ( ) : string |
Returns the current session identifier. |
|
getLastActivityTimestamp ( ) : integer |
Returns the unix time stamp marking the last point in time this session has
been in use. |
|
getLifetime ( ) : integer | DateTime |
Returns date and time after the session expires. |
|
getMaximumAge ( ) : integer | null |
Returns the number of seconds until the session expires. |
|
getName ( ) : string |
Returns the session name. |
|
getPath ( ) : string |
Returns the path describing the scope of this cookie. |
|
getTags ( ) : array |
Returns the tags this session has been tagged with. |
|
hasKey ( string $key ) : boolean |
Returns TRUE if a session data entry $key is available. |
|
init ( mixed $id, string $name, integer | DateTime $lifetime, integer | null $maximumAge, string | null $domain, string $path, boolean $secure, boolean $httpOnly, integer | null $lastActivityTimestamp = null ) : void |
Initializes the session with the passed data. |
|
isHttpOnly ( ) : boolean |
Returns if this session should only be used through the HTTP protocol. |
|
isSecure ( ) : boolean |
Returns if this session should only be sent through a "secure" channel by the user agent. |
|
isStarted ( ) : boolean |
Tells if the session has been started already. |
|
putData ( string $key, mixed $data ) : void |
Stores the given data under the given key in the session |
|
removeData ( string $key ) : void |
Removes the session data entry $key from the session. |
|
removeTag ( string $tag ) : void |
Removes the specified tag from this session. |
|
resume ( ) : integer |
Resumes an existing session, if any. |
|
setDomain ( string $domain ) : void |
Sets the host to which the user agent will send this cookie. |
|
setHttpOnly ( boolean $httpOnly = true ) : void |
Sets the flag that this session should only be used through the HTTP protocol. |
|
setId ( string $id ) : void |
Sets the current session identifier. |
|
setLifetime ( integer | DateTime $lifetime ) : void |
Sets date and time after the session expires. |
|
setMaximumAge ( integer $maximumAge ) : void |
Sets the number of seconds until the session expires. |
|
setName ( string $name ) : void |
Sets the session name. |
|
setPath ( string $path ) : void |
Sets the path describing the scope of this cookie. |
|
setSecure ( boolean $secure = true ) : void |
Sets the flag that this session should only be sent through a "secure" channel by the user agent. |
|
start ( ) : void |
Starts the session, if it has not been already started |
|