com.mooapi.common.command.server
Class ConnectionNameChanged

java.lang.Object
  extended by com.mooapi.common.command.server.AbstractServerCommand
      extended by com.mooapi.common.command.server.ConnectionNameChanged
All Implemented Interfaces:
Command

public class ConnectionNameChanged
extends AbstractServerCommand

MooAPI name change output command.

Author:
Steve Taylor

Constructor Summary
ConnectionNameChanged(int connectionId, java.lang.String connectionName)
          Initialize.
 
Method Summary
static ConnectionNameChanged decode(org.apache.mina.common.ByteBuffer buffer)
           
 org.apache.mina.common.ByteBuffer encode()
          Encode this command as a byte stream.
 boolean equals(java.lang.Object obj)
           
 int getConnectionId()
          Get the connection ID that has changed its name.
 java.lang.String getConnectionName()
          Get the connection's new name.
 int hashCode()
           
 java.lang.String toString()
          Generate a string representation of this message.
 
Methods inherited from class com.mooapi.common.command.server.AbstractServerCommand
getType
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ConnectionNameChanged

public ConnectionNameChanged(int connectionId,
                             java.lang.String connectionName)
Initialize.

Parameters:
connectionId - The connection ID that has changed its name.
connectionName - The connection's new name.
Method Detail

decode

public static ConnectionNameChanged decode(org.apache.mina.common.ByteBuffer buffer)
Parameters:
buffer -
Returns:

encode

public org.apache.mina.common.ByteBuffer encode()
Encode this command as a byte stream.

Specified by:
encode in class AbstractServerCommand
Returns:
A buffer containing the encoded command.

getConnectionId

public int getConnectionId()
Get the connection ID that has changed its name.

Returns:
The connection ID.

getConnectionName

public java.lang.String getConnectionName()
Get the connection's new name.

Returns:
The connection's name.

toString

public java.lang.String toString()
Generate a string representation of this message.

Specified by:
toString in class AbstractServerCommand
Returns:
A string representation of this message.

equals

public boolean equals(java.lang.Object obj)
Specified by:
equals in class AbstractServerCommand
Parameters:
obj -
Returns:

hashCode

public int hashCode()
Specified by:
hashCode in class AbstractServerCommand
Returns:


Copyright © 2009. All Rights Reserved.