interface SessionProxy_Storage_Interface in Session Proxy 7
Storage implementation must be able to index all session using the owner user identifier: this complexify the session handling but allow aggresive optimizations.
Hierarchy
- interface \SessionProxy_Storage_Interface
Expanded class hierarchy of SessionProxy_Storage_Interface
All classes that implement SessionProxy_Storage_Interface
File
- lib/
SessionProxy/ Storage/ Interface.php, line 8
View source
interface SessionProxy_Storage_Interface {
public function open();
public function close();
public function read($sessionId);
public function write($sessionId, $serializedData);
public function destroy($sessionId);
public function gc($lifetime);
/**
* Get the logged in user identifier, if any. In all cases, this will be
* called after read();
*
* @return int
* Valid user identifier or NULL.
*/
public function getSessionUid();
/**
* When session has been regenerated, inform the storage backend that further
* session writing will be done for a new user identenfier.
*
* @param int $uid
*/
public function setSessionUid($uid);
/**
* Destroy all known sessions using the given conditions.
*
* This function implementation is optional, garbage collector should be
* enough for session destruction in most cases.
*
* Implement this function will only improve performances, it is important
* that it should remain silent if you cannot handle the given parameters.
*
* @param string $index
* Potential session index key, such as 'uid'.
* @param mixed $value
* Potential session index value, such as an integer for 'uid'.
*/
public function destroyFor($index, $value);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
SessionProxy_Storage_Interface:: |
public | function | 2 | |
SessionProxy_Storage_Interface:: |
public | function | 2 | |
SessionProxy_Storage_Interface:: |
public | function | Destroy all known sessions using the given conditions. | 2 |
SessionProxy_Storage_Interface:: |
public | function | 2 | |
SessionProxy_Storage_Interface:: |
public | function | Get the logged in user identifier, if any. In all cases, this will be called after read(); | 1 |
SessionProxy_Storage_Interface:: |
public | function | 2 | |
SessionProxy_Storage_Interface:: |
public | function | 2 | |
SessionProxy_Storage_Interface:: |
public | function | When session has been regenerated, inform the storage backend that further session writing will be done for a new user identenfier. | 1 |
SessionProxy_Storage_Interface:: |
public | function | 2 |