StorservConnection - shmolyneaux/SquareJam GitHub Wiki
The StorservConnection class contains the interface between pstorage objects and the storserv socket. The most common action directly done on this class (from a web development perspective) is to get a user's username with the member __username__
The class contains the following members:
__username__
__socket_name__
__sessIP__
__sessID__
__hashID__
It also contains the following methods:
db_command
- A large number of others as wrappers for db_command
- Three exceptions that are called by the server
Members
__username__
is a string containing the username of the connecting user. If no user is logged in the string will have a value of nobody
.
__socket_name__
is a string containing the location of the storserv socket on the host machine.
__sessIP__
is a string containing the IP of the connecting user.
__sessID__
is a integer containing a unique number for the session of the current user.
__hashID__
a string containing the password hash for the current session. This is assigned by the server.
Methods
db_command( command, *args, **vargs)
- the method formats the inputs, and sends them to the server. This method should not be called directly