57 57 | "com.amazonaws.ec2.synthetic",
|
58 58 | "DescribeCoipPoolsInput",
|
59 59 | );
|
60 60 | static DESCRIBECOIPPOOLSINPUT_MEMBER_POOL_IDS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
61 61 | ::aws_smithy_schema::ShapeId::from_static(
|
62 62 | "com.amazonaws.ec2.synthetic#DescribeCoipPoolsInput$PoolIds",
|
63 63 | "com.amazonaws.ec2.synthetic",
|
64 64 | "DescribeCoipPoolsInput",
|
65 65 | ),
|
66 66 | ::aws_smithy_schema::ShapeType::List,
|
67 - | "pool_ids",
|
67 + | "PoolIds",
|
68 68 | 0,
|
69 69 | )
|
70 70 | .with_xml_name("PoolId");
|
71 71 | static DESCRIBECOIPPOOLSINPUT_MEMBER_FILTERS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
72 72 | ::aws_smithy_schema::ShapeId::from_static(
|
73 73 | "com.amazonaws.ec2.synthetic#DescribeCoipPoolsInput$Filters",
|
74 74 | "com.amazonaws.ec2.synthetic",
|
75 75 | "DescribeCoipPoolsInput",
|
76 76 | ),
|
77 77 | ::aws_smithy_schema::ShapeType::List,
|
78 - | "filters",
|
78 + | "Filters",
|
79 79 | 1,
|
80 80 | )
|
81 81 | .with_xml_name("Filter");
|
82 82 | static DESCRIBECOIPPOOLSINPUT_MEMBER_MAX_RESULTS: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
83 83 | ::aws_smithy_schema::ShapeId::from_static(
|
84 84 | "com.amazonaws.ec2.synthetic#DescribeCoipPoolsInput$MaxResults",
|
85 85 | "com.amazonaws.ec2.synthetic",
|
86 86 | "DescribeCoipPoolsInput",
|
87 87 | ),
|
88 88 | ::aws_smithy_schema::ShapeType::Integer,
|
89 - | "max_results",
|
89 + | "MaxResults",
|
90 90 | 2,
|
91 91 | );
|
92 92 | static DESCRIBECOIPPOOLSINPUT_MEMBER_NEXT_TOKEN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
93 93 | ::aws_smithy_schema::ShapeId::from_static(
|
94 94 | "com.amazonaws.ec2.synthetic#DescribeCoipPoolsInput$NextToken",
|
95 95 | "com.amazonaws.ec2.synthetic",
|
96 96 | "DescribeCoipPoolsInput",
|
97 97 | ),
|
98 98 | ::aws_smithy_schema::ShapeType::String,
|
99 - | "next_token",
|
99 + | "NextToken",
|
100 100 | 3,
|
101 101 | );
|
102 102 | static DESCRIBECOIPPOOLSINPUT_MEMBER_DRY_RUN: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_member(
|
103 103 | ::aws_smithy_schema::ShapeId::from_static(
|
104 104 | "com.amazonaws.ec2.synthetic#DescribeCoipPoolsInput$DryRun",
|
105 105 | "com.amazonaws.ec2.synthetic",
|
106 106 | "DescribeCoipPoolsInput",
|
107 107 | ),
|
108 108 | ::aws_smithy_schema::ShapeType::Boolean,
|
109 - | "dry_run",
|
109 + | "DryRun",
|
110 110 | 4,
|
111 111 | );
|
112 112 | static DESCRIBECOIPPOOLSINPUT_SCHEMA: ::aws_smithy_schema::Schema = ::aws_smithy_schema::Schema::new_struct(
|
113 113 | DESCRIBECOIPPOOLSINPUT_SCHEMA_ID,
|
114 114 | ::aws_smithy_schema::ShapeType::Structure,
|
115 115 | &[
|
116 116 | &DESCRIBECOIPPOOLSINPUT_MEMBER_POOL_IDS,
|
117 117 | &DESCRIBECOIPPOOLSINPUT_MEMBER_FILTERS,
|
118 118 | &DESCRIBECOIPPOOLSINPUT_MEMBER_MAX_RESULTS,
|
119 119 | &DESCRIBECOIPPOOLSINPUT_MEMBER_NEXT_TOKEN,
|
120 120 | &DESCRIBECOIPPOOLSINPUT_MEMBER_DRY_RUN,
|
121 121 | ],
|
122 122 | );
|
123 123 | impl DescribeCoipPoolsInput {
|
124 124 | /// The schema for this shape.
|
125 125 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &DESCRIBECOIPPOOLSINPUT_SCHEMA;
|
126 126 | }
|
127 127 | impl ::aws_smithy_schema::serde::SerializableStruct for DescribeCoipPoolsInput {
|
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.pool_ids {
|
134 134 | ser.write_list(
|
135 135 | &DESCRIBECOIPPOOLSINPUT_MEMBER_POOL_IDS,
|
136 136 | &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
|
137 137 | for item in val {
|
138 138 | ser.write_string(&aws_smithy_schema::prelude::STRING, item)?;
|
139 139 | }
|
140 140 | Ok(())
|
141 141 | },
|
142 142 | )?;
|
143 143 | }
|
144 144 | if let Some(ref val) = self.filters {
|
145 145 | ser.write_list(
|
146 146 | &DESCRIBECOIPPOOLSINPUT_MEMBER_FILTERS,
|
147 147 | &|ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer| {
|
148 148 | for item in val {
|
149 149 | ser.write_struct(crate::types::Filter::SCHEMA, item)?;
|
150 150 | }
|
151 151 | Ok(())
|
152 152 | },
|
153 153 | )?;
|
154 154 | }
|
155 155 | if let Some(ref val) = self.max_results {
|
156 156 | ser.write_integer(&DESCRIBECOIPPOOLSINPUT_MEMBER_MAX_RESULTS, *val)?;
|
157 157 | }
|
158 158 | if let Some(ref val) = self.next_token {
|
159 159 | ser.write_string(&DESCRIBECOIPPOOLSINPUT_MEMBER_NEXT_TOKEN, val)?;
|
160 160 | }
|
161 161 | if let Some(ref val) = self.dry_run {
|
162 162 | ser.write_boolean(&DESCRIBECOIPPOOLSINPUT_MEMBER_DRY_RUN, *val)?;
|
163 163 | }
|
164 164 | Ok(())
|
165 165 | }
|
166 166 | }
|
167 167 | impl DescribeCoipPoolsInput {
|
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(&DESCRIBECOIPPOOLSINPUT_SCHEMA, (), |_, member, deser| {
|
181 + | deserializer.read_struct(&DESCRIBECOIPPOOLSINPUT_SCHEMA, &mut |member, deser| {
|
182 182 | match member.member_index() {
|
183 183 | Some(0) => {
|
184 - | builder.pool_ids = Some({
|
185 - | let container = if let Some(cap) = deser.container_size() {
|
186 - | Vec::with_capacity(cap)
|
187 - | } else {
|
188 - | Vec::new()
|
189 - | };
|
190 - | deser.read_list(member, container, |mut list, deser| {
|
191 - | list.push(deser.read_string(member)?);
|
192 - | Ok(list)
|
193 - | })?
|
194 - | });
|
184 + | builder.pool_ids = Some(deser.read_string_list(member)?);
|
195 185 | }
|
196 186 | Some(1) => {
|
197 187 | builder.filters = Some({
|
198 - | let container = if let Some(cap) = deser.container_size() {
|
199 - | Vec::with_capacity(cap)
|
200 - | } else {
|
201 - | Vec::new()
|
202 - | };
|
203 - | deser.read_list(member, container, |mut list, deser| {
|
204 - | list.push(crate::types::Filter::deserialize(deser)?);
|
205 - | Ok(list)
|
206 - | })?
|
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
|
207 194 | });
|
208 195 | }
|
209 196 | Some(2) => {
|
210 197 | builder.max_results = Some(deser.read_integer(member)?);
|
211 198 | }
|
212 199 | Some(3) => {
|
213 200 | builder.next_token = Some(deser.read_string(member)?);
|
214 201 | }
|
215 202 | Some(4) => {
|
216 203 | builder.dry_run = Some(deser.read_boolean(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 DescribeCoipPoolsInput {
|
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 DescribeCoipPoolsInput {
|
228 226 | /// Creates a new builder-style object to manufacture [`DescribeCoipPoolsInput`](crate::operation::describe_coip_pools::DescribeCoipPoolsInput).
|
229 227 | pub fn builder() -> crate::operation::describe_coip_pools::builders::DescribeCoipPoolsInputBuilder {
|
230 228 | crate::operation::describe_coip_pools::builders::DescribeCoipPoolsInputBuilder::default()
|
231 229 | }
|
232 230 | }
|
233 231 |
|
234 232 | /// A builder for [`DescribeCoipPoolsInput`](crate::operation::describe_coip_pools::DescribeCoipPoolsInput).
|
235 233 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
236 234 | #[non_exhaustive]
|