@PrivateApi public class TextDecoder extends Object implements com.hazelcast.internal.networking.ChannelInboundHandler
| Constructor and Description |
|---|
TextDecoder(TcpIpConnection connection,
TextEncoder encoder) |
| Modifier and Type | Method and Description |
|---|---|
void |
closeConnection() |
TextEncoder |
getEncoder() |
void |
onRead(ByteBuffer src)
A callback to indicate that data is available in the src ByteBuffer to be processed.
|
void |
publishRequest(com.hazelcast.internal.ascii.TextCommand command) |
void |
sendResponse(com.hazelcast.internal.ascii.TextCommand command) |
public TextDecoder(TcpIpConnection connection, TextEncoder encoder)
public void sendResponse(com.hazelcast.internal.ascii.TextCommand command)
public void onRead(ByteBuffer src) throws Exception
com.hazelcast.internal.networking.ChannelInboundHandleronRead in interface com.hazelcast.internal.networking.ChannelInboundHandlersrc - the ByteBuffer containing the data to read. The ByteBuffer is already in reading mode and when completed,
should not be converted to write-mode using clear/compact.Exception - if something fails while reading data from the ByteBuffer or processing the data (e.g. when a Packet
fails to get processed). When an exception is thrown, the ChannelErrorHandler is called.public void publishRequest(com.hazelcast.internal.ascii.TextCommand command)
public TextEncoder getEncoder()
public void closeConnection()
Copyright © 2018 Hazelcast, Inc.. All rights reserved.