Models an event passed to event handlers.  
 More...
Models an event passed to event handlers. 
- Since
 - 2.0.0 
 
Definition at line 11 of file Event.php.
 
◆ __construct()
      
        
          | Elgg\Event::__construct  | 
          ( | 
          protected PublicContainer  | 
          $dic,  | 
        
        
           | 
           | 
          protected string  | 
          $name,  | 
        
        
           | 
           | 
          protected string  | 
          $type,  | 
        
        
           | 
           | 
          protected  | 
          $value = null,  | 
        
        
           | 
           | 
          protected  | 
          $params = []  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Constructor. 
- Parameters
 - 
  
    | PublicContainer | $dic | DI container  | 
    | string | $name | Event name  | 
    | string | $type | Event type  | 
    | mixed | $value | Event value  | 
    | mixed | $params | Event params  | 
  
   
Definition at line 22 of file Event.php.
 
 
◆ elgg()
Get the DI container. 
- Returns
 - PublicContainer 
 
Definition at line 136 of file Event.php.
 
 
◆ getEntityParam()
      
        
          | Elgg\Event::getEntityParam  | 
          ( | 
           | ) | 
           | 
        
      
 
Gets the "entity" key from the params if it holds an ElggEntity. 
- Returns
 - \ElggEntity|null 
 
Definition at line 110 of file Event.php.
 
 
◆ getName()
Get the name of the event. 
- Returns
 - string 
 
Definition at line 36 of file Event.php.
 
 
◆ getObject()
      
        
          | Elgg\Event::getObject  | 
          ( | 
           | ) | 
           | 
        
      
 
Get the object of the event. 
- Returns
 - mixed 
 
Definition at line 54 of file Event.php.
 
 
◆ getParam()
      
        
          | Elgg\Event::getParam  | 
          ( | 
          string  | 
          $key,  | 
        
        
           | 
           | 
            | 
          $default = null  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
Get an element of the params array. 
If the params array is not an array, the default will always be returned.
- Parameters
 - 
  
    | string | $key | The key of the value in the params array  | 
    | mixed | $default | The value to return if missing | 
  
   
- Returns
 - mixed 
 
Definition at line 97 of file Event.php.
 
 
◆ getParams()
      
        
          | Elgg\Event::getParams  | 
          ( | 
           | ) | 
           | 
        
      
 
Get the parameters passed to the trigger call. 
- Returns
 - mixed 
 
Definition at line 84 of file Event.php.
 
 
◆ getSequenceID()
      
        
          | Elgg\Event::getSequenceID  | 
          ( | 
           | ) | 
           | 
        
      
 
When the event is part of a sequence a unique ID is set for each sequence. 
- Returns
 - string|null 
 
Definition at line 145 of file Event.php.
 
 
◆ getType()
Get the type of the event object. 
- Returns
 - string 
 
Definition at line 45 of file Event.php.
 
 
◆ getUserParam()
      
        
          | Elgg\Event::getUserParam  | 
          ( | 
           | ) | 
           | 
        
      
 
Gets the "user" key from the params if it holds an ElggUser. 
- Returns
 - \ElggUser|null 
 
Definition at line 123 of file Event.php.
 
 
◆ getValue()
Get the current value of the event. 
- Returns
 - mixed 
 
Definition at line 63 of file Event.php.
 
 
◆ setValue()
      
        
          | Elgg\Event::setValue  | 
          ( | 
            | 
          $value | ) | 
           | 
        
      
 
Update the value. 
- Parameters
 - 
  
  
 
- Returns
 - void 
 
Definition at line 75 of file Event.php.
 
 
The documentation for this class was generated from the following file: