public class APEItem
extends java.lang.Object
This class provides methods for reading the APE Items in an APE tag
. An Item consists of a key
/value
pair.
While the key part of an item is always a String, the value may be a String or it may be raw binary data, such as an image file. The sample code
shown in the APETag
demonstrates how to read the values stored in items an APE tag. The APE specification(s) have defined a standardized
list of keys, but users are not restricted to this list.
Constructor and Description |
---|
APEItem(byte[] bytes,
int index)
constructor.
|
Modifier and Type | Method and Description |
---|---|
byte[] |
getBinaryValue()
gets the value as binary.
|
APEFlags |
getFlags()
gets the flags associated with the APE item.
|
java.lang.String |
getKey()
gets the key associated with the text/binary value.
|
int |
getSize()
gets the size (inn bytes) of the APE item.
|
java.lang.String |
getTextValue()
gets the value as text.
|
APEFlags.Type |
getType()
gets the type of data stored in the value.
|
boolean |
isValueBinary()
gets whether the value is binary.
|
boolean |
isValueText()
gets whether the value is text.
|
java.lang.String |
toString()
gets a string representation of the APE item.
|
public APEItem(byte[] bytes, int index)
bytes
- APE Item bytes.index
- index into the byte array.public int getSize()
public APEFlags getFlags()
public java.lang.String getKey()
public APEFlags.Type getType()
public boolean isValueText()
public boolean isValueBinary()
public java.lang.String getTextValue()
public byte[] getBinaryValue()
public java.lang.String toString()
toString
in class java.lang.Object