Package com.cobber.fta
Class LogicalTypeFactory
- java.lang.Object
-
- com.cobber.fta.LogicalTypeFactory
-
public abstract class LogicalTypeFactory extends java.lang.Object
Construct a LogicalType from PluginDefinition or a Semantic Type name.
-
-
Constructor Summary
Constructors Constructor Description LogicalTypeFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static LogicalType
newInstance(PluginDefinition plugin)
Return a Logical Type based on a Plugin Definition.static LogicalType
newInstance(PluginDefinition plugin, java.util.Locale locale)
Return a Logical Type based on a Plugin Definition in a particular locale.static LogicalType
newInstance(java.lang.String qualifier)
Return a Logical Type based simply on the name of the Logical Type.
-
-
-
Method Detail
-
newInstance
public static LogicalType newInstance(java.lang.String qualifier) throws FTAPluginException
Return a Logical Type based simply on the name of the Logical Type. The locale will be derived from the first valid locale in the internal plugins file.- Parameters:
qualifier
- Name of the Semantic Type for which we wish to retrieve the Logical Type.- Returns:
- The LogicalType The Logical Type associated with the definition (if it exists), null if non-existent. Note: isValid(input) can be invoked on the resulting type, and nextRandom() if the type is an subclass of LogicalTypeCode.
- Throws:
FTAPluginException
- Thrown when the plugin is incorrectly configured.
-
newInstance
public static LogicalType newInstance(PluginDefinition plugin) throws FTAPluginException
Return a Logical Type based on a Plugin Definition.- Parameters:
plugin
- The Definition for this plugin- Returns:
- The LogicalType The Logical Type associated with the definition (if it exists), null if non-existent.
- Throws:
FTAPluginException
- Thrown when the plugin is incorrectly configured.
-
newInstance
public static LogicalType newInstance(PluginDefinition plugin, java.util.Locale locale) throws FTAPluginException
Return a Logical Type based on a Plugin Definition in a particular locale.- Parameters:
plugin
- The Definition for this pluginlocale
- The locale used for this LogicalType- Returns:
- The LogicalType The Logical Type associated with the definition (if it exists), null if non-existent.
- Throws:
FTAPluginException
- Thrown when the plugin is incorrectly configured.
-
-