Package org.eclipse.jetty.fcgi.parser
Class Parser
- java.lang.Object
-
- org.eclipse.jetty.fcgi.parser.Parser
-
- Direct Known Subclasses:
ClientParser
,ServerParser
public abstract class Parser extends java.lang.Object
The FastCGI protocol exchanges frames.
struct frame { ubyte version; ubyte type; ushort requestId; ushort contentLength; ubyte paddingLength; ubyte reserved; ubyte[] content; ubyte[] padding; }
Depending on the
type
, the content may have a different format, so there are specialized content parsers.- See Also:
HeaderParser
,ContentParser
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
Parser.Listener
-
Field Summary
Fields Modifier and Type Field Description protected HeaderParser
headerParser
-
Constructor Summary
Constructors Constructor Description Parser()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract ContentParser
findContentParser(FCGI.FrameType frameType)
boolean
parse(java.nio.ByteBuffer buffer)
-
-
-
Field Detail
-
headerParser
protected final HeaderParser headerParser
-
-
Method Detail
-
parse
public boolean parse(java.nio.ByteBuffer buffer)
- Parameters:
buffer
- the bytes to parse- Returns:
- true if the caller should stop parsing, false if the caller should continue parsing
-
findContentParser
protected abstract ContentParser findContentParser(FCGI.FrameType frameType)
-
-