Interface HttpEncoding (1.44.2)

public interface HttpEncoding

HTTP content encoding.

Implementations don't need to be thread-safe.

Methods

encode(StreamingContent content, OutputStream out)

public abstract void encode(StreamingContent content, OutputStream out)

Encodes the streaming content into the output stream.

Implementations must not close the output stream, and instead should flush the output stream. Some callers may assume that the output stream has not been closed, and will fail to work if it has been closed.

Parameters
Name Description
content StreamingContent

streaming content

out OutputStream

output stream

Exceptions
Type Description
IOException

getName()

public abstract String getName()

Returns the content encoding name (for example "gzip") or null for none.

Returns
Type Description
String