Session Trait

trait SessionTrait

Warning

SESSIONS WILL BE REMOVED FROM Agile core IN THE FUTURE.

Introduction

not yet implemented

Properties

property SessionTrait::$session_key

Internal property to make sure that all session data will be stored in one “container” (array key).

Methods

SessionTrait::startSession($options =[])

Create new session.

SessionTrait::destroySession()

Destroy existing session.

SessionTrait::memorize($key, $value)

Remember data in object-relevant session data.

SessionTrait::learn($key, $default = null)

Similar to memorize, but if value for key exist, will return it.

SessionTrait::recall($key, $default = null)

Returns session data for this object. If not previously set, then $default is returned.

SessionTrait::forget($key = null)

Forget session data for arg $key. If $key is omitted will forget all associated session data.