Package com.sap.ai.sdk.prompt.registry.model

# Class PromptTemplateSubstitutionResponse

java.lang.Object
com.sap.ai.sdk.prompt.registry.model.PromptTemplateSubstitutionResponse

public class PromptTemplateSubstitutionResponse extends Object
PromptTemplateSubstitutionResponse

- ## Constructor Summary

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

- ## Method Summary

  Modifier and Type
  Method
  Description
  `PromptTemplateSubstitutionResponse`
  `addParsedPromptItem(PromptTemplate parsedPromptItem)`
  Add one parsedPrompt instance to this `PromptTemplateSubstitutionResponse`.
  `static PromptTemplateSubstitutionResponse`
  `create()`
  Create a new `PromptTemplateSubstitutionResponse` instance.
  `boolean`
  `equals(Object o)`
  `Object`
  `getCustomField(String name)`
  Deprecated.
  Use `toMap()` instead.
  `Set<String>`
  `getCustomFieldNames()`
  Get the names of the unrecognizable properties of the `PromptTemplateSubstitutionResponse`.
  `List<PromptTemplate>`
  `getParsedPrompt()`
  Get parsedPrompt
  `PromptTemplateGetResponse`
  `getResource()`
  Get resource
  `int`
  `hashCode()`
  `PromptTemplateSubstitutionResponse`
  `parsedPrompt(List<PromptTemplate> parsedPrompt)`
  Set the parsedPrompt of this `PromptTemplateSubstitutionResponse` instance and return the same instance.
  `PromptTemplateSubstitutionResponse`
  `resource(PromptTemplateGetResponse resource)`
  Set the resource of this `PromptTemplateSubstitutionResponse` instance and return the same instance.
  `void`
  `setCustomField(String customFieldName, Object customFieldValue)`
  Set an unrecognizable property of this `PromptTemplateSubstitutionResponse` instance.
  `void`
  `setParsedPrompt(List<PromptTemplate> parsedPrompt)`
  Set the parsedPrompt of this `PromptTemplateSubstitutionResponse` instance.
  `void`
  `setResource(PromptTemplateGetResponse resource)`
  Set the resource of this `PromptTemplateSubstitutionResponse` instance.
  `Map<String,Object>`
  `toMap()`
  Get the value of all properties of this `PromptTemplateSubstitutionResponse` instance including unrecognized properties.
  `String`
  `toString()`

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

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

- ## Constructor Details

  - ### PromptTemplateSubstitutionResponse

    protected PromptTemplateSubstitutionResponse()
    Default constructor for PromptTemplateSubstitutionResponse.

- ## Method Details

  - ### parsedPrompt

    @Nonnull public PromptTemplateSubstitutionResponse parsedPrompt(@Nullable List<PromptTemplate> parsedPrompt)
    Set the parsedPrompt of this `PromptTemplateSubstitutionResponse` instance and return the same instance.
    Parameters:
      `parsedPrompt` - The parsedPrompt of this `PromptTemplateSubstitutionResponse`
    Returns:
      The same instance of this `PromptTemplateSubstitutionResponse` class

  - ### addParsedPromptItem

    @Nonnull public PromptTemplateSubstitutionResponse addParsedPromptItem(@Nonnull PromptTemplate parsedPromptItem)
    Add one parsedPrompt instance to this `PromptTemplateSubstitutionResponse`.
    Parameters:
      `parsedPromptItem` - The parsedPrompt that should be added
    Returns:
      The same instance of type `PromptTemplateSubstitutionResponse`

  - ### getParsedPrompt

    @Nonnull public List<PromptTemplate> getParsedPrompt()
    Get parsedPrompt
    Returns:
      parsedPrompt The parsedPrompt of this `PromptTemplateSubstitutionResponse` instance.

  - ### setParsedPrompt

    public void setParsedPrompt(@Nullable List<PromptTemplate> parsedPrompt)
    Set the parsedPrompt of this `PromptTemplateSubstitutionResponse` instance.
    Parameters:
      `parsedPrompt` - The parsedPrompt of this `PromptTemplateSubstitutionResponse`

  - ### resource

    @Nonnull public PromptTemplateSubstitutionResponse resource(@Nullable PromptTemplateGetResponse resource)
    Set the resource of this `PromptTemplateSubstitutionResponse` instance and return the same instance.
    Parameters:
      `resource` - The resource of this `PromptTemplateSubstitutionResponse`
    Returns:
      The same instance of this `PromptTemplateSubstitutionResponse` class

  - ### getResource

    @Nonnull public PromptTemplateGetResponse getResource()
    Get resource
    Returns:
      resource The resource of this `PromptTemplateSubstitutionResponse` instance.

  - ### setResource

    public void setResource(@Nullable PromptTemplateGetResponse resource)
    Set the resource of this `PromptTemplateSubstitutionResponse` instance.
    Parameters:
      `resource` - The resource of this `PromptTemplateSubstitutionResponse`

  - ### getCustomFieldNames

    @Nonnull public Set<String> getCustomFieldNames()
    Get the names of the unrecognizable properties of the `PromptTemplateSubstitutionResponse`.
    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 `PromptTemplateSubstitutionResponse` 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 `PromptTemplateSubstitutionResponse` 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 `PromptTemplateSubstitutionResponse` 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 PromptTemplateSubstitutionResponse create()
    Create a new `PromptTemplateSubstitutionResponse` instance. No arguments are required.