Interface Node

All Known Implementing Classes:
JacksonNode

interface Node
A node representing a JSON structure. This class is a Pioneer abstraction which allows using different JSON parsers.
  • Method Details

    • isArray

      boolean isArray()
      Returns:
      true if the node represents an array of other nodes
    • elements

      Stream<Node> elements()
      Returns:
      all the elements of this potential array node
    • toType

      <T> T toType(Type type)
      Convert this node into the requested type
      Type Parameters:
      T - the type
      Parameters:
      type - the type into which this node needs to be converted
      Returns:
      the converted type
    • getNode

      Optional<Node> getNode(String name)
      Get the node value with the given name.
      Parameters:
      name - the name of the node
      Returns:
      the node for the given name
    • value

      Object value(Type typeHint)
      Get the value of the node.
      Parameters:
      typeHint - the potential type of the value
      Returns:
      the node value