aws_sdk_redshift/operation/describe_partners/
_describe_partners_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 DescribePartnersInput {
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 whose partner integration is being described.</p>
9    pub cluster_identifier: ::std::option::Option<::std::string::String>,
10    /// <p>The name of the database whose partner integration is being described. If database name is not specified, then all databases in the cluster are described.</p>
11    pub database_name: ::std::option::Option<::std::string::String>,
12    /// <p>The name of the partner that is being described. If partner name is not specified, then all partner integrations are described.</p>
13    pub partner_name: ::std::option::Option<::std::string::String>,
14}
15impl DescribePartnersInput {
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 whose partner integration is being described.</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 whose partner integration is being described. If database name is not specified, then all databases in the cluster are described.</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 being described. If partner name is not specified, then all partner integrations are described.</p>
29    pub fn partner_name(&self) -> ::std::option::Option<&str> {
30        self.partner_name.as_deref()
31    }
32}
33impl DescribePartnersInput {
34    /// Creates a new builder-style object to manufacture [`DescribePartnersInput`](crate::operation::describe_partners::DescribePartnersInput).
35    pub fn builder() -> crate::operation::describe_partners::builders::DescribePartnersInputBuilder {
36        crate::operation::describe_partners::builders::DescribePartnersInputBuilder::default()
37    }
38}
39
40/// A builder for [`DescribePartnersInput`](crate::operation::describe_partners::DescribePartnersInput).
41#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct DescribePartnersInputBuilder {
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 DescribePartnersInputBuilder {
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 whose partner integration is being described.</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 whose partner integration is being described.</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 whose partner integration is being described.</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 whose partner integration is being described. If database name is not specified, then all databases in the cluster are described.</p>
81    pub fn database_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
82        self.database_name = ::std::option::Option::Some(input.into());
83        self
84    }
85    /// <p>The name of the database whose partner integration is being described. If database name is not specified, then all databases in the cluster are described.</p>
86    pub fn set_database_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
87        self.database_name = input;
88        self
89    }
90    /// <p>The name of the database whose partner integration is being described. If database name is not specified, then all databases in the cluster are described.</p>
91    pub fn get_database_name(&self) -> &::std::option::Option<::std::string::String> {
92        &self.database_name
93    }
94    /// <p>The name of the partner that is being described. If partner name is not specified, then all partner integrations are described.</p>
95    pub fn partner_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
96        self.partner_name = ::std::option::Option::Some(input.into());
97        self
98    }
99    /// <p>The name of the partner that is being described. If partner name is not specified, then all partner integrations are described.</p>
100    pub fn set_partner_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
101        self.partner_name = input;
102        self
103    }
104    /// <p>The name of the partner that is being described. If partner name is not specified, then all partner integrations are described.</p>
105    pub fn get_partner_name(&self) -> &::std::option::Option<::std::string::String> {
106        &self.partner_name
107    }
108    /// Consumes the builder and constructs a [`DescribePartnersInput`](crate::operation::describe_partners::DescribePartnersInput).
109    pub fn build(
110        self,
111    ) -> ::std::result::Result<crate::operation::describe_partners::DescribePartnersInput, ::aws_smithy_types::error::operation::BuildError> {
112        ::std::result::Result::Ok(crate::operation::describe_partners::DescribePartnersInput {
113            account_id: self.account_id,
114            cluster_identifier: self.cluster_identifier,
115            database_name: self.database_name,
116            partner_name: self.partner_name,
117        })
118    }
119}