mirrormap.nio
Interface IConnectionEndPoint

All Superinterfaces:
IDestroyable, ILifeCycle
All Known Implementing Classes:
TcpConnectionEndPoint

public interface IConnectionEndPoint
extends ILifeCycle

Encapsulates the end point of an I/O connection. An I/O connection has 2 end points.

Author:
Ramon Servadei

Method Summary
 IConnectionEndPointReceiver getReceiver()
          The object handling the inbound data for the connection
 boolean isOutbound()
          Indicates if this connection was initiated from this end point.
 void send(byte[] data)
          Send the data to the other end point.
 
Methods inherited from interface mirrormap.lifecycle.ILifeCycle
isActive, start
 
Methods inherited from interface mirrormap.lifecycle.IDestroyable
destroy
 

Method Detail

send

void send(byte[] data)
Send the data to the other end point. This may not be a synchronous action; the implementation may queue the data.

Parameters:
data - the data to send

isOutbound

boolean isOutbound()
Indicates if this connection was initiated from this end point.

Returns:
true if the connection was initiated from this end point, false otherwise.

getReceiver

IConnectionEndPointReceiver getReceiver()
The object handling the inbound data for the connection

Returns:
object handling the inbound data for the connection


Copyright © 2010. All Rights Reserved.