Package org.eclipse.jetty.http2.parser
Class HeaderBlockParser
- java.lang.Object
-
- org.eclipse.jetty.http2.parser.HeaderBlockParser
-
public class HeaderBlockParser extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private java.nio.ByteBufferblockBufferprivate org.eclipse.jetty.io.ByteBufferPoolbyteBufferPoolprivate HeaderParserheaderParserprivate HpackDecoderhpackDecoderprivate static org.eclipse.jetty.util.log.LoggerLOGprivate BodyParsernotifierstatic org.eclipse.jetty.http.MetaDataSESSION_FAILUREstatic org.eclipse.jetty.http.MetaDataSTREAM_FAILURE
-
Constructor Summary
Constructors Constructor Description HeaderBlockParser(HeaderParser headerParser, org.eclipse.jetty.io.ByteBufferPool byteBufferPool, HpackDecoder hpackDecoder, BodyParser notifier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetMaxHeaderListSize()org.eclipse.jetty.http.MetaDataparse(java.nio.ByteBuffer buffer, int blockLength)Parses @{code blockLength} HPACK bytes from the givenbuffer.
-
-
-
Field Detail
-
STREAM_FAILURE
public static final org.eclipse.jetty.http.MetaData STREAM_FAILURE
-
SESSION_FAILURE
public static final org.eclipse.jetty.http.MetaData SESSION_FAILURE
-
LOG
private static final org.eclipse.jetty.util.log.Logger LOG
-
headerParser
private final HeaderParser headerParser
-
byteBufferPool
private final org.eclipse.jetty.io.ByteBufferPool byteBufferPool
-
hpackDecoder
private final HpackDecoder hpackDecoder
-
notifier
private final BodyParser notifier
-
blockBuffer
private java.nio.ByteBuffer blockBuffer
-
-
Constructor Detail
-
HeaderBlockParser
public HeaderBlockParser(HeaderParser headerParser, org.eclipse.jetty.io.ByteBufferPool byteBufferPool, HpackDecoder hpackDecoder, BodyParser notifier)
-
-
Method Detail
-
getMaxHeaderListSize
public int getMaxHeaderListSize()
-
parse
public org.eclipse.jetty.http.MetaData parse(java.nio.ByteBuffer buffer, int blockLength)Parses @{code blockLength} HPACK bytes from the givenbuffer.- Parameters:
buffer- the buffer to parseblockLength- the length of the HPACK block- Returns:
- null, if the buffer contains less than
blockLengthbytes;STREAM_FAILUREif parsing the HPACK block produced a stream failure;SESSION_FAILUREif parsing the HPACK block produced a session failure; a valid MetaData object if the parsing was successful.
-
-