Session handler class.
Methods
- __construct — Constructor for the session class.
- cleanup_sessions — Cleanup session data from the database and clear caches.
- delete_session — Delete the session from the cache and database.
- destroy_session — Destroy all session data.
- generate_customer_id — Generate a unique customer ID for guests, or return user ID if logged in.
- get_cache_prefix — Gets a cache prefix. This is used in session names so the entire cache can be invalidated with 1 function call.
- get_session — Returns the session.
- get_session_cookie — Get the session cookie, if set. Otherwise return false.
- get_session_data — Get session data.
- has_session — Return true if the current user has an active session, i.e. a cookie to retrieve values.
- init — Init hooks and session data.
- nonce_user_logged_out — When a user is logged out, ensure they have a unique nonce by using the customer/session ID.
- save_data — Save data.
- set_session_expiration — Set session expiration.
- update_session_timestamp — Update the session expiry timestamp.