public class MaskedFrameInputStream extends FrameInputStream
+-+------+---------+-+---------+
|F|xxx(3)|opcode(4)|R|len(7) |
+-+------+---------+-+---------+
OPCODES
0 - cont
1 - text
2 - binary
8 - close
CLOSE_ERROR, CLOSE_MESSAGE_TOO_BIG, CLOSE_OK, CLOSE_UTF8, FLAG_FIN, FLAG_MASK, MASK_OPCODE, OP_BINARY, OP_CLOSE, OP_CONT, OP_PING, OP_PONG, OP_TEXT, VERSION
Constructor and Description |
---|
MaskedFrameInputStream() |
Modifier and Type | Method and Description |
---|---|
long |
getLength() |
byte[] |
getMask() |
int |
getOpcode() |
void |
init(WebSocketContext cxt,
java.io.InputStream is) |
boolean |
isFinal() |
int |
read() |
int |
read(byte[] buffer,
int offset,
int length) |
protected boolean |
readFrameHeaderImpl() |
closeError, getContext, handleFrame, initReader, readFrameHeader, skipToFrameEnd
public void init(WebSocketContext cxt, java.io.InputStream is)
init
in class FrameInputStream
public int getOpcode()
getOpcode
in class FrameInputStream
public boolean isFinal()
isFinal
in class FrameInputStream
public long getLength()
getLength
in class FrameInputStream
public final byte[] getMask()
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] buffer, int offset, int length) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
protected boolean readFrameHeaderImpl() throws java.io.IOException
readFrameHeaderImpl
in class FrameInputStream
java.io.IOException