| java.lang.Object com.sun.rave.propertyeditors.domains.Element
Element | public class Element implements Comparable(Code) | | An individual item in the set of items returned by a
Domain . An
element consists of a value, an optional label (for display purposes), and
an optional description. Any component of an element may be null.
|
Constructor Summary | |
public | Element(Object value) Construct a new instance that uses value.toString() as the label, and
no description. | public | Element(Object value, String label) Construct a new instance that has an element value and localized
label, but no description. | public | Element(Object value, String label, String description) Construct a new, fully configured, instance. |
EMPTY_ARRAY | final public static Element[] EMPTY_ARRAY(Code) | | An empty array of elements.
|
Element | public Element(Object value)(Code) | | Construct a new instance that uses value.toString() as the label, and
no description.
Parameters: value - Property value that should be set if this elementis selected |
Element | public Element(Object value, String label)(Code) | | Construct a new instance that has an element value and localized
label, but no description.
Parameters: value - Property value that should be set if this elementis selected Parameters: label - Localized label for this element value |
Element | public Element(Object value, String label, String description)(Code) | | Construct a new, fully configured, instance.
Parameters: value - Property value that should be set if this elementis selected Parameters: label - Localized label for this element value Parameters: description - Optional localized description of this element |
compareTo | public int compareTo(Object obj)(Code) | | Compare this element to another element. If the elements' values implement
java.lang.Comparable , then their values are compared. Otherwise, their
labels are compared.
|
equals | public boolean equals(Object obj)(Code) | | An element is equal to another if their values are equal.
|
getDescription | public String getDescription()(Code) | | Return the localized description for this element value. Returns null if
there is no description.
|
getLabel | public String getLabel()(Code) | | Return the localized label for this element value. If not specified,
the Stringified version of the object value is used instead. If no label
or value is present, returns null.
|
getValue | public Object getValue()(Code) | | Return the element value for this element. Returns null if there is no
value.
|
hashCode | public int hashCode()(Code) | | Returns the element's label's hash code.
|
|
|