public class Tree extends Bean
SERIALIZED_CLASS_NAME, TYPEXML_SERIALIZED_CLASS_NAME| Constructor and Description |
|---|
Tree() |
Tree(boolean optimizeTreeStructure) |
Tree(TreeDetectionStrategy detectionStrategy) |
| Modifier and Type | Method and Description |
|---|---|
static String |
createFieldName(TreeNode node,
Set<String> fieldNames)
Builds a normalized field name for the supplied node that is unique within
fieldNames (which this method adds it to): wildcard nodes use their
name pattern hint or id, collisions gain the
parent-name prefix and then a numeric suffix. |
Tree |
fromRecord(Record source)
Loads this instance's state from a record and returns
this (for fluid API call chaining). |
Tree |
fromXmlElement(Element element) |
List<TreeNode> |
getAllFields() |
List<TreeNode> |
getAllNodes() |
List<TreeNode> |
getAllRecordBreaks() |
TreeDetectionStrategy |
getDetectionStrategy() |
TreeNode |
getRootNode() |
static Tree |
loadJson(File file) |
static Tree |
loadJson(File file,
boolean optimizeTreeStructure) |
static Tree |
loadJson(File file,
TreeDetectionStrategy detectionStrategy) |
static Tree |
loadJson(Reader reader) |
static Tree |
loadJson(Reader reader,
boolean optimizeTreeStructure) |
static Tree |
loadJson(Reader reader,
TreeDetectionStrategy detectionStrategy) |
static Tree |
loadXml(File file) |
static Tree |
loadXml(File file,
boolean optimizeTreeStructure) |
static Tree |
loadXml(File file,
TreeDetectionStrategy detectionStrategy) |
static Tree |
loadXml(Reader reader) |
static Tree |
loadXml(Reader reader,
boolean optimizeTreeStructure) |
static Tree |
loadXml(Reader reader,
TreeDetectionStrategy detectionStrategy) |
static String |
normalizeFieldName(String name) |
Tree |
setDetectionStrategy(TreeDetectionStrategy detectionStrategy) |
Record |
toRecord() |
Element |
toXmlElement(Document document) |
void |
visit(boolean headFirst,
Consumer<TreeNode> consumer) |
addExceptionProperties, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfromArrayValue, fromArrayValue, fromArrayValue, fromJson, fromJson, newInstanceFromRecord, newInstanceFromRecord, toArrayValue, toJson, toJson, toJson, toRecordnewInstanceFromJsonforEachGrandChildElement, fromXml, fromXml, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getAttribute, getChildElement, getChildElements, newInstanceFromXml, newInstanceFromXml, setAttribute, toXml, toXml, toXml, toXml, toXml, writeXml, writeXmladdExceptionProperties, contributeExceptionProperties, contributeExceptionProperties, exception, exception, exceptionpublic Tree(boolean optimizeTreeStructure)
public Tree()
public Tree(TreeDetectionStrategy detectionStrategy)
public static Tree loadXml(File file, TreeDetectionStrategy detectionStrategy)
public static Tree loadXml(Reader reader, TreeDetectionStrategy detectionStrategy)
public static Tree loadJson(File file, TreeDetectionStrategy detectionStrategy)
public static Tree loadJson(Reader reader, TreeDetectionStrategy detectionStrategy)
public TreeDetectionStrategy getDetectionStrategy()
public Tree setDetectionStrategy(TreeDetectionStrategy detectionStrategy)
public TreeNode getRootNode()
public static String createFieldName(TreeNode node, Set<String> fieldNames)
fieldNames (which this method adds it to): wildcard nodes use their
name pattern hint or id, collisions gain the
parent-name prefix and then a numeric suffix. Used by the field-naming detection passes.public Record toRecord()
toRecord in interface RecordSerializabletoRecord in class Beanpublic Tree fromRecord(Record source)
RecordSerializablethis (for fluid API call chaining).
For fluid API call chaining, the overridden method should change the declared return type to its class.fromRecord in interface RecordSerializablefromRecord in class BeanCopyright (c) 2006-2026 North Concepts Inc. All Rights Reserved.