public class TransportFilter extends Object implements Transport
Constructor and Description |
---|
TransportFilter(Transport next) |
Modifier and Type | Method and Description |
---|---|
void |
drainInbound() |
void |
flush()
Forces a flush of any output buffers.
|
boolean |
full() |
Executor |
getBlockingExecutor() |
DispatchQueue |
getDispatchQueue()
Returns the dispatch queue used by the transport
|
SocketAddress |
getLocalAddress() |
ProtocolCodec |
getProtocolCodec() |
ReadableByteChannel |
getReadChannel() |
SocketAddress |
getRemoteAddress() |
TransportListener |
getTransportListener()
Returns the current transport listener
|
WritableByteChannel |
getWriteChannel() |
boolean |
isClosed() |
boolean |
isConnected() |
boolean |
offer(Object command)
A one way asynchronous send of a command.
|
void |
resumeRead()
resume delivery of commands.
|
void |
setBlockingExecutor(Executor blockingExecutor) |
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 transportListener)
Registers an inbound command listener
|
void |
start(Runnable onComplete)
Starts the service.
|
void |
start(Task onComplete)
Starts the service.
|
void |
stop(Runnable onComplete)
Stops the service.
|
void |
stop(Task onComplete)
Stops the service.
|
void |
suspendRead()
suspend delivery of commands.
|
public TransportFilter(Transport next)
public void flush()
Transport
public Executor getBlockingExecutor()
getBlockingExecutor
in interface Transport
public DispatchQueue getDispatchQueue()
Transport
getDispatchQueue
in interface Transport
public SocketAddress getLocalAddress()
getLocalAddress
in interface Transport
public ProtocolCodec getProtocolCodec()
getProtocolCodec
in interface Transport
public ReadableByteChannel getReadChannel()
getReadChannel
in interface Transport
public SocketAddress getRemoteAddress()
getRemoteAddress
in interface Transport
public TransportListener getTransportListener()
Transport
getTransportListener
in interface Transport
public WritableByteChannel getWriteChannel()
getWriteChannel
in interface Transport
public boolean isClosed()
public boolean isConnected()
isConnected
in interface Transport
public boolean offer(Object command)
Transport
public void resumeRead()
Transport
resumeRead
in interface Transport
public void setBlockingExecutor(Executor blockingExecutor)
setBlockingExecutor
in interface Transport
public void setDispatchQueue(DispatchQueue queue)
Transport
setDispatchQueue
in interface Transport
public void setProtocolCodec(ProtocolCodec protocolCodec) throws Exception
Transport
setProtocolCodec
in interface Transport
Exception
public void setTransportListener(TransportListener transportListener)
Transport
setTransportListener
in interface Transport
public void start(Runnable onComplete)
Transport
public void start(Task onComplete)
Transport
public void stop(Runnable onComplete)
Transport
public void stop(Task onComplete)
Transport
public void suspendRead()
Transport
suspendRead
in interface Transport
public void drainInbound()
drainInbound
in interface Transport
Copyright © 2010–2017 FuseSource, Corp.. All rights reserved.