|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectSong
CS3134 HW#1 MP3 Song class. Designed to contain information for exactly one song. Complete with built-in routines to automatically read the MP3 header for bitrate and ID3 tags for other info. YOU SHOULD NOT HAVE TO TOUCH THIS CLASS AT ALL.
Constructor Summary | |
Song(java.lang.String filename)
Create a Song instance from a file. |
Method Summary | |
java.lang.String |
getAlbumTitle()
Get the album title. |
java.lang.String |
getArtist()
Get the artist. |
int |
getBitrate()
Get the song's bitrate. |
java.lang.String |
getSongTitle()
Get the song title. |
int |
getYear()
Get the song year. |
int |
length()
Get the song's length (in seconds). |
java.lang.String |
toString()
Return a String representation of this Song. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Song(java.lang.String filename) throws java.io.IOException
filename
- The name of the file
java.io.IOException
- if it has trouble opening the file OR trouble with the
file format. Yes, I know, it's pretty picky right now.Method Detail |
public java.lang.String getArtist()
public java.lang.String getAlbumTitle()
public java.lang.String getSongTitle()
public int getYear()
public int getBitrate()
public int length()
public java.lang.String toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |