Package org.jitsi.impl.neomedia.protocol
Class PushBufferDataSourceAdapter
- java.lang.Object
-
- javax.media.protocol.DataSource
-
- javax.media.protocol.PushBufferDataSource
-
- org.jitsi.impl.neomedia.protocol.CaptureDeviceDelegatePushBufferDataSource
-
- org.jitsi.impl.neomedia.protocol.PushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>
-
- org.jitsi.impl.neomedia.protocol.PushBufferDataSourceAdapter
-
- All Implemented Interfaces:
javax.media.Controls,javax.media.Duration,javax.media.protocol.CaptureDevice,javax.media.protocol.Controls
public class PushBufferDataSourceAdapter extends PushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>
Implements PushBufferDataSource for a specific PullBufferDataSource.- Author:
- Lyubomir Marinov
-
-
Field Summary
-
Fields inherited from class org.jitsi.impl.neomedia.protocol.PushBufferDataSourceDelegate
dataSource
-
Fields inherited from class org.jitsi.impl.neomedia.protocol.CaptureDeviceDelegatePushBufferDataSource
captureDevice, EMPTY_STREAMS
-
-
Constructor Summary
Constructors Constructor Description PushBufferDataSourceAdapter(javax.media.protocol.PullBufferDataSource dataSource)Initializes a new PushBufferDataSourceAdapter which is to implement PushBufferDataSource capabilities for a specific PullBufferDataSource.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddisconnect()ImplementsDataSource.disconnect().javax.media.protocol.PushBufferStream[]getStreams()ImplementsPushBufferDataSource.getStreams().voidstart()ImplementsDataSource.start().voidstop()ImplementsDataSource.start().-
Methods inherited from class org.jitsi.impl.neomedia.protocol.PushBufferDataSourceDelegate
connect, getContentType, getControl, getControls, getDataSource, getDuration, getLocator
-
Methods inherited from class org.jitsi.impl.neomedia.protocol.CaptureDeviceDelegatePushBufferDataSource
getCaptureDeviceInfo, getFormatControls
-
-
-
-
Constructor Detail
-
PushBufferDataSourceAdapter
public PushBufferDataSourceAdapter(javax.media.protocol.PullBufferDataSource dataSource)
Initializes a new PushBufferDataSourceAdapter which is to implement PushBufferDataSource capabilities for a specific PullBufferDataSource.- Parameters:
dataSource- the PullBufferDataSource the new instance is to implement PushBufferDataSource capabilities for
-
-
Method Detail
-
disconnect
public void disconnect()
ImplementsDataSource.disconnect(). Disposes of the PushBufferStreamAdapters which wrap the PullBufferStreams of the PullBufferDataSource wrapped by this instance.- Specified by:
disconnectin interfacejavax.media.protocol.CaptureDevice- Overrides:
disconnectin classPushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>
-
getStreams
public javax.media.protocol.PushBufferStream[] getStreams()
ImplementsPushBufferDataSource.getStreams(). Gets the PushBufferStreams through which this PushBufferDataSource gives access to its media data.- Specified by:
getStreamsin classPushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>- Returns:
- an array of PushBufferStreams through which this PushBufferDataSource gives access to its media data
-
start
public void start() throws IOExceptionImplementsDataSource.start(). Starts the wrapped PullBufferDataSource and the pushing from the PushBufferStreamAdapters which wrap the PullBufferStreams of the PullBufferDataSource wrapped by this instance.- Specified by:
startin interfacejavax.media.protocol.CaptureDevice- Overrides:
startin classPushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>- Throws:
IOException- if anything wrong happens while starting the wrapped PullBufferDataSource or the pushing from the PushBufferStreamAdapters which wrap the PullBufferStreams of the PullBufferDataSource wrapped by this instance
-
stop
public void stop() throws IOExceptionImplementsDataSource.start(). Stops the wrapped PullBufferDataSource and the pushing from the PushBufferStreamAdapters which wrap the PullBufferStreams of the PullBufferDataSource wrapped by this instance.- Specified by:
stopin interfacejavax.media.protocol.CaptureDevice- Overrides:
stopin classPushBufferDataSourceDelegate<javax.media.protocol.PullBufferDataSource>- Throws:
IOException- if anything wrong happens while stopping the wrapped PullBufferDataSource or the pushing from the PushBufferStreamAdapters which wrap the PullBufferStreams of the PullBufferDataSource wrapped by this instance
-
-