A Big Fat Note...

This ID3 Library hasn't been maintained for a number of years. If you want to use it, and have problems with it, you're on your own for support.

Java id3

Java id3 is my java id3 library (very original name, I know). It came into being because I was looking for a library that was a) java, b) simple and c) fast. After poking around on sourceforge, I realized this probably wasn't going to happen. So in the grand tradition of coders everywhere, I decided to re-invent this particular wheel.

As of version 0.1, Java id3 supports all major ID3 versions (1.0, 1.1, 2.2, 2.3, 2.4).

Java id3 is free to use, as long as you can live by its license.

Download

The current version is 0.1
version changes source classes javadoc everything comments
0.10 changes java-id3-0.1-src.jar java-id3-0.1.jar link java-id3-0.1.zip Major reorganization and rewrite
0.02 changes id3-0.02-src.jar id3-0.02.jar link    
0.01 changes id3-0.01-src.jar id3-0.01.jar link   First stab

I have tried to keep Java id3 simple to use. Below are a few illustrations. All try/catches have been removed.

Read an id3 from a file:

        Reader reader = new Reader();
        File songFile = new File("my-song.mp3");
        FileInputStream in = new FileInputStream(songFile);
        Tag tag = reader.read(songFile);
        in.close();
        System.out.println("this song is: " + tag.getTitle());
    

Modify a value (continuing the example above):

        tag.setTitle("my new song title");
        tag.setArtist("The Great Gazoos");
    

Save the song to a file with the new tags:

        Mp3File mp3 = new Mp3File(songFile);
        mp3.setTag(tag);
        File newSongFile = new File("new-song-file.mp3");
        mp3.write(newSongFile);
    

Some TODOs

  • limited image support (only if JAI is included in JDK 1.4--I need to check).
  • Modify the API so that the factories can be replaced by custom implementations. I am mainly thinking about the FrameFactory class and potential future users who want to create even more specialized frame types.