public class FrameBuilderDraft06 extends Object
| Modifier and Type | Class and Description |
|---|---|
protected static class |
FrameBuilderDraft06.Fin
The Enum Fin.
|
protected static class |
FrameBuilderDraft06.Opcode
The Enum Opcode.
|
protected static class |
FrameBuilderDraft06.PayloadLengthType
The Enum PayloadLengthType.
|
protected static class |
FrameBuilderDraft06.Rsv
The Enum Rsv.
|
| Modifier and Type | Field and Description |
|---|---|
protected static int |
FIN_MASK
The Constant FIN_MASK.
|
protected static int |
MAX_FRAME_LENGTH_16
The Constant MAX_FRAME_LENGTH_16.
|
protected static long |
MAX_FRAME_LENGTH_63
The Constant MAX_FRAME_LENGTH_63.
|
protected static byte |
OPCODE_MASK
The Constant OPCODE_MASK.
|
protected static int |
PAYLOAD_LEN_MASK
The Constant PAYLOAD_LEN_MASK.
|
protected static byte |
RSV1_MASK
The Constant RSV1_MASK.
|
protected static byte |
RSV2_MASK
The Constant RSV2_MASK.
|
protected static byte |
RSV3_MASK
The Constant RSV3_MASK.
|
protected static int |
RSV4_MASK
The Constant RSV4_MASK.
|
| Constructor and Description |
|---|
FrameBuilderDraft06() |
| Modifier and Type | Method and Description |
|---|---|
static Frame |
createFrame(FrameHeaderDraft06 header,
byte[] bodyData)
Creates the frame.
|
static FrameHeaderDraft06 |
createFrameHeader(byte[] body,
boolean fragmented,
FrameBuilderDraft06.Opcode opcode)
Creates the frame header.
|
static FrameHeaderDraft06 |
createFrameHeader(ByteBuffer chunkData,
FrameHeaderDraft06 previousHeader)
create frame header from parameter bytes
if a invalid frame data received which may throw IllegalArgumentException.
|
protected static final int MAX_FRAME_LENGTH_16
protected static final long MAX_FRAME_LENGTH_63
protected static final int FIN_MASK
protected static final byte RSV1_MASK
protected static final byte RSV2_MASK
protected static final byte RSV3_MASK
protected static final byte OPCODE_MASK
protected static final int RSV4_MASK
protected static final int PAYLOAD_LEN_MASK
public static FrameHeaderDraft06 createFrameHeader(ByteBuffer chunkData, FrameHeaderDraft06 previousHeader)
chunkData - the chunk datapreviousHeader - the previous headerpublic static FrameHeaderDraft06 createFrameHeader(byte[] body, boolean fragmented, FrameBuilderDraft06.Opcode opcode)
body - the contentsfragmented - the fragmentedopcode - the opcodepublic static Frame createFrame(FrameHeaderDraft06 header, byte[] bodyData)
header - the headerbodyData - the contents dataCopyright © 2021. All rights reserved.