Class PredictResponsePayload
java.lang.Object
com.sap.ai.sdk.foundationmodels.rpt.generated.model.PredictResponsePayload
Response payload for prediction requests. Contains a list of prediction results.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceBuilder helper class.static interfaceBuilder helper class.static interfaceBuilder helper class.static interfaceBuilder helper class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedDefault constructor for PredictResponsePayload. -
Method Summary
Modifier and TypeMethodDescriptionaddPredictionsItem(Map<String, PredictionsInnerValue> predictionsItem) Add one predictions instance to thisPredictResponsePayload.create()Create a type-safe, fluent-api builder object to construct a newPredictResponsePayloadinstance with all required arguments.booleangetCustomField(String name) Deprecated.Get the names of the unrecognizable properties of thePredictResponsePayload.getId()Unique ID for the request.Get metadataMapping of column names to their list of prediction results or index column.Status message that can indicate warnings (e.g.inthashCode()Set the id of thisPredictResponsePayloadinstance and return the same instance.metadata(PredictResponseMetadata metadata) Set the metadata of thisPredictResponsePayloadinstance and return the same instance.predictions(List<Map<String, PredictionsInnerValue>> predictions) Set the predictions of thisPredictResponsePayloadinstance and return the same instance.voidsetCustomField(String customFieldName, Object customFieldValue) Set an unrecognizable property of thisPredictResponsePayloadinstance.voidSet the id of thisPredictResponsePayloadinstance.voidsetMetadata(PredictResponseMetadata metadata) Set the metadata of thisPredictResponsePayloadinstance.voidsetPredictions(List<Map<String, PredictionsInnerValue>> predictions) Set the predictions of thisPredictResponsePayloadinstance.voidsetStatus(PredictResponseStatus status) Set the status of thisPredictResponsePayloadinstance.status(PredictResponseStatus status) Set the status of thisPredictResponsePayloadinstance and return the same instance.toMap()Get the value of all properties of thisPredictResponsePayloadinstance including unrecognized properties.toString()
-
Constructor Details
-
PredictResponsePayload
protected PredictResponsePayload()Default constructor for PredictResponsePayload.
-
-
Method Details
-
id
Set the id of thisPredictResponsePayloadinstance and return the same instance.- Parameters:
id- Unique ID for the request.- Returns:
- The same instance of this
PredictResponsePayloadclass
-
getId
Unique ID for the request.- Returns:
- id The id of this
PredictResponsePayloadinstance.
-
setId
Set the id of thisPredictResponsePayloadinstance.- Parameters:
id- Unique ID for the request.
-
status
Set the status of thisPredictResponsePayloadinstance and return the same instance.- Parameters:
status- Status message that can indicate warnings (e.g. about suboptimal data).- Returns:
- The same instance of this
PredictResponsePayloadclass
-
getStatus
Status message that can indicate warnings (e.g. about suboptimal data).- Returns:
- status The status of this
PredictResponsePayloadinstance.
-
setStatus
Set the status of thisPredictResponsePayloadinstance.- Parameters:
status- Status message that can indicate warnings (e.g. about suboptimal data).
-
predictions
@Nonnull public PredictResponsePayload predictions(@Nonnull List<Map<String, PredictionsInnerValue>> predictions) Set the predictions of thisPredictResponsePayloadinstance and return the same instance.- Parameters:
predictions- Mapping of column names to their list of prediction results or index column.- Returns:
- The same instance of this
PredictResponsePayloadclass
-
addPredictionsItem
@Nonnull public PredictResponsePayload addPredictionsItem(@Nonnull Map<String, PredictionsInnerValue> predictionsItem) Add one predictions instance to thisPredictResponsePayload.- Parameters:
predictionsItem- The predictions that should be added- Returns:
- The same instance of type
PredictResponsePayload
-
getPredictions
Mapping of column names to their list of prediction results or index column.- Returns:
- predictions The predictions of this
PredictResponsePayloadinstance.
-
setPredictions
Set the predictions of thisPredictResponsePayloadinstance.- Parameters:
predictions- Mapping of column names to their list of prediction results or index column.
-
metadata
Set the metadata of thisPredictResponsePayloadinstance and return the same instance.- Parameters:
metadata- The metadata of thisPredictResponsePayload- Returns:
- The same instance of this
PredictResponsePayloadclass
-
getMetadata
Get metadata- Returns:
- metadata The metadata of this
PredictResponsePayloadinstance.
-
setMetadata
Set the metadata of thisPredictResponsePayloadinstance.- Parameters:
metadata- The metadata of thisPredictResponsePayload
-
getCustomFieldNames
Get the names of the unrecognizable properties of thePredictResponsePayload.- 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 thisPredictResponsePayloadinstance.- 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 thisPredictResponsePayloadinstance including unrecognized properties.- Returns:
- The map of all properties
-
setCustomField
Set an unrecognizable property of thisPredictResponsePayloadinstance. 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 newPredictResponsePayloadinstance with all required arguments.
-
toMap()instead.