Package org.apache.http.nio.entity
Interface ProducingNHttpEntity
-
- All Superinterfaces:
HttpEntity
- All Known Implementing Classes:
NByteArrayEntity
,NFileEntity
,NHttpEntityWrapper
,NStringEntity
@Deprecated public interface ProducingNHttpEntity extends HttpEntity
Deprecated.use (4.2)BasicAsyncRequestProducer
orBasicAsyncResponseProducer
AnHttpEntity
that can stream content out into aContentEncoder
.- Since:
- 4.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
finish()
Deprecated.Notification that any resources allocated for writing can be released.void
produceContent(ContentEncoder encoder, IOControl ioctrl)
Deprecated.Notification that content should be written to the encoder.-
Methods inherited from interface org.apache.http.HttpEntity
consumeContent, getContent, getContentEncoding, getContentLength, getContentType, isChunked, isRepeatable, isStreaming, writeTo
-
-
-
-
Method Detail
-
produceContent
void produceContent(ContentEncoder encoder, IOControl ioctrl) throws java.io.IOException
Deprecated.Notification that content should be written to the encoder.IOControl
instance passed as a parameter to the method can be used to suspend output events if the entity is temporarily unable to produce more content.When all content is finished, this MUST call
ContentEncoder.complete()
. Failure to do so could result in the entity never being written.- Parameters:
encoder
- content encoder.ioctrl
- I/O control of the underlying connection.- Throws:
java.io.IOException
-
finish
void finish() throws java.io.IOException
Deprecated.Notification that any resources allocated for writing can be released.- Throws:
java.io.IOException
-
-