4 4 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
|
5 5 | pub struct AddClientIdToOpenIdConnectProviderInput {
|
6 6 | /// <p>The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider resource to add the client ID to. You can get a list of OIDC provider ARNs by using the <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListOpenIDConnectProviders.html">ListOpenIDConnectProviders</a> operation.</p>
|
7 7 | pub open_id_connect_provider_arn: ::std::option::Option<::std::string::String>,
|
8 8 | /// <p>The client ID (also known as audience) to add to the IAM OpenID Connect provider resource.</p>
|
9 9 | pub client_id: ::std::option::Option<::std::string::String>,
|
10 10 | }
|
11 11 | impl AddClientIdToOpenIdConnectProviderInput {
|
12 12 | /// <p>The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider resource to add the client ID to. You can get a list of OIDC provider ARNs by using the <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListOpenIDConnectProviders.html">ListOpenIDConnectProviders</a> operation.</p>
|
13 13 | pub fn open_id_connect_provider_arn(&self) -> ::std::option::Option<&str> {
|
14 14 | self.open_id_connect_provider_arn.as_deref()
|
15 15 | }
|
16 16 | /// <p>The client ID (also known as audience) to add to the IAM OpenID Connect provider resource.</p>
|
17 17 | pub fn client_id(&self) -> ::std::option::Option<&str> {
|
18 18 | self.client_id.as_deref()
|
19 19 | }
|
20 20 | }
|
21 21 | static ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA_ID: ::aws_smithy_schema::ShapeId = ::aws_smithy_schema::ShapeId::from_static(
|
22 22 | "com.amazonaws.iam.synthetic#AddClientIDToOpenIDConnectProviderInput",
|
23 23 | "com.amazonaws.iam.synthetic",
|
24 24 | "AddClientIDToOpenIDConnectProviderInput",
|
25 25 | );
|
26 26 | static ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_OPEN_ID_CONNECT_PROVIDER_ARN: ::aws_smithy_schema::Schema =
|
27 27 | ::aws_smithy_schema::Schema::new_member(
|
28 28 | ::aws_smithy_schema::ShapeId::from_static(
|
29 29 | "com.amazonaws.iam.synthetic#AddClientIDToOpenIDConnectProviderInput$OpenIDConnectProviderArn",
|
30 30 | "com.amazonaws.iam.synthetic",
|
31 31 | "AddClientIDToOpenIDConnectProviderInput",
|
32 32 | ),
|
33 33 | ::aws_smithy_schema::ShapeType::String,
|
34 - | "open_id_connect_provider_arn",
|
34 + | "OpenIDConnectProviderArn",
|
35 35 | 0,
|
36 36 | );
|
37 37 | static ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_CLIENT_ID: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
38 38 | ::aws_smithy_schema::ShapeId::from_static(
|
39 39 | "com.amazonaws.iam.synthetic#AddClientIDToOpenIDConnectProviderInput$ClientID",
|
40 40 | "com.amazonaws.iam.synthetic",
|
41 41 | "AddClientIDToOpenIDConnectProviderInput",
|
42 42 | ),
|
43 43 | ::aws_smithy_schema::ShapeType::String,
|
44 - | "client_id",
|
44 + | "ClientID",
|
45 45 | 1,
|
46 46 | );
|
47 47 | static ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
48 48 | ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA_ID,
|
49 49 | ::aws_smithy_schema::ShapeType::Structure,
|
50 50 | &[
|
51 51 | &ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_OPEN_ID_CONNECT_PROVIDER_ARN,
|
52 52 | &ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_CLIENT_ID,
|
53 53 | ],
|
54 54 | );
|
55 55 | impl AddClientIdToOpenIdConnectProviderInput {
|
56 56 | /// The schema for this shape.
|
57 57 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA;
|
58 58 | }
|
59 59 | impl ::aws_smithy_schema::serde::SerializableStruct for AddClientIdToOpenIdConnectProviderInput {
|
60 60 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
61 61 | fn serialize_members(
|
62 62 | &self,
|
63 63 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
64 64 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
65 65 | if let Some(ref val) = self.open_id_connect_provider_arn {
|
66 66 | ser.write_string(&ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_OPEN_ID_CONNECT_PROVIDER_ARN, val)?;
|
67 67 | }
|
68 68 | if let Some(ref val) = self.client_id {
|
69 69 | ser.write_string(&ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_MEMBER_CLIENT_ID, val)?;
|
70 70 | }
|
71 71 | Ok(())
|
72 72 | }
|
73 73 | }
|
74 74 | impl AddClientIdToOpenIdConnectProviderInput {
|
75 75 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
76 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
77 - | deserializer: &mut D,
|
76 + | pub fn deserialize(
|
77 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
78 78 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
79 79 | #[allow(unused_variables, unused_mut)]
|
80 80 | let mut builder = Self::builder();
|
81 81 | #[allow(
|
82 82 | unused_variables,
|
83 83 | unreachable_code,
|
84 84 | clippy::single_match,
|
85 85 | clippy::match_single_binding,
|
86 86 | clippy::diverging_sub_expression
|
87 87 | )]
|
88 - | deserializer.read_struct(&ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA, (), |_, member, deser| {
|
88 + | deserializer.read_struct(&ADDCLIENTIDTOOPENIDCONNECTPROVIDERINPUT_SCHEMA, &mut |member, deser| {
|
89 89 | match member.member_index() {
|
90 90 | Some(0) => {
|
91 91 | builder.open_id_connect_provider_arn = Some(deser.read_string(member)?);
|
92 92 | }
|
93 93 | Some(1) => {
|
94 94 | builder.client_id = Some(deser.read_string(member)?);
|
95 95 | }
|
96 96 | _ => {}
|
97 97 | }
|
98 98 | Ok(())
|
99 99 | })?;
|
100 + | builder.open_id_connect_provider_arn = builder.open_id_connect_provider_arn.or(Some(String::new()));
|
101 + | builder.client_id = builder.client_id.or(Some(String::new()));
|
100 102 | builder
|
101 103 | .build()
|
102 104 | .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
|
103 105 | }
|
104 106 | }
|
107 + | impl AddClientIdToOpenIdConnectProviderInput {
|
108 + | /// Deserializes this structure from a body deserializer and HTTP response.
|
109 + | pub fn deserialize_with_response(
|
110 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
111 + | _headers: &::aws_smithy_runtime_api::http::Headers,
|
112 + | _status: u16,
|
113 + | _body: &[u8],
|
114 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
115 + | Self::deserialize(deserializer)
|
116 + | }
|
117 + | }
|
105 118 | impl AddClientIdToOpenIdConnectProviderInput {
|
106 119 | /// Creates a new builder-style object to manufacture [`AddClientIdToOpenIdConnectProviderInput`](crate::operation::add_client_id_to_open_id_connect_provider::AddClientIdToOpenIdConnectProviderInput).
|
107 120 | pub fn builder() -> crate::operation::add_client_id_to_open_id_connect_provider::builders::AddClientIdToOpenIdConnectProviderInputBuilder {
|
108 121 | crate::operation::add_client_id_to_open_id_connect_provider::builders::AddClientIdToOpenIdConnectProviderInputBuilder::default()
|
109 122 | }
|
110 123 | }
|
111 124 |
|
112 125 | /// A builder for [`AddClientIdToOpenIdConnectProviderInput`](crate::operation::add_client_id_to_open_id_connect_provider::AddClientIdToOpenIdConnectProviderInput).
|
113 126 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
114 127 | #[non_exhaustive]
|
115 128 | pub struct AddClientIdToOpenIdConnectProviderInputBuilder {
|
116 129 | pub(crate) open_id_connect_provider_arn: ::std::option::Option<::std::string::String>,
|
117 130 | pub(crate) client_id: ::std::option::Option<::std::string::String>,
|
118 131 | }
|
119 132 | impl AddClientIdToOpenIdConnectProviderInputBuilder {
|
120 133 | /// <p>The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider resource to add the client ID to. You can get a list of OIDC provider ARNs by using the <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListOpenIDConnectProviders.html">ListOpenIDConnectProviders</a> operation.</p>
|
121 134 | /// This field is required.
|
122 135 | pub fn open_id_connect_provider_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
|
123 136 | self.open_id_connect_provider_arn = ::std::option::Option::Some(input.into());
|
124 137 | self
|
125 138 | }
|
126 139 | /// <p>The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider resource to add the client ID to. You can get a list of OIDC provider ARNs by using the <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListOpenIDConnectProviders.html">ListOpenIDConnectProviders</a> operation.</p>
|
127 140 | pub fn set_open_id_connect_provider_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
128 141 | self.open_id_connect_provider_arn = input;
|
129 142 | self
|
130 143 | }
|
131 144 | /// <p>The Amazon Resource Name (ARN) of the IAM OpenID Connect (OIDC) provider resource to add the client ID to. You can get a list of OIDC provider ARNs by using the <a href="https://docs.aws.amazon.com/IAM/latest/APIReference/API_ListOpenIDConnectProviders.html">ListOpenIDConnectProviders</a> operation.</p>
|
132 145 | pub fn get_open_id_connect_provider_arn(&self) -> &::std::option::Option<::std::string::String> {
|
133 146 | &self.open_id_connect_provider_arn
|
134 147 | }
|