Class FilterParameter

java.lang.Object
uk.ac.starlink.task.Parameter<ProcessingStep[]>
uk.ac.starlink.ttools.task.FilterParameter
All Implemented Interfaces:
uk.ac.starlink.task.MultiParameter, ExtraParameter

public class FilterParameter extends uk.ac.starlink.task.Parameter<ProcessingStep[]> implements ExtraParameter, uk.ac.starlink.task.MultiParameter
Parameter which contains a value representing one or more ProcessingSteps.
Since:
17 Aug 2005
Author:
Mark Taylor
  • Field Summary

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

    BY_NAME
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns an extended usage message.
    static String
    Returns a formatted string listing available filter commands with their usage.
    char
     
    final void
    setTableDescription(String shortDescrip, AbstractInputTableParameter<?> tableParam, Boolean isBefore)
    Sets the wording used to refer to the target table for the filters this parameter acquires.
    stepsValue(uk.ac.starlink.task.Environment env)
    Returns the value of this parameter as an array of processing steps.
    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 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • FilterParameter

      public FilterParameter(String name)
  • Method Details

    • setTableDescription

      public final void setTableDescription(String shortDescrip, AbstractInputTableParameter<?> tableParam, Boolean isBefore)
      Sets the wording used to refer to the target table for the filters this parameter acquires. The description and prompt are set. If not set, the wording "the table" is used to describe the table.
      Parameters:
      shortDescrip - text to replace "the table"
      tableParam - if supplied, gives the table parameter on behalf of which this format parameter is operating; may be null
      isBefore - TRUE means filter is applied before any other processing, FALSE means after, null don't know
    • getValueSeparator

      public char getValueSeparator()
      Specified by:
      getValueSeparator in interface uk.ac.starlink.task.MultiParameter
    • stringToObject

      public ProcessingStep[] 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<ProcessingStep[]>
      Throws:
      uk.ac.starlink.task.TaskException
    • stepsValue

      public ProcessingStep[] stepsValue(uk.ac.starlink.task.Environment env) throws uk.ac.starlink.task.TaskException
      Returns the value of this parameter as an array of processing steps.
      Parameters:
      env - execution environment
      Returns:
      array of zero or more processing steps
      Throws:
      uk.ac.starlink.task.TaskException
    • getExtraUsage

      public String getExtraUsage(TableEnvironment env)
      Description copied from interface: ExtraParameter
      Returns an extended usage message. This should not repeat the content of the normal usage message. It should be preformatted, that is it should contain newlines to keep the line length down to less than 80 characters.
      Specified by:
      getExtraUsage in interface ExtraParameter
      Parameters:
      env - execution envrionment
      Returns:
      extended usage message
    • getFiltersUsage

      public static String getFiltersUsage(TableEnvironment env)
      Returns a formatted string listing available filter commands with their usage.
      Parameters:
      env - execution environment
      Returns:
      usge string