Class DocumentBlock
-
- All Implemented Interfaces:
public final class DocumentBlock
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classDocumentBlock.BuilderA builder for DocumentBlock.
public final classDocumentBlock.Source
-
Method Summary
Modifier and Type Method Description final Optional<CitationsConfig>citations()Citation configuration for the document final DocumentBlock.Sourcesource()final Optional<String>title()The title of the document final JsonValue_type()Expected to always return the following:
However, this method can be useful for debugging and logging (e.g.JsonValue.from("document")final JsonField<CitationsConfig>_citations()Returns the raw JSON value of citations. final JsonField<DocumentBlock.Source>_source()Returns the raw JSON value of source. final JsonField<String>_title()Returns the raw JSON value of title. final Map<String, JsonValue>_additionalProperties()final DocumentBlock.BuildertoBuilder()final DocumentBlockvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static DocumentBlock.Builderbuilder()Returns a mutable builder for constructing an instance of DocumentBlock. -
-
Method Detail
-
citations
final Optional<CitationsConfig> citations()
Citation configuration for the document
-
source
final DocumentBlock.Source source()
-
_type
final JsonValue _type()
Expected to always return the following:
JsonValue.from("document")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_citations
final JsonField<CitationsConfig> _citations()
Returns the raw JSON value of citations.
Unlike citations, this method doesn't throw if the JSON field has an unexpected type.
-
_source
final JsonField<DocumentBlock.Source> _source()
Returns the raw JSON value of source.
Unlike source, this method doesn't throw if the JSON field has an unexpected type.
-
_title
final JsonField<String> _title()
Returns the raw JSON value of title.
Unlike title, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final DocumentBlock.Builder toBuilder()
-
validate
final DocumentBlock validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
builder
final static DocumentBlock.Builder builder()
Returns a mutable builder for constructing an instance of DocumentBlock.
The following fields are required:
.citations() .source() .title()
-
-
-
-