Package org.apache.http.impl.execchain
Class RequestEntityProxy
java.lang.Object
org.apache.http.impl.execchain.RequestEntityProxy
- All Implemented Interfaces:
org.apache.http.HttpEntity
A Proxy class for
HttpEntity enclosed in a request message.- Since:
- 4.3
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid(package private) static voidenhance(org.apache.http.HttpEntityEnclosingRequest request) org.apache.http.Headerlongorg.apache.http.Headerorg.apache.http.HttpEntitybooleanboolean(package private) static booleanisEnhanced(org.apache.http.HttpEntity entity) boolean(package private) static booleanisRepeatable(org.apache.http.HttpRequest request) booleantoString()voidwriteTo(OutputStream outStream)
-
Field Details
-
original
private final org.apache.http.HttpEntity original -
consumed
private boolean consumed
-
-
Constructor Details
-
RequestEntityProxy
RequestEntityProxy(org.apache.http.HttpEntity original)
-
-
Method Details
-
enhance
static void enhance(org.apache.http.HttpEntityEnclosingRequest request) -
isEnhanced
static boolean isEnhanced(org.apache.http.HttpEntity entity) -
isRepeatable
static boolean isRepeatable(org.apache.http.HttpRequest request) -
getOriginal
public org.apache.http.HttpEntity getOriginal() -
isConsumed
public boolean isConsumed() -
isRepeatable
public boolean isRepeatable()- Specified by:
isRepeatablein interfaceorg.apache.http.HttpEntity
-
isChunked
public boolean isChunked()- Specified by:
isChunkedin interfaceorg.apache.http.HttpEntity
-
getContentLength
public long getContentLength()- Specified by:
getContentLengthin interfaceorg.apache.http.HttpEntity
-
getContentType
public org.apache.http.Header getContentType()- Specified by:
getContentTypein interfaceorg.apache.http.HttpEntity
-
getContentEncoding
public org.apache.http.Header getContentEncoding()- Specified by:
getContentEncodingin interfaceorg.apache.http.HttpEntity
-
getContent
- Specified by:
getContentin interfaceorg.apache.http.HttpEntity- Throws:
IOExceptionIllegalStateException
-
writeTo
- Specified by:
writeToin interfaceorg.apache.http.HttpEntity- Throws:
IOException
-
isStreaming
public boolean isStreaming()- Specified by:
isStreamingin interfaceorg.apache.http.HttpEntity
-
consumeContent
- Specified by:
consumeContentin interfaceorg.apache.http.HttpEntity- Throws:
IOException
-
toString
-