WeakWiki


WeakWiki\User
lib\uc.library.php at line 99

Class User

User

public class User

This class represents a system user.


Method Summary
void

__construct(str uid, mixed level, str fullname, str email, str comment)

Creates a new instance of the class.

void

changePassword(mixed password, mixed repeat, mixed current)

Changes the user password.

void

delete()

Deletes the user object.

void

deserialize(mixed string, bool phashonly)

Deserializes a serialized object string into the user object.

void

getComment()

Returns the comment.

void

getEMail()

Returns the user's e-mail address.

void

getErrorState()

Returns the error state code of the last operation.

void

getFullName()

Returns the user's full name.

void

getLevel()

Returns the user's permission level.

void

getUID()

Returns the user ID.

void

read(mixed uid, bool phashonly)

Reads user object from file.

void

serialize(mixed password, mixed mode)

Serializes the user object into a string.

void

update(mixed uid, mixed password, mixed level, mixed fullname, mixed email, mixed comment, mixed mode)

Writes user object to file.

void

verifyPassword(mixed password)

Verifies a user's password.

Method Detail

lib\uc.library.php at line 145

__construct

public void __construct(str uid, mixed level, str fullname, str email, str comment)

Creates a new instance of the class. @param $uid User ID. Alternatively this will take a serialized user object. @param $level Permission level. @param $fullname Full name. @param $email e-mail address. @param $comment Comment.


lib\uc.library.php at line 326

changePassword

public void changePassword(mixed password, mixed repeat, mixed current)

Changes the user password. @param $password New password. @return Error code state.


lib\uc.library.php at line 350

delete

public void delete()

Deletes the user object. @return Error code state.


lib\uc.library.php at line 205

deserialize

public void deserialize(mixed string, bool phashonly)

Deserializes a serialized object string into the user object. @param $string Serialized object string. @param $phashonly Forces to read only the password hash.


lib\uc.library.php at line 392

getComment

public void getComment()

Returns the comment. @return Comment.


lib\uc.library.php at line 384

getEMail

public void getEMail()

Returns the user's e-mail address. @return e-mail address.


lib\uc.library.php at line 436

getErrorState

public void getErrorState()

Returns the error state code of the last operation. @return Error state code.


lib\uc.library.php at line 376

getFullName

public void getFullName()

Returns the user's full name. @return Full name.


lib\uc.library.php at line 400

getLevel

public void getLevel()

Returns the user's permission level. @return Permission level.


lib\uc.library.php at line 368

getUID

public void getUID()

Returns the user ID. @return User ID.


lib\uc.library.php at line 225

read

public void read(mixed uid, bool phashonly)

Reads user object from file. @param $uid User ID. @param $phashonly Forces to read only the password hash.


lib\uc.library.php at line 182

serialize

public void serialize(mixed password, mixed mode)

Serializes the user object into a string. @param $password Password. @param $mode Mode. @return Serialized object string.


lib\uc.library.php at line 250

update

public void update(mixed uid, mixed password, mixed level, mixed fullname, mixed email, mixed comment, mixed mode)

Writes user object to file. @param $uid User ID. @param $password Password. @param $level Permission level. @param $fullname Full name. @param $email e-mail address. @param $comment Comment. @param $mode Flags the operation mode (update/change password) @return Error code state.


lib\uc.library.php at line 407

verifyPassword

public void verifyPassword(mixed password)

Verifies a user's password.


WeakWiki