Class UnsignedLongConstraintEditor
- java.lang.Object
-
- docking.widgets.table.constrainteditor.AbstractColumnConstraintEditor<java.math.BigInteger>
-
- docking.widgets.table.constrainteditor.UnsignedLongConstraintEditor
-
- All Implemented Interfaces:
ColumnConstraintEditor<java.math.BigInteger>
public class UnsignedLongConstraintEditor extends AbstractColumnConstraintEditor<java.math.BigInteger>
A constraint editor for 64 bit unsigned numbers.
-
-
Field Summary
Fields Modifier and Type Field Description static java.math.BigInteger
MAX_VALUE
-
Fields inherited from class docking.widgets.table.constrainteditor.AbstractColumnConstraintEditor
currentConstraint, INVALID_INPUT_COLOR, VALID_INPUT_COLOR
-
-
Constructor Summary
Constructors Constructor Description UnsignedLongConstraintEditor(ColumnConstraint<java.math.BigInteger> constraint)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.awt.Component
buildInlineEditorComponent()
Delegate the construction of the inline editor component.protected boolean
checkEditorValueValidity()
Template method that subclasses must implement.java.lang.String
getErrorMessage()
If the editor contains and invalid value, this message should indicate why the value is invalid.protected ColumnConstraint<java.math.BigInteger>
getValueFromComponent()
Get the constraints' new value from the editor component.void
reset()
Reset the editor to a known-good state.protected void
updateEditorComponent()
Indicates to subclasses that the constraint has changed, and the user interface needs to be updated to reflect the new state.protected void
updateInfoMessage(boolean isValid)
-
Methods inherited from class docking.widgets.table.constrainteditor.AbstractColumnConstraintEditor
addChangeListener, buildDetailEditorComponent, formatStatus, getDetailComponent, getInlineComponent, getValue, hasEditorComponents, hasValidValue, notifyConstraintChanged, removeChangeListener, setValue, valueChanged
-
-
-
-
Constructor Detail
-
UnsignedLongConstraintEditor
public UnsignedLongConstraintEditor(ColumnConstraint<java.math.BigInteger> constraint)
Constructor.- Parameters:
constraint
- uses BigInteger to represent unsigned 64 bit values.
-
-
Method Detail
-
buildInlineEditorComponent
protected java.awt.Component buildInlineEditorComponent()
Description copied from class:AbstractColumnConstraintEditor
Delegate the construction of the inline editor component.- Specified by:
buildInlineEditorComponent
in classAbstractColumnConstraintEditor<java.math.BigInteger>
- Returns:
- the editors inline component
- See Also:
AbstractColumnConstraintEditor.getInlineComponent()
-
reset
public void reset()
Description copied from interface:ColumnConstraintEditor
Reset the editor to a known-good state.
-
getValueFromComponent
protected ColumnConstraint<java.math.BigInteger> getValueFromComponent()
Description copied from class:AbstractColumnConstraintEditor
Get the constraints' new value from the editor component. This expects the UI to have been constructed.- Specified by:
getValueFromComponent
in classAbstractColumnConstraintEditor<java.math.BigInteger>
- Returns:
- See Also:
AbstractColumnConstraintEditor.getValue()
-
updateEditorComponent
protected void updateEditorComponent()
Description copied from class:AbstractColumnConstraintEditor
Indicates to subclasses that the constraint has changed, and the user interface needs to be updated to reflect the new state.- Specified by:
updateEditorComponent
in classAbstractColumnConstraintEditor<java.math.BigInteger>
-
checkEditorValueValidity
protected boolean checkEditorValueValidity()
Description copied from class:AbstractColumnConstraintEditor
Template method that subclasses must implement. This class will call this method whenever the value changes so that the validity state is updated.Only called when the editor component has been constructed and UI elements are defined.
- Specified by:
checkEditorValueValidity
in classAbstractColumnConstraintEditor<java.math.BigInteger>
- Returns:
- true if the UI defines a valid value, false otherwise
- See Also:
ColumnConstraintEditor.hasValidValue()
-
updateInfoMessage
protected void updateInfoMessage(boolean isValid)
- Specified by:
updateInfoMessage
in classAbstractColumnConstraintEditor<java.math.BigInteger>
-
getErrorMessage
public java.lang.String getErrorMessage()
Description copied from interface:ColumnConstraintEditor
If the editor contains and invalid value, this message should indicate why the value is invalid. Only called ifhasValidValue()
returns false.- Returns:
- an error message, or an empty string if no error
-
-