@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class InvokeModelRequest extends AmazonWebServiceRequest implements Serializable, Cloneable
NOOP
Constructor and Description |
---|
InvokeModelRequest() |
Modifier and Type | Method and Description |
---|---|
InvokeModelRequest |
clone()
Creates a shallow clone of this object for all fields except the handler context.
|
boolean |
equals(Object obj) |
String |
getAccept()
The desired MIME type of the inference body in the response.
|
ByteBuffer |
getBody()
Input data in the format specified in the content-type request header.
|
String |
getContentType()
The MIME type of the input data in the request.
|
String |
getModelId()
Identifier of the model.
|
int |
hashCode() |
void |
setAccept(String accept)
The desired MIME type of the inference body in the response.
|
void |
setBody(ByteBuffer body)
Input data in the format specified in the content-type request header.
|
void |
setContentType(String contentType)
The MIME type of the input data in the request.
|
void |
setModelId(String modelId)
Identifier of the model.
|
String |
toString()
Returns a string representation of this object.
|
InvokeModelRequest |
withAccept(String accept)
The desired MIME type of the inference body in the response.
|
InvokeModelRequest |
withBody(ByteBuffer body)
Input data in the format specified in the content-type request header.
|
InvokeModelRequest |
withContentType(String contentType)
The MIME type of the input data in the request.
|
InvokeModelRequest |
withModelId(String modelId)
Identifier of the model.
|
addHandlerContext, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getHandlerContext, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestCredentialsProvider, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
public void setBody(ByteBuffer body)
Input data in the format specified in the content-type request header. To see the format and content of this field for different models, refer to Inference parameters.
The AWS SDK for Java performs a Base64 encoding on this field before sending this request to the AWS service. Users of the SDK should not perform Base64 encoding on this field.
Warning: ByteBuffers returned by the SDK are mutable. Changes to the content or position of the byte buffer will be seen by all objects that have a reference to this object. It is recommended to call ByteBuffer.duplicate() or ByteBuffer.asReadOnlyBuffer() before using or reading from the buffer. This behavior will be changed in a future major version of the SDK.
body
- Input data in the format specified in the content-type request header. To see the format and content of
this field for different models, refer to Inference
parameters.public ByteBuffer getBody()
Input data in the format specified in the content-type request header. To see the format and content of this field for different models, refer to Inference parameters.
ByteBuffer
s are stateful. Calling their get
methods changes their position
. We recommend
using ByteBuffer.asReadOnlyBuffer()
to create a read-only view of the buffer with an independent
position
, and calling get
methods on this rather than directly on the returned ByteBuffer
.
Doing so will ensure that anyone else using the ByteBuffer
will not be affected by changes to the
position
.
public InvokeModelRequest withBody(ByteBuffer body)
Input data in the format specified in the content-type request header. To see the format and content of this field for different models, refer to Inference parameters.
The AWS SDK for Java performs a Base64 encoding on this field before sending this request to the AWS service. Users of the SDK should not perform Base64 encoding on this field.
Warning: ByteBuffers returned by the SDK are mutable. Changes to the content or position of the byte buffer will be seen by all objects that have a reference to this object. It is recommended to call ByteBuffer.duplicate() or ByteBuffer.asReadOnlyBuffer() before using or reading from the buffer. This behavior will be changed in a future major version of the SDK.
body
- Input data in the format specified in the content-type request header. To see the format and content of
this field for different models, refer to Inference
parameters.public void setContentType(String contentType)
The MIME type of the input data in the request. The default value is application/json
.
contentType
- The MIME type of the input data in the request. The default value is application/json
.public String getContentType()
The MIME type of the input data in the request. The default value is application/json
.
application/json
.public InvokeModelRequest withContentType(String contentType)
The MIME type of the input data in the request. The default value is application/json
.
contentType
- The MIME type of the input data in the request. The default value is application/json
.public void setAccept(String accept)
The desired MIME type of the inference body in the response. The default value is application/json
.
accept
- The desired MIME type of the inference body in the response. The default value is
application/json
.public String getAccept()
The desired MIME type of the inference body in the response. The default value is application/json
.
application/json
.public InvokeModelRequest withAccept(String accept)
The desired MIME type of the inference body in the response. The default value is application/json
.
accept
- The desired MIME type of the inference body in the response. The default value is
application/json
.public void setModelId(String modelId)
Identifier of the model.
modelId
- Identifier of the model.public String getModelId()
Identifier of the model.
public InvokeModelRequest withModelId(String modelId)
Identifier of the model.
modelId
- Identifier of the model.public String toString()
toString
in class Object
Object.toString()
public InvokeModelRequest clone()
AmazonWebServiceRequest
clone
in class AmazonWebServiceRequest
Object.clone()