Package docking.widgets.table.constraint

# Class BooleanMatchColumnConstraint

java.lang.Object
docking.widgets.table.constraint.BooleanMatchColumnConstraint

All Implemented Interfaces:
  `ColumnConstraint<Boolean>`, `Comparable<ColumnConstraint<Boolean>>`

public class BooleanMatchColumnConstraint extends Object implements ColumnConstraint<Boolean>
Column Constraint for boolean values where the column values must match the constraint value of either true of false.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `BooleanMatchColumnConstraint(Boolean matchValue)`
  Construct a new BooleanMatchColumnConstraint that matches the given boolean value.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `boolean`
  `accepts(Boolean value, TableFilterContext context)`
  Compares value against the current constraint value to determine acceptance; true if value satisfies the constraints' value, false otherwise
  `boolean`
  `equals(Object obj)`
  `Class<Boolean>`
  `getColumnType()`
  Returns the column type that this constraint can be used to filter.
  `String`
  `getConstraintValueString()`
  Returns the "value" of the constraint in string form
  `ColumnConstraintEditor<Boolean>`
  `getEditor(ColumnData<Boolean> columnDataSource)`
  Returns a ColumnConstraintEditor which will provide gui components for users to edit the constraint values.
  `String`
  `getGroup()`
  Returns a "group" string that is used to logically group column constraints for presentation to the user
  `String`
  `getName()`
  Returns the name of the constraint
  `Boolean`
  `getValue()`
  Returns the constraints boolean value for matching.
  `ColumnConstraint<Boolean>`
  `parseConstraintValue(String newValue, Object dataSource)`
  Parses the constraint value string for deserialization purposes.

  ### Methods inherited from class java.lang.Object

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

  ### Methods inherited from interface docking.widgets.table.constraint.ColumnConstraint

  `asString, compareTo, getConstraintValueTooltip`

- ## Constructor Details

  - ### BooleanMatchColumnConstraint

    public BooleanMatchColumnConstraint(Boolean matchValue)
    Construct a new BooleanMatchColumnConstraint that matches the given boolean value.
    Parameters:
      `matchValue` - the value (true or false) that acceptable column values have.

- ## Method Details

  - ### getGroup

    public String getGroup()
    Description copied from interface: `ColumnConstraint`
    Returns a "group" string that is used to logically group column constraints for presentation to the user
    Specified by:
      `getGroup` in interface `ColumnConstraint<Boolean>`
    Returns:
      the group this constraint belongs to.

  - ### getName

    public String getName()
    Description copied from interface: `ColumnConstraint`
    Returns the name of the constraint
    Specified by:
      `getName` in interface `ColumnConstraint<Boolean>`
    Returns:
      the name of the constraint.

  - ### accepts

    public boolean accepts(Boolean value, TableFilterContext context)
    Description copied from interface: `ColumnConstraint`
    Compares value against the current constraint value to determine acceptance; true if value satisfies the constraints' value, false otherwise
    Specified by:
      `accepts` in interface `ColumnConstraint<Boolean>`
    Parameters:
      `value` - the column value to be tested.
      `context` - provides additional information about the the table and its data. This allows the filter to base its decision on information other than just the column value.
    Returns:
      true if the column value passes the constraint, false otherwise

  - ### getEditor

    public ColumnConstraintEditor<Boolean> getEditor(ColumnData<Boolean> columnDataSource)
    Description copied from interface: `ColumnConstraint`
    Returns a ColumnConstraintEditor which will provide gui components for users to edit the constraint values.
    Specified by:
      `getEditor` in interface `ColumnConstraint<Boolean>`
    Parameters:
      `columnDataSource` - This provides the constraint with access to the column data in the table model as well as the DataProvider of the table (if it has one)
    Returns:
      A columnConstraintEditor for editing the constraints value.

  - ### getColumnType

    public Class<Boolean> getColumnType()
    Description copied from interface: `ColumnConstraint`
    Returns the column type that this constraint can be used to filter.
    Specified by:
      `getColumnType` in interface `ColumnConstraint<Boolean>`
    Returns:
      the column type

  - ### getValue

    public Boolean getValue()
    Returns the constraints boolean value for matching.
    Returns:
      the constraints boolean value for matching.

  - ### getConstraintValueString

    public String getConstraintValueString()
    Description copied from interface: `ColumnConstraint`
    Returns the "value" of the constraint in string form

    This is used for serializing the constraint.

    Specified by:
      `getConstraintValueString` in interface `ColumnConstraint<Boolean>`
    Returns:
      the "value" of the constraint in string form.

  - ### parseConstraintValue

    public ColumnConstraint<Boolean> parseConstraintValue(String newValue, Object dataSource)
    Description copied from interface: `ColumnConstraint`
    Parses the constraint value string for deserialization purposes.
    Specified by:
      `parseConstraintValue` in interface `ColumnConstraint<Boolean>`
    Parameters:
      `newValue` - the value of the constraint in string form.
      `dataSource` - the DataSource from the Table.
    Returns:
      a new ColumnConstraint

  - ### equals

    public boolean equals(Object obj)
    Overrides:
      `equals` in class `Object`