public class StreamInfo extends Metadata
isLast, METADATA_TYPE_APPLICATION, METADATA_TYPE_CUESHEET, METADATA_TYPE_PADDING, METADATA_TYPE_PICTURE, METADATA_TYPE_SEEKTABLE, METADATA_TYPE_STREAMINFO, METADATA_TYPE_VORBIS_COMMENT, STREAM_METADATA_IS_LAST_LEN, STREAM_METADATA_LENGTH_LEN, STREAM_METADATA_TYPE_LEN| Constructor and Description |
|---|
StreamInfo(BitInputStream is,
int length,
boolean isLast)
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addTotalSamples(long totalSamples) |
int |
calcLength()
Calculate the metadata block size.
|
boolean |
compatiable(StreamInfo info)
Check for compatiable StreamInfo.
|
AudioFormat |
getAudioFormat() |
int |
getBitsPerSample() |
int |
getChannels() |
int |
getMaxBlockSize() |
int |
getMaxFrameSize() |
int |
getMinBlockSize() |
int |
getMinFrameSize() |
int |
getSampleRate() |
long |
getTotalSamples() |
void |
setTotalSamples(long totalSamples) |
String |
toString()
Convert to string.
|
void |
write(BitOutputStream os,
boolean isLast)
Write out the metadata block.
|
public StreamInfo(BitInputStream is, int length, boolean isLast) throws IOException
is - The InputBitStreamlength - Length of the recordisLast - True if this is the last Metadata block in the chainIOException - Thrown if error reading from InputBitStreampublic void write(BitOutputStream os, boolean isLast) throws IOException
os - The output streamisLast - True if this is the last metadata blockIOException - Thrown if error writing datapublic int calcLength()
public boolean compatiable(StreamInfo info)
info - The StreamInfo block to checkpublic String toString()
toString in class ObjectObject.toString()public int getMaxBlockSize()
public int getMinBlockSize()
public long getTotalSamples()
public void setTotalSamples(long totalSamples)
totalSamples - The totalSamples to set.public void addTotalSamples(long totalSamples)
totalSamples - The totalSamples to add.public int getMaxFrameSize()
public int getMinFrameSize()
public int getSampleRate()
public AudioFormat getAudioFormat()
public int getBitsPerSample()
public int getChannels()
Copyright © 2004–2017. All rights reserved.