Package org.apache.thrift.transport.sasl
Class DataFrameHeaderReader
- java.lang.Object
-
- org.apache.thrift.transport.sasl.FixedSizeHeaderReader
-
- org.apache.thrift.transport.sasl.DataFrameHeaderReader
-
- All Implemented Interfaces:
FrameHeaderReader
public class DataFrameHeaderReader extends FixedSizeHeaderReader
The header for data frame, it only contains a 4-byte payload size.
-
-
Field Summary
Fields Modifier and Type Field Description static intPAYLOAD_LENGTH_BYTES-
Fields inherited from class org.apache.thrift.transport.sasl.FixedSizeHeaderReader
byteBuffer
-
-
Constructor Summary
Constructors Constructor Description DataFrameHeaderReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected intheaderSize()protected voidonComplete()Actions (e.g. validation) to carry out when the header is complete.intpayloadSize()As the thrift sasl specification states, all sasl messages (both for negotiatiing and for sending data) should have a header to indicate the size of the payload.-
Methods inherited from class org.apache.thrift.transport.sasl.FixedSizeHeaderReader
clear, isComplete, read, toBytes
-
-
-
-
Field Detail
-
PAYLOAD_LENGTH_BYTES
public static final int PAYLOAD_LENGTH_BYTES
- See Also:
- Constant Field Values
-
-
Method Detail
-
headerSize
protected int headerSize()
- Specified by:
headerSizein classFixedSizeHeaderReader- Returns:
- Size of the header.
-
onComplete
protected void onComplete() throws TInvalidSaslFrameExceptionDescription copied from class:FixedSizeHeaderReaderActions (e.g. validation) to carry out when the header is complete.- Specified by:
onCompletein classFixedSizeHeaderReader- Throws:
TInvalidSaslFrameException
-
payloadSize
public int payloadSize()
Description copied from interface:FrameHeaderReaderAs the thrift sasl specification states, all sasl messages (both for negotiatiing and for sending data) should have a header to indicate the size of the payload.- Returns:
- size of the payload.
-
-