| 构造器和说明 |
|---|
SslPipeLayer(SslConfig config) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
onActive(PipeContext context)
when the Connected.
|
void |
onClose(PipeContext context)
release protocol stack, connection close.
|
PipeStatus |
onError(PipeContext context,
boolean isRcv,
Throwable e,
PipeExceptionHolder eh)
Gets called if a Throwable was thrown.
|
void |
onInit(PipeContext context)
Initialize the protocol stack.
|
PipeStatus |
onMessage(PipeContext context,
boolean isRcv,
PipeRcvQueue<ByteBuf> rcvUp,
PipeSndQueue<ByteBuf> rcvDown,
PipeRcvQueue<ByteBuf> sndUp,
PipeSndQueue<ByteBuf> sndDown)
process data the protocol stack.
|
public SslPipeLayer(SslConfig config)
public void onInit(PipeContext context) throws Throwable
PipeDuplexpublic void onActive(PipeContext context) throws Exception
PipeDuplexpublic PipeStatus onMessage(PipeContext context, boolean isRcv, PipeRcvQueue<ByteBuf> rcvUp, PipeSndQueue<ByteBuf> rcvDown, PipeRcvQueue<ByteBuf> sndUp, PipeSndQueue<ByteBuf> sndDown) throws IOException
PipeDuplexPipeRcvQueue.rcvSubmit()/PipeSndQueue.sndSubmit() method of (RCV_UP, RCV_DOWN, SND_UP, SND_DOWN) will be called.
PipeDuplex.onError(PipeContext, boolean, Throwable, PipeExceptionHolder).onMessage 在接口中 PipeDuplex<ByteBuf,ByteBuf,ByteBuf,ByteBuf>IOExceptionpublic PipeStatus onError(PipeContext context, boolean isRcv, Throwable e, PipeExceptionHolder eh) throws Throwable
PipeDuplexPipeRcvQueue.rcvReset()/PipeSndQueue.sndReset() method of (RCV_UP, RCV_DOWN, SND_UP, SND_DOWN) will be called
... -> onMessage -> onMessage -> Exception
|
onError -> onError -> onError...
You can clear the exception flag with the PipeExceptionHolder.clear() method, and piple execution will continue normally
... -> onMessage -> onError -> onError(invoker clear) -> onMessage -> ...
public void onClose(PipeContext context)
PipeDuplexCopyright © 2022–2024. All rights reserved.