Package org.assertstruct.template.node
Class ObjectNode
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,,TemplateNode> SequencedMap<String,,TemplateNode> MatchResult,DataNode<Map<String,,Object>> StructTemplateNode,TemplateNode
public class ObjectNode
extends LinkedHashMap<String,TemplateNode>
implements StructTemplateNode, DataNode<Map<String,Object>>
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K, V> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancontainsTemplateKey(TemplateKey templateKey) Look for best template key for actual keyvoidprintDebug(StringBuilder out) put(String keyValue, TemplateNode value) toData()Methods inherited from class java.util.LinkedHashMap
clear, containsValue, entrySet, forEach, get, getOrDefault, keySet, newLinkedHashMap, putFirst, putLast, removeEldestEntry, replaceAll, reversed, sequencedEntrySet, sequencedKeySet, sequencedValues, valuesMethods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, isEmpty, merge, newHashMap, putAll, putIfAbsent, remove, remove, replace, replace, sizeMethods inherited from class java.util.AbstractMap
equals, hashCode, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, containsKey, equals, hashCode, isEmpty, merge, putAll, putIfAbsent, remove, remove, replace, replace, sizeMethods inherited from interface org.assertstruct.result.MatchResult
isConfigMethods inherited from interface java.util.SequencedMap
firstEntry, lastEntry, pollFirstEntry, pollLastEntryMethods inherited from interface org.assertstruct.template.StructTemplateNode
getConfig, getStartToken, isDataNode, isScalar, print, sealConfigsMethods inherited from interface org.assertstruct.template.TemplateNode
addSharedValidator, asArray, asDict, getEndToken, getKey, getMatchedTo, getToken, getValidators, hasDifference, isStruct, printEnd, printStart
-
Constructor Details
-
ObjectNode
-
-
Method Details
-
printDebug
- Specified by:
printDebugin interfaceTemplateNode- Throws:
IOException
-
lookup
Look for best template key for actual key- Parameters:
key- keycontext- matcher- Returns:
- template node corespondent to best key
-
put
- Specified by:
putin interfaceMap<String,TemplateNode> - Overrides:
putin classHashMap<String,TemplateNode>
-
getByKey
- Specified by:
getByKeyin interfaceStructTemplateNode
-
containsTemplateKey
-
toData
-