public class NettyWsTransport extends NettyTcpTransport
NettyTcpTransport.NettyDefaultHandler<E>, NettyTcpTransport.NettyTcpTransportHandlerbootstrap, channel, DEFAULT_MAX_FRAME_SIZE, group, ioThreadfactory, listener, maxFrameSize, SHUTDOWN_TIMEOUT| Constructor and Description |
|---|
NettyWsTransport(TransportListener listener,
URI remoteLocation,
TransportOptions options,
boolean secure)
Create a new transport instance
|
NettyWsTransport(URI remoteLocation,
TransportOptions options,
boolean secure)
Create a new transport instance
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addAdditionalHandlers(io.netty.channel.ChannelPipeline pipeline) |
protected io.netty.channel.ChannelInboundHandlerAdapter |
createChannelHandler() |
protected void |
handleConnected(io.netty.channel.Channel channel) |
void |
write(io.netty.buffer.ByteBuf output)
Writes a chunk of data over the Transport connection without performing an
explicit flush on the transport.
|
void |
writeAndFlush(io.netty.buffer.ByteBuf output)
Writes a chunk of data over the Transport connection and requests a flush of
all pending queued write operations
|
allocateSendBuffer, checkConnected, close, connect, flush, getLocalPrincipal, getMaxFrameSize, getRemoteHost, getRemoteLocation, getRemotePort, getThreadFactory, getTransportListener, getTransportOptions, handleChannelInactive, handleException, isConnected, isSecure, setMaxFrameSize, setThreadFactory, setTransportListenerpublic NettyWsTransport(URI remoteLocation, TransportOptions options, boolean secure)
remoteLocation - the URI that defines the remote resource to connect to.options - the transport options used to configure the socket connection.secure - should the transport enable an SSL layer.public NettyWsTransport(TransportListener listener, URI remoteLocation, TransportOptions options, boolean secure)
listener - the TransportListener that will receive events from this Transport.remoteLocation - the URI that defines the remote resource to connect to.options - the transport options used to configure the socket connection.secure - should the transport enable an SSL layer.public void write(io.netty.buffer.ByteBuf output)
throws IOException
Transportwrite in interface Transportwrite in class NettyTcpTransportoutput - The buffer of data that is to be transmitted.IOException - if an error occurs during the write operation.public void writeAndFlush(io.netty.buffer.ByteBuf output)
throws IOException
TransportwriteAndFlush in interface TransportwriteAndFlush in class NettyTcpTransportoutput - The buffer of data that is to be transmitted.IOException - if an error occurs during the write operation.protected io.netty.channel.ChannelInboundHandlerAdapter createChannelHandler()
createChannelHandler in class NettyTcpTransportprotected void addAdditionalHandlers(io.netty.channel.ChannelPipeline pipeline)
addAdditionalHandlers in class NettyTcpTransportprotected void handleConnected(io.netty.channel.Channel channel)
throws Exception
handleConnected in class NettyTcpTransportExceptionCopyright © 2013–2019 The Apache Software Foundation. All rights reserved.