Class JsonAnyContent

java.lang.Object
dev.metaschema.databind.io.json.JsonAnyContent
All Implemented Interfaces:
IAnyContent

public class JsonAnyContent extends Object implements IAnyContent
JSON/YAML-specific implementation of IAnyContent that stores captured unmodeled content as a Jackson ObjectNode.
  • Constructor Summary

    Constructors
    Constructor
    Description
    JsonAnyContent(com.fasterxml.jackson.databind.node.ObjectNode properties)
    Construct a new instance with the provided captured properties.
  • Method Summary

    Modifier and Type
    Method
    Description
    com.fasterxml.jackson.databind.node.ObjectNode
    Get the captured JSON properties.
    boolean
    Determine if this content container has no captured content.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • JsonAnyContent

      public JsonAnyContent(@NonNull com.fasterxml.jackson.databind.node.ObjectNode properties)
      Construct a new instance with the provided captured properties.
      Parameters:
      properties - the captured JSON properties, must not be null
  • Method Details

    • isEmpty

      public boolean isEmpty()
      Description copied from interface: IAnyContent
      Determine if this content container has no captured content.
      Specified by:
      isEmpty in interface IAnyContent
      Returns:
      true if no unmodeled content was captured, false otherwise
    • getProperties

      @NonNull public com.fasterxml.jackson.databind.node.ObjectNode getProperties()
      Get the captured JSON properties.
      Returns:
      the captured ObjectNode