The User class is a global Draco object that provides functionality
for user variables. User variables are global variables that are bound to
the userid of the current session. The global instance of the User
class is stored under the name user
in the current module.
User variables depend on database access and require a logged in session.
You can check if user variables are available by testing the user
instance for non-zeroness.
The User object is a namespace. Use Python's dictionary notation to get, set or remove user variables from the User object. A small example:
from draco.user import user user['ham'] = 'spam' del user['ham']
) |
The public methods of User are:
scope) |
'__system__'
.