#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Queue {
pub name: ::std::option::Option<::std::string::String>,
pub queue_arn: ::std::option::Option<::std::string::String>,
pub queue_id: ::std::option::Option<::std::string::String>,
pub description: ::std::option::Option<::std::string::String>,
pub outbound_caller_config: ::std::option::Option<crate::types::OutboundCallerConfig>,
pub outbound_email_config: ::std::option::Option<crate::types::OutboundEmailConfig>,
pub hours_of_operation_id: ::std::option::Option<::std::string::String>,
pub max_contacts: ::std::option::Option<i32>,
pub status: ::std::option::Option<crate::types::QueueStatus>,
pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub last_modified_time: ::std::option::Option<::aws_smithy_types::DateTime>,
pub last_modified_region: ::std::option::Option<::std::string::String>,
}
impl Queue {
pub fn name(&self) -> ::std::option::Option<&str> {
self.name.as_deref()
}
pub fn queue_arn(&self) -> ::std::option::Option<&str> {
self.queue_arn.as_deref()
}
pub fn queue_id(&self) -> ::std::option::Option<&str> {
self.queue_id.as_deref()
}
pub fn description(&self) -> ::std::option::Option<&str> {
self.description.as_deref()
}
pub fn outbound_caller_config(&self) -> ::std::option::Option<&crate::types::OutboundCallerConfig> {
self.outbound_caller_config.as_ref()
}
pub fn outbound_email_config(&self) -> ::std::option::Option<&crate::types::OutboundEmailConfig> {
self.outbound_email_config.as_ref()
}
pub fn hours_of_operation_id(&self) -> ::std::option::Option<&str> {
self.hours_of_operation_id.as_deref()
}
pub fn max_contacts(&self) -> ::std::option::Option<i32> {
self.max_contacts
}
pub fn status(&self) -> ::std::option::Option<&crate::types::QueueStatus> {
self.status.as_ref()
}
pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
self.tags.as_ref()
}
pub fn last_modified_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.last_modified_time.as_ref()
}
pub fn last_modified_region(&self) -> ::std::option::Option<&str> {
self.last_modified_region.as_deref()
}
}
impl Queue {
pub fn builder() -> crate::types::builders::QueueBuilder {
crate::types::builders::QueueBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct QueueBuilder {
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) queue_arn: ::std::option::Option<::std::string::String>,
pub(crate) queue_id: ::std::option::Option<::std::string::String>,
pub(crate) description: ::std::option::Option<::std::string::String>,
pub(crate) outbound_caller_config: ::std::option::Option<crate::types::OutboundCallerConfig>,
pub(crate) outbound_email_config: ::std::option::Option<crate::types::OutboundEmailConfig>,
pub(crate) hours_of_operation_id: ::std::option::Option<::std::string::String>,
pub(crate) max_contacts: ::std::option::Option<i32>,
pub(crate) status: ::std::option::Option<crate::types::QueueStatus>,
pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub(crate) last_modified_time: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) last_modified_region: ::std::option::Option<::std::string::String>,
}
impl QueueBuilder {
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::Some(input.into());
self
}
pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.name = input;
self
}
pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
&self.name
}
pub fn queue_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.queue_arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_queue_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.queue_arn = input;
self
}
pub fn get_queue_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.queue_arn
}
pub fn queue_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.queue_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_queue_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.queue_id = input;
self
}
pub fn get_queue_id(&self) -> &::std::option::Option<::std::string::String> {
&self.queue_id
}
pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.description = ::std::option::Option::Some(input.into());
self
}
pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.description = input;
self
}
pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
&self.description
}
pub fn outbound_caller_config(mut self, input: crate::types::OutboundCallerConfig) -> Self {
self.outbound_caller_config = ::std::option::Option::Some(input);
self
}
pub fn set_outbound_caller_config(mut self, input: ::std::option::Option<crate::types::OutboundCallerConfig>) -> Self {
self.outbound_caller_config = input;
self
}
pub fn get_outbound_caller_config(&self) -> &::std::option::Option<crate::types::OutboundCallerConfig> {
&self.outbound_caller_config
}
pub fn outbound_email_config(mut self, input: crate::types::OutboundEmailConfig) -> Self {
self.outbound_email_config = ::std::option::Option::Some(input);
self
}
pub fn set_outbound_email_config(mut self, input: ::std::option::Option<crate::types::OutboundEmailConfig>) -> Self {
self.outbound_email_config = input;
self
}
pub fn get_outbound_email_config(&self) -> &::std::option::Option<crate::types::OutboundEmailConfig> {
&self.outbound_email_config
}
pub fn hours_of_operation_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.hours_of_operation_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_hours_of_operation_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.hours_of_operation_id = input;
self
}
pub fn get_hours_of_operation_id(&self) -> &::std::option::Option<::std::string::String> {
&self.hours_of_operation_id
}
pub fn max_contacts(mut self, input: i32) -> Self {
self.max_contacts = ::std::option::Option::Some(input);
self
}
pub fn set_max_contacts(mut self, input: ::std::option::Option<i32>) -> Self {
self.max_contacts = input;
self
}
pub fn get_max_contacts(&self) -> &::std::option::Option<i32> {
&self.max_contacts
}
pub fn status(mut self, input: crate::types::QueueStatus) -> Self {
self.status = ::std::option::Option::Some(input);
self
}
pub fn set_status(mut self, input: ::std::option::Option<crate::types::QueueStatus>) -> Self {
self.status = input;
self
}
pub fn get_status(&self) -> &::std::option::Option<crate::types::QueueStatus> {
&self.status
}
pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut hash_map = self.tags.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.tags = ::std::option::Option::Some(hash_map);
self
}
pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
self.tags = input;
self
}
pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
&self.tags
}
pub fn last_modified_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.last_modified_time = ::std::option::Option::Some(input);
self
}
pub fn set_last_modified_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.last_modified_time = input;
self
}
pub fn get_last_modified_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.last_modified_time
}
pub fn last_modified_region(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.last_modified_region = ::std::option::Option::Some(input.into());
self
}
pub fn set_last_modified_region(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.last_modified_region = input;
self
}
pub fn get_last_modified_region(&self) -> &::std::option::Option<::std::string::String> {
&self.last_modified_region
}
pub fn build(self) -> crate::types::Queue {
crate::types::Queue {
name: self.name,
queue_arn: self.queue_arn,
queue_id: self.queue_id,
description: self.description,
outbound_caller_config: self.outbound_caller_config,
outbound_email_config: self.outbound_email_config,
hours_of_operation_id: self.hours_of_operation_id,
max_contacts: self.max_contacts,
status: self.status,
tags: self.tags,
last_modified_time: self.last_modified_time,
last_modified_region: self.last_modified_region,
}
}
}