Session handler base.
Copyright: | 2013 Petr Skoda {@link http://skodak.org} |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 117 lines (4 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
handler:: (5 methods):
start()
write_close()
abort()
set_requires_write_lock()
requires_write_lock()
start() X-Ref |
Start the session. return: bool success |
write_close() X-Ref |
Write the session and release lock. If the session was not intentionally opened with a write lock, then we will abort the session instead if able. |
abort() X-Ref |
Release lock on the session without writing it. May not be possible in older versions of PHP. If so, session may be written anyway so that any locks are released. |
set_requires_write_lock($requireswritelock) X-Ref |
This is called after init() and before start() to indicate whether the session opened should be writable or not. This is intentionally captured even if your handler doesn't support non-locking sessions, so that behavior (upon session close) matches closely between handlers. param: bool $requireswritelock true if needs to be open for writing |
requires_write_lock() X-Ref |
Has this session been opened with a writelock? Your handler should call this during start() if you support read-only sessions. return: bool true if session is intended to have a write lock. |