Manage user accounts file. More...
Public Member Functions | |
| def | __init__ |
| def | add |
| def | find |
| def | modif |
| def | remove |
| def | resolve_path |
| def | update |
| def | user_list |
Public Attributes | |
| accounts_dir | |
| accounts_xml | |
Static Public Attributes | |
| string | ACCOUNTS_FILENAME = 'accounts.db' |
| string | CREATED = 'created' |
| string | MODIFIED = 'modified' |
| string | PASSWORD = 'password' |
| string | PRIVILEGE = 'privilege' |
| string | UID = 'id' |
| string | USER = 'user' |
| string | USER_STR_ITEM |
Private Member Functions | |
| def | _xml_file_generator |
Manage user accounts file.
Manage user account file xml:
- Get user list
- Find user account,
- Add user account,
- Modif user account,
- Remove user account.
Definition at line 183 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.__init__ | ( | self | ) |
Constructor
Definition at line 210 of file accounts.py.
|
private |
Definition at line 253 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.add | ( | self, | |
| userinfo | |||
| ) |
Add new user account in "accounts.db" file.
@param: userinfo: user informations.
@type userinfo: C{User}.
Definition at line 303 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.find | ( | self, | |
| userid | |||
| ) |
Read and get user account information
@param: userid: user id.
@type userid: str.
@return: userinfo: user informations.
@type userinfo: C{User}.
Definition at line 277 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.modif | ( | self, | |
| usersource, | |||
| usermodifed | |||
| ) |
Update user informations.
@param: usersource: current user informations.
@type usersource: C{User}.
@param: usermodifed: new user informations.
@type usermodifed: C{User}.
Definition at line 333 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.remove | ( | self, | |
| userinfo | |||
| ) |
Remove user account.
@param: userinfo: user informations.
@type userinfo: C{User}.
Definition at line 366 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.resolve_path | ( | self, | |
| userid | |||
| ) |
Definition at line 262 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.update | ( | self | ) |
Definition at line 234 of file accounts.py.
| def airbus_cobot_gui.account.accounts.UserAccounts.user_list | ( | self | ) |
Read and get user(s) id list registered in user accounts file @return: user_list: user(s) id list. @type user_list: array string.
Definition at line 265 of file accounts.py.
| airbus_cobot_gui.account.accounts.UserAccounts.accounts_dir |
Definition at line 213 of file accounts.py.
|
static |
Definition at line 192 of file accounts.py.
| airbus_cobot_gui.account.accounts.UserAccounts.accounts_xml |
Definition at line 224 of file accounts.py.
|
static |
Definition at line 200 of file accounts.py.
|
static |
Definition at line 201 of file accounts.py.
|
static |
Definition at line 197 of file accounts.py.
|
static |
Definition at line 196 of file accounts.py.
|
static |
Definition at line 199 of file accounts.py.
|
static |
Definition at line 195 of file accounts.py.
|
static |
Definition at line 203 of file accounts.py.