org.apache.commons.collections.keyvalue
Class AbstractKeyValue
- KeyValue
public abstract class AbstractKeyValue
Abstract pair class to assist with creating KeyValue and MapEntry implementations.
$Revision: 1.3 $ $Date: 2004/02/18 01:00:08 $- James Strachan
- Michael A. Smith
- Neil O'Toole
- Stephen Colebourne
protected Object | key- The key
|
protected Object | value- The value
|
AbstractKeyValue(Object key, Object value)- Constructs a new pair with the specified key and given value.
|
Object | getKey()- Gets the key from the pair.
|
Object | getValue()- Gets the value from the pair.
|
String | toString()- Gets a debugging String view of the pair.
|
key
protected Object key
The key
value
protected Object value
The value
AbstractKeyValue
protected AbstractKeyValue(Object key,
Object value) Constructs a new pair with the specified key and given value.
key - the key for the entry, may be nullvalue - the value for the entry, may be null
getKey
public Object getKey()
Gets the key from the pair.
- getKey in interface KeyValue
getValue
public Object getValue()
Gets the value from the pair.
- getValue in interface KeyValue
toString
public String toString()
Gets a debugging String view of the pair.
- a String view of the entry
Copyright © 2001-2006 Apache Software Foundation. All Rights Reserved.