ultimix

- Main Page
- Data Structures
- Files
- Examples

- Data Structures
- Data Structure Index
- Data Fields

Public Member Functions | Data Fields
user_access_utilities_1_0_0 Class Reference

## Public Member Functions
| __construct ()
| rise_create_event ($Login, $id)
| rise_activate_event ($Login, $id)
| rise_deactivate_event ($id)
| rise_update_event ($id)
| handle_update_record (&$Record)

## Data Fields
| $NativeTable = '`umx_user`'
| $GuestUserId = 2
| $Database = false
| $DatabaseAlgorithms = false
| $Security = false
| $SecurityParser = false
| $UsersCache = array()

## Detailed Description

Class for authentification.

Author
  Dodonov A.A.

Definition at line 26 of file user_access_utilities.php.

## Constructor & Destructor Documentation

__construct | ( |  | ) |

Constructor.

Author
  Dodonov A.A.

Definition at line 89 of file user_access_utilities.php.

{
try
{
$this->Database = get_package( 'database' , 'last' , __FILE__ );
$this->DatabaseAlgorithms = get_package( 'database::database_algorithms' , 'last' , __FILE__ );
$this->Security = get_package( 'security' , 'last' , __FILE__ );
$this->SecurityParser = get_package( 'security::security_parser' , 'last' , __FILE__ );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

## Member Function Documentation

handle_update_record | ( | & | $Record | ) |

Function returns update data.

Parameters

  $Record | - Example for update.

Returns
  array( $Fields , $Values ).

Exceptions

  Exception | An exception of this type is thrown.

Author
  Dodonov A.A.

Definition at line 395 of file user_access_utilities.php.

{
try
{
$Fields = $Values = array();
foreach( $Record as $f => $v )
{
switch( $f )
{
case( 'sex' ):
$this->UserAccessUtilieis->handle_sex_field( $Fields , $Values , $v );
break;
case( 'active' ):
$this->handle_active_field( $Fields , $Values , $v );
break;
case( 'password' ):
$this->handle_password_field( $Fields , $Values , $v );
break;
default:
$Fields [] = $f;
$Values [] = "'$v'";
break;
}
}
return( array( $Fields , $Values ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

rise_activate_event | ( |  | $Login,
|  |  | $id
| ) |  |

Function rises event.

Parameters

  $Login | - Login of the deleting user.
  $id | - id of the created user.

Exceptions

  Exception | An exception of this type is thrown.

Author
  Dodonov A.A.

Definition at line 162 of file user_access_utilities.php.

{
try
{
$EventManager = get_package( 'event_manager' , 'last' , __FILE__ );
$EventManager->trigger_event( 'on_after_activate_user' , array( 'login' => $Login , 'id' => $id ) );
$EventManager->trigger_event( 'anonimous' , array( 'master_id' => $id , 'master_type' => 'user' ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

rise_create_event | ( |  | $Login,
|  |  | $id
| ) |  |

Function rises event.

Parameters

  $Login | - Login of the deleting user.
  $id | - id of the created user.

Exceptions

  Exception | An exception of this type is thrown.

Author
  Dodonov A.A.

Definition at line 126 of file user_access_utilities.php.

{
try
{
$EventManager = get_package( 'event_manager' , 'last' , __FILE__ );
$EventManager->trigger_event( 'on_after_create_user' , array( 'login' => $Login , 'id' => $id ) );
$EventManager->trigger_event( 'anonimous' , array( 'master_id' => $id , 'master_type' => 'user' ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

rise_deactivate_event | ( |  | $id | ) |

Function rises event.

Parameters

  $id | - id of the created user.

Exceptions

  Exception | An exception of this type is thrown.

Author
  Dodonov A.A.

Definition at line 194 of file user_access_utilities.php.

{
try
{
$EventManager = get_package( 'event_manager' , 'last' , __FILE__ );
$EventManager->trigger_event( 'on_after_deactivate_user' , array( 'id' => $id ) );
$EventManager->trigger_event( 'anonimous' , array( 'master_id' => $id , 'master_type' => 'user' ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

rise_update_event | ( |  | $id | ) |

Function rises event.

Parameters

  $id | - id of the created user.

Exceptions

  Exception | An exception of this type is thrown.

Author
  Dodonov A.A.

Definition at line 226 of file user_access_utilities.php.

{
try
{
$EventManager = get_package( 'event_manager' , 'last' , __FILE__ );
$EventManager->trigger_event( 'on_after_update_user' , array( 'id' => $id ) );
$EventManager->trigger_event( 'anonimous' , array( 'master_id' => $id , 'master_type' => 'user' ) );
}
catch( Exception $e )
{
$a = func_get_args();_throw_exception_object( __METHOD__ , $a , $e );
}
}

## Field Documentation

$Database = false

Cached objects.

Author
  Dodonov A.A.

Definition at line 62 of file user_access_utilities.php.

$DatabaseAlgorithms = false

Definition at line 63 of file user_access_utilities.php.

$GuestUserId = 2

Guest's id.

Author
  Dodonov A.A.

Definition at line 50 of file user_access_utilities.php.

$NativeTable = '`umx_user`'

Table name in wich objects of this entity are stored.

Author
  Dodonov A.A.

Definition at line 38 of file user_access_utilities.php.

$Security = false

Definition at line 64 of file user_access_utilities.php.

$SecurityParser = false

Definition at line 65 of file user_access_utilities.php.

$UsersCache = array()

Cache of users.

Author
  Dodonov A.A.

Definition at line 77 of file user_access_utilities.php.

The documentation for this class was generated from the following file:

- packages/user/packages/user_access/packages/user_access_utilities/user_access_utilities.php