Package repast.simphony.integration
Class DataContent
java.lang.Object
org.jdom.Content
repast.simphony.integration.DataContent
- All Implemented Interfaces:
Serializable
,Cloneable
public class DataContent
extends org.jdom.Content
A
Content
that holds a value in it, and when it's getValue method is called will
return that value. Used by the JDOM builders for storing values in Element
s.- Author:
- Jerry Vos
- See Also:
-
Field Summary
Fields inherited from class org.jdom.Content
parent
-
Constructor Summary
ConstructorDescriptionCreates this without an object to use as data.DataContent
(Object data) Creates this with the specified object as data. -
Method Summary
Modifier and TypeMethodDescriptiongetData()
Retrieves the data to be used in thegetValue()
method.getValue()
Retrieves the string value of the data.void
Sets the data to be used in thegetValue()
method.toString()
This is the same asgetValue()
.Methods inherited from class org.jdom.Content
clone, detach, equals, getDocument, getParent, getParentElement, hashCode, setParent
-
Constructor Details
-
DataContent
public DataContent()Creates this without an object to use as data. Before this is used thesetData(Object)
method should be called- See Also:
-
DataContent
Creates this with the specified object as data.- Parameters:
data
- the object to used ingetValue()
- See Also:
-
-
Method Details
-
getValue
Retrieves the string value of the data.- Specified by:
getValue
in classorg.jdom.Content
- Returns:
- null if the data is null, otherwise
data.toString()
-
getData
Retrieves the data to be used in thegetValue()
method.- Returns:
- the data object
-
setData
Sets the data to be used in thegetValue()
method.- Parameters:
data
- the data object
-
toString
This is the same asgetValue()
.- Overrides:
toString
in classObject
- Returns:
- the same as
getValue()
- See Also:
-