Class PutDataFileRequest.Builder
- java.lang.Object
-
- com.oracle.bmc.apmconfig.requests.PutDataFileRequest.Builder
-
- All Implemented Interfaces:
BmcRequest.Builder<PutDataFileRequest,InputStream>
- Enclosing class:
- PutDataFileRequest
public static class PutDataFileRequest.Builder extends Object implements BmcRequest.Builder<PutDataFileRequest,InputStream>
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PutDataFileRequest.BuilderapmDomainId(String apmDomainId)The APM Domain ID the request is intended for.PutDataFileRequest.BuilderapmType(String apmType)The type of the data file.PutDataFileRequest.Builderbody$(InputStream body)Alternative setter for the body parameter.PutDataFileRequestbuild()Build the instance of PutDataFileRequest as configured by this builderPutDataFileRequestbuildWithoutInvocationCallback()Build the instance of PutDataFileRequest as configured by this builderPutDataFileRequest.BuildercontentDisposition(String contentDisposition)Optional parameter that provides presentation information for how the content should be displayed or handled by the recipient.PutDataFileRequest.BuildercontentEncoding(String contentEncoding)Optional parameter indicating the content encodings applied to the request body (e.g., gzip, deflate).PutDataFileRequest.BuildercontentLanguage(String contentLanguage)Optional parameter that indicates the natural language of the content.PutDataFileRequest.BuildercontentMD5(String contentMD5)Optional base64-encoded MD5 hash of the request body.PutDataFileRequest.BuildercontentType(String contentType)Optional parameter specifying the media type (MIME type) of the request or response body.PutDataFileRequest.Buildercopy(PutDataFileRequest o)Copy method to populate the builder with values from the given instance.PutDataFileRequest.BuilderdataFileName(String dataFileName)The name of the data file.PutDataFileRequest.BuilderinvocationCallback(com.oracle.bmc.http.client.RequestInterceptor invocationCallback)Set the invocation callback for the request to be built.PutDataFileRequest.Buildermetadata(String metadata)A string containing a JSON-encoded object with metadata related to the uploaded file or resource.PutDataFileRequest.BuilderopcClientRequestId(String opcClientRequestId)The client request ID for tracing.PutDataFileRequest.BuilderopcRetryToken(String opcRetryToken)A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again.PutDataFileRequest.BuilderputDataFileBody(InputStream putDataFileBody)The data file to be uploaded.PutDataFileRequest.BuilderretryConfiguration(RetryConfiguration retryConfiguration)Set the retry configuration for the request to be built.
-
-
-
Method Detail
-
putDataFileBody
public PutDataFileRequest.Builder putDataFileBody(InputStream putDataFileBody)
The data file to be uploaded.- Parameters:
putDataFileBody- the value to set- Returns:
- this builder instance
-
dataFileName
public PutDataFileRequest.Builder dataFileName(String dataFileName)
The name of the data file.- Parameters:
dataFileName- the value to set- Returns:
- this builder instance
-
apmDomainId
public PutDataFileRequest.Builder apmDomainId(String apmDomainId)
The APM Domain ID the request is intended for.- Parameters:
apmDomainId- the value to set- Returns:
- this builder instance
-
apmType
public PutDataFileRequest.Builder apmType(String apmType)
The type of the data file.- Parameters:
apmType- the value to set- Returns:
- this builder instance
-
contentMD5
public PutDataFileRequest.Builder contentMD5(String contentMD5)
Optional base64-encoded MD5 hash of the request body.If provided, the server will perform a data integrity check by computing the MD5 of the received content and comparing it to the supplied value.
If the values do not match, the request will be rejected with an HTTP 400 error and a message such as:
"The computed MD5 of the request body (ACTUAL_MD5) does not match the Content-MD5 header (HEADER_MD5)"
- Parameters:
contentMD5- the value to set- Returns:
- this builder instance
-
contentType
public PutDataFileRequest.Builder contentType(String contentType)
Optional parameter specifying the media type (MIME type) of the request or response body.If not specified, the default is application/octet-stream.
This value can be used by recipients to determine how to interpret or render the content.
- Parameters:
contentType- the value to set- Returns:
- this builder instance
-
contentLanguage
public PutDataFileRequest.Builder contentLanguage(String contentLanguage)
Optional parameter that indicates the natural language of the content.This value can be used by clients or intermediaries to select or display content based on language preferences.
- Parameters:
contentLanguage- the value to set- Returns:
- this builder instance
-
contentEncoding
public PutDataFileRequest.Builder contentEncoding(String contentEncoding)
Optional parameter indicating the content encodings applied to the request body (e.g., gzip, deflate).This value can be used by recipients to determine how to decode the content.
- Parameters:
contentEncoding- the value to set- Returns:
- this builder instance
-
contentDisposition
public PutDataFileRequest.Builder contentDisposition(String contentDisposition)
Optional parameter that provides presentation information for how the content should be displayed or handled by the recipient.For example, to prompt a file download with a custom filename: attachment; filename="example.txt"
- Parameters:
contentDisposition- the value to set- Returns:
- this builder instance
-
metadata
public PutDataFileRequest.Builder metadata(String metadata)
A string containing a JSON-encoded object with metadata related to the uploaded file or resource.Example: {“fileName”:“report.pdf”,“uploader”:“jane.doe”,“category”:“financial”}
- Parameters:
metadata- the value to set- Returns:
- this builder instance
-
opcRetryToken
public PutDataFileRequest.Builder opcRetryToken(String opcRetryToken)
A token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again.Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations. For example, if a resource has been deleted and purged from the system, then a retry of the original creation request might be rejected.
- Parameters:
opcRetryToken- the value to set- Returns:
- this builder instance
-
opcClientRequestId
public PutDataFileRequest.Builder opcClientRequestId(String opcClientRequestId)
The client request ID for tracing.- Parameters:
opcClientRequestId- the value to set- Returns:
- this builder instance
-
invocationCallback
public PutDataFileRequest.Builder invocationCallback(com.oracle.bmc.http.client.RequestInterceptor invocationCallback)
Set the invocation callback for the request to be built.- Parameters:
invocationCallback- the invocation callback to be set for the request- Returns:
- this builder instance
-
retryConfiguration
public PutDataFileRequest.Builder retryConfiguration(RetryConfiguration retryConfiguration)
Set the retry configuration for the request to be built.- Parameters:
retryConfiguration- the retry configuration to be used for the request- Returns:
- this builder instance
-
copy
public PutDataFileRequest.Builder copy(PutDataFileRequest o)
Copy method to populate the builder with values from the given instance.- Specified by:
copyin interfaceBmcRequest.Builder<PutDataFileRequest,InputStream>- Parameters:
o- other request from which to copy values- Returns:
- this builder instance
-
build
public PutDataFileRequest build()
Build the instance of PutDataFileRequest as configured by this builderNote that this method takes calls to
invocationCallback(com.oracle.bmc.http.client.RequestInterceptor)into account, while the methodbuildWithoutInvocationCallback()does not.This is the preferred method to build an instance.
- Specified by:
buildin interfaceBmcRequest.Builder<PutDataFileRequest,InputStream>- Returns:
- instance of PutDataFileRequest
-
body$
public PutDataFileRequest.Builder body$(InputStream body)
Alternative setter for the body parameter.- Specified by:
body$in interfaceBmcRequest.Builder<PutDataFileRequest,InputStream>- Parameters:
body- the body parameter- Returns:
- this builder instance
-
buildWithoutInvocationCallback
public PutDataFileRequest buildWithoutInvocationCallback()
Build the instance of PutDataFileRequest as configured by this builderNote that this method does not take calls to
invocationCallback(com.oracle.bmc.http.client.RequestInterceptor)into account, while the methodbuild()does- Returns:
- instance of PutDataFileRequest
-
-