153 153 | &[
|
154 154 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_STRING,
|
155 155 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_SHORT,
|
156 156 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_INTEGER,
|
157 157 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_LONG,
|
158 158 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_FLOAT,
|
159 159 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_DOUBLE,
|
160 160 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_BOOLEAN,
|
161 161 | &HTTPREQUESTWITHLABELSINPUT_MEMBER_TIMESTAMP,
|
162 162 | ],
|
163 - | );
|
163 + | )
|
164 + | .with_http(aws_smithy_schema::traits::HttpTrait::new(
|
165 + | "GET",
|
166 + | "/HttpRequestWithLabels/{string}/{short}/{integer}/{long}/{float}/{double}/{boolean}/{timestamp}",
|
167 + | None,
|
168 + | ));
|
164 169 | impl HttpRequestWithLabelsInput {
|
165 170 | /// The schema for this shape.
|
166 171 | pub const SCHEMA: &'static ::aws_smithy_schema::Schema = &HTTPREQUESTWITHLABELSINPUT_SCHEMA;
|
167 172 | }
|
168 173 | impl ::aws_smithy_schema::serde::SerializableStruct for HttpRequestWithLabelsInput {
|
169 174 | #[allow(unused_variables, clippy::diverging_sub_expression)]
|
170 175 | fn serialize_members(
|
171 176 | &self,
|
172 177 | ser: &mut dyn ::aws_smithy_schema::serde::ShapeSerializer,
|
173 178 | ) -> ::std::result::Result<(), ::aws_smithy_schema::serde::SerdeError> {
|
174 179 | if let Some(ref val) = self.string {
|
175 180 | ser.write_string(&HTTPREQUESTWITHLABELSINPUT_MEMBER_STRING, val)?;
|
176 181 | }
|
177 182 | if let Some(ref val) = self.short {
|
178 183 | ser.write_short(&HTTPREQUESTWITHLABELSINPUT_MEMBER_SHORT, *val)?;
|
179 184 | }
|
180 185 | if let Some(ref val) = self.integer {
|
181 186 | ser.write_integer(&HTTPREQUESTWITHLABELSINPUT_MEMBER_INTEGER, *val)?;
|
182 187 | }
|
183 188 | if let Some(ref val) = self.long {
|
184 189 | ser.write_long(&HTTPREQUESTWITHLABELSINPUT_MEMBER_LONG, *val)?;
|
185 190 | }
|
186 191 | if let Some(ref val) = self.float {
|
187 192 | ser.write_float(&HTTPREQUESTWITHLABELSINPUT_MEMBER_FLOAT, *val)?;
|
188 193 | }
|
189 194 | if let Some(ref val) = self.double {
|
190 195 | ser.write_double(&HTTPREQUESTWITHLABELSINPUT_MEMBER_DOUBLE, *val)?;
|
191 196 | }
|
192 197 | if let Some(ref val) = self.boolean {
|
193 198 | ser.write_boolean(&HTTPREQUESTWITHLABELSINPUT_MEMBER_BOOLEAN, *val)?;
|
194 199 | }
|
195 200 | if let Some(ref val) = self.timestamp {
|
196 201 | ser.write_timestamp(&HTTPREQUESTWITHLABELSINPUT_MEMBER_TIMESTAMP, val)?;
|
197 202 | }
|
198 203 | Ok(())
|
199 204 | }
|
200 205 | }
|
201 206 | impl HttpRequestWithLabelsInput {
|
202 207 | /// Deserializes this structure from a [`ShapeDeserializer`].
|
203 - | pub fn deserialize<D: ::aws_smithy_schema::serde::ShapeDeserializer>(
|
204 - | deserializer: &mut D,
|
208 + | pub fn deserialize(
|
209 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
205 210 | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
206 211 | #[allow(unused_variables, unused_mut)]
|
207 212 | let mut builder = Self::builder();
|
208 213 | #[allow(
|
209 214 | unused_variables,
|
210 215 | unreachable_code,
|
211 216 | clippy::single_match,
|
212 217 | clippy::match_single_binding,
|
213 218 | clippy::diverging_sub_expression
|
214 219 | )]
|
215 - | deserializer.read_struct(&HTTPREQUESTWITHLABELSINPUT_SCHEMA, (), |_, member, deser| {
|
220 + | deserializer.read_struct(&HTTPREQUESTWITHLABELSINPUT_SCHEMA, &mut |member, deser| {
|
216 221 | match member.member_index() {
|
217 222 | Some(0) => {
|
218 223 | builder.string = Some(deser.read_string(member)?);
|
219 224 | }
|
220 225 | Some(1) => {
|
221 226 | builder.short = Some(deser.read_short(member)?);
|
222 227 | }
|
223 228 | Some(2) => {
|
224 229 | builder.integer = Some(deser.read_integer(member)?);
|
225 230 | }
|
226 231 | Some(3) => {
|
227 232 | builder.long = Some(deser.read_long(member)?);
|
228 233 | }
|
229 234 | Some(4) => {
|
230 235 | builder.float = Some(deser.read_float(member)?);
|
231 236 | }
|
232 237 | Some(5) => {
|
233 238 | builder.double = Some(deser.read_double(member)?);
|
234 239 | }
|
235 240 | Some(6) => {
|
236 241 | builder.boolean = Some(deser.read_boolean(member)?);
|
237 242 | }
|
238 243 | Some(7) => {
|
239 244 | builder.timestamp = Some(deser.read_timestamp(member)?);
|
240 245 | }
|
241 246 | _ => {}
|
242 247 | }
|
243 248 | Ok(())
|
244 249 | })?;
|
250 + | builder.string = builder.string.or(Some(String::new()));
|
251 + | builder.short = builder.short.or(Some(0i16));
|
252 + | builder.integer = builder.integer.or(Some(0i32));
|
253 + | builder.long = builder.long.or(Some(0i64));
|
254 + | builder.float = builder.float.or(Some(0.0f32));
|
255 + | builder.double = builder.double.or(Some(0.0f64));
|
256 + | builder.boolean = builder.boolean.or(Some(false));
|
257 + | builder.timestamp = builder.timestamp.or(Some(::aws_smithy_types::DateTime::from_secs(0)));
|
245 258 | builder
|
246 259 | .build()
|
247 260 | .map_err(|e| aws_smithy_schema::serde::SerdeError::Custom { message: e.to_string() })
|
248 261 | }
|
249 262 | }
|
263 + | impl HttpRequestWithLabelsInput {
|
264 + | /// Deserializes this structure from a body deserializer and HTTP response.
|
265 + | pub fn deserialize_with_response(
|
266 + | deserializer: &mut dyn ::aws_smithy_schema::serde::ShapeDeserializer,
|
267 + | _headers: &::aws_smithy_runtime_api::http::Headers,
|
268 + | _status: u16,
|
269 + | _body: &[u8],
|
270 + | ) -> ::std::result::Result<Self, ::aws_smithy_schema::serde::SerdeError> {
|
271 + | Self::deserialize(deserializer)
|
272 + | }
|
273 + | }
|
250 274 | impl HttpRequestWithLabelsInput {
|
251 275 | /// Creates a new builder-style object to manufacture [`HttpRequestWithLabelsInput`](crate::operation::http_request_with_labels::HttpRequestWithLabelsInput).
|
252 276 | pub fn builder() -> crate::operation::http_request_with_labels::builders::HttpRequestWithLabelsInputBuilder {
|
253 277 | crate::operation::http_request_with_labels::builders::HttpRequestWithLabelsInputBuilder::default()
|
254 278 | }
|
255 279 | }
|
256 280 |
|
257 281 | /// A builder for [`HttpRequestWithLabelsInput`](crate::operation::http_request_with_labels::HttpRequestWithLabelsInput).
|
258 282 | #[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
|
259 283 | #[non_exhaustive]
|
260 284 | pub struct HttpRequestWithLabelsInputBuilder {
|
261 285 | pub(crate) string: ::std::option::Option<::std::string::String>,
|
262 286 | pub(crate) short: ::std::option::Option<i16>,
|
263 287 | pub(crate) integer: ::std::option::Option<i32>,
|
264 288 | pub(crate) long: ::std::option::Option<i64>,
|
265 289 | pub(crate) float: ::std::option::Option<f32>,
|
266 290 | pub(crate) double: ::std::option::Option<f64>,
|
267 291 | pub(crate) boolean: ::std::option::Option<bool>,
|
268 292 | pub(crate) timestamp: ::std::option::Option<::aws_smithy_types::DateTime>,
|
269 293 | }
|
270 294 | impl HttpRequestWithLabelsInputBuilder {
|
271 295 | #[allow(missing_docs)] // documentation missing in model
|
272 296 | /// This field is required.
|
273 297 | pub fn string(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
|
274 298 | self.string = ::std::option::Option::Some(input.into());
|
275 299 | self
|
276 300 | }
|
277 301 | #[allow(missing_docs)] // documentation missing in model
|
278 302 | pub fn set_string(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
|
279 303 | self.string = input;
|