org.ocap.media
Class VBIFilterEvent

java.lang.Object
  extended by org.ocap.media.VBIFilterEvent

public class VBIFilterEvent
extends java.lang.Object

This class represents a VBI filter event. When a specific event happens, the VBIFilterListener.filterUpdate(org.ocap.media.VBIFilterEvent) method is called with an event that has a proper event code to indicate the event.


Field Summary
static int EVENT_CODE_BUFFER_FULL
          Indicates an internal buffer is full.
static int EVENT_CODE_FAILED_TO_DESCRAMBLE
          Indicates descrambling is unavailable for current video.
static int EVENT_CODE_FIRST_VBI_DATA_AVAILABLE
          Indicates that the first VBI data unit is available.
static int EVENT_CODE_FORCIBLE_TERMINATED
          Indicates current filtering is terminated forcibly for any reason except other EVENT_CODE_ constants.
static int EVENT_CODE_TIME_NOTIFICATION
          Indicates that a specified time-period elapsed after receiving the first byte of a data unit.
static int EVENT_CODE_TIMEOUT
          Indicates a timeout (specified by VBIFilter.setTimeOut(long)) occurred, i.e., this event code indicates no data unit is available.
static int EVENT_CODE_UNITS_NOTIFICATION
          Indicates that the specified number of new data units are filtered and stored in a buffer cyclically.
static int EVENT_CODE_VIDEO_SOURCE_CHANGED
          Indicates the current video for VBI data unit filtering has changed.
 
Constructor Summary
VBIFilterEvent()
          Constructor of this class.
 
Method Summary
 java.lang.Object getAppData()
          This method returns application specific data that was specified by VBIFilter.startFiltering() methods.
 int getEventCode()
          This method returns the specific event code that caused this event.
 java.lang.Object getSource()
          This method returns an instance of a class implementing VBIFilter that is the source of the event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EVENT_CODE_FIRST_VBI_DATA_AVAILABLE

public static final int EVENT_CODE_FIRST_VBI_DATA_AVAILABLE
Indicates that the first VBI data unit is available. This event code is issued only once after calling VBIFilter.startFiltering(java.lang.Object) method even if multiple lines/fields is specified to the filter. Filtering continues.

See Also:
Constant Field Values

EVENT_CODE_FORCIBLE_TERMINATED

public static final int EVENT_CODE_FORCIBLE_TERMINATED
Indicates current filtering is terminated forcibly for any reason except other EVENT_CODE_ constants. E.g., a VBIFilter.stopFiltering() is called.

See Also:
Constant Field Values

EVENT_CODE_VIDEO_SOURCE_CHANGED

public static final int EVENT_CODE_VIDEO_SOURCE_CHANGED
Indicates the current video for VBI data unit filtering has changed. Note that current filtering doesn't stop even if this event happens. An application may stop filtering and then restart to retrieve valid data units.

See Also:
Constant Field Values

EVENT_CODE_FAILED_TO_DESCRAMBLE

public static final int EVENT_CODE_FAILED_TO_DESCRAMBLE
Indicates descrambling is unavailable for current video. Note that current filtering doesn't stop even if this event happens. Continues filtering until timeout.

See Also:
Constant Field Values

EVENT_CODE_TIMEOUT

public static final int EVENT_CODE_TIMEOUT
Indicates a timeout (specified by VBIFilter.setTimeOut(long)) occurred, i.e., this event code indicates no data unit is available.

See Also:
Constant Field Values

EVENT_CODE_BUFFER_FULL

public static final int EVENT_CODE_BUFFER_FULL
Indicates an internal buffer is full. Filtering stops automatically.

See Also:
Constant Field Values

EVENT_CODE_TIME_NOTIFICATION

public static final int EVENT_CODE_TIME_NOTIFICATION
Indicates that a specified time-period elapsed after receiving the first byte of a data unit.

See Also:
Constant Field Values

EVENT_CODE_UNITS_NOTIFICATION

public static final int EVENT_CODE_UNITS_NOTIFICATION
Indicates that the specified number of new data units are filtered and stored in a buffer cyclically.

See Also:
Constant Field Values
Constructor Detail

VBIFilterEvent

public VBIFilterEvent()
Constructor of this class.

Method Detail

getSource

public java.lang.Object getSource()
This method returns an instance of a class implementing VBIFilter that is the source of the event.

Returns:
instance of a class implementing VBIFilter that is the source of the event.

getAppData

public java.lang.Object getAppData()
This method returns application specific data that was specified by VBIFilter.startFiltering() methods.

Returns:
an application specific data that was specified by VBIFilter.startFiltering() methods.

getEventCode

public int getEventCode()
This method returns the specific event code that caused this event.

Returns:
an event code. One of the constants that has EVENT_CODE_ prefix.