java.lang.Object | |
↳ | org.apache.http.entity.AbstractHttpEntity |
Known Direct Subclasses |
Known Indirect Subclasses |
Abstract base class for entities.
Provides the commonly used attributes for streamed and self-contained
implementations of HttpEntity
.
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
chunked | The 'chunked' flag. | ||||||||||
contentEncoding | The Content-Encoding header. | ||||||||||
contentType | The Content-Type header. |
Protected Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Protected default constructor.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Does not consume anything.
| |||||||||||
Obtains the Content-Encoding header.
| |||||||||||
Obtains the Content-Type header.
| |||||||||||
Obtains the 'chunked' flag.
| |||||||||||
Specifies the 'chunked' flag.
| |||||||||||
Specifies the Content-Encoding header.
| |||||||||||
Specifies the Content-Encoding header, as a string.
| |||||||||||
Specifies the Content-Type header, as a string.
| |||||||||||
Specifies the Content-Type header.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class java.lang.Object
| |||||||||||
From interface org.apache.http.HttpEntity
|
The 'chunked' flag.
Returned by isChunked
,
unless that method is overridden.
The Content-Encoding header.
Returned by getContentEncoding
,
unless that method is overridden.
The Content-Type header.
Returned by getContentType
,
unless that method is overridden.
Protected default constructor.
The attributes of the created object remain
null
and false
, respectively.
Does not consume anything.
The default implementation does nothing if
isStreaming
returns false
, and throws an exception
if it returns true
.
This removes the burden of implementing
an empty method for non-streaming entities.
IOException | in case of an I/O problem |
---|---|
UnsupportedOperationException | if a streaming subclass does not override this method |
Obtains the Content-Encoding header.
The default implementation returns the value of the
contentEncoding
attribute.
null
Obtains the Content-Type header.
The default implementation returns the value of the
contentType
attribute.
null
Obtains the 'chunked' flag.
The default implementation returns the value of the
chunked
attribute.
Specifies the 'chunked' flag.
The default implementation sets the value of the
chunked
attribute.
b | the new 'chunked' flag |
---|
Specifies the Content-Encoding header.
The default implementation sets the value of the
contentEncoding
attribute.
contentEncoding | the new Content-Encoding header, or
null to unset
|
---|
Specifies the Content-Encoding header, as a string.
The default implementation calls
setContentEncoding(Header)
.
ceString | the new Content-Encoding header, or
null to unset
|
---|
Specifies the Content-Type header, as a string.
The default implementation calls
setContentType(Header)
.
ctString | the new Content-Type header, or
null to unset
|
---|
Specifies the Content-Type header.
The default implementation sets the value of the
contentType
attribute.
contentType | the new Content-Encoding header, or
null to unset
|
---|