Class PublishMessageRequest.Builder
- java.lang.Object
-
- com.oracle.bmc.ons.requests.PublishMessageRequest.Builder
-
- All Implemented Interfaces:
BmcRequest.Builder<PublishMessageRequest,MessageDetails>
- Enclosing class:
- PublishMessageRequest
public static class PublishMessageRequest.Builder extends Object implements BmcRequest.Builder<PublishMessageRequest,MessageDetails>
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PublishMessageRequest.Builderbody$(MessageDetails body)Alternative setter for the body parameter.PublishMessageRequestbuild()Build the instance of PublishMessageRequest as configured by this builderPublishMessageRequestbuildWithoutInvocationCallback()Build the instance of PublishMessageRequest as configured by this builderPublishMessageRequest.Buildercopy(PublishMessageRequest o)Copy method to populate the builder with values from the given instance.PublishMessageRequest.BuilderinvocationCallback(com.oracle.bmc.http.client.RequestInterceptor invocationCallback)Set the invocation callback for the request to be built.PublishMessageRequest.BuildermessageDetails(MessageDetails messageDetails)The message to publish.PublishMessageRequest.BuildermessageType(PublishMessageRequest.MessageType messageType)Deprecated. Support for JSON is deprecated.PublishMessageRequest.BuilderopcRequestId(String opcRequestId)The unique Oracle-assigned identifier for the request.PublishMessageRequest.BuilderretryConfiguration(RetryConfiguration retryConfiguration)Set the retry configuration for the request to be built.PublishMessageRequest.BuildertopicId(String topicId)The OCID of the topic.
-
-
-
Method Detail
-
topicId
public PublishMessageRequest.Builder topicId(String topicId)
The OCID of the topic.- Parameters:
topicId- the value to set- Returns:
- this builder instance
-
messageDetails
public PublishMessageRequest.Builder messageDetails(MessageDetails messageDetails)
The message to publish.- Parameters:
messageDetails- the value to set- Returns:
- this builder instance
-
opcRequestId
public PublishMessageRequest.Builder opcRequestId(String opcRequestId)
The unique Oracle-assigned identifier for the request.If you need to contact Oracle about a particular request, please provide the request ID.
- Parameters:
opcRequestId- the value to set- Returns:
- this builder instance
-
messageType
public PublishMessageRequest.Builder messageType(PublishMessageRequest.MessageType messageType)
Deprecated. Support for JSON is deprecated.You can send a JSON payload even when transmitting the payload as a raw string. Configure your receiving system to read the raw payload as JSON format.
Type of message body in the request. For messageType of JSON, a default key-value pair is required. Example: {"default": "Alarm breached", "Email": "Alarm breached:
"}. - Parameters:
messageType- the value to set- Returns:
- this builder instance
-
invocationCallback
public PublishMessageRequest.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 PublishMessageRequest.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 PublishMessageRequest.Builder copy(PublishMessageRequest o)
Copy method to populate the builder with values from the given instance.- Specified by:
copyin interfaceBmcRequest.Builder<PublishMessageRequest,MessageDetails>- Parameters:
o- other request from which to copy values- Returns:
- this builder instance
-
build
public PublishMessageRequest build()
Build the instance of PublishMessageRequest 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<PublishMessageRequest,MessageDetails>- Returns:
- instance of PublishMessageRequest
-
body$
public PublishMessageRequest.Builder body$(MessageDetails body)
Alternative setter for the body parameter.- Specified by:
body$in interfaceBmcRequest.Builder<PublishMessageRequest,MessageDetails>- Parameters:
body- the body parameter- Returns:
- this builder instance
-
buildWithoutInvocationCallback
public PublishMessageRequest buildWithoutInvocationCallback()
Build the instance of PublishMessageRequest 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 PublishMessageRequest
-
-