bbc.rd.id3
Class ID3Util

java.lang.Object
  extended bybbc.rd.id3.ID3Util

public class ID3Util
extends java.lang.Object

Utility methods for ID3v2 tags and frames.

Author:
Chris Newell, BBC R&D.

Constructor Summary
ID3Util()
           
 
Method Summary
static de.vdheide.mp3.ID3v230Frame getID3v230Frame(de.vdheide.mp3.ID3v2Frame frame)
           
static de.vdheide.mp3.ID3v230Frame getID3v230Frame(java.lang.String frameId, byte[] content)
           
static de.vdheide.mp3.ID3v230Frame getTextFrame(java.lang.String frameId, java.lang.String text)
           
static long getTimeInMilliseconds(java.lang.String timeString)
          Convert a formatted time string to a count in milliseconds.
static int getVersion()
           
static void setVersion(int version)
           
static java.lang.String toString(de.vdheide.mp3.ID3v2Frame frame)
           
static int U2I(byte a)
          Convert an 8-bit unsigned byte value to an integer (32-bit).
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ID3Util

public ID3Util()
Method Detail

getID3v230Frame

public static de.vdheide.mp3.ID3v230Frame getID3v230Frame(de.vdheide.mp3.ID3v2Frame frame)

getID3v230Frame

public static de.vdheide.mp3.ID3v230Frame getID3v230Frame(java.lang.String frameId,
                                                          byte[] content)

getTextFrame

public static de.vdheide.mp3.ID3v230Frame getTextFrame(java.lang.String frameId,
                                                       java.lang.String text)

toString

public static java.lang.String toString(de.vdheide.mp3.ID3v2Frame frame)

U2I

public static int U2I(byte a)
Convert an 8-bit unsigned byte value to an integer (32-bit).


getTimeInMilliseconds

public static long getTimeInMilliseconds(java.lang.String timeString)
Convert a formatted time string to a count in milliseconds. The method will accept time strings of the form: [s]s[.nn] [m]m:ss[.nn] [h]h:mm:ss[.nn] or: N * s + [.nn]

Parameters:
timeString - a formatted time string representing hours, minutes, seconds & centiseconds (e.g. "1:05:17.32") or seconds & centiseconds (e.g. "1572.32").
Returns:
a time in milliseconds

setVersion

public static void setVersion(int version)

getVersion

public static int getVersion()


BBC 2005. All rights reserved.