89 89 | "com.amazonaws.iam.synthetic",
|
90 90 | "UpdateAccountPasswordPolicyInput",
|
91 91 | );
|
92 92 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MINIMUM_PASSWORD_LENGTH: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
93 93 | ::aws_smithy_schema::ShapeId::from_static(
|
94 94 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$MinimumPasswordLength",
|
95 95 | "com.amazonaws.iam.synthetic",
|
96 96 | "UpdateAccountPasswordPolicyInput",
|
97 97 | ),
|
98 98 | ::aws_smithy_schema::ShapeType::Integer,
|
99 - | "minimum_password_length",
|
99 + | "MinimumPasswordLength",
|
100 100 | 0,
|
101 101 | );
|
102 102 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_SYMBOLS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
103 103 | ::aws_smithy_schema::ShapeId::from_static(
|
104 104 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$RequireSymbols",
|
105 105 | "com.amazonaws.iam.synthetic",
|
106 106 | "UpdateAccountPasswordPolicyInput",
|
107 107 | ),
|
108 108 | ::aws_smithy_schema::ShapeType::Boolean,
|
109 - | "require_symbols",
|
109 + | "RequireSymbols",
|
110 110 | 1,
|
111 111 | );
|
112 112 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_NUMBERS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
113 113 | ::aws_smithy_schema::ShapeId::from_static(
|
114 114 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$RequireNumbers",
|
115 115 | "com.amazonaws.iam.synthetic",
|
116 116 | "UpdateAccountPasswordPolicyInput",
|
117 117 | ),
|
118 118 | ::aws_smithy_schema::ShapeType::Boolean,
|
119 - | "require_numbers",
|
119 + | "RequireNumbers",
|
120 120 | 2,
|
121 121 | );
|
122 122 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_UPPERCASE_CHARACTERS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
123 123 | ::aws_smithy_schema::ShapeId::from_static(
|
124 124 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$RequireUppercaseCharacters",
|
125 125 | "com.amazonaws.iam.synthetic",
|
126 126 | "UpdateAccountPasswordPolicyInput",
|
127 127 | ),
|
128 128 | ::aws_smithy_schema::ShapeType::Boolean,
|
129 - | "require_uppercase_characters",
|
129 + | "RequireUppercaseCharacters",
|
130 130 | 3,
|
131 131 | );
|
132 132 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_LOWERCASE_CHARACTERS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
133 133 | ::aws_smithy_schema::ShapeId::from_static(
|
134 134 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$RequireLowercaseCharacters",
|
135 135 | "com.amazonaws.iam.synthetic",
|
136 136 | "UpdateAccountPasswordPolicyInput",
|
137 137 | ),
|
138 138 | ::aws_smithy_schema::ShapeType::Boolean,
|
139 - | "require_lowercase_characters",
|
139 + | "RequireLowercaseCharacters",
|
140 140 | 4,
|
141 141 | );
|
142 142 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_ALLOW_USERS_TO_CHANGE_PASSWORD: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
143 143 | ::aws_smithy_schema::ShapeId::from_static(
|
144 144 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$AllowUsersToChangePassword",
|
145 145 | "com.amazonaws.iam.synthetic",
|
146 146 | "UpdateAccountPasswordPolicyInput",
|
147 147 | ),
|
148 148 | ::aws_smithy_schema::ShapeType::Boolean,
|
149 - | "allow_users_to_change_password",
|
149 + | "AllowUsersToChangePassword",
|
150 150 | 5,
|
151 151 | );
|
152 152 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MAX_PASSWORD_AGE: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
153 153 | ::aws_smithy_schema::ShapeId::from_static(
|
154 154 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$MaxPasswordAge",
|
155 155 | "com.amazonaws.iam.synthetic",
|
156 156 | "UpdateAccountPasswordPolicyInput",
|
157 157 | ),
|
158 158 | ::aws_smithy_schema::ShapeType::Integer,
|
159 - | "max_password_age",
|
159 + | "MaxPasswordAge",
|
160 160 | 6,
|
161 161 | );
|
162 162 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_PASSWORD_REUSE_PREVENTION: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
163 163 | ::aws_smithy_schema::ShapeId::from_static(
|
164 164 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$PasswordReusePrevention",
|
165 165 | "com.amazonaws.iam.synthetic",
|
166 166 | "UpdateAccountPasswordPolicyInput",
|
167 167 | ),
|
168 168 | ::aws_smithy_schema::ShapeType::Integer,
|
169 - | "password_reuse_prevention",
|
169 + | "PasswordReusePrevention",
|
170 170 | 7,
|
171 171 | );
|
172 172 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_HARD_EXPIRY: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
173 173 | ::aws_smithy_schema::ShapeId::from_static(
|
174 174 | "com.amazonaws.iam.synthetic#UpdateAccountPasswordPolicyInput$HardExpiry",
|
175 175 | "com.amazonaws.iam.synthetic",
|
176 176 | "UpdateAccountPasswordPolicyInput",
|
177 177 | ),
|
178 178 | ::aws_smithy_schema::ShapeType::Boolean,
|
179 - | "hard_expiry",
|
179 + | "HardExpiry",
|
180 180 | 8,
|
181 181 | );
|
182 182 | static UPDATEACCOUNTPASSWORDPOLICYINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
183 183 | UPDATEACCOUNTPASSWORDPOLICYINPUT_SCHEMA_ID,
|
184 184 | ::aws_smithy_schema::ShapeType::Structure,
|
185 185 | &[
|
186 186 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MINIMUM_PASSWORD_LENGTH,
|
187 187 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_SYMBOLS,
|
188 188 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_NUMBERS,
|
189 189 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_UPPERCASE_CHARACTERS,
|
190 190 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_LOWERCASE_CHARACTERS,
|
191 191 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_ALLOW_USERS_TO_CHANGE_PASSWORD,
|
192 192 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MAX_PASSWORD_AGE,
|
193 193 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_PASSWORD_REUSE_PREVENTION,
|
194 194 | &UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_HARD_EXPIRY,
|
195 195 | ],
|
196 196 | );
|
197 197 | impl UpdateAccountPasswordPolicyInput {
|
198 198 | /// The schema for this shape.
|
199 199 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &UPDATEACCOUNTPASSWORDPOLICYINPUT_SCHEMA;
|
200 200 | }
|
201 201 | impl ::aws_smithy_schema::serde::SerializableStruct for UpdateAccountPasswordPolicyInput {
|
202 202 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
203 203 | fn serialize_members(
|
204 204 | &self,
|
205 205 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
206 206 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
207 207 | if let Some(ref val) = self.minimum_password_length {
|
208 208 | ser.write_integer(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MINIMUM_PASSWORD_LENGTH, *val)?;
|
209 209 | }
|
210 210 | if let Some(ref val) = self.require_symbols {
|
211 211 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_SYMBOLS, *val)?;
|
212 212 | }
|
213 213 | if let Some(ref val) = self.require_numbers {
|
214 214 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_NUMBERS, *val)?;
|
215 215 | }
|
216 216 | if let Some(ref val) = self.require_uppercase_characters {
|
217 217 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_UPPERCASE_CHARACTERS, *val)?;
|
218 218 | }
|
219 219 | if let Some(ref val) = self.require_lowercase_characters {
|
220 220 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_REQUIRE_LOWERCASE_CHARACTERS, *val)?;
|
221 221 | }
|
222 222 | if let Some(ref val) = self.allow_users_to_change_password {
|
223 223 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_ALLOW_USERS_TO_CHANGE_PASSWORD, *val)?;
|
224 224 | }
|
225 225 | if let Some(ref val) = self.max_password_age {
|
226 226 | ser.write_integer(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_MAX_PASSWORD_AGE, *val)?;
|
227 227 | }
|
228 228 | if let Some(ref val) = self.password_reuse_prevention {
|
229 229 | ser.write_integer(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_PASSWORD_REUSE_PREVENTION, *val)?;
|
230 230 | }
|
231 231 | if let Some(ref val) = self.hard_expiry {
|
232 232 | ser.write_boolean(&UPDATEACCOUNTPASSWORDPOLICYINPUT_MEMBER_HARD_EXPIRY, *val)?;
|
233 233 | }
|
234 234 | Ok(())
|
235 235 | }
|
236 236 | }
|
237 237 | impl UpdateAccountPasswordPolicyInput {
|
238 238 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
239 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
240 - | deserializer: &mut D,
|
239 + | pub fn deserialize(
|
240 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
241 241 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
242 242 | #[allow(unused_variables, unused_mut)]
|
243 243 | let mut builder = Self::builder();
|
244 244 | #[allow(
|
245 245 | unused_variables,
|
246 246 | unreachable_code,
|
247 247 | clippy::single_match,
|
248 248 | clippy::match_single_binding,
|
249 249 | clippy::diverging_sub_expression
|
250 250 | )]
|
251 - | deserializer.read_struct(&UPDATEACCOUNTPASSWORDPOLICYINPUT_SCHEMA, (), |_, member, deser| {
|
251 + | deserializer.read_struct(&UPDATEACCOUNTPASSWORDPOLICYINPUT_SCHEMA, &mut |member, deser| {
|
252 252 | match member.member_index() {
|
253 253 | Some(0) => {
|
254 254 | builder.minimum_password_length = Some(deser.read_integer(member)?);
|
255 255 | }
|
256 256 | Some(1) => {
|
257 257 | builder.require_symbols = Some(deser.read_boolean(member)?);
|
258 258 | }
|
259 259 | Some(2) => {
|
260 260 | builder.require_numbers = Some(deser.read_boolean(member)?);
|
261 261 | }
|
262 262 | Some(3) => {
|
263 263 | builder.require_uppercase_characters = Some(deser.read_boolean(member)?);
|
264 264 | }
|
265 265 | Some(4) => {
|
266 266 | builder.require_lowercase_characters = Some(deser.read_boolean(member)?);
|
267 267 | }
|
268 268 | Some(5) => {
|
269 269 | builder.allow_users_to_change_password = Some(deser.read_boolean(member)?);
|
270 270 | }
|
271 271 | Some(6) => {
|
272 272 | builder.max_password_age = Some(deser.read_integer(member)?);
|
273 273 | }
|
274 274 | Some(7) => {
|
275 275 | builder.password_reuse_prevention = Some(deser.read_integer(member)?);
|
276 276 | }
|
277 277 | Some(8) => {
|
278 278 | builder.hard_expiry = Some(deser.read_boolean(member)?);
|
279 279 | }
|
280 280 | _ => {}
|
281 281 | }
|
282 282 | Ok(())
|
283 283 | })?;
|
284 284 | builder
|
285 285 | .build()
|
286 286 | .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
|
287 287 | }
|
288 288 | }
|
289 + | impl UpdateAccountPasswordPolicyInput {
|
290 + | /// Deserializes this structure from a body deserializer and HTTP response.
|
291 + | pub fn deserialize_with_response(
|
292 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
293 + | _headers: &::aws_smithy_runtime_api::http::Headers,
|
294 + | _status: u16,
|
295 + | _body: &[u8],
|
296 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
297 + | Self::deserialize(deserializer)
|
298 + | }
|
299 + | }
|
289 300 | impl UpdateAccountPasswordPolicyInput {
|
290 301 | /// Creates a new builder-style object to manufacture [`UpdateAccountPasswordPolicyInput`](crate::operation::update_account_password_policy::UpdateAccountPasswordPolicyInput).
|
291 302 | pub fn builder() -> crate::operation::update_account_password_policy::builders::UpdateAccountPasswordPolicyInputBuilder {
|
292 303 | crate::operation::update_account_password_policy::builders::UpdateAccountPasswordPolicyInputBuilder::default()
|
293 304 | }
|
294 305 | }
|
295 306 |
|
296 307 | /// A builder for [`UpdateAccountPasswordPolicyInput`](crate::operation::update_account_password_policy::UpdateAccountPasswordPolicyInput).
|
297 308 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
298 309 | #[non_exhaustive]
|