Methods Summary |
---|
public void | addLyric(ID3v2LyricLine line)
this.lyric += line.getText();
|
public void | addLyric(java.lang.String newLyric)
this.lyric += newLyric;
|
public void | addTimeStamp(Lyrics3TimeStamp time)
timeStamp.add(time);
|
public boolean | equals(java.lang.Object obj)
if (!(obj instanceof Lyrics3Line))
{
return false;
}
Lyrics3Line object = (Lyrics3Line) obj;
if (!this.lyric.equals(object.lyric))
{
return false;
}
return this.timeStamp.equals(object.timeStamp) && super.equals(obj);
|
public java.lang.String | getLyric()
return lyric;
|
public int | getSize()
int size = 0;
for (Object aTimeStamp : timeStamp)
{
size += ((Lyrics3TimeStamp) aTimeStamp).getSize();
}
return size + lyric.length();
|
public java.util.Iterator | getTimeStamp()
return timeStamp.iterator();
|
public boolean | hasTimeStamp()
return !timeStamp.isEmpty();
|
public void | readByteArray(byte[] arr, int offset)
readString(arr.toString(), offset);
|
public void | readString(java.lang.String lineString, int offset)
if (lineString == null)
{
throw new NullPointerException("Image is null");
}
if ((offset < 0) || (offset >= lineString.length()))
{
throw new IndexOutOfBoundsException("Offset to line is out of bounds: offset = " + offset + ", line.length()" + lineString.length());
}
int delim;
Lyrics3TimeStamp time;
timeStamp = new LinkedList<Lyrics3TimeStamp>();
delim = lineString.indexOf("[", offset);
while (delim >= 0)
{
offset = lineString.indexOf("]", delim) + 1;
time = new Lyrics3TimeStamp("Time Stamp");
time.readString(lineString.substring(delim, offset));
timeStamp.add(time);
delim = lineString.indexOf("[", offset);
}
lyric = lineString.substring(offset);
|
public void | setLyric(java.lang.String lyric)
this.lyric = lyric;
|
public void | setLyric(ID3v2LyricLine line)
this.lyric = line.getText();
|
public void | setTimeStamp(Lyrics3TimeStamp time)
timeStamp.clear();
timeStamp.add(time);
|
public java.lang.String | toString()
String str = "";
for (Object aTimeStamp : timeStamp)
{
str += aTimeStamp.toString();
}
return "timeStamp = " + str + ", lyric = " + lyric + "\n";
|
public byte[] | writeByteArray()
return Utils.getDefaultBytes(writeString(), "ISO8859-1");
|
public java.lang.String | writeString()
String str = "";
Lyrics3TimeStamp time;
for (Object aTimeStamp : timeStamp)
{
time = (Lyrics3TimeStamp) aTimeStamp;
str += time.writeString();
}
return str + lyric;
|