|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcgl.narada.transport.MonitoredLink
cgl.narada.transport.niotcp.NIOTCPLink
public class NIOTCPLink
This is a NIOTCP implementation of the Link interface. Say we are trying to establish a communication from node A to node B. To create links one needs following properties to be specified.
Field Summary |
---|
Constructor Summary | |
---|---|
NIOTCPLink(SocketChannel sc,
NIOTCPLinkFactory niotcpLinkFactory)
|
Method Summary | |
---|---|
void |
closeLink()
Garbage collect resources associated with this link. |
String |
getLinkId()
Retrieves the String based id of the link |
String |
getLinkType()
Returns the type of the communication link |
Object |
getNaradaBrokeringId()
Returns the NaradaBrokeringId associated with this link |
String |
getSecurityInformation()
Information pertaining to the security strategy adopted for this communication link |
TransportHandler |
getTransportHandler()
|
boolean |
isSecure()
Indicates weather communication is encrypted on this link |
void |
processLossOfSocketConnection(boolean senderNotification)
If the senderNotification is false, it implies that the detection of connection loss has been reported by the receiver thread. |
void |
sendData(byte[] data)
The method used to send data over a communication link |
void |
sendData(byte[] data,
String dataType)
The method used to send data over a communication link, this method also includes information regarding the type (audio/video/xml-attachments etc.) of the data encapsulated within the data stream. |
void |
setKeepAliveTime(long keepAliveTime)
Set the amount of time after which resources associated with this link need to be garbage collected. |
void |
setLinkId(String stringId)
Sets the Id of the communication link |
void |
setLinkMigrationConstraint(String constraint,
String linkType)
Sets the conditions under which communication protocols need to be switched and the transport link that it should be switched to under the condition. |
void |
setLinkStatusInterval(long interval)
Check the status of the communication link at intervals specified in the argument of this method |
void |
setNaradaBrokeringId(Object brokeringId)
The Naradabrokering Id of the node this link interacts with |
void |
startLinkServices()
|
Methods inherited from class cgl.narada.transport.MonitoredLink |
---|
disablePerformanceFactor, enablePerformanceFactor, getAllPerformanceData, getLatencies, getPerformanceData, getPerformanceFactorsMeasured, performanceGatheringEnabled, processPerformancePackets, sendPerformancePackets, setPerformanceGathering |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface cgl.narada.transport.Link |
---|
getAllPerformanceData, getPerformanceData, getPerformanceFactorsMeasured, performanceGatheringEnabled, setPerformanceGathering |
Constructor Detail |
---|
public NIOTCPLink(SocketChannel sc, NIOTCPLinkFactory niotcpLinkFactory) throws TransportException
TransportException
Method Detail |
---|
public void startLinkServices()
public void sendData(byte[] data) throws TransportException
TransportException
public void sendData(byte[] data, String dataType) throws TransportException
TransportException
public void setLinkId(String stringId)
public String getLinkId()
public void setNaradaBrokeringId(Object brokeringId)
setNaradaBrokeringId
in interface Link
public Object getNaradaBrokeringId()
getNaradaBrokeringId
in interface Link
public String getLinkType()
getLinkType
in interface Link
public void setLinkMigrationConstraint(String constraint, String linkType)
setLinkMigrationConstraint
in interface Link
public void setLinkStatusInterval(long interval)
setLinkStatusInterval
in interface Link
public void setKeepAliveTime(long keepAliveTime)
setKeepAliveTime
in interface Link
public void closeLink()
public boolean isSecure()
public String getSecurityInformation()
getSecurityInformation
in interface Link
public void processLossOfSocketConnection(boolean senderNotification)
public TransportHandler getTransportHandler()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |