|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.red5.io.mp3.impl.MP3Reader
public class MP3Reader
Read MP3 files
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.red5.io.flv.IKeyFrameDataAnalyzer |
|---|
IKeyFrameDataAnalyzer.KeyFrameMeta |
| Field Summary | |
|---|---|
protected static Logger |
log
Logger |
| Constructor Summary | |
|---|---|
MP3Reader(File file)
Creates reader from file input stream |
|
| Method Summary | |
|---|---|
IKeyFrameDataAnalyzer.KeyFrameMeta |
analyzeKeyFrames()
Analyze and return keyframe metadata. |
void |
close()
Closes the reader and free any allocated memory. |
void |
decodeHeader()
Decode the header of the stream; |
long |
getBytesRead()
Returns the amount of bytes read |
long |
getDuration()
Return length in seconds |
IStreamableFile |
getFile()
Return the file that is loaded. |
int |
getOffset()
Returns the offet length |
long |
getTotalBytes()
Get the total readable bytes in a file or ByteBuffer. |
boolean |
hasMoreTags()
Returns a boolean stating whether the FLV has more tags |
boolean |
hasVideo()
A MP3 stream never has video. |
void |
position(long pos)
Move the reader pointer to given position in file. |
ITag |
readTag()
Returns a Tag object |
void |
searchNextFrame()
Search for next frame sync word. |
void |
setFrameCache(IKeyFrameMetaCache frameCache)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static Logger log
| Constructor Detail |
|---|
public MP3Reader(File file)
throws FileNotFoundException
file - file input
FileNotFoundException - if not found| Method Detail |
|---|
public boolean hasVideo()
hasVideo in interface ITagReaderfalsepublic void setFrameCache(IKeyFrameMetaCache frameCache)
public void searchNextFrame()
public IStreamableFile getFile()
getFile in interface ITagReaderpublic int getOffset()
getOffset in interface ITagReaderpublic long getBytesRead()
getBytesRead in interface ITagReaderpublic long getDuration()
getDuration in interface ITagReaderpublic long getTotalBytes()
getTotalBytes in interface ITagReaderpublic boolean hasMoreTags()
hasMoreTags in interface ITagReaderpublic ITag readTag()
readTag in interface ITagReaderpublic void close()
close in interface ITagReaderpublic void decodeHeader()
decodeHeader in interface ITagReaderpublic void position(long pos)
position in interface ITagReaderpos - File position to move topublic IKeyFrameDataAnalyzer.KeyFrameMeta analyzeKeyFrames()
analyzeKeyFrames in interface IKeyFrameDataAnalyzer
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||