|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jaudiotagger.tag.id3.AbstractTagItem org.jaudiotagger.tag.id3.AbstractTagFrameBody org.jaudiotagger.tag.id3.framebody.AbstractID3v2FrameBody org.jaudiotagger.tag.id3.framebody.FrameBodyAPIC
public class FrameBodyAPIC
Attached picture frame.
This frame contains a picture directly related to the audio file. Image format is the MIME type and subtype for the image. In the event that the MIME media type name is omitted, "image/" will be implied. The "image/png" or "image/jpeg" picture format should be used when interoperability is wanted. Description is a short description of the picture, represented as a terminated textstring. The description has a maximum length of 64 characters, but may be empty. There may be several pictures attached to one file, each in their individual "APIC" frame, but only one with the same content descriptor. There may only be one picture with the picture type declared as picture type $01 and $02 respectively. There is the possibility to put only a link to the image file by using the 'MIME type' "-->" and having a complete URL instead of picture data. The use of linked files should however be used sparingly since there is the risk of separation of files.<Header for 'Attached picture', ID: "APIC"> | |
Text encoding | $xx |
MIME type | <text string> $00 |
Picture type | $xx |
Description | <text string according to encoding> $00 (00) |
Picture data | <binary data> |
Picture type: | $00 | Other |
$01 | 32x32 pixels 'file icon' (PNG only) | |
$02 | Other file icon | |
$03 | Cover (front) | |
$04 | Cover (back) | |
$05 | Leaflet page | |
$06 | Media (e.g. lable side of CD) | |
$07 | Lead artist/lead performer/soloist | |
$08 | Artist/performer | |
$09 | Conductor | |
$0A | Band/Orchestra | |
$0B | Composer | |
$0C | Lyricist/text writer | |
$0D | Recording Location | |
$0E | During recording | |
$0F | During performance | |
$10 | Movie/video screen capture | |
$11 | A bright coloured fish | |
$12 | Illustration | |
$13 | Band/artist logotype | |
$14 | Publisher/Studio logotype |
For more details, please refer to the ID3 specifications:
Field Summary | |
---|---|
static java.lang.String |
IMAGE_IS_URL
|
Fields inherited from class org.jaudiotagger.tag.id3.framebody.AbstractID3v2FrameBody |
---|
TYPE_BODY |
Fields inherited from class org.jaudiotagger.tag.id3.AbstractTagFrameBody |
---|
objectList |
Fields inherited from class org.jaudiotagger.tag.id3.AbstractTagItem |
---|
logger |
Constructor Summary | |
---|---|
FrameBodyAPIC()
Creates a new FrameBodyAPIC datatype. |
|
FrameBodyAPIC(java.nio.ByteBuffer byteBuffer,
int frameSize)
Creates a new FrameBodyAPIC datatype. |
|
FrameBodyAPIC(byte textEncoding,
java.lang.String mimeType,
byte pictureType,
java.lang.String description,
byte[] data)
Creates a new FrameBodyAPIC datatype. |
|
FrameBodyAPIC(FrameBodyAPIC body)
|
|
FrameBodyAPIC(FrameBodyPIC body)
Conversion from v2 PIC to v3/v4 APIC |
Method Summary | |
---|---|
java.lang.String |
getDescription()
Get a description of the image |
java.lang.String |
getIdentifier()
The ID3v2 frame identifier |
byte[] |
getImageData()
Get Image data |
java.lang.String |
getImageUrl()
|
java.lang.String |
getMimeType()
Get mimetype |
int |
getPictureType()
|
boolean |
isImageUrl()
|
void |
setDescription(java.lang.String description)
Set a description of the image |
void |
setImageData(byte[] imageData)
Set imageData |
void |
setMimeType(java.lang.String mimeType)
Set mimeType |
void |
setPictureType(byte pictureType)
Set Picture Type |
protected void |
setupObjectList()
Create the list of Datatypes that this body expects in the correct order This method needs to be implemented by concrete subclasses |
void |
write(java.io.ByteArrayOutputStream tagBuffer)
If the description cannot be encoded using current encoder, change the encoder |
Methods inherited from class org.jaudiotagger.tag.id3.framebody.AbstractID3v2FrameBody |
---|
createStructure, equals, getSize, read, setSize, setSize |
Methods inherited from class org.jaudiotagger.tag.id3.AbstractTagFrameBody |
---|
getBriefDescription, getHeader, getLongDescription, getObject, getObjectValue, getTextEncoding, isSubsetOf, iterator, setHeader, setObjectValue, setTextEncoding, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String IMAGE_IS_URL
Constructor Detail |
---|
public FrameBodyAPIC()
public FrameBodyAPIC(FrameBodyAPIC body)
public FrameBodyAPIC(FrameBodyPIC body)
body
- public FrameBodyAPIC(byte textEncoding, java.lang.String mimeType, byte pictureType, java.lang.String description, byte[] data)
textEncoding
- mimeType
- pictureType
- description
- data
- public FrameBodyAPIC(java.nio.ByteBuffer byteBuffer, int frameSize) throws InvalidTagException
byteBuffer
- frameSize
-
InvalidTagException
- if unable to create framebody from bufferMethod Detail |
---|
public void setDescription(java.lang.String description)
description
- public java.lang.String getDescription()
public void setMimeType(java.lang.String mimeType)
mimeType
- public java.lang.String getMimeType()
public void setImageData(byte[] imageData)
imageData
- public byte[] getImageData()
public void setPictureType(byte pictureType)
pictureType
- public int getPictureType()
public java.lang.String getIdentifier()
getIdentifier
in class AbstractID3v2FrameBody
public void write(java.io.ByteArrayOutputStream tagBuffer)
write
in class AbstractID3v2FrameBody
protected void setupObjectList()
AbstractTagFrameBody
setupObjectList
in class AbstractTagFrameBody
public boolean isImageUrl()
public java.lang.String getImageUrl()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |