Class SessionConfig

Summary

Fully Qualified Name: Zend\Session\Config\SessionConfig
Extends: StandardConfig

Description

Session configuration proxying to session INI options

Methods

Name Description Defined By
__call() Intercept get*() and set*() methods StandardConfig
getCacheExpire() Get session.cache_expire StandardConfig
getCookieDomain() Get session.cookie_domain StandardConfig
getCookieHttpOnly() Get session.cookie_httponly StandardConfig
getCookieLifetime() Get session.cookie_lifetime StandardConfig
getCookiePath() Get session.cookie_path StandardConfig
getCookieSecure() Get session.cookie_secure StandardConfig
getEntropyFile() Get session.entropy_file StandardConfig
getEntropyLength() Get session.entropy_length StandardConfig
getGcDivisor() Get session.gc_divisor StandardConfig
getGcMaxlifetime() Get session.gc_maxlifetime StandardConfig
getGcProbability() Get session.gc_probability StandardConfig
getHashBitsPerCharacter() Get session.hash_bits_per_character StandardConfig
getHashFunction() Get session.hash_function StandardConfig
getName() Get session.name StandardConfig
getOption() Get an individual option StandardConfig
getOptions() Get all options set StandardConfig
getRememberMeSeconds() Get remember_me_seconds StandardConfig
getSavePath() Set session.save_path StandardConfig
getSidBitsPerCharacter() Get session.sid_bits_per_character StandardConfig
getSidLength() Get session.sid_length StandardConfig
getStorageOption() Retrieve a storage option from a backend configuration store SessionConfig
getUseCookies() Get session.use_cookies StandardConfig
hasOption() Check to see if an internal option has been set for the key provided. StandardConfig
setCacheExpire() Set session.cache_expire StandardConfig
setCacheLimiter() Set cache limiter SessionConfig
setCookieDomain() Set session.cookie_domain StandardConfig
setCookieHttpOnly() Set session.cookie_httponly StandardConfig
setCookieLifetime() Set session.cookie_lifetime StandardConfig
setCookiePath() Set session.cookie_path StandardConfig
setCookieSecure() Set session.cookie_secure StandardConfig
setEntropyFile() Set session.entropy_file StandardConfig
setEntropyLength() set session.entropy_length StandardConfig
setGcDivisor() Set session.gc_divisor StandardConfig
setGcMaxlifetime() Set gc_maxlifetime StandardConfig
setGcProbability() Set session.gc_probability StandardConfig
setHashBitsPerCharacter() Set session.hash_bits_per_character SessionConfig
setHashFunction() Set session.hash_function SessionConfig
setName() Set session.name StandardConfig
setOption() Override standard option setting. SessionConfig
setOptions() Set many options at once StandardConfig
setPhpSaveHandler() Set session.save_handler SessionConfig
setRememberMeSeconds() Set remember_me_seconds StandardConfig
setSaveHandler() Proxy to setPhpSaveHandler() SessionConfig
setSavePath() Set session.save_path SessionConfig
setSerializeHandler() Set session.serialize_handler SessionConfig
setSidBitsPerCharacter() Set session.sid_bits_per_character SessionConfig
setSidLength() Set session.sid_length StandardConfig
setStorageOption() Set storage option in backend configuration store SessionConfig
setUseCookies() Set session.use_cookies StandardConfig
toArray() Cast configuration to an array StandardConfig

Method Details

__call()

Intercept get*() and set*() methods

Intercepts getters and setters and passes them to getOption() and setOption(), respectively.

Parameter Name Type Description
$method string
$args array

Returns: mixed

getCacheExpire()

Get session.cache_expire

Returns: string

getCookieDomain()

Get session.cookie_domain

Returns: string

getCookieHttpOnly()

Get session.cookie_httponly

Returns: bool

getCookieLifetime()

Get session.cookie_lifetime

Returns: int

getCookiePath()

Get session.cookie_path

Returns: string

getCookieSecure()

Get session.cookie_secure

Returns: bool

getEntropyFile()

Get session.entropy_file

Returns: string

getEntropyLength()

Get session.entropy_length

Returns: string

getGcDivisor()

Get session.gc_divisor

Returns: int

getGcMaxlifetime()

Get session.gc_maxlifetime

Returns: int

getGcProbability()

Get session.gc_probability

Returns: int

getHashBitsPerCharacter()

Get session.hash_bits_per_character

Returns: string

getHashFunction()

Get session.hash_function

Returns: string

getName()

Get session.name

Returns: null|string

getOption()

Get an individual option

Keys are normalized to lowercase. If the option is not found, attempts to retrieve it via {@link getStorageOption()}; if a value is returned from that method, it will be set as the internal value and returned.

