|
2004.04.29 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--com.jdc.lang.Object
|
+--com.jdc.util.NameValue
NameValue represents a name/value pair. The name must be a
String whereas the value may be any Java Object.
| Field Summary |
| Fields inherited from class com.jdc.lang.Object |
string |
| Constructor Summary | |
NameValue(String name)
Constructs a new NameValue object for the specified name. |
|
NameValue(String name,
Object value)
Constructs a new NameValue object for the specified name and
value pair. |
|
| Method Summary | |
boolean |
equals(Object object)
Compares this NameValue object to the specified object. |
String |
getName()
Returns the name for the name/value pair. |
Object |
getValue()
Returns the value for the name/value pair. |
int |
hashCode()
Returns a hash code value for this NameValue object. |
protected void |
setName(String name)
Sets the name for the name/value pair. |
void |
setValue(Object value)
Sets the value for the name/value pair. |
String |
toString()
Returns a String representing the value for this NameValue
object. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public NameValue(String name)
NameValue object for the specified name.
public NameValue(String name,
Object value)
NameValue object for the specified name and
value pair.
| Method Detail |
public boolean equals(Object object)
NameValue object to the specified object. Returns
true if the name for the specified name/value pair is equal to
the name for this name/value pair.
equals in class ObjectTrue if a specified object is equal to this name/value pair. False if the specified object is not equal to this name/value pair.public int hashCode()
NameValue object. This
method is supported for the benefit of hashtables such as those provided
by Hashtable.
hashCode in class Objectpublic String getName()
public Object getValue()
protected void setName(String name)
public void setValue(Object value)
public String toString()
String representing the value for this NameValue
object. If the value for the name/value pair is null, a String
value of "null" is returned.
toString in class ObjectString representing the value for this NameValue object.
|
2004.04.29 |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||