Class Account

Description

Model is used to creating account.

  • author: Libor Tichy

Located in /Application/AccountModel.php (line 15)

NObject
   |
   --Account
Variable Summary
int $created
int $deleted
int $id
string $login
string $name
string $path
string $picture
int $role
Method Summary
static string block (array $id)
static boolean exist (FormItem $item)
static string makePassword (string $word)
static boolean sendLogin (string $login)
static string unblock (array $id)
Account __construct ([ $userId = null])
string save (array 0)
void setEmail (string $email)
void setLogin (string $login)
void setName (string $name)
void setPassword (string $password)
string setPicture (string $image)
void setRole (int $role)
mixed &__get (string $item)
Variables
int $character_id (line 24)
  • access: public
int $created (line 34)
  • access: public
int $deleted (line 36)
  • access: public
int $id (line 22)
  • access: public
string $login (line 28)
  • access: public
string $name (line 26)
  • access: public
string $path = "/game/www/up/" (line 20)
  • access: public
string $picture = "default.png" (line 18)
  • access: public
int $role (line 32)
  • access: public
Methods
static block (line 73)

Block the account.

  • access: public
static string block (array $id)
  • array $id
static exist (line 223)

Check if the user already exists in DB.

  • access: public
static boolean exist (FormItem $item)
  • FormItem $item
static makePassword (line 145)

Create the hash of the password.

  • access: public
static string makePassword (string $word)
  • string $word
static sendLogin (line 155)

Send email to recipient, if he exists in DB.

  • throws: Exception
  • access: public
static boolean sendLogin (string $login)
  • string $login
static unblock (line 82)

Unblock the account.

  • access: public
static string unblock (array $id)
  • array $id
Constructor __construct (line 40)
  • access: public
Account __construct ([ $userId = null])
  • $userId
save (line 191)

Create the user and his character.

  • access: public
string save (array 0)
  • array 0
setEmail (line 100)

Set accont email address. Unused!

  • access: public
void setEmail (string $email)
  • string $email
setLogin (line 118)

Set accont login.

  • access: public
void setLogin (string $login)
  • string $login
setName (line 127)

Set account name. Unused!

  • access: public
void setName (string $name)
  • string $name
setPassword (line 109)

Set accont password.

  • access: public
void setPassword (string $password)
  • string $password
setPicture (line 61)

Change the image of account.

  • throws: Exception
  • access: public
string setPicture (string $image)
  • string $image
setRole (line 91)

Set accont role.

  • access: public
void setRole (int $role)
  • int $role
__get (line 255)

Returns user data value.

  • access: public
mixed &__get (string $item)
  • string $item: property name

Documentation generated on Tue, 07 Jun 2011 20:47:26 +0200 by phpDocumentor 1.4.3