public interface

ProducingNHttpEntity

implements HttpEntity
org.apache.http.nio.entity.ProducingNHttpEntity
Known Indirect Subclasses

Class Overview

An HttpEntity that can stream content out into a ContentEncoder.

Summary

Public Methods
abstract void finish()
Notification that any resources allocated for writing can be released.
abstract void produceContent(ContentEncoder encoder, IOControl ioctrl)
Notification that content should be written to the encoder.
[Expand]
Inherited Methods
From interface org.apache.http.HttpEntity

Public Methods

public abstract void finish ()

Notification that any resources allocated for writing can be released.

Throws
IOException

public abstract void produceContent (ContentEncoder encoder, IOControl ioctrl)

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 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
IOException