Package com.sap.ai.sdk.orchestration
Class ResponseJsonSchema
java.lang.Object
com.sap.ai.sdk.orchestration.ResponseJsonSchema
The schema object to use for the response format parameter in
OrchestrationTemplate.- Since:
- 1.4.0
-
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic ResponseJsonSchemaCreate a new instance ofResponseJsonSchemawith the given schema map and name.static ResponseJsonSchemaCreate a new instance ofResponseJsonSchemafrom a given class.getName()⚠️ Fields of the schema class should be annotated with@JsonProperty(required = true)to not fail requests if set to true.inthashCode()toString()withDescription(String description) withSchemaMap(Map<String, Object> schemaMap) withStrict(Boolean strict) ⚠️ Fields of the schema class should be annotated with@JsonProperty(required = true)to not fail requests if set to true.
-
Method Details
-
fromMap
@Nonnull public static ResponseJsonSchema fromMap(@Nonnull Map<String, Object> schemaMap, @Nonnull String name) Create a new instance ofResponseJsonSchemawith the given schema map and name.- Parameters:
schemaMap- The schema mapname- The name of the schema- Returns:
- The new instance of
ResponseJsonSchema
-
fromType
Create a new instance ofResponseJsonSchemafrom a given class.⚠️ Fields of the schema class should be annotated with
@JsonProperty(required = true).- Parameters:
classType- The class to generate the schema from- Returns:
- The new instance of
ResponseJsonSchema
-
getSchemaMap
-
getName
-
getDescription
-
getStrict
⚠️ Fields of the schema class should be annotated with@JsonProperty(required = true)to not fail requests if set to true. -
equals
-
hashCode
public int hashCode() -
toString
-
withSchemaMap
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withName
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withDescription
- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-
withStrict
⚠️ Fields of the schema class should be annotated with@JsonProperty(required = true)to not fail requests if set to true.- Returns:
- a clone of this object, except with this updated property (returns
thisif an identical value is passed).
-