|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.brains2b.collection.EntryImpl
A Map.Entry written to rely on Strings instead of objects
Used primarely for Reference tables, JCombobox and the like. For that reason the toString() returns only the value.
Note: This is not an implementation of MapEntry
Map.Entry
,
Serialized FormConstructor Summary | |
EntryImpl()
Default Constructor for EntryImpl |
|
EntryImpl(java.lang.String key,
java.lang.String value)
Constructor for EntryImpl, initializes the values |
Method Summary | |
boolean |
equals(java.lang.Object obj)
Compares this EntryImpl to another object to see if they are equal The following rules apply: If comparing a EntryImpl equals returns true if they have the same key If comparing a String equals returns true if the String equals the key In all other cases false is returned. |
java.lang.String |
getKey()
Returns the key. |
java.lang.String |
getValue()
Returns the value. |
java.lang.String |
paramString()
Method paramString is used for testing purposes. |
void |
setKey(java.lang.String key)
sets the Key |
void |
setValue(java.lang.String value)
sets the Value |
java.lang.String |
toString()
The toString is equivalent to getValue() to make it possible to use it in a Combobox. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public EntryImpl()
public EntryImpl(java.lang.String key, java.lang.String value)
key
- Stringvalue
- StringMethod Detail |
public java.lang.String getKey()
public java.lang.String getValue()
public java.lang.String toString()
Object.toString()
public boolean equals(java.lang.Object obj)
Object.equals(Object)
public void setKey(java.lang.String key)
Prefered method is using the Constructor to initialize the object, instead of setting or updating the key here.
key
- Stringpublic void setValue(java.lang.String value)
Prefered method is using the Constructor to initialize the object, instead of setting or updating the value here.
value
- Stringpublic java.lang.String paramString()
Do not use this in runtime code for implementation may change, without notice
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |