Package docking.widgets.table.constraint
Class AtLeastDateColumnConstraint
- java.lang.Object
-
- docking.widgets.table.constraint.SingleValueColumnConstraint<java.time.LocalDate>
-
- docking.widgets.table.constraint.AtLeastDateColumnConstraint
-
- All Implemented Interfaces:
ColumnConstraint<java.time.LocalDate>,java.lang.Comparable<ColumnConstraint<java.time.LocalDate>>
public class AtLeastDateColumnConstraint extends SingleValueColumnConstraint<java.time.LocalDate>
Column Constraint where acceptable column values are greater than or equal to some specified value of the column type.
-
-
Field Summary
-
Fields inherited from class docking.widgets.table.constraint.SingleValueColumnConstraint
editorProvider, name
-
-
Constructor Summary
Constructors Constructor Description AtLeastDateColumnConstraint(java.time.LocalDate minValue, EditorProvider<java.time.LocalDate> editorProvider)Constructs a new AtLeasDateColumnConstraint with a default name, default group and a minimum value
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanaccepts(java.time.LocalDate value, TableFilterContext context)Compares value against the current constraint value to determine acceptance; true if value satisfies the constraints' value, false otherwiseSingleValueColumnConstraint<java.time.LocalDate>copy(java.time.LocalDate newValue)subclasses must override to generate new versions of themselves but with new comparison value.-
Methods inherited from class docking.widgets.table.constraint.SingleValueColumnConstraint
equals, getColumnType, getConstraintValue, getConstraintValueString, getEditor, getGroup, getName, hashCode, parseConstraintValue
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface docking.widgets.table.constraint.ColumnConstraint
asString, compareTo, getConstraintValueTooltip
-
-
-
-
Constructor Detail
-
AtLeastDateColumnConstraint
public AtLeastDateColumnConstraint(java.time.LocalDate minValue, EditorProvider<java.time.LocalDate> editorProvider)Constructs a new AtLeasDateColumnConstraint with a default name, default group and a minimum value- Parameters:
minValue- the value for which all acceptable column values must be greater than or equal.editorProvider- an object that can provide a ConstraintEditor for this constraint type.
-
-
Method Detail
-
accepts
public boolean accepts(java.time.LocalDate value, TableFilterContext context)Description copied from interface:ColumnConstraintCompares value against the current constraint value to determine acceptance; true if value satisfies the constraints' value, false otherwise- 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
-
copy
public SingleValueColumnConstraint<java.time.LocalDate> copy(java.time.LocalDate newValue)
Description copied from class:SingleValueColumnConstraintsubclasses must override to generate new versions of themselves but with new comparison value.- Specified by:
copyin classSingleValueColumnConstraint<java.time.LocalDate>- Parameters:
newValue- the new value to compare column values against.- Returns:
- a new ColumnConstraint that is the same type as this constraint but with a new comparison value.
-
-