Package com.sap.ai.sdk.grounding.model
Class DocumentsChunk
java.lang.Object
com.sap.ai.sdk.grounding.model.DocumentsChunk
DocumentsChunk
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceBuilder helper class.static interfaceBuilder helper class.static interfaceBuilder helper class. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddDocumentsItem(DocumentOutput documentsItem) Add one documents instance to thisDocumentsChunk.addMetadataItem(VectorKeyValueListPair metadataItem) Add one metadata instance to thisDocumentsChunk.static DocumentsChunk.Buildercreate()Create a type-safe, fluent-api builder object to construct a newDocumentsChunkinstance with all required arguments.documents(List<DocumentOutput> documents) Set the documents of thisDocumentsChunkinstance and return the same instance.booleangetCustomField(String name) Deprecated.Get the names of the unrecognizable properties of theDocumentsChunk.Get documentsgetId()Get idGet metadatagetTitle()Get titleinthashCode()Set the id of thisDocumentsChunkinstance and return the same instance.metadata(List<VectorKeyValueListPair> metadata) Set the metadata of thisDocumentsChunkinstance and return the same instance.voidsetCustomField(String customFieldName, Object customFieldValue) Set an unrecognizable property of thisDocumentsChunkinstance.voidsetDocuments(List<DocumentOutput> documents) Set the documents of thisDocumentsChunkinstance.voidSet the id of thisDocumentsChunkinstance.voidsetMetadata(List<VectorKeyValueListPair> metadata) Set the metadata of thisDocumentsChunkinstance.voidSet the title of thisDocumentsChunkinstance.Set the title of thisDocumentsChunkinstance and return the same instance.toMap()Get the value of all properties of thisDocumentsChunkinstance including unrecognized properties.toString()
-
Constructor Details
-
DocumentsChunk
protected DocumentsChunk()Default constructor for DocumentsChunk.
-
-
Method Details
-
id
Set the id of thisDocumentsChunkinstance and return the same instance.- Parameters:
id- The id of thisDocumentsChunk- Returns:
- The same instance of this
DocumentsChunkclass
-
getId
Get id- Returns:
- id The id of this
DocumentsChunkinstance.
-
setId
Set the id of thisDocumentsChunkinstance.- Parameters:
id- The id of thisDocumentsChunk
-
title
Set the title of thisDocumentsChunkinstance and return the same instance.- Parameters:
title- The title of thisDocumentsChunk- Returns:
- The same instance of this
DocumentsChunkclass
-
getTitle
Get title- Returns:
- title The title of this
DocumentsChunkinstance.
-
setTitle
Set the title of thisDocumentsChunkinstance.- Parameters:
title- The title of thisDocumentsChunk
-
metadata
Set the metadata of thisDocumentsChunkinstance and return the same instance.- Parameters:
metadata- The metadata of thisDocumentsChunk- Returns:
- The same instance of this
DocumentsChunkclass
-
addMetadataItem
Add one metadata instance to thisDocumentsChunk.- Parameters:
metadataItem- The metadata that should be added- Returns:
- The same instance of type
DocumentsChunk
-
getMetadata
Get metadata- Returns:
- metadata The metadata of this
DocumentsChunkinstance.
-
setMetadata
Set the metadata of thisDocumentsChunkinstance.- Parameters:
metadata- The metadata of thisDocumentsChunk
-
documents
Set the documents of thisDocumentsChunkinstance and return the same instance.- Parameters:
documents- The documents of thisDocumentsChunk- Returns:
- The same instance of this
DocumentsChunkclass
-
addDocumentsItem
Add one documents instance to thisDocumentsChunk.- Parameters:
documentsItem- The documents that should be added- Returns:
- The same instance of type
DocumentsChunk
-
getDocuments
Get documents- Returns:
- documents The documents of this
DocumentsChunkinstance.
-
setDocuments
Set the documents of thisDocumentsChunkinstance.- Parameters:
documents- The documents of thisDocumentsChunk
-
getCustomFieldNames
Get the names of the unrecognizable properties of theDocumentsChunk.- Returns:
- The set of properties names
-
getCustomField
@Nullable @Deprecated public Object getCustomField(@Nonnull String name) throws NoSuchElementException Deprecated.UsetoMap()instead.Get the value of an unrecognizable property of thisDocumentsChunkinstance.- Parameters:
name- The name of the property- Returns:
- The value of the property
- Throws:
NoSuchElementException- If no property with the given name could be found.
-
toMap
Get the value of all properties of thisDocumentsChunkinstance including unrecognized properties.- Returns:
- The map of all properties
-
setCustomField
Set an unrecognizable property of thisDocumentsChunkinstance. If the map previously contained a mapping for the key, the old value is replaced by the specified value.- Parameters:
customFieldName- The name of the propertycustomFieldValue- The value of the property
-
equals
-
hashCode
public int hashCode() -
toString
-
create
Create a type-safe, fluent-api builder object to construct a newDocumentsChunkinstance with all required arguments.
-
toMap()instead.