public class ContentEncoderChannel
extends java.lang.Object
implements java.nio.channels.WritableByteChannel
WritableByteChannel
that delegates to a ContentEncoder
.
Attempts to close this channel are ignored, and isOpen()
always
returns true
.Modifier and Type | Field and Description |
---|---|
private ContentEncoder |
contentEncoder |
Constructor and Description |
---|
ContentEncoderChannel(ContentEncoder contentEncoder) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
boolean |
isOpen() |
int |
write(java.nio.ByteBuffer src) |
private final ContentEncoder contentEncoder
public ContentEncoderChannel(ContentEncoder contentEncoder)
public int write(java.nio.ByteBuffer src) throws java.io.IOException
write
in interface java.nio.channels.WritableByteChannel
java.io.IOException
public void close()
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in interface java.nio.channels.Channel
public boolean isOpen()
isOpen
in interface java.nio.channels.Channel