public static interface Http2RemoteFlowController.FlowControlled
write(int)
has
been called at least once and it's size()
is now zero.Modifier and Type | Method and Description |
---|---|
void |
error(Throwable cause)
Signal an error and release any retained buffers.
|
int |
size()
The size of the payload in terms of bytes applied to the flow-control window.
|
boolean |
write(int allowedBytes)
Writes up to
allowedBytes of the encapsulated payload to the stream. |
int size()
HEADER
frames have no cost against flow control and would
return 0 for this value even though they produce a non-zero number of bytes on
the wire. Other frames like DATA
frames have both their payload and padding count
against flow-control.void error(Throwable cause)
cause
- of the error.boolean write(int allowedBytes)
allowedBytes
of the encapsulated payload to the stream. Note that
a value of 0 may be passed which will allow payloads with flow-control size == 0 to be
written. The flow-controller may call this method multiple times with different values until
the payload is fully written.allowedBytes
- an upper bound on the number of bytes the payload can write at this time.true
if a flush is required, false
otherwise.Copyright © 2008–2015 The Netty Project. All rights reserved.