Scalr\Model\Entity\Account\User::getEmail PHP Method

getEmail() public method

Gets email address of the User
public getEmail ( ) : string
return string Returns user email address
    public function getEmail()
    {
        return $this->email;
    }

Usage Example

Example #1
0
 /**
  * Prepares extra data to pass to a backend
  * Those include RUID, EUID, AccountID, environment etc.
  *
  * @return array Prepared extra data for logging
  */
 protected function getCommonData()
 {
     $data = empty($this->user) ? ["login" => $this->systemTask ? '_' . $this->systemTask : 'guest', "ruid" => null, "euid" => null, "env_id" => $this->envId ?: 0, "account_id" => $this->accountId] : ["login" => $this->user->getEmail(), "ruid" => $this->realUserId ?: $this->user->id, "euid" => $this->user->id, "env_id" => $this->envId ?: 0, "account_id" => empty($this->accountId) ? $this->user->getAccountId() : $this->accountId];
     $data['ip_address'] = $this->ipAddress;
     $data['timestamp'] = AuditLogger::getTimestamp();
     $data['request_type'] = $this->requestType;
     return $data;
 }
All Usage Examples Of Scalr\Model\Entity\Account\User::getEmail