Returns null for unfound options

Parameter Name Type Description
$option string

Returns: mixed

getOptions()

Get all options set

Returns: array

getRememberMeSeconds()

Get remember_me_seconds

Returns: int

getSavePath()

Set session.save_path

Returns: string|null

getSidBitsPerCharacter()

Get session.sid_bits_per_character

Returns: string

getSidLength()

Get session.sid_length

Returns: string

getStorageOption()

Retrieve a storage option from a backend configuration store

Used to retrieve default values from a backend configuration store.

Parameter Name Type Description
$storageOption string

Returns: mixed

getUseCookies()

Get session.use_cookies

Returns: bool

hasOption()

Check to see if an internal option has been set for the key provided.

Parameter Name Type Description
$option string

Returns: bool

setCacheExpire()

Set session.cache_expire

Parameter Name Type Description
$cacheExpire int

Returns: \StandardConfig

setCacheLimiter()

Set cache limiter

Parameter Name Type Description
$cacheLimiter
$cacheLimiter

Returns: \SessionConfig

setCookieDomain()

Set session.cookie_domain

Parameter Name Type Description
$cookieDomain string

Returns: \StandardConfig

setCookieHttpOnly()

Set session.cookie_httponly

case sensitive method lookups in setOptions means this method has an unusual casing

Parameter Name Type Description
$cookieHttpOnly bool

Returns: \StandardConfig

setCookieLifetime()

Set session.cookie_lifetime

Parameter Name Type Description
$cookieLifetime int

Returns: \StandardConfig

setCookiePath()

Set session.cookie_path

Parameter Name Type Description
$cookiePath string

Returns: \StandardConfig

setCookieSecure()

Set session.cookie_secure

Parameter Name Type Description
$cookieSecure bool

Returns: \StandardConfig

setEntropyFile()

Set session.entropy_file

Parameter Name Type Description
$entropyFile string

Returns: \StandardConfig

setEntropyLength()

set session.entropy_length

Parameter Name Type Description
$entropyLength int

Returns: \StandardConfig

setGcDivisor()

Set session.gc_divisor

Parameter Name Type Description
$gcDivisor int

Returns: \StandardConfig

setGcMaxlifetime()

Set gc_maxlifetime

Parameter Name Type Description
$gcMaxlifetime int

Returns: \StandardConfig

setGcProbability()

Set session.gc_probability

Parameter Name Type Description
$gcProbability int

Returns: \StandardConfig

setHashBitsPerCharacter()

Set session.hash_bits_per_character

Parameter Name Type Description
$hashBitsPerCharacter int

Returns: \SessionConfig

setHashFunction()

Set session.hash_function

Parameter Name Type Description
$hashFunction string|int

Returns: \SessionConfig

setName()

Set session.name

Parameter Name Type Description
$name string

Returns: \StandardConfig

setOption()

Override standard option setting.

Provides an overload for setting the save handler.

{@inheritDoc}

Parameter Name Type Description
$option
$value

Returns:

setOptions()

Set many options at once

If a setter method exists for the key, that method will be called; otherwise, a standard option will be set with the value provided via {@link setOption()}.

Parameter Name Type Description
$options array|\Traversable

Returns: \StandardConfig

setPhpSaveHandler()

Set session.save_handler

Parameter Name Type Description
$phpSaveHandler string

Returns: \SessionConfig

setRememberMeSeconds()

Set remember_me_seconds

Parameter Name Type Description
$rememberMeSeconds int

Returns: \StandardConfig

setSaveHandler()

Proxy to setPhpSaveHandler()

Prevents calls to setSaveHandler() from hitting setOption() instead, and thus bypassing the logic of setPhpSaveHandler().

Parameter Name Type Description
$phpSaveHandler string

Returns: \SessionConfig

setSavePath()

Set session.save_path

Parameter Name Type Description
$savePath string

Returns: \SessionConfig

setSerializeHandler()

Set session.serialize_handler

Parameter Name Type Description
$serializeHandler string

Returns: \SessionConfig

setSidBitsPerCharacter()

Set session.sid_bits_per_character

Parameter Name Type Description
$sidBitsPerCharacter int

Returns: \SessionConfig

setSidLength()

Set session.sid_length

Parameter Name Type Description
$sidLength int

Returns: \StandardConfig

setStorageOption()

Set storage option in backend configuration store

Parameter Name Type Description
$storageName string
$storageValue mixed

Returns: \SessionConfig

setUseCookies()

Set session.use_cookies

Parameter Name Type Description
$useCookies bool

Returns: \StandardConfig

toArray()

Cast configuration to an array

Returns: array

Top