net.sf.juoserver.protocol
Class ServerConnect

java.lang.Object
  extended by net.sf.juoserver.protocol.AbstractMessage
      extended by net.sf.juoserver.protocol.ServerConnect
All Implemented Interfaces:
Serializable, Message

public class ServerConnect
extends AbstractMessage

See Also:
Serialized Form

Field Summary
static int CODE
           
 
Fields inherited from class net.sf.juoserver.protocol.AbstractMessage
NO_CODE, UTF8
 
Constructor Summary
ServerConnect(InetAddress host, int port, int accountID)
           
 
Method Summary
 ByteBuffer encode()
          Encodes this message into a byte array packet.
 boolean equals(Object obj)
           
 int getAccountID()
           
 InetAddress getHost()
           
 int getPort()
           
 int hashCode()
           
 boolean isCompressed()
          

Default value is true.

 String toString()
           
 
Methods inherited from class net.sf.juoserver.protocol.AbstractMessage
getCode, getLength, getName, wrapContents, wrapContents
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

CODE

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

ServerConnect

public ServerConnect(InetAddress host,
                     int port,
                     int accountID)
Method Detail

encode

public ByteBuffer encode()
Description copied from interface: Message
Encodes this message into a byte array packet.

The array is wrapped in a byte buffer in order to let subclasses append their contents.

Specified by:
encode in interface Message
Overrides:
encode in class AbstractMessage
Returns:
the byte array representation (a.k.a. packet) of this message

isCompressed

public boolean isCompressed()
Description copied from class: AbstractMessage

Default value is true.

Specified by:
isCompressed in interface Message
Overrides:
isCompressed in class AbstractMessage
Returns:
true if and only if this message should be compressed when sent by the server

getHost

public InetAddress getHost()

getPort

public int getPort()

getAccountID

public int getAccountID()

hashCode

public int hashCode()
Specified by:
hashCode in class AbstractMessage

equals

public boolean equals(Object obj)
Specified by:
equals in class AbstractMessage

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2010-2012. All Rights Reserved.