original_string: public function GetForRole($RoleID = '', $Offset = '0', $Limit = '50') {
        if (!is_array($RoleID))
           $RoleID = array($RoleID);
        
        $Offset = is_numeric($Offset) ? $Offset : 0;
        if ($Offset < 0)
           $Offset = 0;
  
        $Limit = is_numeric($Limit) ? $Limit : 0;
        if ($Limit < 0)
           $Limit = 0;
        
        $this->ActivityQuery();
        $Result = $this->SQL
           ->Join('UserRole ur', 'a.ActivityUserID = ur.UserID')
           ->WhereIn('ur.RoleID', $RoleID)
           ->Where('t.Public', '1')
           ->OrderBy('a.DateInserted', 'desc')
           ->Limit($Limit, $Offset)
           ->Get();
           
        $this->EventArguments['Data'] =& $Result;
        $this->FireEvent('AfterGet');
        
        return $Result;
     }
code: public function GetForRole($RoleID = '', $Offset = '0', $Limit = '50') {
        if (!is_array($RoleID))
           $RoleID = array($RoleID);
        
        $Offset = is_numeric($Offset) ? $Offset : 0;
        if ($Offset < 0)
           $Offset = 0;
  
        $Limit = is_numeric($Limit) ? $Limit : 0;
        if ($Limit < 0)
           $Limit = 0;
        
        $this->ActivityQuery();
        $Result = $this->SQL
           ->Join('UserRole ur', 'a.ActivityUserID = ur.UserID')
           ->WhereIn('ur.RoleID', $RoleID)
           ->Where('t.Public', '1')
           ->OrderBy('a.DateInserted', 'desc')
           ->Limit($Limit, $Offset)
           ->Get();
           
        $this->EventArguments['Data'] =& $Result;
        $this->FireEvent('AfterGet');
        
        return $Result;
     }
code_tokens: public function GetForRole ( $ RoleID = '' , $ Offset = '0' , $ Limit = '50' ) { if ( ! is_array ( $ RoleID ) ) $ RoleID = array ( $ RoleID ) ; $ Offset = is_numeric ( $ Offset ) ? $ Offset : 0 ; if ( $ Offset < 0 ) $ Offset = 0 ; $ Limit = is_numeric ( $ Limit ) ? $ Limit : 0 ; if ( $ Limit < 0 ) $ Limit = 0 ; $ this -> ActivityQuery ( ) ; $ Result = $ this -> SQL -> Join ( 'UserRole ur' , 'a.ActivityUserID = ur.UserID' ) -> WhereIn ( 'ur.RoleID' , $ RoleID ) -> Where ( 't.Public' , '1' ) -> OrderBy ( 'a.DateInserted' , 'desc' ) -> Limit ( $ Limit , $ Offset ) -> Get ( ) ; $ this -> EventArguments [ 'Data' ] = & $ Result ; $ this -> FireEvent ( 'AfterGet' ) ; return $ Result ; }
docstring: Get activity related to a particular role.
  
  Events: AfterGet.
  
  @since 2.0.18
  @access public
  @param string $RoleID Unique ID of role.
  @param int $Offset Number to skip.
  @param int $Limit Max number to return.
  @return DataSet SQL results.
docstring_tokens: Get activity related to a particular role .