Package adams.data.spreadsheet
Class MetaData
- java.lang.Object
-
- adams.data.spreadsheet.MetaData
-
- All Implemented Interfaces:
CloneHandler<MetaData>
,SpreadSheetSupporter
,Serializable
public class MetaData extends Object implements Serializable, SpreadSheetSupporter, CloneHandler<MetaData>
Simple meta-data storage.- Version:
- $Revision$
- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected SpreadSheet
m_Data
for storing the meta-data.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(String key, Object value)
Adds the meta-data.MetaData
getClone()
Returns a clone of itself.boolean
has(String key)
Checks the meta-data for an existing key.SpreadSheet
toSpreadSheet()
Returns the meta-data as spreadsheet.String
toString()
Returns the underlying spreadsheet as string.
-
-
-
Field Detail
-
m_Data
protected SpreadSheet m_Data
for storing the meta-data.
-
-
Constructor Detail
-
MetaData
public MetaData()
Initializes the meta-data.
-
MetaData
public MetaData(MetaData source)
Initializes the meta-data with the provided meta-data.- Parameters:
source
- the meta-data to copy
-
-
Method Detail
-
has
public boolean has(String key)
Checks the meta-data for an existing key.- Parameters:
key
- the key to check- Returns:
- true if exists
-
add
public void add(String key, Object value)
Adds the meta-data.- Parameters:
key
- the keyvalue
- the value
-
toSpreadSheet
public SpreadSheet toSpreadSheet()
Returns the meta-data as spreadsheet.- Specified by:
toSpreadSheet
in interfaceSpreadSheetSupporter
- Returns:
- the meta-data
-
getClone
public MetaData getClone()
Returns a clone of itself.- Specified by:
getClone
in interfaceCloneHandler<MetaData>
- Returns:
- the clone
-
-