Logo Search packages:      
Sourcecode: jampal version File versions  Download package

Public Member Functions | Package Functions | Static Package Attributes | Private Member Functions | Private Attributes

pgbennett::id3::ID3v2Tag Class Reference

Inheritance diagram for pgbennett::id3::ID3v2Tag:
Inheritance graph
Collaboration diagram for pgbennett::id3::ID3v2Tag:
Collaboration graph

List of all members.

Public Member Functions

void copyFrom (ID3Tag tag)
byte[] getBytes ()
byte[] getFrameData (String id)
String getFrameDataString (String id) throws ID3v2FormatException
ID3v2Frames getFrames ()
ID3v2Header getHead ()
int getPadding ()
int getSize ()
int getTotalSize ()
 ID3v2Tag (File mp3, long mpegOffset) throws FileNotFoundException, IOException, ID3v2FormatException
 ID3v2Tag (File mp3, long mpegOffset, boolean emptyTag) throws FileNotFoundException, IOException, ID3v2FormatException
void removeFrame (String id)
void removeTag () throws FileNotFoundException, IOException
void setCommentFrame (String description, String comment)
void setGenericFrame (String id, String data)
void setGenericFrame (String id, String lang, String desc, String data)
void setGenericFrame (String id, byte[] data) throws UnsupportedEncodingException
void setPictureFrame (ID3v2Picture pic) throws UnsupportedEncodingException
void setTextFrame (String id, String data)
void setURLFrame (String id, String data)
void setUserDefinedTextFrame (String description, String value)
void setUserDefinedURLFrame (String description, String value)
boolean tagExists ()
String toString ()
void updateFrameData (String id, byte[] data) throws UnsupportedEncodingException
void writeTag () throws FileNotFoundException, IOException

Package Functions

void init (File mp3, long mpegOffset, boolean emptyTag) throws FileNotFoundException, IOException, ID3v2FormatException

Static Package Attributes

static Properties v2Mappings

Private Member Functions

void parseFrames (UnsynchRandomAccessFile raf) throws IOException, ID3v2FormatException

Private Attributes

final String ENC_TYPE = "ISO-8859-1"
boolean exists
ID3v2ExtendedHeader ext_head = null
ID3v2Footer foot = null
ID3v2Frames frames = null
ID3v2Header head = null
File mp3 = null
final String MP3EXT_BADID = "MP3e"
long mpegOffset
final int NEWTAG_LIMIT = 16000
int padding
int writtenTagSize

Detailed Description

Description: This class reads and writes id3v2 tags from a file.

Version History
1.11.1 - 2002.1023 by gruni
-Made Sourcecode compliant to the Sun CodingConventions
1.11 - 2002.0127 by helliker

-The getBytes method is public to adhere to the ID3Tag interface.

1.10 - 2002.0125 by helliker
-Uses RandomAccessFile.readInt method to read ints.
1.9 - 2002.0125 by helliker
-Writes tag correctly if the 1st mpeg frame is corrupt. -Fixed infinite loop in padding calculation.
1.8 - 2002.0124 by helliker
-Throws an exception with an invalid frame size.
1.7 - 2002.0113 by helliker
-Implements new ID3Tag interface. -Optimized new padding calculation for writing.
1.6 - 2001.1204 by helliker
-Major revisions to size and padding calculations. -Fixes to write and remove methods.
1.5 - 2001.1129 by helliker
-Fixed file handle leaks
1.4 - 2001.1110 by helliker

-Removed the getPaddingBytes method because it was not needed.

1.3 - 2001.1024 by helliker

-The padding size is updated before writing a tag, not during.

-Created a method to update the padding size.

1.2 - 2001.1019 by helliker
-All set for release.
Jonathan Hilliker

Definition at line 77 of file ID3v2Tag.java.

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index