game.multiplayer.containers
Class Client

java.lang.Object
  extended by game.multiplayer.containers.Client
All Implemented Interfaces:
java.io.Serializable

public class Client
extends java.lang.Object
implements java.io.Serializable

Client container class for the multiplayer game.

Author:
Chris Barton
See Also:
Serialized Form

Field Summary
 java.lang.String name
           
 PlayerState state
           
 
Constructor Summary
Client(java.lang.String name)
          Constructs a Client with with PlayerState.CONNECTED.
Client(java.lang.String name, PlayerState state)
          Constructs a Client.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 int hashCode()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

name

public java.lang.String name

state

public PlayerState state
Constructor Detail

Client

public Client(java.lang.String name)
Constructs a Client with with PlayerState.CONNECTED.

Parameters:
name - - String naming the Client.

Client

public Client(java.lang.String name,
              PlayerState state)
Constructs a Client.

Parameters:
name - - String naming the Client.
state - - PlayerState setting the state of the Client.
Method Detail

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object