UniVista.editors
Class ConstraintsEditor

java.lang.Object
  |
  +--java.beans.PropertyEditorSupport
        |
        +--UniVista.editors.ConstraintsEditor
All Implemented Interfaces:
java.beans.PropertyEditor

public class ConstraintsEditor
extends java.beans.PropertyEditorSupport

This is a custom propert editor for the constraints property of Variables. It is responsible for editing the upper and lower constraints for a Variable. The values are user definable.


Constructor Summary
ConstraintsEditor()
          Constructor.
ConstraintsEditor(java.lang.Class display)
          Constructor with the Display Bean Class supplied.
 
Method Summary
 java.awt.Component getCustomEditor()
          Returns the component to the builder.
 java.lang.Object getLowerBound()
          Get the constraining object.
 java.lang.Object getUpperBound()
           
 boolean isPaintable()
          Also must be true.
 void setEnabled(boolean b)
          Make the UI enabled.
 void setLowerBound(java.lang.Object lo)
          Set the lower constraint.
 void setUpperBound(java.lang.Object up)
           
 boolean supportsCustomEditor()
          Has to return true.
 
Methods inherited from class java.beans.PropertyEditorSupport
addPropertyChangeListener, firePropertyChange, getAsText, getJavaInitializationString, getTags, getValue, paintValue, removePropertyChangeListener, setAsText, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConstraintsEditor

public ConstraintsEditor()
Constructor.

ConstraintsEditor

public ConstraintsEditor(java.lang.Class display)
Constructor with the Display Bean Class supplied. This will allow the two fields to be editable with the given UI.
Method Detail

getCustomEditor

public java.awt.Component getCustomEditor()
Returns the component to the builder.
Overrides:
getCustomEditor in class java.beans.PropertyEditorSupport

setLowerBound

public void setLowerBound(java.lang.Object lo)
Set the lower constraint.

setUpperBound

public void setUpperBound(java.lang.Object up)

getLowerBound

public java.lang.Object getLowerBound()
Get the constraining object.

getUpperBound

public java.lang.Object getUpperBound()

supportsCustomEditor

public boolean supportsCustomEditor()
Has to return true.
Overrides:
supportsCustomEditor in class java.beans.PropertyEditorSupport

isPaintable

public boolean isPaintable()
Also must be true.
Overrides:
isPaintable in class java.beans.PropertyEditorSupport

setEnabled

public void setEnabled(boolean b)
Make the UI enabled.