Startpage - All pages - Edit - Show Properties - Create new page - Help - Login / Sign in

Development


Version as of 16.06.2007 16:24:46


Writing Plugins

Plugin types

There are 3 types of plugins. DataPlugins, FilePlugins and GeneralPlugins. DataPlugins are all the plugins, which fetch the metadata from different sources like the filename, the filetag or sources in the web like musicbrainz.
Through FilePlugins JMP3Renamer gets the capability to open files with the according suffix and to read and write meta information. Let's have a look at the Mp3-Plugin. Is it installed, JMP3Renamer can open Mp3s and read and write ID3-Tags (Version 1.1 and 2.3).
The last type are GeneralPlugins. They extend the functionality of JMP3Renamer in a general way. All plugins, which are no Data- or FilePlugin are GeneralPlugins.

Naming conventions

To write your own plugin you have to follow some naming conventions. Otherwise JMP3Renamer is not able to load your plugin. The main class of your plugin has to belong to a package net.sf.jmp3renamer.plugins.<Main Class>
So, let's assume to write a plugin named ExamplePlugin. The first few lines of code have to look like this: