aws_sdk_appconfig/operation/get_deployment/
_get_deployment_input.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct GetDeploymentInput {
6 pub application_id: ::std::option::Option<::std::string::String>,
8 pub environment_id: ::std::option::Option<::std::string::String>,
10 pub deployment_number: ::std::option::Option<i32>,
12}
13impl GetDeploymentInput {
14 pub fn application_id(&self) -> ::std::option::Option<&str> {
16 self.application_id.as_deref()
17 }
18 pub fn environment_id(&self) -> ::std::option::Option<&str> {
20 self.environment_id.as_deref()
21 }
22 pub fn deployment_number(&self) -> ::std::option::Option<i32> {
24 self.deployment_number
25 }
26}
27impl GetDeploymentInput {
28 pub fn builder() -> crate::operation::get_deployment::builders::GetDeploymentInputBuilder {
30 crate::operation::get_deployment::builders::GetDeploymentInputBuilder::default()
31 }
32}
33
34#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
36#[non_exhaustive]
37pub struct GetDeploymentInputBuilder {
38 pub(crate) application_id: ::std::option::Option<::std::string::String>,
39 pub(crate) environment_id: ::std::option::Option<::std::string::String>,
40 pub(crate) deployment_number: ::std::option::Option<i32>,
41}
42impl GetDeploymentInputBuilder {
43 pub fn application_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
46 self.application_id = ::std::option::Option::Some(input.into());
47 self
48 }
49 pub fn set_application_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
51 self.application_id = input;
52 self
53 }
54 pub fn get_application_id(&self) -> &::std::option::Option<::std::string::String> {
56 &self.application_id
57 }
58 pub fn environment_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
61 self.environment_id = ::std::option::Option::Some(input.into());
62 self
63 }
64 pub fn set_environment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
66 self.environment_id = input;
67 self
68 }
69 pub fn get_environment_id(&self) -> &::std::option::Option<::std::string::String> {
71 &self.environment_id
72 }
73 pub fn deployment_number(mut self, input: i32) -> Self {
76 self.deployment_number = ::std::option::Option::Some(input);
77 self
78 }
79 pub fn set_deployment_number(mut self, input: ::std::option::Option<i32>) -> Self {
81 self.deployment_number = input;
82 self
83 }
84 pub fn get_deployment_number(&self) -> &::std::option::Option<i32> {
86 &self.deployment_number
87 }
88 pub fn build(
90 self,
91 ) -> ::std::result::Result<crate::operation::get_deployment::GetDeploymentInput, ::aws_smithy_types::error::operation::BuildError> {
92 ::std::result::Result::Ok(crate::operation::get_deployment::GetDeploymentInput {
93 application_id: self.application_id,
94 environment_id: self.environment_id,
95 deployment_number: self.deployment_number,
96 })
97 }
98}