Package org.javarosa.core.model.instance
Class FormInstance
java.lang.Object
org.javarosa.core.model.instance.DataInstance<TreeElement>
org.javarosa.core.model.instance.FormInstance
- All Implemented Interfaces:
IMetaData,Persistable,Externalizable
public class FormInstance extends DataInstance<TreeElement> implements Persistable, IMetaData
This class represents the xform model instance
-
Field Summary
Fields Modifier and Type Field Description StringformVersionstatic StringMETA_IDstatic StringMETA_XMLNSprotected TreeElementrootThe root of this treeStringschemastatic StringSTORAGE_KEYStringuiVersion -
Constructor Summary
Constructors Constructor Description FormInstance()FormInstance(TreeElement root)FormInstance(TreeElement root, String id)Creates a new data model using the root given. -
Method Summary
Methods inherited from class org.javarosa.core.model.instance.DataInstance
explodeReference, getFormId, getID, getInstanceId, getName, getTemplate, getTemplatePath, hasTemplatePath, isRuntimeEvaluated, resolveReference, resolveReference, setFormId, setID, setInstanceId, setName, toString, unpackReference
-
Field Details
-
STORAGE_KEY
- See Also:
- Constant Field Values
-
schema
-
formVersion
-
uiVersion
-
root
The root of this tree -
META_XMLNS
- See Also:
- Constant Field Values
-
META_ID
- See Also:
- Constant Field Values
-
-
Constructor Details
-
FormInstance
public FormInstance() -
FormInstance
-
FormInstance
Creates a new data model using the root given.- Parameters:
root- The root of the tree for this data model.
-
-
Method Details
-
getBase
- Specified by:
getBasein classDataInstance<TreeElement>
-
getRoot
- Specified by:
getRootin classDataInstance<TreeElement>
-
setRoot
Sets the root element of this Model's tree- Parameters:
topLevel- The root of the tree for this data model.
-
copyNode
public TreeReference copyNode(TreeReference from, TreeReference to) throws InvalidReferenceException- Throws:
InvalidReferenceException
-
copyNode
- Throws:
InvalidReferenceException
-
getDateSaved
-
addNode
-
addNode
-
addNamespace
-
getNamespacePrefixes
-
getNamespaceURI
-
processSaved
-
clone
-
readExternal
public void readExternal(DataInputStream in, PrototypeFactory pf) throws IOException, DeserializationException- Specified by:
readExternalin interfaceExternalizable- Overrides:
readExternalin classDataInstance<TreeElement>- Throws:
IOExceptionDeserializationException
-
writeExternal
- Specified by:
writeExternalin interfaceExternalizable- Overrides:
writeExternalin classDataInstance<TreeElement>- Throws:
IOException
-
setDateSaved
-
copyItemsetNode
public void copyItemsetNode(TreeElement copyNode, TreeReference destRef, FormDef f) throws InvalidReferenceException- Throws:
InvalidReferenceException
-
accept
-
isHomogeneous
-
initialize
- Specified by:
initializein classDataInstance<TreeElement>
-
getMetaDataFields
- Specified by:
getMetaDataFieldsin interfaceIMetaData
-
getMetaData
- Specified by:
getMetaDatain interfaceIMetaData
-
getMetaData
- Specified by:
getMetaDatain interfaceIMetaData
-