57 57 | "com.amazonaws.ec2.synthetic",
|
58 58 | "DescribePrefixListsInput",
|
59 59 | );
|
60 60 | static DESCRIBEPREFIXLISTSINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
61 61 | ::aws_smithy_schema::ShapeId::from_static(
|
62 62 | "com.amazonaws.ec2.synthetic#DescribePrefixListsInput$DryRun",
|
63 63 | "com.amazonaws.ec2.synthetic",
|
64 64 | "DescribePrefixListsInput",
|
65 65 | ),
|
66 66 | ::aws_smithy_schema::ShapeType::Boolean,
|
67 - | "dry_run",
|
67 + | "DryRun",
|
68 68 | 0,
|
69 69 | );
|
70 70 | static DESCRIBEPREFIXLISTSINPUT_MEMBER_FILTERS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
71 71 | ::aws_smithy_schema::ShapeId::from_static(
|
72 72 | "com.amazonaws.ec2.synthetic#DescribePrefixListsInput$Filters",
|
73 73 | "com.amazonaws.ec2.synthetic",
|
74 74 | "DescribePrefixListsInput",
|
75 75 | ),
|
76 76 | ::aws_smithy_schema::ShapeType::List,
|
77 - | "filters",
|
77 + | "Filters",
|
78 78 | 1,
|
79 79 | )
|
80 80 | .with_xml_name("Filter");
|
81 81 | static DESCRIBEPREFIXLISTSINPUT_MEMBER_MAX_RESULTS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
82 82 | ::aws_smithy_schema::ShapeId::from_static(
|
83 83 | "com.amazonaws.ec2.synthetic#DescribePrefixListsInput$MaxResults",
|
84 84 | "com.amazonaws.ec2.synthetic",
|
85 85 | "DescribePrefixListsInput",
|
86 86 | ),
|
87 87 | ::aws_smithy_schema::ShapeType::Integer,
|
88 - | "max_results",
|
88 + | "MaxResults",
|
89 89 | 2,
|
90 90 | );
|
91 91 | static DESCRIBEPREFIXLISTSINPUT_MEMBER_NEXT_TOKEN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
92 92 | ::aws_smithy_schema::ShapeId::from_static(
|
93 93 | "com.amazonaws.ec2.synthetic#DescribePrefixListsInput$NextToken",
|
94 94 | "com.amazonaws.ec2.synthetic",
|
95 95 | "DescribePrefixListsInput",
|
96 96 | ),
|
97 97 | ::aws_smithy_schema::ShapeType::String,
|
98 - | "next_token",
|
98 + | "NextToken",
|
99 99 | 3,
|
100 100 | );
|
101 101 | static DESCRIBEPREFIXLISTSINPUT_MEMBER_PREFIX_LIST_IDS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
102 102 | ::aws_smithy_schema::ShapeId::from_static(
|
103 103 | "com.amazonaws.ec2.synthetic#DescribePrefixListsInput$PrefixListIds",
|
104 104 | "com.amazonaws.ec2.synthetic",
|
105 105 | "DescribePrefixListsInput",
|
106 106 | ),
|
107 107 | ::aws_smithy_schema::ShapeType::List,
|
108 - | "prefix_list_ids",
|
108 + | "PrefixListIds",
|
109 109 | 4,
|
110 110 | )
|
111 111 | .with_xml_name("PrefixListId");
|
112 112 | static DESCRIBEPREFIXLISTSINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
113 113 | DESCRIBEPREFIXLISTSINPUT_SCHEMA_ID,
|
114 114 | ::aws_smithy_schema::ShapeType::Structure,
|
115 115 | &[
|
116 116 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_DRY_RUN,
|
117 117 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_FILTERS,
|
118 118 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_MAX_RESULTS,
|
119 119 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_NEXT_TOKEN,
|
120 120 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_PREFIX_LIST_IDS,
|
121 121 | ],
|
122 122 | );
|
123 123 | impl DescribePrefixListsInput {
|
124 124 | /// The schema for this shape.
|
125 125 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBEPREFIXLISTSINPUT_SCHEMA;
|
126 126 | }
|
127 127 | impl ::aws_smithy_schema::serde::SerializableStruct for DescribePrefixListsInput {
|
128 128 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
129 129 | fn serialize_members(
|
130 130 | &self,
|
131 131 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
132 132 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
133 133 | if let Some(ref val) = self.dry_run {
|
134 134 | ser.write_boolean(&DESCRIBEPREFIXLISTSINPUT_MEMBER_DRY_RUN, *val)?;
|
135 135 | }
|
136 136 | if let Some(ref val) = self.filters {
|
137 137 | ser.write_list(
|
138 138 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_FILTERS,
|
139 139 | &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
|
140 140 | for item in val {
|
141 141 | ser.write_struct(crate::types::Filter::SCHEMA, item)?;
|
142 142 | }
|
143 143 | Ok(())
|
144 144 | },
|
145 145 | )?;
|
146 146 | }
|
147 147 | if let Some(ref val) = self.max_results {
|
148 148 | ser.write_integer(&DESCRIBEPREFIXLISTSINPUT_MEMBER_MAX_RESULTS, *val)?;
|
149 149 | }
|
150 150 | if let Some(ref val) = self.next_token {
|
151 151 | ser.write_string(&DESCRIBEPREFIXLISTSINPUT_MEMBER_NEXT_TOKEN, val)?;
|
152 152 | }
|
153 153 | if let Some(ref val) = self.prefix_list_ids {
|
154 154 | ser.write_list(
|
155 155 | &DESCRIBEPREFIXLISTSINPUT_MEMBER_PREFIX_LIST_IDS,
|
156 156 | &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
|
157 157 | for item in val {
|
158 158 | ser.write_string(&aws_smithy_schema::prelude::STRING, item)?;
|
159 159 | }
|
160 160 | Ok(())
|
161 161 | },
|
162 162 | )?;
|
163 163 | }
|
164 164 | Ok(())
|
165 165 | }
|
166 166 | }
|
167 167 | impl DescribePrefixListsInput {
|
168 168 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
169 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
170 - | deserializer: &mut D,
|
169 + | pub fn deserialize(
|
170 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
171 171 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
172 172 | #[allow(unused_variables, unused_mut)]
|
173 173 | let mut builder = Self::builder();
|
174 174 | #[allow(
|
175 175 | unused_variables,
|
176 176 | unreachable_code,
|
177 177 | clippy::single_match,
|
178 178 | clippy::match_single_binding,
|
179 179 | clippy::diverging_sub_expression
|
180 180 | )]
|
181 - | deserializer.read_struct(&DESCRIBEPREFIXLISTSINPUT_SCHEMA, (), |_, member, deser| {
|
181 + | deserializer.read_struct(&DESCRIBEPREFIXLISTSINPUT_SCHEMA, &mut |member, deser| {
|
182 182 | match member.member_index() {
|
183 183 | Some(0) => {
|
184 184 | builder.dry_run = Some(deser.read_boolean(member)?);
|
185 185 | }
|
186 186 | Some(1) => {
|
187 187 | builder.filters = Some({
|
188 - | let container = if let Some(cap) = deser.container_size() {
|
189 - | Vec::with_capacity(cap)
|
190 - | } else {
|
191 - | Vec::new()
|
192 - | };
|
193 - | deser.read_list(member, container, |mut list, deser| {
|
194 - | list.push(crate::types::Filter::deserialize(deser)?);
|
195 - | Ok(list)
|
196 - | })?
|
188 + | let mut container = Vec::new();
|
189 + | deser.read_list(member, &mut |deser| {
|
190 + | container.push(crate::types::Filter::deserialize(deser)?);
|
191 + | Ok(())
|
192 + | })?;
|
193 + | container
|
197 194 | });
|
198 195 | }
|
199 196 | Some(2) => {
|
200 197 | builder.max_results = Some(deser.read_integer(member)?);
|
201 198 | }
|
202 199 | Some(3) => {
|
203 200 | builder.next_token = Some(deser.read_string(member)?);
|
204 201 | }
|
205 202 | Some(4) => {
|
206 - | builder.prefix_list_ids = Some({
|
207 - | let container = if let Some(cap) = deser.container_size() {
|
208 - | Vec::with_capacity(cap)
|
209 - | } else {
|
210 - | Vec::new()
|
211 - | };
|
212 - | deser.read_list(member, container, |mut list, deser| {
|
213 - | list.push(deser.read_string(member)?);
|
214 - | Ok(list)
|
215 - | })?
|
216 - | });
|
203 + | builder.prefix_list_ids = Some(deser.read_string_list(member)?);
|
217 204 | }
|
218 205 | _ => {}
|
219 206 | }
|
220 207 | Ok(())
|
221 208 | })?;
|
222 209 | builder
|
223 210 | .build()
|
224 211 | .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
|
225 212 | }
|
226 213 | }
|
214 + | impl DescribePrefixListsInput {
|
215 + | /// Deserializes this structure from a body deserializer and HTTP response.
|
216 + | pub fn deserialize_with_response(
|
217 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
218 + | _headers: &::aws_smithy_runtime_api::http::Headers,
|
219 + | _status: u16,
|
220 + | _body: &[u8],
|
221 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
222 + | Self::deserialize(deserializer)
|
223 + | }
|
224 + | }
|
227 225 | impl DescribePrefixListsInput {
|
228 226 | /// Creates a new builder-style object to manufacture [`DescribePrefixListsInput`](crate::operation::describe_prefix_lists::DescribePrefixListsInput).
|
229 227 | pub fn builder() -> crate::operation::describe_prefix_lists::builders::DescribePrefixListsInputBuilder {
|
230 228 | crate::operation::describe_prefix_lists::builders::DescribePrefixListsInputBuilder::default()
|
231 229 | }
|
232 230 | }
|
233 231 |
|
234 232 | /// A builder for [`DescribePrefixListsInput`](crate::operation::describe_prefix_lists::DescribePrefixListsInput).
|
235 233 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
236 234 | #[non_exhaustive]
|