# Class TableFactoryParameter

java.lang.Object
uk.ac.starlink.task.Parameter<uk.ac.starlink.table.StarTableFactory>
uk.ac.starlink.ttools.task.TableFactoryParameter

public class TableFactoryParameter extends uk.ac.starlink.task.Parameter<uk.ac.starlink.table.StarTableFactory>
Parameter whose value is a StarTableFactory.

Author:
  Mark Taylor

## Field Summary

### Fields inherited from class uk.ac.starlink.task.Parameter

`BY_NAME`

## Constructor Summary

Constructors
Constructor
Description
`TableFactoryParameter(String name)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`static uk.ac.starlink.table.StarTableFactory`
`createTableFactory(String sval)`
Decodes a string value which represents a particular prescription for resolving table names to table data, returning a functioning StarTableFactory object which embodies this behaviour.
`static uk.ac.starlink.table.StarTableFactory`
`createTableFactory(TableLocator locator)`
Returns a table factory based on a TableLocator instance.
`uk.ac.starlink.table.StarTableFactory`
`stringToObject(uk.ac.starlink.task.Environment env, String sval)`

### Methods inherited from class uk.ac.starlink.task.Parameter

`clearValue, getDescription, getName, getPosition, getPreferExplicit, getPrompt, getStringDefault, getUsage, getValueClass, isNullPermitted, objectToString, objectValue, setDescription, setDescription, setName, setNullPermitted, setPosition, setPreferExplicit, setPrompt, setStringDefault, setUsage, setValue, setValueFromObject, setValueFromString, stringValue, toArray, toString`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Constructor Details

### TableFactoryParameter

public TableFactoryParameter(String name)
Constructor.

Parameters:
  `name` - parameter name

## Method Details

### stringToObject

public uk.ac.starlink.table.StarTableFactory stringToObject(uk.ac.starlink.task.Environment env, String sval) throws uk.ac.starlink.task.TaskException

Specified by:
  `stringToObject` in class `uk.ac.starlink.task.Parameter<uk.ac.starlink.table.StarTableFactory>`
Throws:
  `uk.ac.starlink.task.TaskException`

### createTableFactory

public static uk.ac.starlink.table.StarTableFactory createTableFactory(String sval) throws uk.ac.starlink.task.UsageException
Decodes a string value which represents a particular prescription for resolving table names to table data, returning a functioning StarTableFactory object which embodies this behaviour.

Parameters:
  `sval` - string representation of behaviour
Returns:
  table factory
Throws:
  `uk.ac.starlink.task.UsageException` - if the string value cannot be decoded

### createTableFactory

public static uk.ac.starlink.table.StarTableFactory createTableFactory(TableLocator locator)
Returns a table factory based on a TableLocator instance.

Parameters:
  `locator` - locator
Returns:
  table factory