public class CreateMessageOptions extends QueueServiceOptions
createMessage requests. These options include a server response timeout for
the request, the visibility timeout to set on the created message, and the
time-to-live value to set on the message.| Constructor and Description |
|---|
CreateMessageOptions() |
| Modifier and Type | Method and Description |
|---|---|
Integer |
getTimeToLiveInSeconds()
Gets the message time-to-live in seconds value associated with this
CreateMessageOptions instance. |
Integer |
getVisibilityTimeoutInSeconds()
Gets the message visibility timeout in seconds value in this
CreateMessageOptions instance. |
CreateMessageOptions |
setTimeout(Integer timeout)
Sets the server request timeout value associated with this
CreateMessageOptions instance. |
CreateMessageOptions |
setTimeToLiveInSeconds(Integer timeToLiveInSeconds)
Sets the message time-to-live timeout value to set on messages when
making a
createMessage request. |
CreateMessageOptions |
setVisibilityTimeoutInSeconds(Integer visibilityTimeoutInSeconds)
Sets the message visibility timeout in seconds value to set on messages
when making a
createMessage request. |
getTimeoutpublic CreateMessageOptions setTimeout(Integer timeout)
CreateMessageOptions instance.
The timeout value only affects calls made on methods where this
CreateMessageOptions instance is passed as a parameter.
setTimeout in class QueueServiceOptionstimeout - The server request timeout value to set in milliseconds.CreateMessageOptions instance.public Integer getVisibilityTimeoutInSeconds()
CreateMessageOptions instance. to set on messages when making a
createMessage request.public CreateMessageOptions setVisibilityTimeoutInSeconds(Integer visibilityTimeoutInSeconds)
createMessage request. This allows messages to be loaded into the queue
but not become visible until the visibility timeout has passed. Valid
visibility timeout values range from 0 to 604800 seconds (0 to 7 days),
and must be less than the time-to-live value.
The visibilityTimeoutInSeconds value only affects calls made on
methods where this CreateMessageOptions instance is passed as a
parameter.
visibilityTimeoutInSeconds - The length of time during which the message will be invisible,
starting when it is added to the queue, or 0 to make the
message visible immediately. This value must be greater than
or equal to zero and less than or equal to the time-to-live
value.CreateMessageOptions instance.public Integer getTimeToLiveInSeconds()
CreateMessageOptions instance.public CreateMessageOptions setTimeToLiveInSeconds(Integer timeToLiveInSeconds)
createMessage request. This is the maximum duration in seconds for the
message to remain in the queue after it is created. Valid
timeToLiveInSeconds values range from 0 to 604800 seconds (0 to
7 days), with the default value set to seven days.
The timeToLiveInSeconds value only affects calls made on methods
where this CreateMessageOptions instance is passed as a
parameter.
timeToLiveInSeconds - The maximum time to allow the message to be in the queue, in
seconds.CreateMessageOptions instance./**
* Copyright Microsoft Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/