org.blinkenlights.jid3.io
Class TextEncoding

java.lang.Object
  extended byorg.blinkenlights.jid3.io.TextEncoding

public class TextEncoding
extends java.lang.Object

Text encoding representation used in v2 frames.


Field Summary
static TextEncoding ISO_8859_1
           
static TextEncoding UNICODE
           
 
Method Summary
 boolean equals(java.lang.Object oOther)
           
static TextEncoding getDefaultTextEncoding()
          Get the default text encoding which will be used in v2 frames, when not specified.
 java.lang.String getEncodingString()
          Get the Java encoding string matching this text encoding.
 byte getEncodingValue()
          Get the byte value corresponding to this text encoding.
static TextEncoding getTextEncoding(byte byEncoding)
          Get the text encoding object represented by a given byte value.
static TextEncoding getTextEncoding(int iEncoding)
          Get the text encoding object represented by a given integer value.
static void setDefaultTextEncoding(TextEncoding oTextEncoding)
          Set the default text encoding to be used in v2 frames, when not specified.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ISO_8859_1

public static final TextEncoding ISO_8859_1

UNICODE

public static final TextEncoding UNICODE
Method Detail

getTextEncoding

public static TextEncoding getTextEncoding(int iEncoding)
                                    throws ID3Exception
Get the text encoding object represented by a given integer value.

Parameters:
iEncoding - the value corresponding to a given text encoding
Returns:
the matching text encoding object
Throws:
ID3Exception - if no matching encoding exists

getTextEncoding

public static TextEncoding getTextEncoding(byte byEncoding)
                                    throws ID3Exception
Get the text encoding object represented by a given byte value.

Parameters:
byEncoding - the value corresponding to a given text encoding
Returns:
the matching text encoding object
Throws:
ID3Exception - if no matching encoding exists

getEncodingValue

public byte getEncodingValue()
Get the byte value corresponding to this text encoding.

Returns:
the corresponding byte value

getEncodingString

public java.lang.String getEncodingString()
Get the Java encoding string matching this text encoding.

Returns:
the matching encoding string

equals

public boolean equals(java.lang.Object oOther)

getDefaultTextEncoding

public static TextEncoding getDefaultTextEncoding()
Get the default text encoding which will be used in v2 frames, when not specified.

Returns:
the default text encoding used when not specified

setDefaultTextEncoding

public static void setDefaultTextEncoding(TextEncoding oTextEncoding)
Set the default text encoding to be used in v2 frames, when not specified.

Parameters:
oTextEncoding - the default text encoding to be used when not specified