Class ConfigField

java.lang.Object
org.apache.uima.tools.cpm.ConfigField

public class ConfigField extends Object
Configuration Field class used for representation of resource parameters in dynamically created MetaDataPanels.
See Also:
  • Constructor Details

    • ConfigField

      public ConfigField(String pn, String cs, boolean mv, JComponent c)
      Instantiates a new config field.
      Parameters:
      pn - Resource parameter name e.g. outputDir
      cs - String value of Java type used for value e.g. Integer
      mv - true if the value is a multi-value array
      c - Component used to represent field - Could be JTextField, JCheckBox, FileSelector or ListSelector
  • Method Details

    • getParameterName

      public String getParameterName()
      Gets the parameter name.
      Returns:
      the parameter name
    • getClassString

      public String getClassString()
      Gets the class string.
      Returns:
      the class string
    • getFieldComponent

      public JComponent getFieldComponent()
      Gets the field component.
      Returns:
      the field component
    • isMultiValued

      public boolean isMultiValued()
      Checks if is multi valued.
      Returns:
      true, if is multi valued
    • getFieldValue

      public Object getFieldValue()
      Gets the field value.
      Returns:
      the field value
    • setFieldValue

      public void setFieldValue(Object fieldValue)
      Sets the field value.
      Parameters:
      fieldValue - the new field value
    • isModified

      public boolean isModified()
      Returns whether this field has been modified from its original value. This is not affected by whether the user has saved the new value; for that use isDirty().
      Returns:
      true, if is modified
    • isDirty

      public boolean isDirty()
      Returns whether this field has been modified since the last time the CPE descriptor was saved.
      Returns:
      true, if is dirty
    • clearDirty

      public void clearDirty()
      To be called when the CPE descriptor is saved. Sets this field to be not dirty, until it is next modified.