aws_sdk_redshift/operation/delete_partner/
_delete_partner_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 DeletePartnerInput {
6    /// <p>The Amazon Web Services account ID that owns the cluster.</p>
7    pub account_id: ::std::option::Option<::std::string::String>,
8    /// <p>The cluster identifier of the cluster that receives data from the partner.</p>
9    pub cluster_identifier: ::std::option::Option<::std::string::String>,
10    /// <p>The name of the database that receives data from the partner.</p>
11    pub database_name: ::std::option::Option<::std::string::String>,
12    /// <p>The name of the partner that is authorized to send data.</p>
13    pub partner_name: ::std::option::Option<::std::string::String>,
14}
15impl DeletePartnerInput {
16    /// <p>The Amazon Web Services account ID that owns the cluster.</p>
17    pub fn account_id(&self) -> ::std::option::Option<&str> {
18        self.account_id.as_deref()
19    }
20    /// <p>The cluster identifier of the cluster that receives data from the partner.</p>
21    pub fn cluster_identifier(&self) -> ::std::option::Option<&str> {
22        self.cluster_identifier.as_deref()
23    }
24    /// <p>The name of the database that receives data from the partner.</p>
25    pub fn database_name(&self) -> ::std::option::Option<&str> {
26        self.database_name.as_deref()
27    }
28    /// <p>The name of the partner that is authorized to send data.</p>
29    pub fn partner_name(&self) -> ::std::option::Option<&str> {
30        self.partner_name.as_deref()
31    }
32}
33impl DeletePartnerInput {
34    /// Creates a new builder-style object to manufacture [`DeletePartnerInput`](crate::operation::delete_partner::DeletePartnerInput).
35    pub fn builder() -> crate::operation::delete_partner::builders::DeletePartnerInputBuilder {
36        crate::operation::delete_partner::builders::DeletePartnerInputBuilder::default()
37    }
38}
39
40/// A builder for [`DeletePartnerInput`](crate::operation::delete_partner::DeletePartnerInput).
41#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct DeletePartnerInputBuilder {
44    pub(crate) account_id: ::std::option::Option<::std::string::String>,
45    pub(crate) cluster_identifier: ::std::option::Option<::std::string::String>,
46    pub(crate) database_name: ::std::option::Option<::std::string::String>,
47    pub(crate) partner_name: ::std::option::Option<::std::string::String>,
48}
49impl DeletePartnerInputBuilder {
50    /// <p>The Amazon Web Services account ID that owns the cluster.</p>
51    /// This field is required.
52    pub fn account_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
53        self.account_id = ::std::option::Option::Some(input.into());
54        self
55    }
56    /// <p>The Amazon Web Services account ID that owns the cluster.</p>
57    pub fn set_account_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
58        self.account_id = input;
59        self
60    }
61    /// <p>The Amazon Web Services account ID that owns the cluster.</p>
62    pub fn get_account_id(&self) -> &::std::option::Option<::std::string::String> {
63        &self.account_id
64    }
65    /// <p>The cluster identifier of the cluster that receives data from the partner.</p>
66    /// This field is required.
67    pub fn cluster_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
68        self.cluster_identifier = ::std::option::Option::Some(input.into());
69        self
70    }
71    /// <p>The cluster identifier of the cluster that receives data from the partner.</p>
72    pub fn set_cluster_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
73        self.cluster_identifier = input;
74        self
75    }
76    /// <p>The cluster identifier of the cluster that receives data from the partner.</p>
77    pub fn get_cluster_identifier(&self) -> &::std::option::Option<::std::string::String> {
78        &self.cluster_identifier
79    }
80    /// <p>The name of the database that receives data from the partner.</p>
81    /// This field is required.
82    pub fn database_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
83        self.database_name = ::std::option::Option::Some(input.into());
84        self
85    }
86    /// <p>The name of the database that receives data from the partner.</p>
87    pub fn set_database_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
88        self.database_name = input;
89        self
90    }
91    /// <p>The name of the database that receives data from the partner.</p>
92    pub fn get_database_name(&self) -> &::std::option::Option<::std::string::String> {
93        &self.database_name
94    }
95    /// <p>The name of the partner that is authorized to send data.</p>
96    /// This field is required.
97    pub fn partner_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
98        self.partner_name = ::std::option::Option::Some(input.into());
99        self
100    }
101    /// <p>The name of the partner that is authorized to send data.</p>
102    pub fn set_partner_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
103        self.partner_name = input;
104        self
105    }
106    /// <p>The name of the partner that is authorized to send data.</p>
107    pub fn get_partner_name(&self) -> &::std::option::Option<::std::string::String> {
108        &self.partner_name
109    }
110    /// Consumes the builder and constructs a [`DeletePartnerInput`](crate::operation::delete_partner::DeletePartnerInput).
111    pub fn build(
112        self,
113    ) -> ::std::result::Result<crate::operation::delete_partner::DeletePartnerInput, ::aws_smithy_types::error::operation::BuildError> {
114        ::std::result::Result::Ok(crate::operation::delete_partner::DeletePartnerInput {
115            account_id: self.account_id,
116            cluster_identifier: self.cluster_identifier,
117            database_name: self.database_name,
118            partner_name: self.partner_name,
119        })
120    }
121}