From 7039a05147b8bbfc829babea1c65bd436450b505 Mon Sep 17 00:00:00 2001 From: Björn Stenberg Date: Mon, 8 Jan 2007 23:53:00 +0000 Subject: Splitting out songdbj git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11953 a1c6a512-1295-4272-9138-f99709370657 --- songdbj/ArtistEntry.java | 56 ------------------------------------------------ 1 file changed, 56 deletions(-) delete mode 100644 songdbj/ArtistEntry.java (limited to 'songdbj/ArtistEntry.java') diff --git a/songdbj/ArtistEntry.java b/songdbj/ArtistEntry.java deleted file mode 100644 index fcaaac7dee..0000000000 --- a/songdbj/ArtistEntry.java +++ /dev/null @@ -1,56 +0,0 @@ -import java.util.*; -import java.io.*; - -public class ArtistEntry extends Entry implements Comparable { - protected String name; - protected Vector albums; - protected int albumcount; - - public ArtistEntry(String n) { - name=n; - albums=new Vector(); - albumcount=0; - } - - public void addAlbum(AlbumEntry e) { - if(!albums.contains(e)) { - albums.add(e); - e.setArtist(this); - albumcount++; - Collections.sort(albums); - } - } - - public void removeAlbum(AlbumEntry e) { - albums.remove(e); - albumcount--; - } - - public int size() { return albumcount; } - - public int compareTo(Object o) { - return String.CASE_INSENSITIVE_ORDER.compare(name,((ArtistEntry)o).getName()); - } - - public String getName() { return name; } - public Collection getAlbums() { return albums; } - public void write(DataOutputStream w) throws IOException { - int x; - w.writeBytes(name); - for(x=TagDatabase.getInstance().artistlen-name.length();x>0;x--) - w.write(0); - Iterator i2 = albums.iterator(); - x=0; - while(i2.hasNext()) { - Entry e = (Entry) i2.next(); - w.writeInt(e.getOffset()); - x++; - } - for(;x