aws_sdk_ssoadmin/operation/update_application/
_update_application_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 UpdateApplicationInput {
6    /// <p>Specifies the ARN of the application. For more information about ARNs, see <a href="/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces</a> in the <i>Amazon Web Services General Reference</i>.</p>
7    pub application_arn: ::std::option::Option<::std::string::String>,
8    /// <p>Specifies the updated name for the application.</p>
9    pub name: ::std::option::Option<::std::string::String>,
10    /// <p>The description of the .</p>
11    pub description: ::std::option::Option<::std::string::String>,
12    /// <p>Specifies whether the application is enabled or disabled.</p>
13    pub status: ::std::option::Option<crate::types::ApplicationStatus>,
14    /// <p>A structure that describes the options for the portal associated with an application.</p>
15    pub portal_options: ::std::option::Option<crate::types::UpdateApplicationPortalOptions>,
16}
17impl UpdateApplicationInput {
18    /// <p>Specifies the ARN of the application. For more information about ARNs, see <a href="/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces</a> in the <i>Amazon Web Services General Reference</i>.</p>
19    pub fn application_arn(&self) -> ::std::option::Option<&str> {
20        self.application_arn.as_deref()
21    }
22    /// <p>Specifies the updated name for the application.</p>
23    pub fn name(&self) -> ::std::option::Option<&str> {
24        self.name.as_deref()
25    }
26    /// <p>The description of the .</p>
27    pub fn description(&self) -> ::std::option::Option<&str> {
28        self.description.as_deref()
29    }
30    /// <p>Specifies whether the application is enabled or disabled.</p>
31    pub fn status(&self) -> ::std::option::Option<&crate::types::ApplicationStatus> {
32        self.status.as_ref()
33    }
34    /// <p>A structure that describes the options for the portal associated with an application.</p>
35    pub fn portal_options(&self) -> ::std::option::Option<&crate::types::UpdateApplicationPortalOptions> {
36        self.portal_options.as_ref()
37    }
38}
39impl UpdateApplicationInput {
40    /// Creates a new builder-style object to manufacture [`UpdateApplicationInput`](crate::operation::update_application::UpdateApplicationInput).
41    pub fn builder() -> crate::operation::update_application::builders::UpdateApplicationInputBuilder {
42        crate::operation::update_application::builders::UpdateApplicationInputBuilder::default()
43    }
44}
45
46/// A builder for [`UpdateApplicationInput`](crate::operation::update_application::UpdateApplicationInput).
47#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
48#[non_exhaustive]
49pub struct UpdateApplicationInputBuilder {
50    pub(crate) application_arn: ::std::option::Option<::std::string::String>,
51    pub(crate) name: ::std::option::Option<::std::string::String>,
52    pub(crate) description: ::std::option::Option<::std::string::String>,
53    pub(crate) status: ::std::option::Option<crate::types::ApplicationStatus>,
54    pub(crate) portal_options: ::std::option::Option<crate::types::UpdateApplicationPortalOptions>,
55}
56impl UpdateApplicationInputBuilder {
57    /// <p>Specifies the ARN of the application. For more information about ARNs, see <a href="/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces</a> in the <i>Amazon Web Services General Reference</i>.</p>
58    /// This field is required.
59    pub fn application_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
60        self.application_arn = ::std::option::Option::Some(input.into());
61        self
62    }
63    /// <p>Specifies the ARN of the application. For more information about ARNs, see <a href="/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces</a> in the <i>Amazon Web Services General Reference</i>.</p>
64    pub fn set_application_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
65        self.application_arn = input;
66        self
67    }
68    /// <p>Specifies the ARN of the application. For more information about ARNs, see <a href="/general/latest/gr/aws-arns-and-namespaces.html">Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces</a> in the <i>Amazon Web Services General Reference</i>.</p>
69    pub fn get_application_arn(&self) -> &::std::option::Option<::std::string::String> {
70        &self.application_arn
71    }
72    /// <p>Specifies the updated name for the application.</p>
73    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
74        self.name = ::std::option::Option::Some(input.into());
75        self
76    }
77    /// <p>Specifies the updated name for the application.</p>
78    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
79        self.name = input;
80        self
81    }
82    /// <p>Specifies the updated name for the application.</p>
83    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
84        &self.name
85    }
86    /// <p>The description of the .</p>
87    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
88        self.description = ::std::option::Option::Some(input.into());
89        self
90    }
91    /// <p>The description of the .</p>
92    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
93        self.description = input;
94        self
95    }
96    /// <p>The description of the .</p>
97    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
98        &self.description
99    }
100    /// <p>Specifies whether the application is enabled or disabled.</p>
101    pub fn status(mut self, input: crate::types::ApplicationStatus) -> Self {
102        self.status = ::std::option::Option::Some(input);
103        self
104    }
105    /// <p>Specifies whether the application is enabled or disabled.</p>
106    pub fn set_status(mut self, input: ::std::option::Option<crate::types::ApplicationStatus>) -> Self {
107        self.status = input;
108        self
109    }
110    /// <p>Specifies whether the application is enabled or disabled.</p>
111    pub fn get_status(&self) -> &::std::option::Option<crate::types::ApplicationStatus> {
112        &self.status
113    }
114    /// <p>A structure that describes the options for the portal associated with an application.</p>
115    pub fn portal_options(mut self, input: crate::types::UpdateApplicationPortalOptions) -> Self {
116        self.portal_options = ::std::option::Option::Some(input);
117        self
118    }
119    /// <p>A structure that describes the options for the portal associated with an application.</p>
120    pub fn set_portal_options(mut self, input: ::std::option::Option<crate::types::UpdateApplicationPortalOptions>) -> Self {
121        self.portal_options = input;
122        self
123    }
124    /// <p>A structure that describes the options for the portal associated with an application.</p>
125    pub fn get_portal_options(&self) -> &::std::option::Option<crate::types::UpdateApplicationPortalOptions> {
126        &self.portal_options
127    }
128    /// Consumes the builder and constructs a [`UpdateApplicationInput`](crate::operation::update_application::UpdateApplicationInput).
129    pub fn build(
130        self,
131    ) -> ::std::result::Result<crate::operation::update_application::UpdateApplicationInput, ::aws_smithy_types::error::operation::BuildError> {
132        ::std::result::Result::Ok(crate::operation::update_application::UpdateApplicationInput {
133            application_arn: self.application_arn,
134            name: self.name,
135            description: self.description,
136            status: self.status,
137            portal_options: self.portal_options,
138        })
139    }
140}