lecturequiz.server.data
Class User

java.lang.Object
  extended by lecturequiz.server.data.User

public class User
extends java.lang.Object


Field Summary
static int ADMIN
           
static int STUDENT
           
static int TEACHER
           
 
Constructor Summary
User(int id, java.lang.String nickname, int role)
           
User(java.lang.String nickname, int role)
           
 
Method Summary
 AbstractGameMode getCurrentGame()
          Returns the current game this user is connected to.
 int getId()
          Returns the ID of the user.
 java.lang.String getNickname()
           
 int getRole()
           
 void setCurrentGame(AbstractGameMode game)
          Sets the current game this user is connected to.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ADMIN

public static final int ADMIN
See Also:
Constant Field Values

TEACHER

public static final int TEACHER
See Also:
Constant Field Values

STUDENT

public static final int STUDENT
See Also:
Constant Field Values
Constructor Detail

User

public User(int id,
            java.lang.String nickname,
            int role)

User

public User(java.lang.String nickname,
            int role)
Method Detail

getNickname

public java.lang.String getNickname()

getRole

public int getRole()

getId

public int getId()
Returns the ID of the user.

Returns:
the ID of the user.

getCurrentGame

public AbstractGameMode getCurrentGame()
Returns the current game this user is connected to.

Returns:
The current game this user is connected to.

setCurrentGame

public void setCurrentGame(AbstractGameMode game)
Sets the current game this user is connected to.

Parameters:
game - The game this user is conencted to.