com.jenkov.mrpersister.impl.mapping
Class KeyValue
java.lang.Object
com.jenkov.mrpersister.impl.mapping.KeyValue
- All Implemented Interfaces:
- IKeyValue
public class KeyValue
- extends java.lang.Object
- implements IKeyValue
- Author:
- Jakob Jenkov - Copyright 2005 Jenkov Development
Method Summary |
void |
addColumnValue(java.lang.String column,
java.lang.Object value)
Adds a value to a column of this key. |
java.lang.Object |
getColumnValue(java.lang.String column)
Returns the value for the given column. |
java.util.Map |
getColumnValues()
Returns a map of all column values in this key value. |
void |
removeColumnValue(java.lang.String column)
Removes a column value from this key value. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
columnValues
protected java.util.Map columnValues
KeyValue
public KeyValue()
addColumnValue
public void addColumnValue(java.lang.String column,
java.lang.Object value)
- Description copied from interface:
IKeyValue
- Adds a value to a column of this key.
- Specified by:
addColumnValue
in interface IKeyValue
- Parameters:
column
- The column to specify the value of.value
- The column value.
removeColumnValue
public void removeColumnValue(java.lang.String column)
- Description copied from interface:
IKeyValue
- Removes a column value from this key value.
- Specified by:
removeColumnValue
in interface IKeyValue
- Parameters:
column
- The column to remove the value of.
getColumnValue
public java.lang.Object getColumnValue(java.lang.String column)
- Description copied from interface:
IKeyValue
- Returns the value for the given column. If there is no
value for that column null is returned.
- Specified by:
getColumnValue
in interface IKeyValue
- Parameters:
column
- The column to return the value of.
- Returns:
- The column value if present. Otherwise null.
getColumnValues
public java.util.Map getColumnValues()
- Description copied from interface:
IKeyValue
- Returns a map of all column values in this key value.
- Specified by:
getColumnValues
in interface IKeyValue
- Returns:
- A map of all column values in this key value.
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object