org.alliance.core.comm
Class InvitationConnection

java.lang.Object
  extended by org.alliance.core.comm.Connection
      extended by org.alliance.core.comm.PacketConnection
          extended by org.alliance.core.comm.AuthenticatedConnection
              extended by org.alliance.core.comm.InvitationConnection

public class InvitationConnection
extends AuthenticatedConnection

This connection swings both ways - it's used by invitor and invited Created by IntelliJ IDEA. User: maciek Date: 2006-mar-16 Time: 19:47:04 To change this template use File | Settings | File Templates.


Nested Class Summary
 
Nested classes/interfaces inherited from class org.alliance.core.comm.Connection
Connection.Direction
 
Field Summary
static int CONNECTION_ID
           
 
Fields inherited from class org.alliance.core.comm.AuthenticatedConnection
remoteUserGUID
 
Fields inherited from class org.alliance.core.comm.Connection
bandwidthIn, bandwidthOut, bytesReceived, bytesSent, connected, core, direction, hasWriteInterest, key, netMan, statusString
 
Constructor Summary
InvitationConnection(NetworkManager netMan, Connection.Direction direction, int passkey)
           
InvitationConnection(NetworkManager netMan, Connection.Direction direction, java.lang.Object key, int passkey)
           
 
Method Summary
protected  int getConnectionId()
           
 void packetReceived(Packet p)
           
 void sendConnectionIdentifier()
           
 
Methods inherited from class org.alliance.core.comm.AuthenticatedConnection
getRemoteFriend, getRemoteUserGUID, getSocketAddress, init, newInstance, setRemoteUserGUID, toString
 
Methods inherited from class org.alliance.core.comm.PacketConnection
getLastPacketSentAt, getPacketsReceived, readyToSend, received, send
 
Methods inherited from class org.alliance.core.comm.Connection
bytesReceived, bytesSent, close, getBandwidthIn, getBandwidthOut, getBytesReceived, getBytesSent, getConnectionIdForRemote, getDirection, getKey, getNetMan, getStatusString, hasWriteInterest, isConnected, setHasWriteInterest, setKey, setStatusString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CONNECTION_ID

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

InvitationConnection

public InvitationConnection(NetworkManager netMan,
                            Connection.Direction direction,
                            int passkey)

InvitationConnection

public InvitationConnection(NetworkManager netMan,
                            Connection.Direction direction,
                            java.lang.Object key,
                            int passkey)
Method Detail

sendConnectionIdentifier

public void sendConnectionIdentifier()
                              throws java.io.IOException
Overrides:
sendConnectionIdentifier in class AuthenticatedConnection
Throws:
java.io.IOException

packetReceived

public void packetReceived(Packet p)
                    throws java.io.IOException
Specified by:
packetReceived in class PacketConnection
Throws:
java.io.IOException

getConnectionId

protected int getConnectionId()
Specified by:
getConnectionId in class Connection