aws_sdk_connect/operation/disassociate_flow/_disassociate_flow_input.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct DisassociateFlowInput {
6 /// <p>The identifier of the Amazon Connect instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
7 pub instance_id: ::std::option::Option<::std::string::String>,
8 /// <p>The identifier of the resource.</p>
9 /// <ul>
10 /// <li>
11 /// <p>Amazon Web Services End User Messaging SMS phone number ARN when using <code>SMS_PHONE_NUMBER</code></p></li>
12 /// <li>
13 /// <p>Amazon Web Services End User Messaging Social phone number ARN when using <code>WHATSAPP_MESSAGING_PHONE_NUMBER</code></p></li>
14 /// </ul>
15 pub resource_id: ::std::option::Option<::std::string::String>,
16 /// <p>A valid resource type.</p>
17 pub resource_type: ::std::option::Option<crate::types::FlowAssociationResourceType>,
18}
19impl DisassociateFlowInput {
20 /// <p>The identifier of the Amazon Connect instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
21 pub fn instance_id(&self) -> ::std::option::Option<&str> {
22 self.instance_id.as_deref()
23 }
24 /// <p>The identifier of the resource.</p>
25 /// <ul>
26 /// <li>
27 /// <p>Amazon Web Services End User Messaging SMS phone number ARN when using <code>SMS_PHONE_NUMBER</code></p></li>
28 /// <li>
29 /// <p>Amazon Web Services End User Messaging Social phone number ARN when using <code>WHATSAPP_MESSAGING_PHONE_NUMBER</code></p></li>
30 /// </ul>
31 pub fn resource_id(&self) -> ::std::option::Option<&str> {
32 self.resource_id.as_deref()
33 }
34 /// <p>A valid resource type.</p>
35 pub fn resource_type(&self) -> ::std::option::Option<&crate::types::FlowAssociationResourceType> {
36 self.resource_type.as_ref()
37 }
38}
39impl DisassociateFlowInput {
40 /// Creates a new builder-style object to manufacture [`DisassociateFlowInput`](crate::operation::disassociate_flow::DisassociateFlowInput).
41 pub fn builder() -> crate::operation::disassociate_flow::builders::DisassociateFlowInputBuilder {
42 crate::operation::disassociate_flow::builders::DisassociateFlowInputBuilder::default()
43 }
44}
45
46/// A builder for [`DisassociateFlowInput`](crate::operation::disassociate_flow::DisassociateFlowInput).
47#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
48#[non_exhaustive]
49pub struct DisassociateFlowInputBuilder {
50 pub(crate) instance_id: ::std::option::Option<::std::string::String>,
51 pub(crate) resource_id: ::std::option::Option<::std::string::String>,
52 pub(crate) resource_type: ::std::option::Option<crate::types::FlowAssociationResourceType>,
53}
54impl DisassociateFlowInputBuilder {
55 /// <p>The identifier of the Amazon Connect instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
56 /// This field is required.
57 pub fn instance_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
58 self.instance_id = ::std::option::Option::Some(input.into());
59 self
60 }
61 /// <p>The identifier of the Amazon Connect instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
62 pub fn set_instance_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
63 self.instance_id = input;
64 self
65 }
66 /// <p>The identifier of the Amazon Connect instance. You can <a href="https://docs.aws.amazon.com/connect/latest/adminguide/find-instance-arn.html">find the instance ID</a> in the Amazon Resource Name (ARN) of the instance.</p>
67 pub fn get_instance_id(&self) -> &::std::option::Option<::std::string::String> {
68 &self.instance_id
69 }
70 /// <p>The identifier of the resource.</p>
71 /// <ul>
72 /// <li>
73 /// <p>Amazon Web Services End User Messaging SMS phone number ARN when using <code>SMS_PHONE_NUMBER</code></p></li>
74 /// <li>
75 /// <p>Amazon Web Services End User Messaging Social phone number ARN when using <code>WHATSAPP_MESSAGING_PHONE_NUMBER</code></p></li>
76 /// </ul>
77 /// This field is required.
78 pub fn resource_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
79 self.resource_id = ::std::option::Option::Some(input.into());
80 self
81 }
82 /// <p>The identifier of the resource.</p>
83 /// <ul>
84 /// <li>
85 /// <p>Amazon Web Services End User Messaging SMS phone number ARN when using <code>SMS_PHONE_NUMBER</code></p></li>
86 /// <li>
87 /// <p>Amazon Web Services End User Messaging Social phone number ARN when using <code>WHATSAPP_MESSAGING_PHONE_NUMBER</code></p></li>
88 /// </ul>
89 pub fn set_resource_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
90 self.resource_id = input;
91 self
92 }
93 /// <p>The identifier of the resource.</p>
94 /// <ul>
95 /// <li>
96 /// <p>Amazon Web Services End User Messaging SMS phone number ARN when using <code>SMS_PHONE_NUMBER</code></p></li>
97 /// <li>
98 /// <p>Amazon Web Services End User Messaging Social phone number ARN when using <code>WHATSAPP_MESSAGING_PHONE_NUMBER</code></p></li>
99 /// </ul>
100 pub fn get_resource_id(&self) -> &::std::option::Option<::std::string::String> {
101 &self.resource_id
102 }
103 /// <p>A valid resource type.</p>
104 /// This field is required.
105 pub fn resource_type(mut self, input: crate::types::FlowAssociationResourceType) -> Self {
106 self.resource_type = ::std::option::Option::Some(input);
107 self
108 }
109 /// <p>A valid resource type.</p>
110 pub fn set_resource_type(mut self, input: ::std::option::Option<crate::types::FlowAssociationResourceType>) -> Self {
111 self.resource_type = input;
112 self
113 }
114 /// <p>A valid resource type.</p>
115 pub fn get_resource_type(&self) -> &::std::option::Option<crate::types::FlowAssociationResourceType> {
116 &self.resource_type
117 }
118 /// Consumes the builder and constructs a [`DisassociateFlowInput`](crate::operation::disassociate_flow::DisassociateFlowInput).
119 pub fn build(
120 self,
121 ) -> ::std::result::Result<crate::operation::disassociate_flow::DisassociateFlowInput, ::aws_smithy_types::error::operation::BuildError> {
122 ::std::result::Result::Ok(crate::operation::disassociate_flow::DisassociateFlowInput {
123 instance_id: self.instance_id,
124 resource_id: self.resource_id,
125 resource_type: self.resource_type,
126 })
127 }
128}