public final class Http2Flags extends Object
Modifier and Type | Field and Description |
---|---|
static short |
ACK |
static short |
END_HEADERS |
static short |
END_STREAM |
static short |
PADDED |
static short |
PRIORITY |
Constructor and Description |
---|
Http2Flags() |
Http2Flags(short value) |
Modifier and Type | Method and Description |
---|---|
boolean |
ack()
Determines whether the flag is set indicating that this frame is an ACK.
|
Http2Flags |
ack(boolean ack)
Sets the
ACK flag. |
boolean |
endOfHeaders()
Determines whether the
END_HEADERS flag is set. |
Http2Flags |
endOfHeaders(boolean endOfHeaders)
Sets the
END_HEADERS flag. |
boolean |
endOfStream()
Determines whether the
END_STREAM flag is set. |
Http2Flags |
endOfStream(boolean endOfStream)
Sets the
END_STREAM flag. |
boolean |
equals(Object obj) |
int |
getNumPriorityBytes()
Gets the number of bytes expected for the priority fields of the payload.
|
int |
getPaddingPresenceFieldLength()
Gets the length in bytes of the padding presence field expected in the payload.
|
int |
hashCode() |
boolean |
isFlagSet(short mask)
Indicates whether or not a particular flag is set.
|
boolean |
paddingPresent()
For frames that include padding, indicates if the
PADDED field is present. |
Http2Flags |
paddingPresent(boolean paddingPresent)
Sets the
PADDED flag. |
boolean |
priorityPresent()
Determines whether the flag is set indicating the presence of the exclusive, stream
dependency, and weight fields in a HEADERS frame.
|
Http2Flags |
priorityPresent(boolean priorityPresent)
Sets the
PRIORITY flag. |
Http2Flags |
setFlag(boolean on,
short mask)
Generic method to set any flag.
|
String |
toString() |
short |
value()
Gets the underlying flags value.
|
public static final short END_STREAM
public static final short END_HEADERS
public static final short ACK
public static final short PADDED
public static final short PRIORITY
public short value()
public boolean endOfStream()
END_STREAM
flag is set. Only applies to DATA and HEADERS
frames.public boolean endOfHeaders()
END_HEADERS
flag is set. Only applies for HEADERS,
PUSH_PROMISE, and CONTINUATION frames.public boolean priorityPresent()
public boolean ack()
public boolean paddingPresent()
PADDED
field is present. Only
applies to DATA, HEADERS, PUSH_PROMISE and CONTINUATION frames.public int getNumPriorityBytes()
priorityPresent()
flag.public int getPaddingPresenceFieldLength()
paddingPresent()
flag.public Http2Flags endOfStream(boolean endOfStream)
END_STREAM
flag.public Http2Flags endOfHeaders(boolean endOfHeaders)
END_HEADERS
flag.public Http2Flags priorityPresent(boolean priorityPresent)
PRIORITY
flag.public Http2Flags paddingPresent(boolean paddingPresent)
PADDED
flag.public Http2Flags ack(boolean ack)
ACK
flag.public Http2Flags setFlag(boolean on, short mask)
on
- if the flag should be enabled or disabled.mask
- the mask that identifies the bit for the flag.public boolean isFlagSet(short mask)
mask
- the mask identifying the bit for the particular flag being testedtrue
if the flag is setCopyright © 2008–2024 The Netty Project. All rights reserved.