|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface Transport
Represents an abstract connection. It can be a client side or server side connection.
| Method Summary | ||
|---|---|---|
void |
flush()
Forces a flush of any output buffers. |
|
boolean |
full()
|
|
DispatchQueue |
getDispatchQueue()
Returns the dispatch queue used by the transport |
|
SocketAddress |
getLocalAddress()
|
|
ProtocolCodec |
getProtocolCodec()
|
|
SocketAddress |
getRemoteAddress()
|
|
TransportListener |
getTransportListener()
Returns the current transport listener |
|
String |
getTypeId()
|
|
boolean |
isConnected()
|
|
boolean |
isDisposed()
|
|
boolean |
isFaultTolerant()
Indicates if the transport can handle faults |
|
|
narrow(Class<T> target)
|
|
boolean |
offer(Object command)
A one way asynchronous send of a command. |
|
void |
reconnect(URI uri)
reconnect to another location |
|
void |
resumeRead()
resume delivery of commands. |
|
void |
setDispatchQueue(DispatchQueue queue)
Sets the dispatch queue used by the transport |
|
void |
setProtocolCodec(ProtocolCodec protocolCodec)
Sets the protocol codec for the transport |
|
void |
setTransportListener(TransportListener commandListener)
Registers an inbound command listener |
|
void |
start(Runnable onComplete)
Starts the service. |
|
void |
stop(Runnable onComplete)
Stops the service. |
|
void |
suspendRead()
suspend delivery of commands. |
|
| Method Detail |
|---|
void start(Runnable onComplete)
onComplete - my be set to null if not interested in a callback.void stop(Runnable onComplete)
onComplete - my be set to null if not interested in a callback.boolean full()
boolean offer(Object command)
command -
void flush()
TransportListener getTransportListener()
void setTransportListener(TransportListener commandListener)
commandListener - DispatchQueue getDispatchQueue()
void setDispatchQueue(DispatchQueue queue)
queue - void suspendRead()
void resumeRead()
<T> T narrow(Class<T> target)
target -
SocketAddress getRemoteAddress()
SocketAddress getLocalAddress()
boolean isFaultTolerant()
boolean isDisposed()
boolean isConnected()
ProtocolCodec getProtocolCodec()
void setProtocolCodec(ProtocolCodec protocolCodec)
throws Exception
protocolCodec -
Exceptionvoid reconnect(URI uri)
uri -
IOException - on failure of if not supportedString getTypeId()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||