net.sf.asyncobjects.io
Class BufferedByteChannel
java.lang.Object
net.sf.asyncobjects.AsyncUnicastServer<C>
net.sf.asyncobjects.io.WrappingChannel<BinaryData,AByteInput,AByteOutput,AByteChannel>
net.sf.asyncobjects.io.BufferedByteChannel
- All Implemented Interfaces:
- ACloseable, AsyncObject, ExplicitSharing, AByteChannel, AChannel<BinaryData,AByteInput,AByteOutput>
public class BufferedByteChannel
- extends WrappingChannel<BinaryData,AByteInput,AByteOutput,AByteChannel>
- implements AByteChannel
Byte channel that wraps existing channel and adds buffering functionality
over it.
- Author:
- const
Field Summary |
protected int |
bufferSize
a buffer size |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
bufferSize
protected final int bufferSize
- a buffer size
BufferedByteChannel
public BufferedByteChannel(AByteChannel wrapped,
int bufferSize)
- A constructor
- Parameters:
wrapped
- a wrapped channelbufferSize
- a buffer size for streams
wrap
protected AByteInput wrap(AByteInput input)
- Wrap input into buffered stream
- Specified by:
wrap
in class WrappingChannel<BinaryData,AByteInput,AByteOutput,AByteChannel>
- Parameters:
input
- an input to wrap
- Returns:
- a buffered stream
- See Also:
WrappingChannel.wrap(net.sf.asyncobjects.io.AInput)
wrap
protected AByteOutput wrap(AByteOutput output)
- Wrap output into buffered stream
- Specified by:
wrap
in class WrappingChannel<BinaryData,AByteInput,AByteOutput,AByteChannel>
- Parameters:
output
- an output
- Returns:
- wrapped stream
- See Also:
WrappingChannel.wrap(net.sf.asyncobjects.io.AOutput)
Copyright © 2002-2007 Constantine Plotnikov. All Rights Reserved.