All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.ocap.si.Descriptor.html Maven / Gradle / Ivy

There is a newer version: 1.3.1
Show newest version






Descriptor














org.ocap.si
Class Descriptor

java.lang.Object
  extended by org.ocap.si.Descriptor

public abstract class Descriptor
extends java.lang.Object

This class represents an MPEG-2 descriptor.


Constructor Summary
Descriptor()
           
 
Method Summary
abstract  byte getByteAt(int index)
          Get a particular byte within the descriptor content.
abstract  byte[] getContent()
          Get the data contained within this descriptor.
abstract  short getContentLength()
          Get the descriptor_length field.
abstract  short getTag()
          Get the descriptor_tag field.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Descriptor

public Descriptor()
Method Detail

getTag

public abstract short getTag()
Get the descriptor_tag field. Eight bit field that identifies each descriptor. The range of valid MPEG-2 descriptor tag values is 0x2 through 0xFF.

Returns:
The descriptor tag.

getContentLength

public abstract short getContentLength()
Get the descriptor_length field. Eight bit field specifying the number of bytes of the descriptor immediately following the descriptor_length field.

Returns:
The descriptor length.

getContent

public abstract byte[] getContent()
Get the data contained within this descriptor. The data is returned in an array of bytes and consists of the data immediately following the descriptor_length field with length indicated by that field.

Returns:
The descriptor data.

getByteAt

public abstract byte getByteAt(int index)
Get a particular byte within the descriptor content. The data is returned in a byte which is located at the position specified by an index parameter in the data content immediately following the descriptor_length field.

Parameters:
index - An index to the descriptor content. Value 0 corresponds to the first byte after the length field.
Returns:
The required byte data.
Throws:
java.lang.IndexOutOfBoundsException - if index < 0 or index >= ContentLength






© 2015 - 2024 Weber Informatics LLC | Privacy Policy