net.sf.asyncobjects.io
Class BufferedTextChannel
java.lang.Object
net.sf.asyncobjects.AsyncUnicastServer<C>
net.sf.asyncobjects.io.WrappingChannel<TextData,ATextInput,ATextOutput,ATextChannel>
net.sf.asyncobjects.io.BufferedTextChannel
- All Implemented Interfaces:
- ACloseable, AsyncObject, ExplicitSharing, AChannel<TextData,ATextInput,ATextOutput>, ATextChannel
public class BufferedTextChannel
- extends WrappingChannel<TextData,ATextInput,ATextOutput,ATextChannel>
- implements ATextChannel
Text 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
BufferedTextChannel
public BufferedTextChannel(ATextChannel wrapped,
int bufferSize)
- A constructor
- Parameters:
wrapped
- a wrapped channelbufferSize
- a buffer size for streams
wrap
protected ATextInput wrap(ATextInput input)
- Wrap input into buffered stream
- Specified by:
wrap
in class WrappingChannel<TextData,ATextInput,ATextOutput,ATextChannel>
- Parameters:
input
- an input to wrap
- Returns:
- a buffered stream
- See Also:
WrappingChannel.wrap(net.sf.asyncobjects.io.AInput)
wrap
protected ATextOutput wrap(ATextOutput output)
- Wrap output into buffered stream
- Specified by:
wrap
in class WrappingChannel<TextData,ATextInput,ATextOutput,ATextChannel>
- Parameters:
output
- an output
- Returns:
- wrapped stream
- See Also:
WrappingChannel.wrap(net.sf.asyncobjects.io.AOutput)
Copyright © 2002-2007 Constantine Plotnikov. All Rights Reserved.