BufferState
public enum BufferState
BufferState
represents the state of either the inbound, or the outbound EmbeddedChannel
buffer. These
buffers contain data that travelled the ChannelPipeline
all the way.
If the last ChannelHandler
explicitly (by calling fireChannelRead
) or implicitly (by not implementing
channelRead
) sends inbound data into the end of the EmbeddedChannel
, it will be held in the
EmbeddedChannel
‘s inbound buffer. Similarly for write
on the outbound side. The state of the respective
buffer will be returned from writeInbound
/writeOutbound
as a BufferState
.
-
The buffer is empty.
Declaration
Swift
case empty
-
The buffer is non-empty.
Declaration
Swift
case full([NIOAny])
-
Returns
true
is the buffer was empty.Declaration
Swift
public var isEmpty: Bool { get }
-
Returns
true
if the buffer was non-empty.Declaration
Swift
public var isFull: Bool { get }