This class is used to read WebSocket frames from the underlying socket and
makes the payload available for reading as an InputStream. It only
makes the number of bytes declared in the payload length available for
reading even if more bytes are available from the socket.

Method Detail

nextFrame

block - Should this method block until a frame is presented if no
data is currently available to process. Note that if a
single byte is available, this method will block until the
complete frame (excluding payload for non-control frames) is
available.

Returns:

The next frame to be processed or null if block is
false and there is no data to be processed.