net.java.sip.communicator.impl.media
Class StreamSubstituteBufferTransferHandler
java.lang.Object
net.java.sip.communicator.impl.media.StreamSubstituteBufferTransferHandler
- All Implemented Interfaces:
- javax.media.protocol.BufferTransferHandler
public class StreamSubstituteBufferTransferHandler
- extends Object
- implements javax.media.protocol.BufferTransferHandler
Implements a BufferTransferHandler wrapper which doesn't
expose a PushBufferStream but rather a specific substitute in order
to give full control to the PushBufferStream.read(Buffer) method of
the substitute.
The purpose is achieved in #transferData(PushBufferStream)
where the method argument stream is ignored and the substitute
is used instead.
- Author:
- Lubomir Marinov
|
Constructor Summary |
StreamSubstituteBufferTransferHandler(javax.media.protocol.BufferTransferHandler transferHandler,
javax.media.protocol.PushBufferStream stream,
javax.media.protocol.PushBufferStream substitute)
Initializes a new StreamSubstituteBufferTransferHandler instance
which is to overwrite the source PushBufferStream of a specific
BufferTransferHandler. |
|
Method Summary |
void |
transferData(javax.media.protocol.PushBufferStream stream)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
StreamSubstituteBufferTransferHandler
public StreamSubstituteBufferTransferHandler(javax.media.protocol.BufferTransferHandler transferHandler,
javax.media.protocol.PushBufferStream stream,
javax.media.protocol.PushBufferStream substitute)
- Initializes a new StreamSubstituteBufferTransferHandler instance
which is to overwrite the source PushBufferStream of a specific
BufferTransferHandler.
- Parameters:
transferHandler - the BufferTransferHandler the new
instance is to overwrite the source PushBufferStream
ofstream - the PushBufferStream to be overridden for the
specified transferHandler with the specified
substitutesubstitute - the PushBufferStream to override the
specified stream for the specified
transferHandler
transferData
public void transferData(javax.media.protocol.PushBufferStream stream)
- Specified by:
transferData in interface javax.media.protocol.BufferTransferHandler
SIP Communicator, the OpenSource Java VoIP and Instant Messaging client.
Distributable under LGPL license.