Registering A MIME Type Extension
The RETS IQ RETS Library recognises a wide variety of MIME types and can map them to a file extension. The mappings are used in the getObjects call to write objects to the file system and name them.
In the event that a MIME type does not have an extension associated with it and objects are written without a file extension, it is possible to register a mapping between a MIME type and an extension.
To do this call the MimeTypeExtension.register() method before calling the getObjects method.
MimeTypeExtension.register("text/xml", "xml");
The example above registers the MIME type text/xml with the extension xml. This means that any objects returned with the text/xml MIME type will be saved with .xml extension. Obviously this particular MIME type has already been registered with the extension.