Class Identity (namespace Nette\Security)


Default implementation of IIdentity.

Object
   |
   --FreezableObject
      |
      --Identity

Implements interfaces:

Author: David Grudl
Copyright: Copyright (c) 2004, 2009 David Grudl
Located: in /Security/Identity.php (line 39)
Public Method Summary
Identity
__construct (string $name, [mixed $roles = NULL], [array $data = NULL])
array
getData ()
Returns an user data.
string
getName ()
Returns the name of user.
array
Returns a list of roles that the user is a member of.
void
setName (string $name)
Sets the name of user.
void
setRoles ($roles)
Sets a list of roles that the user is a member of.
& mixed
__get (string $key)
Returns user data value.
void
__set (string $key, mixed $value)
Sets user data value.
Methods Inherited From FreezableObject
freeze(), isFrozen(), updating(), __clone()
Methods Inherited From Object
extensionMethod(), getClass(), getReflection(), __call(), __callStatic(), __get(), __isset(), __set(), __unset()

Method Details

line 56

__construct

public Identity __construct (string $name, [mixed $roles = NULL], [array $data = NULL])

Input
string $name identity name
mixed $roles roles
array $data user data
Output
Identity  

line 117

getData

public array getData ()

Returns an user data.

Output
array  

line 82

getName

public string getName ()

Returns the name of user.

Implementation of:

Output
string  

line 106

getRoles

public array getRoles ()

Returns a list of roles that the user is a member of.

Implementation of:

Output
array  

line 70

setName

public void setName (string $name)

Sets the name of user.

Input
string $name
Output
void  

line 94

setRoles

public void setRoles ($roles)

Sets a list of roles that the user is a member of.

Input
$roles
Output
void  

line 148

__get

public mixed & __get (string $key)

Returns user data value.

Input
string $key property name
Output
& mixed  

line 130

__set

public void __set (string $key, mixed $value)

Sets user data value.

Input
string $key property name
mixed $value property value
Output
void