Record Class ClassifierContent.JsonArray
java.lang.Object
java.lang.Record
com.google.adk.classifiers.ClassifierContent.JsonArray
- All Implemented Interfaces:
ClassifierContent, ClassifierInput
- Enclosing interface:
ClassifierContent
public static record ClassifierContent.JsonArray(com.fasterxml.jackson.databind.node.ArrayNode json)
extends Record
implements ClassifierContent
A JSON array. Creating one throws
IllegalArgumentException under the same conditions as
ClassifierContent.JsonObject.-
Nested Class Summary
Nested classes/interfaces inherited from interface ClassifierContent
ClassifierContent.JsonArray, ClassifierContent.JsonObject, ClassifierContent.TextModifier and TypeInterfaceDescriptionstatic final recordA JSON array.static final recordA JSON object.static final recordPlain text.Nested classes/interfaces inherited from interface ClassifierInput
ClassifierInput.Content -
Constructor Summary
ConstructorsConstructorDescriptionJsonArray(com.fasterxml.jackson.databind.node.ArrayNode json) Creates an instance of aJsonArrayrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.com.fasterxml.jackson.databind.node.ArrayNodejson()Returns a copy of the array, with each number written as the long or double it parses to.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
JsonArray
public JsonArray(com.fasterxml.jackson.databind.node.ArrayNode json) Creates an instance of aJsonArrayrecord class.- Parameters:
json- the value for thejsonrecord component
-
-
Method Details
-
json
public com.fasterxml.jackson.databind.node.ArrayNode json()Returns a copy of the array, with each number written as the long or double it parses to. -
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object).
-