j3d.org Code

org.j3d.util.device
Class FileLoaderDescriptor

java.lang.Object
  extended byorg.j3d.util.device.DeviceDescriptor
      extended byorg.j3d.util.device.FileLoaderDescriptor

public class FileLoaderDescriptor
extends DeviceDescriptor

An descriptor class for file loaders.

A single file loader instance is used to represent a particular file format type. The descriptor assumes that there is only one file extension and mime type for a given file format type. If there are more than one, it will not work correctly at this point in time.

Version:
$revision$

Constructor Summary
FileLoaderDescriptor(java.lang.String name, java.lang.String desc, java.lang.String cls, java.lang.String type, java.lang.String ext)
          Construct an instance of this class with the given information about the name, description and class file.
 
Method Summary
 java.lang.String getContentType()
          Get the MIME type that this loader can handle.
 java.lang.String getExtension()
          Get the file extension associated with the file type that this loader can handle.
 
Methods inherited from class org.j3d.util.device.DeviceDescriptor
equals, getDescription, getName
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileLoaderDescriptor

public FileLoaderDescriptor(java.lang.String name,
                            java.lang.String desc,
                            java.lang.String cls,
                            java.lang.String type,
                            java.lang.String ext)
Construct an instance of this class with the given information about the name, description and class file.

Parameters:
name - The name of the device
desc - A description of the device
cls - The fully qualified name of the class file
type - The mime type for this loader
ext - The file extension associated with this type
Method Detail

getContentType

public java.lang.String getContentType()
Get the MIME type that this loader can handle.

Returns:
The mime type as a string

getExtension

public java.lang.String getExtension()
Get the file extension associated with the file type that this loader can handle. This is useful for putting in FileOpen dialogs and the like.

Returns:
The extension associated with this file type

j3d.org Code

Latest Info from http://code.j3d.org/
Copyright © 2001 - j3d.org