public final class ProxyProtocolDecoder extends Object
proxy_protocol on;
| 构造器和说明 |
|---|
ProxyProtocolDecoder() |
| 限定符和类型 | 方法和说明 |
|---|---|
static Packet |
decode(ByteBuffer buffer,
int readableLength,
ChannelContext context)
解码 proxy protocol
|
static ProxyProtocolMessage |
decodeMessage(ByteBuffer buffer,
int readableLength)
解码 proxy protocol
|
static void |
enableProxyProtocol(ChannelContext context)
开始 proxy protocol
|
static boolean |
isProxyProtocolEnabled(ChannelContext context)
判断是否开启 proxy protocol
|
static void |
removeProxyProtocol(ChannelContext context)
去掉 proxy protocol
|
public static void enableProxyProtocol(ChannelContext context)
context - ChannelContextpublic static void removeProxyProtocol(ChannelContext context)
context - ChannelContextpublic static boolean isProxyProtocolEnabled(ChannelContext context)
context - ChannelContextpublic static Packet decode(ByteBuffer buffer, int readableLength, ChannelContext context) throws TioDecodeException
buffer - ByteBufferreadableLength - readableLengthcontext - ChannelContextTioDecodeException - TioDecodeExceptionpublic static ProxyProtocolMessage decodeMessage(ByteBuffer buffer, int readableLength) throws TioDecodeException
buffer - ByteBufferreadableLength - readableLengthTioDecodeException - TioDecodeExceptionCopyright © 2023. All rights reserved.