javax.media
接口 PlugIn

所有超级接口:
Controls
所有已知子接口:
Codec, Demultiplexer, Effect, Multiplexer, Renderer
所有已知实现类:
BasicCodec, BasicPlugIn

public interface PlugIn
extends Controls

The base interface for JMF plug-ins. A PlugIn is a media processing unit that accepts data in a particular format and processes or presents the data. Plug-ins are registered through the PlugInManager.

从以下版本开始:
JMF 2.0

字段摘要
static int BUFFER_PROCESSED_FAILED
          The input Buffer could not be handled.
static int BUFFER_PROCESSED_OK
          The input Buffer was converted successfully to output.
static int INPUT_BUFFER_NOT_CONSUMED
          The input Buffer chunk was not fully consumed.
static int OUTPUT_BUFFER_NOT_FILLED
          The output Buffer chunk was not filled.
static int PLUGIN_TERMINATED
          The processing of the given buffer has caused the plugin to terminate.
 
方法摘要
 void close()
          Closes the plug-in component and releases the resources it was using.
 java.lang.String getName()
          Gets the name of this plug-in as a human-readable string.
 void open()
          Opens the plug-in software or hardware component and acquires the resources that the plug-in needs to operate.
 void reset()
          Resets the state of the plug-in.
 
从接口 javax.media.Controls 继承的方法
getControl, getControls
 

字段详细信息

BUFFER_PROCESSED_OK

static final int BUFFER_PROCESSED_OK
The input Buffer was converted successfully to output.

另请参见:
常量字段值

BUFFER_PROCESSED_FAILED

static final int BUFFER_PROCESSED_FAILED
The input Buffer could not be handled.

另请参见:
常量字段值

INPUT_BUFFER_NOT_CONSUMED

static final int INPUT_BUFFER_NOT_CONSUMED
The input Buffer chunk was not fully consumed. The plug-in should update the offset + length fields of the Buffer. The plug-in will be called later with the same input Buffer.

另请参见:
常量字段值

OUTPUT_BUFFER_NOT_FILLED

static final int OUTPUT_BUFFER_NOT_FILLED
The output Buffer chunk was not filled. The plug-in should update the offset + length fields of the Buffer. The plug-in will be called later with the same output Buffer.

另请参见:
常量字段值

PLUGIN_TERMINATED

static final int PLUGIN_TERMINATED
The processing of the given buffer has caused the plugin to terminate. The plugin will not be able to continue further processing.

另请参见:
常量字段值
方法详细信息

getName

java.lang.String getName()
Gets the name of this plug-in as a human-readable string.

返回:
A String that contains the descriptive name of the plug-in.

open

void open()
          throws ResourceUnavailableException
Opens the plug-in software or hardware component and acquires the resources that the plug-in needs to operate. All required input and/or output formats have to be set on the plug-in before open is called. Buffers should not be passed into the plug-in without first calling this method.

抛出:
ResourceUnavailableException - If all of the required resources cannot be acquired.

close

void close()
Closes the plug-in component and releases the resources it was using. No more data will be accepted by the plug-in after close is called. A closed plug-in can be reinstated by calling open again.


reset

void reset()
Resets the state of the plug-in. The reset method is typically called if the end of media is reached or the media is repositioned.