public class ListItem<T>
extends java.lang.Object
| Constructor and Description |
|---|
ListItem(java.lang.String label,
T value)
Constructor takes label and value.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object o)
Compares only the values, not the label!
|
java.lang.String |
getLabel()
Returns the label.
|
T |
getValue()
Returns the value.
|
int |
hashCode() |
java.lang.String |
toString()
Returns the label for use in lists and combo boxes.
|
public ListItem(java.lang.String label,
T value)
label - displayed to the uservalue - programmatic valuepublic java.lang.String getLabel()
public T getValue()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Object