public class OggPageHeader
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
OggPageHeader.HeaderTypeFlag
This represents all the flags that can be set in the headerType field.
|
static class |
OggPageHeader.PacketStartAndLength
Within the page specifies the start and length of each packet
in the page offset from the end of the pageheader (after the segment table)
|
Constructor and Description |
---|
OggPageHeader(byte[] b) |
Modifier and Type | Method and Description |
---|---|
double |
getAbsoluteGranulePosition() |
int |
getCheckSum() |
byte |
getHeaderType() |
java.util.List<OggPageHeader.PacketStartAndLength> |
getPacketList() |
int |
getPageLength() |
int |
getPageSequence() |
byte[] |
getRawHeaderData() |
byte[] |
getSegmentTable() |
int |
getSerialNumber() |
long |
getStartByte()
Startbyte of this pageHeader in the file
This is useful for Ogg files that contain unsupported additional data at the start of the file such
as ID3 data
|
boolean |
isLastPacketIncomplete() |
boolean |
isValid() |
static OggPageHeader |
read(java.nio.ByteBuffer byteBuffer)
Read next PageHeader from Buffer
|
static OggPageHeader |
read(java.io.RandomAccessFile raf)
Read next PageHeader from file
|
void |
setStartByte(long startByte) |
java.lang.String |
toString() |
private int |
u(int i) |
public static java.util.logging.Logger logger
public static final byte[] CAPTURE_PATTERN
public static final int OGG_PAGE_HEADER_FIXED_LENGTH
public static final int MAXIMUM_NO_OF_SEGMENT_SIZE
public static final int MAXIMUM_SEGMENT_SIZE
public static final int MAXIMUM_PAGE_HEADER_SIZE
public static final int MAXIMUM_PAGE_DATA_SIZE
public static final int MAXIMUM_PAGE_SIZE
public static final int FIELD_CAPTURE_PATTERN_POS
public static final int FIELD_STREAM_STRUCTURE_VERSION_POS
public static final int FIELD_HEADER_TYPE_FLAG_POS
public static final int FIELD_ABSOLUTE_GRANULE_POS
public static final int FIELD_STREAM_SERIAL_NO_POS
public static final int FIELD_PAGE_SEQUENCE_NO_POS
public static final int FIELD_PAGE_CHECKSUM_POS
public static final int FIELD_PAGE_SEGMENTS_POS
public static final int FIELD_SEGMENT_TABLE_POS
public static final int FIELD_CAPTURE_PATTERN_LENGTH
public static final int FIELD_STREAM_STRUCTURE_VERSION_LENGTH
public static final int FIELD_HEADER_TYPE_FLAG_LENGTH
public static final int FIELD_ABSOLUTE_GRANULE_LENGTH
public static final int FIELD_STREAM_SERIAL_NO_LENGTH
public static final int FIELD_PAGE_SEQUENCE_NO_LENGTH
public static final int FIELD_PAGE_CHECKSUM_LENGTH
public static final int FIELD_PAGE_SEGMENTS_LENGTH
private byte[] rawHeaderData
private double absoluteGranulePosition
private int checksum
private byte headerTypeFlag
private boolean isValid
private int pageLength
private int pageSequenceNumber
private int streamSerialNumber
private byte[] segmentTable
private java.util.List<OggPageHeader.PacketStartAndLength> packetList
private boolean lastPacketIncomplete
private long startByte
public static OggPageHeader read(java.nio.ByteBuffer byteBuffer) throws java.io.IOException, CannotReadException
byteBuffer
- java.io.IOException
CannotReadException
public static OggPageHeader read(java.io.RandomAccessFile raf) throws java.io.IOException, CannotReadException
raf
- java.io.IOException
CannotReadException
private int u(int i)
public boolean isLastPacketIncomplete()
public double getAbsoluteGranulePosition()
public int getCheckSum()
public byte getHeaderType()
public int getPageLength()
public int getPageSequence()
public int getSerialNumber()
public byte[] getSegmentTable()
public boolean isValid()
public java.util.List<OggPageHeader.PacketStartAndLength> getPacketList()
public byte[] getRawHeaderData()
public java.lang.String toString()
toString
in class java.lang.Object
public long getStartByte()
public void setStartByte(long startByte)
Copyright © 2005-2013 java.net. All Rights Reserved.