|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.sound.sampled.spi.AudioFileReader
org.tritonus.share.sampled.file.TAudioFileReader
javazoom.spi.mpeg.sampled.file.MpegAudioFileReader
public class MpegAudioFileReader
This class implements AudioFileReader for MP3 SPI.
Field Summary | |
---|---|
static int |
INITAL_READ_LENGTH
|
static java.lang.String |
VERSION
|
Constructor Summary | |
---|---|
MpegAudioFileReader()
|
Method Summary | |
---|---|
javax.sound.sampled.AudioFileFormat |
getAudioFileFormat(java.io.File file)
Returns AudioFileFormat from File. |
javax.sound.sampled.AudioFileFormat |
getAudioFileFormat(java.io.InputStream inputStream,
long mediaLength)
Returns AudioFileFormat from inputstream and medialength. |
javax.sound.sampled.AudioFileFormat |
getAudioFileFormat(java.net.URL url)
Returns AudioFileFormat from URL. |
javax.sound.sampled.AudioInputStream |
getAudioInputStream(java.io.File file)
Returns AudioInputStream from file. |
javax.sound.sampled.AudioInputStream |
getAudioInputStream(java.io.InputStream inputStream)
Return the AudioInputStream from the given InputStream. |
javax.sound.sampled.AudioInputStream |
getAudioInputStream(java.net.URL url)
Returns AudioInputStream from url. |
protected void |
loadShoutcastInfo(java.io.InputStream input,
java.util.HashMap props)
Load shoutcast (ICY) info. |
protected void |
parseID3v1Frames(byte[] frames,
java.util.HashMap props)
Parser ID3v1 frames |
protected void |
parseID3v2Frames(java.io.InputStream frames,
java.util.HashMap props)
Parse ID3v2 frames to add album (TALB), title (TIT2), date (TYER), author (TPE1), copyright (TCOP), comment (COMM) ... |
protected java.lang.String |
parseText(byte[] bframes,
int offset,
int size,
int skip)
Parse Text Frames. |
Methods inherited from class org.tritonus.share.sampled.file.TAudioFileReader |
---|
calculateFrameSize, getAudioFileFormat, getAudioInputStream, readIeeeExtended, readLittleEndianInt, readLittleEndianShort |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String VERSION
public static final int INITAL_READ_LENGTH
Constructor Detail |
---|
public MpegAudioFileReader()
Method Detail |
---|
public javax.sound.sampled.AudioFileFormat getAudioFileFormat(java.io.File file) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioFileFormat
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
public javax.sound.sampled.AudioFileFormat getAudioFileFormat(java.net.URL url) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioFileFormat
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
public javax.sound.sampled.AudioFileFormat getAudioFileFormat(java.io.InputStream inputStream, long mediaLength) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioFileFormat
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
public javax.sound.sampled.AudioInputStream getAudioInputStream(java.io.File file) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioInputStream
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
public javax.sound.sampled.AudioInputStream getAudioInputStream(java.net.URL url) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioInputStream
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
public javax.sound.sampled.AudioInputStream getAudioInputStream(java.io.InputStream inputStream) throws javax.sound.sampled.UnsupportedAudioFileException, java.io.IOException
getAudioInputStream
in class org.tritonus.share.sampled.file.TAudioFileReader
javax.sound.sampled.UnsupportedAudioFileException
java.io.IOException
protected void parseID3v1Frames(byte[] frames, java.util.HashMap props)
frames
- props
- protected void parseID3v2Frames(java.io.InputStream frames, java.util.HashMap props)
frames
- props
- protected java.lang.String parseText(byte[] bframes, int offset, int size, int skip)
bframes
- offset
- size
- skip
-
protected void loadShoutcastInfo(java.io.InputStream input, java.util.HashMap props) throws java.io.IOException
input
- props
-
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |