Package com.sap.ai.sdk.grounding.model

# Class DataRepository

java.lang.Object
com.sap.ai.sdk.grounding.model.DataRepository

public class DataRepository extends Object
DataRepository schema expected by Retrieval.

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static interface`
  `DataRepository.Builder`
  Builder helper class.
  `static interface`
  `DataRepository.Builder1`
  Builder helper class.
  `static interface`
  `DataRepository.Builder2`
  Builder helper class.

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `DataRepository()`
  Default constructor for DataRepository.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `DataRepository`
  `addMetadataItem(RetrievalKeyValueListPair metadataItem)`
  Add one metadata instance to this `DataRepository`.
  `static DataRepository.Builder`
  `create()`
  Create a type-safe, fluent-api builder object to construct a new `DataRepository` instance with all required arguments.
  `boolean`
  `equals(Object o)`
  `Object`
  `getCustomField(String name)`
  Deprecated.
  Use `toMap()` instead.
  `Set<String>`
  `getCustomFieldNames()`
  Get the names of the unrecognizable properties of the `DataRepository`.
  `UUID`
  `getId()`
  Unique identifier of this DataRepository.
  `String`
  `getMessage()`
  Get message
  `List<RetrievalKeyValueListPair>`
  `getMetadata()`
  Metadata attached to DataRepository.
  `String`
  `getRemoteGroundingName()`
  Get remoteGroundingName
  `String`
  `getTitle()`
  Get title
  `DataRepositoryType`
  `getType()`
  Get type
  `int`
  `hashCode()`
  `DataRepository`
  `id(UUID id)`
  Set the id of this `DataRepository` instance and return the same instance.
  `DataRepository`
  `message(String message)`
  Set the message of this `DataRepository` instance and return the same instance.
  `DataRepository`
  `metadata(List<RetrievalKeyValueListPair> metadata)`
  Set the metadata of this `DataRepository` instance and return the same instance.
  `DataRepository`
  `remoteGroundingName(String remoteGroundingName)`
  Set the remoteGroundingName of this `DataRepository` instance and return the same instance.
  `void`
  `setCustomField(String customFieldName, Object customFieldValue)`
  Set an unrecognizable property of this `DataRepository` instance.
  `void`
  `setId(UUID id)`
  Set the id of this `DataRepository` instance.
  `void`
  `setMessage(String message)`
  Set the message of this `DataRepository` instance.
  `void`
  `setMetadata(List<RetrievalKeyValueListPair> metadata)`
  Set the metadata of this `DataRepository` instance.
  `void`
  `setRemoteGroundingName(String remoteGroundingName)`
  Set the remoteGroundingName of this `DataRepository` instance.
  `void`
  `setTitle(String title)`
  Set the title of this `DataRepository` instance.
  `void`
  `setType(DataRepositoryType type)`
  Set the type of this `DataRepository` instance.
  `DataRepository`
  `title(String title)`
  Set the title of this `DataRepository` instance and return the same instance.
  `Map<String,Object>`
  `toMap()`
  Get the value of all properties of this `DataRepository` instance including unrecognized properties.
  `String`
  `toString()`
  `DataRepository`
  `type(DataRepositoryType type)`
  Set the type of this `DataRepository` instance and return the same instance.

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### DataRepository

    protected DataRepository()
    Default constructor for DataRepository.

- ## Method Details

  - ### id

    @Nonnull public DataRepository id(@Nonnull UUID id)
    Set the id of this `DataRepository` instance and return the same instance.
    Parameters:
      `id` - Unique identifier of this DataRepository.
    Returns:
      The same instance of this `DataRepository` class

  - ### getId

    @Nonnull public UUID getId()
    Unique identifier of this DataRepository.
    Returns:
      id The id of this `DataRepository` instance.

  - ### setId

    public void setId(@Nonnull UUID id)
    Set the id of this `DataRepository` instance.
    Parameters:
      `id` - Unique identifier of this DataRepository.

  - ### title

    @Nonnull public DataRepository title(@Nonnull String title)
    Set the title of this `DataRepository` instance and return the same instance.
    Parameters:
      `title` - The title of this `DataRepository`
    Returns:
      The same instance of this `DataRepository` class

  - ### getTitle

    @Nonnull public String getTitle()
    Get title
    Returns:
      title The title of this `DataRepository` instance.

  - ### setTitle

    public void setTitle(@Nonnull String title)
    Set the title of this `DataRepository` instance.
    Parameters:
      `title` - The title of this `DataRepository`

  - ### metadata

    @Nonnull public DataRepository metadata(@Nullable List<RetrievalKeyValueListPair> metadata)
    Set the metadata of this `DataRepository` instance and return the same instance.
    Parameters:
      `metadata` - Metadata attached to DataRepository. Useful to later limit search to a subset of DataRepositories.
    Returns:
      The same instance of this `DataRepository` class

  - ### addMetadataItem

    @Nonnull public DataRepository addMetadataItem(@Nonnull RetrievalKeyValueListPair metadataItem)
    Add one metadata instance to this `DataRepository`.
    Parameters:
      `metadataItem` - The metadata that should be added
    Returns:
      The same instance of type `DataRepository`

  - ### getMetadata

    @Nonnull public List<RetrievalKeyValueListPair> getMetadata()
    Metadata attached to DataRepository. Useful to later limit search to a subset of DataRepositories.
    Returns:
      metadata The metadata of this `DataRepository` instance.

  - ### setMetadata

    public void setMetadata(@Nullable List<RetrievalKeyValueListPair> metadata)
    Set the metadata of this `DataRepository` instance.
    Parameters:
      `metadata` - Metadata attached to DataRepository. Useful to later limit search to a subset of DataRepositories.

  - ### remoteGroundingName

    @Nonnull public DataRepository remoteGroundingName(@Nullable String remoteGroundingName)
    Set the remoteGroundingName of this `DataRepository` instance and return the same instance.
    Parameters:
      `remoteGroundingName` - The remoteGroundingName of this `DataRepository`
    Returns:
      The same instance of this `DataRepository` class

  - ### getRemoteGroundingName

    @Nullable public String getRemoteGroundingName()
    Get remoteGroundingName
    Returns:
      remoteGroundingName The remoteGroundingName of this `DataRepository` instance.

  - ### setRemoteGroundingName

    public void setRemoteGroundingName(@Nullable String remoteGroundingName)
    Set the remoteGroundingName of this `DataRepository` instance.
    Parameters:
      `remoteGroundingName` - The remoteGroundingName of this `DataRepository`

  - ### message

    @Nonnull public DataRepository message(@Nullable String message)
    Set the message of this `DataRepository` instance and return the same instance.
    Parameters:
      `message` - The message of this `DataRepository`
    Returns:
      The same instance of this `DataRepository` class

  - ### getMessage

    @Nullable public String getMessage()
    Get message
    Returns:
      message The message of this `DataRepository` instance.

  - ### setMessage

    public void setMessage(@Nullable String message)
    Set the message of this `DataRepository` instance.
    Parameters:
      `message` - The message of this `DataRepository`

  - ### type

    @Nonnull public DataRepository type(@Nonnull DataRepositoryType type)
    Set the type of this `DataRepository` instance and return the same instance.
    Parameters:
      `type` - The type of this `DataRepository`
    Returns:
      The same instance of this `DataRepository` class

  - ### getType

    @Nonnull public DataRepositoryType getType()
    Get type
    Returns:
      type The type of this `DataRepository` instance.

  - ### setType

    public void setType(@Nonnull DataRepositoryType type)
    Set the type of this `DataRepository` instance.
    Parameters:
      `type` - The type of this `DataRepository`

  - ### getCustomFieldNames

    @Nonnull public Set<String> getCustomFieldNames()
    Get the names of the unrecognizable properties of the `DataRepository`.
    Returns:
      The set of properties names

  - ### getCustomField

    @Nullable @Deprecated public Object getCustomField(@Nonnull String name) throws NoSuchElementException
    Deprecated.
    Use `toMap()` instead.
    Get the value of an unrecognizable property of this `DataRepository` instance.
    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

    @Nonnull public Map<String,Object> toMap()
    Get the value of all properties of this `DataRepository` instance including unrecognized properties.
    Returns:
      The map of all properties

  - ### setCustomField

    public void setCustomField(@Nonnull String customFieldName, @Nullable Object customFieldValue)
    Set an unrecognizable property of this `DataRepository` instance. 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 property
      `customFieldValue` - The value of the property

  - ### equals

    public boolean equals(@Nullable Object o)
    Overrides:
      `equals` in class `Object`

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `Object`

  - ### toString

    @Nonnull public String toString()
    Overrides:
      `toString` in class `Object`

  - ### create

    public static DataRepository.Builder create()
    Create a type-safe, fluent-api builder object to construct a new `DataRepository` instance with all required arguments.