[ Index ] |
|
Code source de PRADO 3.0.6 |
[Code source] [Imprimer] [Statistiques]
TUserManager class
Author: | Qiang Xue <qiang.xue@gmail.com> |
Copyright: | Copyright © 2005 PradoSoft |
License: | http://www.pradosoft.com/license/ |
Version: | $Id: TUserManager.php 1397 2006-09-07 07:55:53Z wei $ |
Poids: | 283 lignes (8 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
TUserManager:: (13 méthodes):
init()
loadUserData()
getUsers()
getRoles()
getUserFile()
setUserFile()
getGuestName()
setGuestName()
getPasswordMode()
setPasswordMode()
validateUser()
getUser()
switchToGuest()
TUserManagerPasswordMode:: (0 méthodes):
Classe: TUserManager - X-Ref
TUserManager classinit($config) X-Ref |
Initializes the module. This method is required by IModule and is invoked by application. It loads user/role information from the module configuration. param: TXmlElement module configuration |
loadUserData($xmlNode) X-Ref |
Loads user/role information from an XML node. param: TXmlElement the XML node containing the user information |
getUsers() X-Ref |
Returns an array of all users. Each array element represents a single user. The array key is the username in lower case, and the array value is the corresponding user password. return: array list of users |
getRoles() X-Ref |
Returns an array of user role information. Each array element represents the roles for a single user. The array key is the username in lower case, and the array value is the roles (represented as an array) that the user is in. return: array list of user role information |
getUserFile() X-Ref |
return: string the full path to the file storing user/role information |
setUserFile($value) X-Ref |
param: string user/role data file path (in namespace form). The file format is XML |
getGuestName() X-Ref |
return: string guest name, defaults to 'Guest' |
setGuestName($value) X-Ref |
param: string name to be used for guest users. |
getPasswordMode() X-Ref |
return: TUserManagerPasswordMode how password is stored, clear text, or MD5 or SHA1 hashed. Default to TUserManagerPasswordMode::MD5. |
setPasswordMode($value) X-Ref |
param: TUserManagerPasswordMode how password is stored, clear text, or MD5 or SHA1 hashed. |
validateUser($username,$password) X-Ref |
Validates if the username and password are correct. param: string user name param: string password return: boolean true if validation is successful, false otherwise. |
getUser($username=null) X-Ref |
Returns a user instance given the user name. param: string user name, null if it is a guest. return: TUser the user instance, null if the specified username is not in the user database. |
switchToGuest($user) X-Ref |
Sets a user as a guest. User name is changed as guest name, and roles are emptied. param: TUser the user to be changed to a guest. |
Classe: TUserManagerPasswordMode - X-Ref
TUserManagerPasswordMode class.Généré le : Sun Feb 25 21:07:04 2007 | par Balluche grâce à PHPXref 0.7 |