The CombineFormatizer maintains a list of recognizers which are able to recognize certain file types, see
List<FormatRecognizer> recognizerList in
Formatizer.addFormatRecognizer (FormatRecognizer recognizer)
SbmlRecognizer.priority = 200
The abstract class has 4 functions that you need to implement:
int getPriority ()must return a positive priority. Default recognizers have a priority of 100. Recognizers with a higher priority are asked first for a format. The first who knows a format wins this competition.
URI getFormatByParsing (File file, String mimeType)you’ll get a files and it’s mime type, try to identify it’s format by looking into the file
URI getFormatFromMime (String mime)you’ll get the mime type of a file, try to identify it’s format
URI getFormatFromExtension (String extension) you’ll get the extension of a file, try to identify it’s format
nulland the next recognizer will be asked
An example of an extension can be found at PharmMLRecognizer There the Formatizer was extended to also recognize PharmML files.