Package docking.widgets.table.constraint
Class RangeColumnConstraint<T>
java.lang.Object
docking.widgets.table.constraint.RangeColumnConstraint<T>
- Type Parameters:
- T- the column type
- All Implemented Interfaces:
- ColumnConstraint<T>,- Comparable<ColumnConstraint<T>>
- Direct Known Subclasses:
- InDateRangeColumnConstraint,- InRangeColumnConstraint,- NotInDateRangeColumnConstraint,- NotInRangeColumnConstraint
Abstract base class for range constraints.
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprotected EditorProvider<T> protected final StringThis constraints' name
- 
Constructor SummaryConstructorsModifierConstructorDescriptionprotectedRangeColumnConstraint(String name, T minValue, T maxValue, EditorProvider<T> editorProvider, String group) Constructor
- 
Method SummaryModifier and TypeMethodDescriptionabstract RangeColumnConstraint<T> subclasses must override to generate new versions of themselves but with new range values.booleanReturns the column type that this constraint can be used to filter.Returns the "value" of the constraint in string formfinal ColumnConstraintEditor<T> getEditor(ColumnData<T> columnDataSource) Returns a ColumnConstraintEditor which will provide gui components for users to edit the constraint values.getGroup()Returns a "group" string that is used to logically group column constraints for presentation to the userReturns the max value of the range used by this constraint.Returns the min value of the range used by this constraint.getName()Returns the name of the constraintinthashCode()parseConstraintValue(String newValue, Object dataSource) Parses the constraint value string for deserialization purposes.Methods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface docking.widgets.table.constraint.ColumnConstraintaccepts, asString, compareTo, getConstraintValueTooltip
- 
Field Details- 
nameThis constraints' nameIt sometimes makes grammatical sense to set a more useful name than the default; while 'at least' makes sense for a number-based constraint, 'after' reads better for date-based constraints. 
- 
editorProvider
 
- 
- 
Constructor Details- 
RangeColumnConstraintprotected RangeColumnConstraint(String name, T minValue, T maxValue, EditorProvider<T> editorProvider, String group) Constructor- Parameters:
- name- the name of the constraint.
- minValue- the min value of the range.
- maxValue- the max value of the range.
- editorProvider- the editor provider that generates the appropriate editors for constraints of this type.
- group- the group of the constraint for visual grouping when presenting to the user.
 
 
- 
- 
Method Details- 
getGroupDescription copied from interface:ColumnConstraintReturns a "group" string that is used to logically group column constraints for presentation to the user- Specified by:
- getGroupin interface- ColumnConstraint<T>
- Returns:
- the group this constraint belongs to.
 
- 
getNameDescription copied from interface:ColumnConstraintReturns the name of the constraint- Specified by:
- getNamein interface- ColumnConstraint<T>
- Returns:
- the name of the constraint.
 
- 
getMinValueReturns the min value of the range used by this constraint.- Returns:
- the min value of the range used by this constraint.
 
- 
getMaxValueReturns the max value of the range used by this constraint.- Returns:
- the max value of the range used by this constraint.
 
- 
getColumnTypeDescription copied from interface:ColumnConstraintReturns the column type that this constraint can be used to filter.- Specified by:
- getColumnTypein interface- ColumnConstraint<T>
- Returns:
- the column type
 
- 
getEditorDescription copied from interface:ColumnConstraintReturns a ColumnConstraintEditor which will provide gui components for users to edit the constraint values.- Specified by:
- getEditorin interface- ColumnConstraint<T>
- 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.
 
- 
getConstraintValueStringDescription copied from interface:ColumnConstraintReturns the "value" of the constraint in string formThis is used for serializing the constraint. - Specified by:
- getConstraintValueStringin interface- ColumnConstraint<T>
- Returns:
- the "value" of the constraint in string form.
 
- 
parseConstraintValueDescription copied from interface:ColumnConstraintParses the constraint value string for deserialization purposes.- Specified by:
- parseConstraintValuein interface- ColumnConstraint<T>
- Parameters:
- newValue- the value of the constraint in string form.
- dataSource- the DataSource from the Table.
- Returns:
- a new ColumnConstraint
 
- 
copysubclasses must override to generate new versions of themselves but with new range values.- Parameters:
- min- the min value of the range.
- max- the max value of the range.
- Returns:
- a new ColumnConstraint that is the same type as this constraint but with a new range defined.
 
- 
hashCodepublic int hashCode()
- 
equals
 
-