|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jaudiotagger.tag.id3.AbstractTagItem
org.jaudiotagger.tag.id3.AbstractTag
org.jaudiotagger.tag.id3.AbstractID3Tag
org.jaudiotagger.tag.id3.AbstractID3v1Tag
org.jaudiotagger.tag.id3.ID3v1Tag
org.jaudiotagger.tag.id3.ID3v11Tag
public class ID3v11Tag
Represents an ID3v11 tag.
| Field Summary | |
|---|---|
protected static int |
FIELD_COMMENT_LENGTH
|
protected static int |
FIELD_COMMENT_POS
|
protected static int |
FIELD_TRACK_INDICATOR_LENGTH
|
protected static int |
FIELD_TRACK_INDICATOR_POS
|
protected static int |
FIELD_TRACK_LENGTH
|
protected static int |
FIELD_TRACK_POS
|
private static byte |
MAJOR_VERSION
|
private static byte |
RELEASE
|
private static byte |
REVISION
|
protected byte |
track
Track is held as a single byte in v1.1 |
protected static int |
TRACK_MAX_VALUE
|
protected static int |
TRACK_MIN_VALUE
|
protected static int |
TRACK_UNDEFINED
|
protected static java.lang.String |
TYPE_TRACK
|
| Fields inherited from class org.jaudiotagger.tag.id3.ID3v1Tag |
|---|
album, artist, BYTE_TO_UNSIGNED, comment, genre, GENRE_UNDEFINED, tagFieldToID3v1Field, title, TYPE_COMMENT, year |
| Fields inherited from class org.jaudiotagger.tag.id3.AbstractID3v1Tag |
|---|
END_OF_FIELD, endofStringPattern, FIELD_ALBUM_LENGTH, FIELD_ALBUM_POS, FIELD_ARTIST_LENGTH, FIELD_ARTIST_POS, FIELD_GENRE_LENGTH, FIELD_GENRE_POS, FIELD_TAGID_LENGTH, FIELD_TAGID_POS, FIELD_TITLE_LENGTH, FIELD_TITLE_POS, FIELD_YEAR_LENGTH, FIELD_YEAR_POS, logger, TAG_DATA_LENGTH, TAG_ID, TAG_LENGTH, TYPE_ALBUM, TYPE_ARTIST, TYPE_GENRE, TYPE_TITLE, TYPE_YEAR |
| Fields inherited from class org.jaudiotagger.tag.id3.AbstractID3Tag |
|---|
TAG_RELEASE |
| Fields inherited from class org.jaudiotagger.tag.id3.AbstractTag |
|---|
TYPE_TAG |
| Constructor Summary | |
|---|---|
ID3v11Tag()
Creates a new ID3v11 datatype. |
|
ID3v11Tag(AbstractTag mp3tag)
Creates a new ID3v11 datatype from a non v11 tag |
|
ID3v11Tag(ID3v11Tag copyObject)
|
|
ID3v11Tag(java.io.RandomAccessFile file)
Deprecated. use ID3v11Tag(RandomAccessFile,String) instead |
|
ID3v11Tag(java.io.RandomAccessFile file,
java.lang.String loggingFilename)
Creates a new ID3v11 datatype. |
|
| Method Summary | |
|---|---|
void |
addTrack(java.lang.String track)
|
void |
createStructure()
Create structured representation of this item. |
void |
deleteField(FieldKey genericKey)
Delete any instance of tag fields with this key |
boolean |
equals(java.lang.Object obj)
Compares Object with this only returns true if both v1_1 tags with all fields set to same value |
int |
getFieldCount()
Return the number of fields |
java.util.List<TagField> |
getFields(FieldKey genericKey)
Returns a list of TagField objects whose "id"
is the specified one. |
java.lang.String |
getFirst(FieldKey genericKey)
Retrieve the first value that exists for this generic key |
java.lang.String |
getFirstComment()
Get Comment |
TagField |
getFirstField(java.lang.String id)
Retrieve the first field that exists for this format specific key |
java.lang.String |
getFirstTrack()
Return the track number as a String. |
byte |
getMajorVersion()
Retrieve the Major Version |
byte |
getRelease()
Retrieve the Release |
byte |
getRevision()
Retrieve the Revision |
java.util.List<TagField> |
getTrack()
|
boolean |
isEmpty()
Determines whether the tag has no fields specified. |
void |
read(java.nio.ByteBuffer byteBuffer)
Read in a tag from the ByteBuffer |
boolean |
seek(java.nio.ByteBuffer byteBuffer)
Find identifier within byteBuffer to indicate that a v11 tag exists within the buffer |
void |
setComment(java.lang.String comment)
Set Comment |
void |
setField(TagField field)
Sets a field in the structure, used internally by the library |
void |
setTrack(java.lang.String trackValue)
Set the track, v11 stores track numbers in a single byte value so can only handle a simple number in the range 0-255. |
void |
write(java.io.RandomAccessFile file)
Write this representation of tag to the file indicated |
| Methods inherited from class org.jaudiotagger.tag.id3.ID3v1Tag |
|---|
addField, addField, addField, createField, createField, deleteArtworkField, deleteField, getAlbum, getArtist, getArtworkList, getComment, getEncoding, getFieldCountIncludingSubValues, getFields, getFields, getFirst, getFirstAlbum, getFirstArtist, getFirstArtwork, getFirstField, getFirstGenre, getFirstTitle, getFirstYear, getGenre, getSubValue, getTitle, getValue, getYear, hasCommonFields, hasField, iterator, returnFieldToList, setAlbum, setArtist, setEncoding, setField, setField, setGenre, setTitle, setYear |
| Methods inherited from class org.jaudiotagger.tag.id3.AbstractID3v1Tag |
|---|
delete, getSize, seekForV1OrV11Tag |
| Methods inherited from class org.jaudiotagger.tag.id3.AbstractID3Tag |
|---|
getIdentifier, getLoggingFilename, setLoggingFilename, toString |
| Methods inherited from class org.jaudiotagger.tag.id3.AbstractTagItem |
|---|
isSubsetOf |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.jaudiotagger.tag.Tag |
|---|
toString |
| Field Detail |
|---|
protected static final java.lang.String TYPE_TRACK
protected static final int TRACK_UNDEFINED
protected static final int TRACK_MAX_VALUE
protected static final int TRACK_MIN_VALUE
protected static final int FIELD_COMMENT_LENGTH
protected static final int FIELD_COMMENT_POS
protected static final int FIELD_TRACK_INDICATOR_LENGTH
protected static final int FIELD_TRACK_INDICATOR_POS
protected static final int FIELD_TRACK_LENGTH
protected static final int FIELD_TRACK_POS
protected byte track
private static final byte RELEASE
private static final byte MAJOR_VERSION
private static final byte REVISION
| Constructor Detail |
|---|
public ID3v11Tag()
public ID3v11Tag(ID3v11Tag copyObject)
public ID3v11Tag(AbstractTag mp3tag)
mp3tag -
java.lang.UnsupportedOperationException
public ID3v11Tag(java.io.RandomAccessFile file,
java.lang.String loggingFilename)
throws TagNotFoundException,
java.io.IOException
file - loggingFilename -
TagNotFoundException
java.io.IOException
public ID3v11Tag(java.io.RandomAccessFile file)
throws TagNotFoundException,
java.io.IOException
ID3v11Tag(RandomAccessFile,String) instead
file -
TagNotFoundException
java.io.IOException| Method Detail |
|---|
public byte getRelease()
getRelease in class ID3v1Tagpublic byte getMajorVersion()
getMajorVersion in class ID3v1Tagpublic byte getRevision()
getRevision in class ID3v1Tagpublic int getFieldCount()
TagFields with the same identifiers are counted separately i.e two TITLE fields in a Vorbis Comment file would count as two
getFieldCount in interface TaggetFieldCount in class ID3v1Tagpublic void setComment(java.lang.String comment)
setComment in class ID3v1Tagcomment - public java.lang.String getFirstComment()
getFirstComment in class ID3v1Tagpublic void setTrack(java.lang.String trackValue)
trackValue - public java.lang.String getFirstTrack()
getFirstTrack in class ID3v1Tagpublic void addTrack(java.lang.String track)
public java.util.List<TagField> getTrack()
getTrack in class ID3v1Tagpublic void setField(TagField field)
Tag
setField in interface TagsetField in class ID3v1Tagfield - The field to add.public java.util.List<TagField> getFields(FieldKey genericKey)
ID3v1TagTagField objects whose "id"
is the specified one.
getFields in interface TaggetFields in class ID3v1TaggenericKey - The generic field key
TagField objects with the given "id".public java.lang.String getFirst(FieldKey genericKey)
ID3v1Tag
getFirst in interface TaggetFirst in class ID3v1Tagpublic TagField getFirstField(java.lang.String id)
TagCan be used to retrieve fields with any identifier, useful if the identifier is not within FieldKey
getFirstField in interface TaggetFirstField in class ID3v1Tagid - audio specific key
public boolean isEmpty()
Tag
isEmpty in interface TagisEmpty in class ID3v1Tagtrue if tag contains no field.public void deleteField(FieldKey genericKey)
deleteField in interface TagdeleteField in class ID3v1TaggenericKey - public boolean equals(java.lang.Object obj)
equals in class ID3v1Tagobj - Comparing Object
public boolean seek(java.nio.ByteBuffer byteBuffer)
seek in class ID3v1TagbyteBuffer -
public void read(java.nio.ByteBuffer byteBuffer)
throws TagNotFoundException
read in class ID3v1TagbyteBuffer - from where to read in a tag
TagNotFoundException - if unable to read a tag in the byteBuffer
public void write(java.io.RandomAccessFile file)
throws java.io.IOException
write in class ID3v1Tagfile - that this tag should be written to
java.io.IOException - thrown if there were problems writing to the filepublic void createStructure()
ID3v1Tag
createStructure in class ID3v1Tag
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||