| Modifier and Type | Class and Description |
|---|---|
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private static final Field | |
| private static final Field |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| private static boolean | |
| public static ReadableByteChannel | |
| public static OutputStream | Returns: An unwrapped stream, presumably unbufferedThe stream to unwrap filteredStream)Unwrap all filtering streams between the given stream and its actual unfiltered stream. |
| public static InputStream | Returns: An unwrapped stream, presumably unbufferedThe stream to unwrap filteredStream)Unwrap all filtering streams between the given stream and its actual unfiltered stream. |
| private static OutputStream | |
| private static InputStream | |
| public static InputStream | Returns: the deeped non-FilterInputStream stream, or filterInputStream if it is not a FilterInputStream to begin with.a stream to be unwrapped, if it is a FilterInputStream filteredStream)Unwrap the given stream to its first non-FilterInputStream. |
| public static OutputStream | Returns: the deeped non-FilterOutputStream stream, or filterOutputStream if it is not a FilterOutputStream to begin with.a stream to be unwrapped, if it is a FilterOutputStream filteredStream)Unwrap the given stream to its first non-FilterOutputStream. |
| public static WritableByteChannel |
| filterInField | back to summary |
|---|---|
| private static final Field filterInField | |
| filterOutField | back to summary |
|---|---|
| private static final Field filterOutField | |
| ChannelHelper | back to summary |
|---|---|
| private ChannelHelper() | |
| isDripSwitchable | back to summary |
|---|---|
| private static boolean isDripSwitchable(Object stream) | |
| readableChannel | back to summary |
|---|---|
| public static ReadableByteChannel readableChannel(final InputStream inputStream) | |
| unwrapBufferedStream | back to summary |
|---|---|
| public static OutputStream unwrapBufferedStream(OutputStream filteredStream) Unwrap all filtering streams between the given stream and its actual unfiltered stream. This is primarily to unwrap streams that have buffers that would interfere with interactivity.
| |
| unwrapBufferedStream | back to summary |
|---|---|
| public static InputStream unwrapBufferedStream(InputStream filteredStream) Unwrap all filtering streams between the given stream and its actual unfiltered stream. This is primarily to unwrap streams that have buffers that would interfere with interactivity.
| |
| unwrapDripStream | back to summary |
|---|---|
| private static OutputStream unwrapDripStream(OutputStream stream) | |
| unwrapDripStream | back to summary |
|---|---|
| private static InputStream unwrapDripStream(InputStream stream) | |
| unwrapFilterInputStream | back to summary |
|---|---|
| public static InputStream unwrapFilterInputStream(InputStream filteredStream) Unwrap the given stream to its first non-FilterInputStream. If the stream is not a FilterInputStream it is returned immediately. Note that this version is used when you are absolutely sure you want to unwrap; the unwrapBufferedStream version will perform checks for certain types of process-related streams that should not be unwrapped (Java 7+ Process, e.g.).
| |
| unwrapFilterOutputStream | back to summary |
|---|---|
| public static OutputStream unwrapFilterOutputStream(OutputStream filteredStream) Unwrap the given stream to its first non-FilterOutputStream. If the stream is not a FilterOutputStream it is returned immediately. Note that this version is used when you are absolutely sure you want to unwrap; the unwrapBufferedStream version will perform checks for certain types of process-related streams that should not be unwrapped (Java 7+ Process, e.g.).
| |
| writableChannel | back to summary |
|---|---|
| public static WritableByteChannel writableChannel(final OutputStream outputStream) | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final WritableByteChannel | |
| private final OutputStream |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| protected void | implCloseChannel()
Implements abstract java. Closes this channel. |
| public int | write(ByteBuffer
The buffer from which bytes are to be retrieved src)Implements java. Writes a sequence of bytes to this channel from the given buffer. |
| out | back to summary |
|---|---|
| pack-priv final WritableByteChannel out | |
| output | back to summary |
|---|---|
| private final OutputStream output | |
| SyncOutputStreamChannel | back to summary |
|---|---|
| pack-priv SyncOutputStreamChannel(OutputStream output) | |
| implCloseChannel | back to summary |
|---|---|
| protected void implCloseChannel() throws IOException Implements abstract java. Doc from java. Closes this channel. This method is invoked by the An implementation of this method must arrange for any other thread that is blocked in an I/O operation upon this channel to return immediately, either by throwing an exception or by returning normally.
| |
| write | back to summary |
|---|---|
| public int write(ByteBuffer src) throws IOException Implements java. Doc from java. Writes a sequence of bytes to this channel from the given buffer. An attempt is made to write up to r bytes to the channel,
where r is the number of bytes remaining in the buffer, that is,
Suppose that a byte sequence of length n is written, where
Unless otherwise specified, a write operation will return only after writing all of the r requested bytes. Some types of channels, depending upon their state, may write only some of the bytes or possibly none at all. A socket channel in non-blocking mode, for example, cannot write any more bytes than are free in the socket's output buffer. This method may be invoked at any time. If another thread has already initiated a write operation upon this channel, however, then an invocation of this method will block until the first operation is complete.
| |