Package org.eclipse.jetty.client.http
Class HttpReceiverOverHTTP
java.lang.Object
org.eclipse.jetty.client.HttpReceiver
org.eclipse.jetty.client.http.HttpReceiverOverHTTP
- All Implemented Interfaces:
HttpParser.HttpHandler
,HttpParser.ResponseHandler
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
badMessage
(BadMessageException failure) Called to signal that a bad HTTP message has been received.boolean
content
(ByteBuffer buffer) boolean
void
earlyEOF()
Called to signal that an EOF was received unexpectedly during the parsing of an HTTP messageprotected void
protected ByteBuffer
boolean
protected boolean
boolean
protected ByteBuffer
void
parsedHeader
(HttpField field) This is the method called by parser when an HTTP Header name and value is foundvoid
parsedTrailer
(HttpField trailer) This is the method called by parser when an HTTP Trailer name and value is foundvoid
receive()
protected void
reset()
Resets the state of this HttpReceiver.void
startResponse
(HttpVersion version, int status, String reason) This is the method called by parser when the HTTP request line is parsedtoString()
Methods inherited from class org.eclipse.jetty.client.HttpReceiver
abort, demand, dispose, getHttpDestination, getHttpExchange, hasDemandOrStall, isFailed, responseBegin, responseContent, responseFailure, responseHeader, responseHeaders, responseSuccess, storeCookie
-
Constructor Details
-
HttpReceiverOverHTTP
-
-
Method Details
-
getHttpChannel
- Overrides:
getHttpChannel
in classHttpReceiver
-
getResponseBuffer
-
receive
public void receive()- Overrides:
receive
in classHttpReceiver
-
onUpgradeFrom
-
fillInterested
protected void fillInterested() -
isShutdown
protected boolean isShutdown() -
startResponse
Description copied from interface:HttpParser.ResponseHandler
This is the method called by parser when the HTTP request line is parsed- Specified by:
startResponse
in interfaceHttpParser.ResponseHandler
- Parameters:
version
- the http version in usestatus
- the response statusreason
- the response reason phrase
-
parsedHeader
Description copied from interface:HttpParser.HttpHandler
This is the method called by parser when an HTTP Header name and value is found- Specified by:
parsedHeader
in interfaceHttpParser.HttpHandler
- Parameters:
field
- The field parsed
-
headerComplete
public boolean headerComplete()- Specified by:
headerComplete
in interfaceHttpParser.HttpHandler
-
content
- Specified by:
content
in interfaceHttpParser.HttpHandler
-
contentComplete
public boolean contentComplete()- Specified by:
contentComplete
in interfaceHttpParser.HttpHandler
-
parsedTrailer
Description copied from interface:HttpParser.HttpHandler
This is the method called by parser when an HTTP Trailer name and value is found- Specified by:
parsedTrailer
in interfaceHttpParser.HttpHandler
- Parameters:
trailer
- The field parsed
-
messageComplete
public boolean messageComplete()- Specified by:
messageComplete
in interfaceHttpParser.HttpHandler
-
earlyEOF
public void earlyEOF()Description copied from interface:HttpParser.HttpHandler
Called to signal that an EOF was received unexpectedly during the parsing of an HTTP message- Specified by:
earlyEOF
in interfaceHttpParser.HttpHandler
-
badMessage
Description copied from interface:HttpParser.HttpHandler
Called to signal that a bad HTTP message has been received.- Specified by:
badMessage
in interfaceHttpParser.HttpHandler
- Parameters:
failure
- the failure with the bad message information
-
reset
protected void reset()Description copied from class:HttpReceiver
Resets the state of this HttpReceiver.Subclasses should override (but remember to call
super
) to reset their own state.Either this method or
HttpReceiver.dispose()
is called.- Overrides:
reset
in classHttpReceiver
-
toString
- Overrides:
toString
in classHttpReceiver
-