artofillusion
Interface Translator


public interface Translator

The Translator interface defines the methods for importing and exporting scenes in foreign file formats.


Method Summary
 boolean canExport()
          Specify whether this translator can export files.
 boolean canImport()
          Specify whether this translator can import files.
 void exportFile(BFrame parent, Scene theScene)
          Prompt the user for a filename and any other necessary information, and export the scene.
 java.lang.String getName()
          Get the name of the file format which this translator imports or exports.
 void importFile(BFrame parent)
          Prompt the user to select a file, read it, and create a new LayoutWindow containing the imported scene.
 

Method Detail

getName

java.lang.String getName()
Get the name of the file format which this translator imports or exports.


canImport

boolean canImport()
Specify whether this translator can import files.


canExport

boolean canExport()
Specify whether this translator can export files.


importFile

void importFile(BFrame parent)
Prompt the user to select a file, read it, and create a new LayoutWindow containing the imported scene. parent is the Frame which should be used as the parent for dialog boxes. If canImport() returns false, this method will never be called.


exportFile

void exportFile(BFrame parent,
                Scene theScene)
Prompt the user for a filename and any other necessary information, and export the scene. parent is the Frame which should be used as the parent for dialog boxes. The user should be given the option of only exporting the objects which are currently selected. If canExport() returns false, this method will never be called.



Copyright © 1999-2011 by Peter Eastman.