com.bbn.swede.tools.translator
Class TranslatorPlugin

java.lang.Object
  extended byPlugin
      extended bycom.bbn.swede.tools.translator.TranslatorPlugin

public final class TranslatorPlugin
extends Plugin

A singleton class representing information about the translators extension point, and other translation-related information.

Author:
aperezlo
See Also:
Serialized Form

Method Summary
 String getID()
          Retrieves the unique identifier of the plug-in.
 Collection getInputExtensions()
          Gets an unordered set of all of the extensions for which a translator exists that has that extension as its input.
 Collection getOutputExtensions()
          Gets an unordered set of all of the extensions for which a translator exists that has that extension as its output.
static TranslatorPlugin getPlugin()
          Retrieves the singleton instance of TranslatorPlugin.
 List getTranslators()
          This method returns a list of all of the translators available to SWeDE.
static TreeNode getTranslatorsAsTree(List translatorList)
          A convenience method, which generates a representation of the available translators in a tree form.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInputExtensions

public Collection getInputExtensions()
Gets an unordered set of all of the extensions for which a translator exists that has that extension as its input.

Returns:
a set of all available translator input extensions

getOutputExtensions

public Collection getOutputExtensions()
Gets an unordered set of all of the extensions for which a translator exists that has that extension as its output.

Returns:
a set of all available translator output extensions

getPlugin

public static TranslatorPlugin getPlugin()
Retrieves the singleton instance of TranslatorPlugin.

Returns:
the singleton TranslatorPlugin

getTranslators

public List getTranslators()
This method returns a list of all of the translators available to SWeDE.

Returns:
a List of TranslatorDescriptor objects
See Also:
TranslatorDescriptor

getTranslatorsAsTree

public static TreeNode getTranslatorsAsTree(List translatorList)
A convenience method, which generates a representation of the available translators in a tree form. The leaf nodes of the tree are individual translators, while branch nodes are menu titles.

Parameters:
translatorList - The translators to structure as a tree
Returns:
A tree containing available translators, organized by translator group

getID

public String getID()
Retrieves the unique identifier of the plug-in.

Returns:
the TranslatorPlugin 's plugin ID string


Copyright © 2004-2005 BBN Technologies. All Rights Reserved.