Package com.google.genai.types
Class CitationMetadata
-
- All Implemented Interfaces:
public abstract class CitationMetadata extends JsonSerializable
Citation information when the model quotes another source.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public abstract classCitationMetadata.BuilderBuilder for CitationMetadata.
-
Field Summary
Fields Modifier and Type Field Description public final static StringMAX_READ_LENGTH_PROPERTY
-
Constructor Summary
Constructors Constructor Description CitationMetadata()
-
Method Summary
Modifier and Type Method Description abstract Optional<List<Citation>>citations()Contains citation information when the model directly quotes, at length, from another source. static CitationMetadata.Builderbuilder()Instantiates a builder for CitationMetadata. abstract CitationMetadata.BuildertoBuilder()Creates a builder with the same values as this instance. static CitationMetadatafromJson(String jsonString)Deserializes a JSON string to a CitationMetadata object. -
Methods inherited from class com.google.genai.JsonSerializable
fromJsonNode, fromJsonString, objectMapper, setMaxReadLength, stringToJsonNode, toJson, toJsonNode, toJsonString -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
citations
abstract Optional<List<Citation>> citations()
Contains citation information when the model directly quotes, at length, from another source. Can include traditional websites and code repositories.
-
builder
static CitationMetadata.Builder builder()
Instantiates a builder for CitationMetadata.
-
toBuilder
abstract CitationMetadata.Builder toBuilder()
Creates a builder with the same values as this instance.
-
fromJson
static CitationMetadata fromJson(String jsonString)
Deserializes a JSON string to a CitationMetadata object.
-
-
-
-