|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrabbit.httpio.HttpHeaderParser
public class HttpHeaderParser
A parser of http headers
Constructor Summary | |
---|---|
HttpHeaderParser(boolean request,
boolean strictHttp)
Create a new HttpHeaderParser |
Method Summary | |
---|---|
HttpHeader |
getHeader()
Get the current header |
boolean |
handleBuffer(ByteBuffer buffer)
Read the data from the buffer and try to build a http header. |
void |
lineRead(String line)
Handle a newly read line. |
void |
reset()
Restore the parser to its initial state |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HttpHeaderParser(boolean request, boolean strictHttp)
request
- if true try to read a request, if false try to read a responsestrictHttp
- if true http headers will be strictly parsed, if false
http newlines may be single \nMethod Detail |
---|
public void reset()
public HttpHeader getHeader()
public boolean handleBuffer(ByteBuffer buffer)
buffer
- the ByteBuffer to parse
public void lineRead(String line)
lineRead
in interface LineListener
line
- the line of text that have been read.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |