Last updated November 28, 2009 12:04, by Fallen_Demon
Use Cases
The following page iterates use cases encountered in the HiveMind domain.
Contents
- 1 Server access
- 1.1 Logon
- 1.2 Quitting from the server
- 1.3 Connection Crashes
- 2 Channels
- 3 Glossary
Server access
Logon
Triggers:
- The user wishes to logon to the server
Preconditions:
- The client is not already in a logged on state
Postconditions:
- Both the server and user recognise that the user is in a logged on state
Actors:
- The user
Actions
- Client sends an AUTH command to the server which contains their username and password
- Server receives the data
- Server checks against its user database for the credentials
- If the username/password combination is found, the user is entered into a "logged in" DB and the server sends back an AUTH confirmation. If the user was already logged in, the server logs them off before confirming the new session
- Otherwise, the server sends back an error octet to the user
- The user receives the response
- If the user was authenticated, the client will enter into a logged on state
- Otherwise, the client action is undefined
Quitting from the server
Triggers
- The user closes the client daemon
- The client logs off
- The server boots a client
Preconditions
- The client is recognised as logged in by both the client and the server
Postconditions
- The client is not recognised as logged in by both the client and the server
Actors
- The user
- The user issues a quit command to the client (with or without a message)
- The client sends the QUIT command to the server
- Both the server and client close the connection
- The server issues a notification on all channels that the user was connected to that the user has quit
Connection Crashes
Triggers
- The connection fails
- There is a ping timeout between the client and server
Preconditions
- The client is recognised as logged in by both the client and the server
Postconditions
- The client is not recognised as logged in by both the client and the server
- None
- If they are still active
- Client close the connection
- Server closes the connection
Channels
Joining a channel
Triggers
- User issues a join channel command to the client
- User is not recognised as being in a channel by either the client or server
- Both the client and the server recognise that the user is in a channel
- The user
- The client sends the join signal and its parameters to the server
- The server receives the command
- If the user is authorised to join the channel, the server sends back a matching JOIN command to the client and enters the user into the database
- If they are denied, nothing happens
User Parting a Channel
Triggers
- The user issues a part command to the client
- The user is in the channel they wish part from
- The user leaves the channel
- The client sends a PART command to the server
- The server removes the user from the channel database
- The client recognises it is no joined to the channel
Glossary
User: The user of the HiveMind client app
Client: HiveMind client app
Server: The HiveMind server
AUTH Command: The AUTH command outlined in the protocol specification
AUTH Confirmation: The AUTH confirmation outlined in the protocol
Error Octet: The error octet (0x0E) outlined in the protocol
DB: Database





