Interface ValueNodeContainer

All Known Implementing Classes:
ArrayValue, Field

public interface ValueNodeContainer
A general interface for nodes that allow values to be added to itself.
  • Method Details

    • addValue

      ValueNodeContainer addValue(FieldType type, Object value)
      Adds a value with the specified FieldType to this container.
      Parameters:
      type - the field type of the value to add, or null to infer the type
      value - the value to add, may be null
      Returns:
      this container for method chaining
    • addValue

      ValueNodeContainer addValue(Object value)
      Adds a value to this container, inferring the FieldType from the value's class.
      Parameters:
      value - the value to add, may be null
      Returns:
      this container for method chaining
    • addNull

      Adds a typed null value to this container.
      Parameters:
      type - the field type of the null value to add
      Returns:
      this container for method chaining
    • hasValue

      boolean hasValue()
      Returns true if this container has had any value added, including null. Otherwise, it returns false.