org.tigris.swidgets
Class Property
java.lang.Object
org.tigris.swidgets.Property
- Comparable
public class Property
extends java.lang.Object
implements Comparable
A property that can be displayed and edited within a PropertyTable.
Property(String theName, Class theValueType, Object theInitialValue) - Constructs a new Property.
|
Property(String theName, Class theValueType, Object theInitialValue, Object[] values) - Constructs a new Property.
|
int | compareTo(Object o) - Compares two Properties by comparing their names.
|
Object[] | getAvailableValues() - Returns the set of available property values, or null if no such
finite set exists.
|
Object | getCurrentValue() - Returns the currently selected property value.
|
Object | getInitialValue() - Returns the initial property value.
|
String | getName() - Returns the property name.
|
Class | getValueType() - Property editors should be configured to edit objects of this type.
|
void | setCurrentValue(Object value) - Sets the currently selected property value.
|
Property
public Property(String theName,
Class theValueType,
Object theInitialValue)
Constructs a new Property. This version of the constructor does
not specify a finite set of available values.
theName
- the property nametheValueType
- the value type classtheInitialValue
- the initial value
Property
public Property(String theName,
Class theValueType,
Object theInitialValue,
Object[] values)
Constructs a new Property. This version of the constructor does
not specify a finite set of available values.
theName
- the property nametheValueType
- the value type classtheInitialValue
- the initial valuevalues
- the set of available values to choose from
compareTo
public int compareTo(Object o)
Compares two Properties by comparing their names.
java.lang.Comparable.compareTo(java.lang.Object)
getAvailableValues
public Object[] getAvailableValues()
Returns the set of available property values, or null if no such
finite set exists.
- set of available property values
getCurrentValue
public Object getCurrentValue()
Returns the currently selected property value.
getInitialValue
public Object getInitialValue()
Returns the initial property value.
getName
public String getName()
Returns the property name.
getValueType
public Class getValueType()
Property editors should be configured to edit objects of this type.
setCurrentValue
public void setCurrentValue(Object value)
Sets the currently selected property value.
value
- new property value