Atavism Version 2018.1AGIS API

atavism.server.network
Class ClientTCPConnection

java.lang.Object
  extended by atavism.server.network.ClientConnection
      extended by atavism.server.network.ClientTCPConnection

public class ClientTCPConnection
extends ClientConnection


Nested Class Summary
 
Nested classes/interfaces inherited from class atavism.server.network.ClientConnection
ClientConnection.AcceptCallback, ClientConnection.MessageCallback
 
Field Summary
 
Fields inherited from class atavism.server.network.ClientConnection
aggregatedReceives, aggregatedSends, connectionTypeRDP, connectionTypeTCP, connectionTypeUDP, lock, logMessageContents, packetAggregator, receivedMessagesAggregated, sentMessagesAggregated, unaggregatedReceives, unaggregatedSends
 
Constructor Summary
ClientTCPConnection(ClientTCPMessageIO clientTCPMessageIO)
           
ClientTCPConnection(ClientTCPMessageIO clientTCPMessageIO, java.nio.channels.SocketChannel socketChannel, ClientConnection.MessageCallback messageCallback)
           
ClientTCPConnection(java.nio.channels.SocketChannel socketChannel)
           
 
Method Summary
 boolean canSend()
           
 boolean canSendInternal()
           
 void close()
           
 int connectionKind()
           
 void connectionReset()
           
 AgentInfo getAgentInfo()
           
 ClientConnection.MessageCallback getMessageCallback()
           
protected  void initializeFromSocketChannel(java.nio.channels.SocketChannel socketChannel)
           
 java.lang.String IPAndPort()
           
 boolean isOpen()
           
 void open(java.lang.String hostname, int remotePort)
           
 void registerMessageCallback(ClientConnection.MessageCallback messageCallback)
           
 void send(AOByteBuffer buf)
           
 boolean sendIfPossible(AOByteBuffer buf)
           
 boolean sendInternal(AOByteBuffer buf)
           
 int sendMultibuf(java.util.List<AOByteBuffer> subMessages, int currentSize)
           
 
Methods inherited from class atavism.server.network.ClientConnection
getAggregator, getAssociation, getLock, getLogMessageContents, setAssociation, setLogMessageContents, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClientTCPConnection

public ClientTCPConnection(ClientTCPMessageIO clientTCPMessageIO)

ClientTCPConnection

public ClientTCPConnection(java.nio.channels.SocketChannel socketChannel)

ClientTCPConnection

public ClientTCPConnection(ClientTCPMessageIO clientTCPMessageIO,
                           java.nio.channels.SocketChannel socketChannel,
                           ClientConnection.MessageCallback messageCallback)
Method Detail

initializeFromSocketChannel

protected void initializeFromSocketChannel(java.nio.channels.SocketChannel socketChannel)

IPAndPort

public java.lang.String IPAndPort()
Specified by:
IPAndPort in class ClientConnection

registerMessageCallback

public void registerMessageCallback(ClientConnection.MessageCallback messageCallback)
Specified by:
registerMessageCallback in class ClientConnection

getMessageCallback

public ClientConnection.MessageCallback getMessageCallback()

send

public void send(AOByteBuffer buf)
Specified by:
send in class ClientConnection

sendInternal

public boolean sendInternal(AOByteBuffer buf)
Specified by:
sendInternal in class ClientConnection

sendIfPossible

public boolean sendIfPossible(AOByteBuffer buf)
Specified by:
sendIfPossible in class ClientConnection

sendMultibuf

public int sendMultibuf(java.util.List<AOByteBuffer> subMessages,
                        int currentSize)
Specified by:
sendMultibuf in class ClientConnection

open

public void open(java.lang.String hostname,
                 int remotePort)
Specified by:
open in class ClientConnection

connectionReset

public void connectionReset()
Specified by:
connectionReset in class ClientConnection

close

public void close()
Specified by:
close in class ClientConnection

isOpen

public boolean isOpen()
Specified by:
isOpen in class ClientConnection

canSend

public boolean canSend()
Specified by:
canSend in class ClientConnection

canSendInternal

public boolean canSendInternal()
Specified by:
canSendInternal in class ClientConnection

connectionKind

public int connectionKind()
Specified by:
connectionKind in class ClientConnection

getAgentInfo

public AgentInfo getAgentInfo()


Copyright © 2018 Dragonsan Studios Sp. z o.o.