|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.gjt.btools.utilities.ExtendedObject
Stores an object and a corresponding text description. This can be used in list boxes, combo boxes and the like where the program needs to store some underlying value but the user interface should display a friendly description. Routine toString() has been overridden to behave properly in these circumstances.
Constructor Summary | |
ExtendedObject(java.lang.Object value,
java.lang.String desc)
Creates a new extended object. |
Method Summary | |
java.lang.String |
getDescription()
Returns the text description associated with this object. |
java.lang.Object |
getValue()
Returns the underlying value stored with this object. |
void |
setDescription(java.lang.String desc)
Sets the text description associated with this object. |
void |
setValue(java.lang.Object value)
Sets the underlying value stored with this object. |
java.lang.String |
toString()
Returns the text description associated with this object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public ExtendedObject(java.lang.Object value, java.lang.String desc)
value
- the underlying value to store.desc
- the corresponding text description.Method Detail |
public java.lang.Object getValue()
public void setValue(java.lang.Object value)
value
- the new underlying value to store.public java.lang.String getDescription()
public void setDescription(java.lang.String desc)
desc
- the new text description.public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |