Class ExtendedDocument
java.lang.Object
com.inductiveautomation.ignition.common.document.DocumentElement
com.inductiveautomation.ignition.common.document.Document
com.inductiveautomation.ignition.common.document.ExtendedDocument
- All Implemented Interfaces:
- Serializable
Allows cloning a 
It's extremely important that the delegate Document is never modified. In cases where the delegate Document might change,
Document without having to create a deep copy of all it's elements. This is managed by
 tracking all modifications to a delegate Document instead of applying those modifications directly to the Document.
 If extend(com.inductiveautomation.ignition.common.document.Document) is called on an ExtendedDocument the delegate Document is reused and
 modifications are copied to the new ExtendedDocument.
 It's extremely important that the delegate Document is never modified. In cases where the delegate Document might change,
Document.deepCopy() should be used instead.- See Also:
- 
Field Summary
- 
Method SummaryModifier and TypeMethodDescriptionvoidadd(String property, DocumentElement value) Adds a member, which is a name-value pair, to self.voidaddProperty(String property, Object value) deepCopy()Creates a deep copy of this element and all its childrenentrySet()Returns a set of members of this object.static DocumentReturns the member with the specified name.getAsDocument(String memberName) Convenience method to get the specified member as a Document.getAsDocumentArray(String memberName) Convenience method to get the specified member as a JsonArray.getAsDocumentPrimitive(String memberName) Convenience method to get the specified member as a JsonPrimitive element.booleanConvenience method to check if a member with the specified name is present in this object.keySet()Returns a set of members key values.Removes thepropertyfrom thisDocument.intsize()Returns the number of key/value pairs in the object.protected Set<Map.Entry<String,DocumentElement>> Methods inherited from class com.inductiveautomation.ignition.common.document.Documentadd, add, add, add, equals, hashCode, toJsonElementMethods inherited from class com.inductiveautomation.ignition.common.document.DocumentElementfromJson, getAsBigDecimal, getAsBigInteger, getAsBoolean, getAsByte, getAsCharacter, getAsDocument, getAsDocumentArray, getAsDocumentNull, getAsDocumentPrimitive, getAsDouble, getAsFloat, getAsInt, getAsLong, getAsNumber, getAsShort, getAsString, isDocument, isDocumentArray, isDocumentNull, isDocumentPrimitive, toString, toStringNoIndent
- 
Method Details- 
extend
- 
deepCopyDescription copied from class:DocumentCreates a deep copy of this element and all its children
- 
unsafeEntrySet- Overrides:
- unsafeEntrySetin class- Document
 
- 
addDescription copied from class:DocumentAdds a member, which is a name-value pair, to self. The name must be a String, but the value can be an arbitrary DocumentElement, thereby allowing you to build a full tree of DocumentElements rooted at this node.
- 
removeDescription copied from class:DocumentRemoves thepropertyfrom thisDocument.- Overrides:
- removein class- Document
- Parameters:
- property- name of the member that should be removed.
- Returns:
- the DocumentElementobject that is being removed.
 
- 
addProperty- Overrides:
- addPropertyin class- Document
 
- 
entrySetDescription copied from class:DocumentReturns a set of members of this object. The set is ordered, and the order is in which the elements were added.
- 
keySetDescription copied from class:DocumentReturns a set of members key values.
- 
sizepublic int size()Description copied from class:DocumentReturns the number of key/value pairs in the object.
- 
hasDescription copied from class:DocumentConvenience method to check if a member with the specified name is present in this object.
- 
getDescription copied from class:DocumentReturns the member with the specified name.
- 
getAsDocumentPrimitiveDescription copied from class:DocumentConvenience method to get the specified member as a JsonPrimitive element.- Overrides:
- getAsDocumentPrimitivein class- Document
- Parameters:
- memberName- name of the member being requested.
- Returns:
- the JsonPrimitive corresponding to the specified member.
 
- 
getAsDocumentArrayDescription copied from class:DocumentConvenience method to get the specified member as a JsonArray.- Overrides:
- getAsDocumentArrayin class- Document
- Parameters:
- memberName- name of the member being requested.
- Returns:
- the JsonArray corresponding to the specified member.
 
- 
getAsDocumentDescription copied from class:DocumentConvenience method to get the specified member as a Document.- Overrides:
- getAsDocumentin class- Document
- Parameters:
- memberName- name of the member being requested.
- Returns:
- the Document corresponding to the specified member.
 
 
-