Class ChunkExtension


  • public class ChunkExtension
    extends java.lang.Object
    Unlike other HTTP parsers, this is a stateless (state is held by the calling code), streaming parser as chunk headers are read as part of the request body and it is not always possible to buffer then entire chunk header in memory.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  ChunkExtension.State
      Parsing states for chunk extension.
    • Method Detail

      • parse

        public static ChunkExtension.State parse​(byte b,
                                                 ChunkExtension.State state)
                                          throws java.io.IOException
        Parses the next byte of a chunk extension.
        Parameters:
        b - the byte to parse
        state - the current parsing state
        Returns:
        the next parsing state
        Throws:
        java.io.IOException - if the byte is invalid for the current state