Class JPropNode
java.lang.Object
com.fasterxml.jackson.dataformat.javaprop.util.JPropNode
Value in an ordered tree presentation built from an arbitrarily ordered
set of flat input values. Since either index- OR name-based access is to
be supported (similar to, say, Javascript objects) -- but only one, not both --
storage is bit of a hybrid. In addition, branches may also have values.
So, code does bit coercion as necessary, trying to maintain something
consistent and usable at all times, without failure.
-
Field Summary
FieldsModifier and TypeFieldDescriptionChild entries with integral number index, if any.Child entries accessed with String property name, if any.protected boolean
protected String
Value for the path, for leaf nodes; usually null for branches. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddByIndex
(int index) asRaw()
Helper method, mostly for debugging/testing, to convert structure contained into simple List/Map/String equivalent.getValue()
boolean
isArray()
boolean
isLeaf()
Child entries accessed with String property name, if any.
-
Field Details
-
_value
Value for the path, for leaf nodes; usually null for branches. If both children and value exists, typically need to construct bogus value with empty String key. -
_byIndex
Child entries with integral number index, if any. -
_byName
Child entries accessed with String property name, if any. -
_hasContents
protected boolean _hasContents
-
-
Constructor Details
-
JPropNode
public JPropNode()
-
-
Method Details
-
setValue
-
addByIndex
-
addByName
-
isLeaf
public boolean isLeaf() -
isArray
public boolean isArray() -
getValue
-
arrayContents
-
objectContents
Child entries accessed with String property name, if any. -
asRaw
Helper method, mostly for debugging/testing, to convert structure contained into simple List/Map/String equivalent.
-