Definition at line 18 of file ElggSession.php.
 
◆ __construct()
◆ __isset()
      
        
          | ElggSession::__isset  | 
          ( | 
            | 
          $key | ) | 
           | 
        
      
 
Test if property is set either as an attribute or metadata. 
- Parameters
 - 
  
    | string | $key | The name of the attribute or metadata. | 
  
   
- Returns
 - bool 
 
Definition at line 275 of file ElggSession.php.
 
 
◆ del()
◆ generateSessionToken()
  
  
      
        
          | ElggSession::generateSessionToken  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
protected   | 
  
 
Adds a token to the session. 
This is used in creation of CSRF token
- Returns
 - void 
 
Definition at line 260 of file ElggSession.php.
 
 
◆ get()
      
        
          | ElggSession::get  | 
          ( | 
            | 
          $name,  | 
        
        
           | 
           | 
            | 
          $default = null  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Get an attribute of the session. 
- Parameters
 - 
  
    | string | $name | Name of the attribute to get  | 
    | mixed | $default | Value to return if attribute is not set (default is null)  | 
  
   
- Returns
 - mixed 
 
Definition at line 136 of file ElggSession.php.
 
 
◆ getId()
Get the session ID. 
- Returns
 - string 
 
- Since
 - 1.9 
 
Definition at line 93 of file ElggSession.php.
 
 
◆ getLoggedInUser()
      
        
          | ElggSession::getLoggedInUser  | 
          ( | 
           | ) | 
           | 
        
      
 
Gets the logged in user. 
- Returns
 - \ElggUser 
 
- Since
 - 1.9 
 
Definition at line 203 of file ElggSession.php.
 
 
◆ getLoggedInUserGuid()
      
        
          | ElggSession::getLoggedInUserGuid  | 
          ( | 
           | ) | 
           | 
        
      
 
 
◆ getName()
Get the session name. 
- Returns
 - string 
 
- Since
 - 1.9 
 
Definition at line 114 of file ElggSession.php.
 
 
◆ has()
      
        
          | ElggSession::has  | 
          ( | 
            | 
          $name | ) | 
           | 
        
      
 
Has the attribute been defined. 
- Parameters
 - 
  
    | string | $name | Name of the attribute  | 
  
   
- Returns
 - bool 
 
- Since
 - 1.9 
 
Definition at line 181 of file ElggSession.php.
 
 
◆ invalidate()
      
        
          | ElggSession::invalidate  | 
          ( | 
           | ) | 
           | 
        
      
 
Invalidates the session. 
Deletes session data and session persistence. Starts a new session.
- Returns
 - boolean 
 
- Since
 - 1.9 
 
Definition at line 69 of file ElggSession.php.
 
 
◆ isAdminLoggedIn()
      
        
          | ElggSession::isAdminLoggedIn  | 
          ( | 
           | ) | 
           | 
        
      
 
Returns whether or not the viewer is currently logged in and an admin user. 
- Returns
 - bool 
 
Definition at line 227 of file ElggSession.php.
 
 
◆ isLoggedIn()
      
        
          | ElggSession::isLoggedIn  | 
          ( | 
           | ) | 
           | 
        
      
 
Returns whether or not the user is currently logged in. 
- Returns
 - bool 
 
Definition at line 238 of file ElggSession.php.
 
 
◆ isStarted()
      
        
          | ElggSession::isStarted  | 
          ( | 
           | ) | 
           | 
        
      
 
Has the session been started. 
- Returns
 - boolean 
 
- Since
 - 1.9 
 
Definition at line 83 of file ElggSession.php.
 
 
◆ migrate()
      
        
          | ElggSession::migrate  | 
          ( | 
            | 
          $destroy = false | ) | 
           | 
        
      
 
Migrates the session to a new session id while maintaining session attributes. 
- Parameters
 - 
  
    | boolean | $destroy | Whether to delete the session or let gc handle clean up  | 
  
   
- Returns
 - boolean 
 
- Since
 - 1.9 
 
Definition at line 57 of file ElggSession.php.
 
 
◆ offsetExists()
      
        
          | ElggSession::offsetExists  | 
          ( | 
            | 
          $offset | ) | 
           | 
        
      
 
Return whether the value is set in either the session or the cache. 
- See also
 - \ArrayAccess::offsetExists()
 
- Parameters
 - 
  
  
 
- Returns
 - bool 
 
Definition at line 368 of file ElggSession.php.
 
 
◆ offsetGet()
      
        
          | ElggSession::offsetGet  | 
          ( | 
            | 
          $key | ) | 
           | 
        
      
 
Get a variable from either the session, or if its not in the session attempt to get it from an api call. 
- See also
 - \ArrayAccess::offsetGet()
 
- Parameters
 - 
  
  
 
- Returns
 - mixed 
 
Definition at line 306 of file ElggSession.php.
 
 
◆ offsetSet()
      
        
          | ElggSession::offsetSet  | 
          ( | 
            | 
          $key,  | 
        
        
           | 
           | 
            | 
          $value  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Set a value, go straight to session. 
- Parameters
 - 
  
    | string | $key | Name  | 
    | mixed | $value | Value | 
  
   
- Returns
 - void 
 
Definition at line 290 of file ElggSession.php.
 
 
◆ offsetUnset()
      
        
          | ElggSession::offsetUnset  | 
          ( | 
            | 
          $key | ) | 
           | 
        
      
 
Unset a value from the cache and the session. 
- See also
 - \ArrayAccess::offsetUnset()
 
- Parameters
 - 
  
  
 
- Returns
 - void 
 
Definition at line 353 of file ElggSession.php.
 
 
◆ remove()
      
        
          | ElggSession::remove  | 
          ( | 
            | 
          $name | ) | 
           | 
        
      
 
Remove an attribute. 
- Parameters
 - 
  
    | string | $name | The name of the attribute to remove  | 
  
   
- Returns
 - mixed The removed attribute 
 
- Since
 - 1.9 
 
Definition at line 158 of file ElggSession.php.
 
 
◆ removeLoggedInUser()
      
        
          | ElggSession::removeLoggedInUser  | 
          ( | 
           | ) | 
           | 
        
      
 
Remove the logged in user. 
- Returns
 - void 
 
- Since
 - 1.9 
 
Definition at line 248 of file ElggSession.php.
 
 
◆ set()
      
        
          | ElggSession::set  | 
          ( | 
            | 
          $name,  | 
        
        
           | 
           | 
            | 
          $value  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Set an attribute. 
- Parameters
 - 
  
    | string | $name | Name of the attribute to set  | 
    | mixed | $value | Value to be set  | 
  
   
- Returns
 - void 
 
Definition at line 147 of file ElggSession.php.
 
 
◆ setId()
      
        
          | ElggSession::setId  | 
          ( | 
            | 
          $id | ) | 
           | 
        
      
 
Set the session ID. 
- Parameters
 - 
  
  
 
- Returns
 - void 
 
- Since
 - 1.9 
 
Definition at line 104 of file ElggSession.php.
 
 
◆ setLoggedInUser()
      
        
          | ElggSession::setLoggedInUser  | 
          ( | 
          \ElggUser  | 
          $user | ) | 
           | 
        
      
 
Sets the logged in user. 
- Parameters
 - 
  
    | \ElggUser | $user | The user who is logged in  | 
  
   
- Returns
 - void 
 
- Since
 - 1.9 
 
Definition at line 192 of file ElggSession.php.
 
 
◆ setName()
      
        
          | ElggSession::setName  | 
          ( | 
            | 
          $name | ) | 
           | 
        
      
 
Set the session name. 
- Parameters
 - 
  
  
 
- Returns
 - void 
 
- Since
 - 1.9 
 
Definition at line 125 of file ElggSession.php.
 
 
◆ start()
Start the session. 
- Returns
 - boolean 
 
- Exceptions
 - 
  
    | RuntimeException | If session fails to start.  | 
  
   
- Since
 - 1.9 
 
Definition at line 44 of file ElggSession.php.
 
 
◆ $loggedInUser
  
  
      
        
          | ElggSession::$loggedInUser | 
         
       
   | 
  
protected   | 
  
 
 
◆ $storage
The documentation for this class was generated from the following file: