Interface Value

All Known Implementing Classes:
CharSequenceValue, NumberValue, ValueContainer

public interface Value
Represents a lazily decoded JSON token or container managed by the index-overlay parser.
  • Method Details

    • byteValue

      byte byteValue()
      Converts this token to a byte value.
      Returns:
      the byte representation
    • shortValue

      short shortValue()
      Converts this token to a short value.
      Returns:
      the short representation
    • intValue

      int intValue()
      Converts this token to an int value.
      Returns:
      the int representation
    • longValue

      long longValue()
      Converts this token to a long value.
      Returns:
      the long representation
    • bigDecimalValue

      BigDecimal bigDecimalValue()
      Converts this token to a BigDecimal.
      Returns:
      the decimal representation
    • bigIntegerValue

      BigInteger bigIntegerValue()
      Converts this token to a BigInteger.
      Returns:
      the integer representation
    • floatValue

      float floatValue()
      Converts this token to a float value.
      Returns:
      the float representation
    • doubleValue

      double doubleValue()
      Converts this token to a double value.
      Returns:
      the double representation
    • booleanValue

      boolean booleanValue()
      Converts this token to a boolean value.
      Returns:
      the boolean representation
    • dateValue

      Date dateValue()
      Converts this token to a Date.
      Returns:
      the date representation
    • stringValue

      String stringValue()
      Returns the string form using the value's configured decoding policy.
      Returns:
      the string representation
    • stringValueEncoded

      String stringValueEncoded()
      Returns the fully decoded string form.
      Returns:
      the decoded string representation
    • toValue

      Object toValue()
      Materializes this token as a regular Java value.
      Returns:
      the hydrated value
    • toEnum

      <T extends Enum> T toEnum(Class<T> cls)
      Converts this token to an enum constant.
      Type Parameters:
      T - enum type
      Parameters:
      cls - enum type to resolve
      Returns:
      the resolved enum constant
    • isContainer

      boolean isContainer()
      Indicates whether this value wraps a map or a collection.
      Returns:
      true for container values
    • chop

      void chop()
      Copies any shared backing buffer into a dedicated slice.
    • charValue

      char charValue()
      Converts this token to a single character.
      Returns:
      the leading character representation