1349 1361 | > + Clone
|
1350 1362 | + Send
|
1351 1363 | + 'static,
|
1352 1364 | S::Future: Send + 'static,
|
1353 1365 | {
|
1354 1366 | self.document_type_as_payload =
|
1355 1367 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1356 1368 | self
|
1357 1369 | }
|
1358 1370 |
|
1359 - | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1371 + | /// Sets the [`DuplexStream`](crate::operation_shape::DuplexStream) operation.
|
1360 1372 | ///
|
1361 1373 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1362 1374 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1363 1375 | ///
|
1364 1376 | /// # Example
|
1365 1377 | ///
|
1366 1378 | /// ```no_run
|
1367 1379 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1368 1380 | ///
|
1369 1381 | /// use rest_json_http0x::{input, output, error};
|
1370 1382 | ///
|
1371 - | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> output::EmptyInputAndEmptyOutputOutput {
|
1383 + | /// async fn handler(input: input::DuplexStreamInput) -> Result<output::DuplexStreamOutput, error::DuplexStreamError> {
|
1372 1384 | /// todo!()
|
1373 1385 | /// }
|
1374 1386 | ///
|
1375 1387 | /// let config = RestJsonConfig::builder().build();
|
1376 1388 | /// let app = RestJson::builder(config)
|
1377 - | /// .empty_input_and_empty_output(handler)
|
1389 + | /// .duplex_stream(handler)
|
1378 1390 | /// /* Set other handlers */
|
1379 1391 | /// .build()
|
1380 1392 | /// .unwrap();
|
1381 1393 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1382 1394 | /// ```
|
1383 1395 | ///
|
1384 - | pub fn empty_input_and_empty_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1396 + | pub fn duplex_stream<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1385 1397 | where
|
1386 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerExtractors>,
|
1398 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DuplexStream, HandlerExtractors>,
|
1387 1399 |
|
1388 1400 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1389 1401 | RestJson<L>,
|
1390 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1391 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerType>
|
1402 + | crate::operation_shape::DuplexStream,
|
1403 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DuplexStream, HandlerType>
|
1392 1404 | >,
|
1393 1405 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1394 1406 | RestJson<L>,
|
1395 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1407 + | crate::operation_shape::DuplexStream,
|
1396 1408 | ModelPl::Output
|
1397 1409 | >,
|
1398 1410 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1399 1411 | RestJson<L>,
|
1400 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1412 + | crate::operation_shape::DuplexStream,
|
1401 1413 | <
|
1402 1414 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1403 1415 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1404 1416 | RestJson<L>,
|
1405 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1417 + | crate::operation_shape::DuplexStream,
|
1406 1418 | ModelPl::Output
|
1407 1419 | >
|
1408 1420 | >::Output
|
1409 1421 | >,
|
1410 1422 |
|
1411 1423 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1412 1424 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1413 1425 |
|
1414 1426 | {
|
1415 1427 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1416 1428 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1417 - | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_handler(handler);
|
1429 + | let svc = crate::operation_shape::DuplexStream::from_handler(handler);
|
1418 1430 | let svc = self.model_plugin.apply(svc);
|
1419 1431 | let svc =
|
1420 1432 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1421 1433 | .apply(svc);
|
1422 1434 | let svc = self.http_plugin.apply(svc);
|
1423 - | self.empty_input_and_empty_output_custom(svc)
|
1435 + | self.duplex_stream_custom(svc)
|
1424 1436 | }
|
1425 1437 |
|
1426 - | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1438 + | /// Sets the [`DuplexStream`](crate::operation_shape::DuplexStream) operation.
|
1427 1439 | ///
|
1428 1440 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1429 1441 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1430 1442 | ///
|
1431 1443 | /// # Example
|
1432 1444 | ///
|
1433 1445 | /// ```no_run
|
1434 1446 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1435 1447 | ///
|
1436 1448 | /// use rest_json_http0x::{input, output, error};
|
1437 1449 | ///
|
1438 - | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> Result<output::EmptyInputAndEmptyOutputOutput, std::convert::Infallible> {
|
1450 + | /// async fn handler(input: input::DuplexStreamInput) -> Result<output::DuplexStreamOutput, error::DuplexStreamError> {
|
1439 1451 | /// todo!()
|
1440 1452 | /// }
|
1441 1453 | ///
|
1442 1454 | /// let config = RestJsonConfig::builder().build();
|
1443 1455 | /// let svc = ::tower::util::service_fn(handler);
|
1444 1456 | /// let app = RestJson::builder(config)
|
1445 - | /// .empty_input_and_empty_output_service(svc)
|
1457 + | /// .duplex_stream_service(svc)
|
1446 1458 | /// /* Set other handlers */
|
1447 1459 | /// .build()
|
1448 1460 | /// .unwrap();
|
1449 1461 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1450 1462 | /// ```
|
1451 1463 | ///
|
1452 - | pub fn empty_input_and_empty_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1464 + | pub fn duplex_stream_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1453 1465 | where
|
1454 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EmptyInputAndEmptyOutput, ServiceExtractors>,
|
1466 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DuplexStream, ServiceExtractors>,
|
1455 1467 |
|
1456 1468 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1457 1469 | RestJson<L>,
|
1458 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1459 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EmptyInputAndEmptyOutput, S>
|
1470 + | crate::operation_shape::DuplexStream,
|
1471 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DuplexStream, S>
|
1460 1472 | >,
|
1461 1473 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1462 1474 | RestJson<L>,
|
1463 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1475 + | crate::operation_shape::DuplexStream,
|
1464 1476 | ModelPl::Output
|
1465 1477 | >,
|
1466 1478 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1467 1479 | RestJson<L>,
|
1468 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1480 + | crate::operation_shape::DuplexStream,
|
1469 1481 | <
|
1470 1482 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1471 1483 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1472 1484 | RestJson<L>,
|
1473 - | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1485 + | crate::operation_shape::DuplexStream,
|
1474 1486 | ModelPl::Output
|
1475 1487 | >
|
1476 1488 | >::Output
|
1477 1489 | >,
|
1478 1490 |
|
1479 1491 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1480 1492 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1481 1493 |
|
1482 1494 | {
|
1483 1495 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1484 1496 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1485 - | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_service(service);
|
1497 + | let svc = crate::operation_shape::DuplexStream::from_service(service);
|
1486 1498 | let svc = self.model_plugin.apply(svc);
|
1487 1499 | let svc =
|
1488 1500 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1489 1501 | .apply(svc);
|
1490 1502 | let svc = self.http_plugin.apply(svc);
|
1491 - | self.empty_input_and_empty_output_custom(svc)
|
1503 + | self.duplex_stream_custom(svc)
|
1492 1504 | }
|
1493 1505 |
|
1494 - | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) to a custom [`Service`](tower::Service).
|
1506 + | /// Sets the [`DuplexStream`](crate::operation_shape::DuplexStream) to a custom [`Service`](tower::Service).
|
1495 1507 | /// not constrained by the Smithy contract.
|
1496 - | fn empty_input_and_empty_output_custom<S>(mut self, svc: S) -> Self
|
1508 + | fn duplex_stream_custom<S>(mut self, svc: S) -> Self
|
1497 1509 | where
|
1498 1510 | S: ::tower::Service<
|
1499 1511 | ::http::Request<Body>,
|
1500 1512 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1501 1513 | Error = ::std::convert::Infallible,
|
1502 1514 | > + Clone
|
1503 1515 | + Send
|
1504 1516 | + 'static,
|
1505 1517 | S::Future: Send + 'static,
|
1506 1518 | {
|
1507 - | self.empty_input_and_empty_output =
|
1508 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1519 + | self.duplex_stream = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1509 1520 | self
|
1510 1521 | }
|
1511 1522 |
|
1512 - | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
1523 + | /// Sets the [`DuplexStreamWithDistinctStreams`](crate::operation_shape::DuplexStreamWithDistinctStreams) operation.
|
1513 1524 | ///
|
1514 1525 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1515 1526 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1516 1527 | ///
|
1517 1528 | /// # Example
|
1518 1529 | ///
|
1519 1530 | /// ```no_run
|
1520 1531 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1521 1532 | ///
|
1522 1533 | /// use rest_json_http0x::{input, output, error};
|
1523 1534 | ///
|
1524 - | /// async fn handler(input: input::EndpointOperationInput) -> output::EndpointOperationOutput {
|
1535 + | /// async fn handler(input: input::DuplexStreamWithDistinctStreamsInput) -> Result<output::DuplexStreamWithDistinctStreamsOutput, error::DuplexStreamWithDistinctStreamsError> {
|
1525 1536 | /// todo!()
|
1526 1537 | /// }
|
1527 1538 | ///
|
1528 1539 | /// let config = RestJsonConfig::builder().build();
|
1529 1540 | /// let app = RestJson::builder(config)
|
1530 - | /// .endpoint_operation(handler)
|
1541 + | /// .duplex_stream_with_distinct_streams(handler)
|
1531 1542 | /// /* Set other handlers */
|
1532 1543 | /// .build()
|
1533 1544 | /// .unwrap();
|
1534 1545 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1535 1546 | /// ```
|
1536 1547 | ///
|
1537 - | pub fn endpoint_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1548 + | pub fn duplex_stream_with_distinct_streams<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1538 1549 | where
|
1539 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointOperation, HandlerExtractors>,
|
1550 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DuplexStreamWithDistinctStreams, HandlerExtractors>,
|
1540 1551 |
|
1541 1552 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1542 1553 | RestJson<L>,
|
1543 - | crate::operation_shape::EndpointOperation,
|
1544 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointOperation, HandlerType>
|
1554 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1555 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DuplexStreamWithDistinctStreams, HandlerType>
|
1545 1556 | >,
|
1546 1557 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1547 1558 | RestJson<L>,
|
1548 - | crate::operation_shape::EndpointOperation,
|
1559 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1549 1560 | ModelPl::Output
|
1550 1561 | >,
|
1551 1562 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1552 1563 | RestJson<L>,
|
1553 - | crate::operation_shape::EndpointOperation,
|
1564 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1554 1565 | <
|
1555 1566 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1556 1567 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1557 1568 | RestJson<L>,
|
1558 - | crate::operation_shape::EndpointOperation,
|
1569 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1559 1570 | ModelPl::Output
|
1560 1571 | >
|
1561 1572 | >::Output
|
1562 1573 | >,
|
1563 1574 |
|
1564 1575 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1565 1576 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1566 1577 |
|
1567 1578 | {
|
1568 1579 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1569 1580 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1570 - | let svc = crate::operation_shape::EndpointOperation::from_handler(handler);
|
1581 + | let svc = crate::operation_shape::DuplexStreamWithDistinctStreams::from_handler(handler);
|
1571 1582 | let svc = self.model_plugin.apply(svc);
|
1572 1583 | let svc =
|
1573 1584 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1574 1585 | .apply(svc);
|
1575 1586 | let svc = self.http_plugin.apply(svc);
|
1576 - | self.endpoint_operation_custom(svc)
|
1587 + | self.duplex_stream_with_distinct_streams_custom(svc)
|
1577 1588 | }
|
1578 1589 |
|
1579 - | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
1590 + | /// Sets the [`DuplexStreamWithDistinctStreams`](crate::operation_shape::DuplexStreamWithDistinctStreams) operation.
|
1580 1591 | ///
|
1581 1592 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1582 1593 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1583 1594 | ///
|
1584 1595 | /// # Example
|
1585 1596 | ///
|
1586 1597 | /// ```no_run
|
1587 1598 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1588 1599 | ///
|
1589 1600 | /// use rest_json_http0x::{input, output, error};
|
1590 1601 | ///
|
1591 - | /// async fn handler(input: input::EndpointOperationInput) -> Result<output::EndpointOperationOutput, std::convert::Infallible> {
|
1602 + | /// async fn handler(input: input::DuplexStreamWithDistinctStreamsInput) -> Result<output::DuplexStreamWithDistinctStreamsOutput, error::DuplexStreamWithDistinctStreamsError> {
|
1592 1603 | /// todo!()
|
1593 1604 | /// }
|
1594 1605 | ///
|
1595 1606 | /// let config = RestJsonConfig::builder().build();
|
1596 1607 | /// let svc = ::tower::util::service_fn(handler);
|
1597 1608 | /// let app = RestJson::builder(config)
|
1598 - | /// .endpoint_operation_service(svc)
|
1609 + | /// .duplex_stream_with_distinct_streams_service(svc)
|
1599 1610 | /// /* Set other handlers */
|
1600 1611 | /// .build()
|
1601 1612 | /// .unwrap();
|
1602 1613 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1603 1614 | /// ```
|
1604 1615 | ///
|
1605 - | pub fn endpoint_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1616 + | pub fn duplex_stream_with_distinct_streams_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1606 1617 | where
|
1607 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointOperation, ServiceExtractors>,
|
1618 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DuplexStreamWithDistinctStreams, ServiceExtractors>,
|
1608 1619 |
|
1609 1620 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1610 1621 | RestJson<L>,
|
1611 - | crate::operation_shape::EndpointOperation,
|
1612 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointOperation, S>
|
1622 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1623 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DuplexStreamWithDistinctStreams, S>
|
1613 1624 | >,
|
1614 1625 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1615 1626 | RestJson<L>,
|
1616 - | crate::operation_shape::EndpointOperation,
|
1627 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1617 1628 | ModelPl::Output
|
1618 1629 | >,
|
1619 1630 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1620 1631 | RestJson<L>,
|
1621 - | crate::operation_shape::EndpointOperation,
|
1632 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1622 1633 | <
|
1623 1634 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1624 1635 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1625 1636 | RestJson<L>,
|
1626 - | crate::operation_shape::EndpointOperation,
|
1637 + | crate::operation_shape::DuplexStreamWithDistinctStreams,
|
1627 1638 | ModelPl::Output
|
1628 1639 | >
|
1629 1640 | >::Output
|
1630 1641 | >,
|
1631 1642 |
|
1632 1643 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1633 1644 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1634 1645 |
|
1635 1646 | {
|
1636 1647 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1637 1648 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1638 - | let svc = crate::operation_shape::EndpointOperation::from_service(service);
|
1649 + | let svc = crate::operation_shape::DuplexStreamWithDistinctStreams::from_service(service);
|
1639 1650 | let svc = self.model_plugin.apply(svc);
|
1640 1651 | let svc =
|
1641 1652 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1642 1653 | .apply(svc);
|
1643 1654 | let svc = self.http_plugin.apply(svc);
|
1644 - | self.endpoint_operation_custom(svc)
|
1655 + | self.duplex_stream_with_distinct_streams_custom(svc)
|
1645 1656 | }
|
1646 1657 |
|
1647 - | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) to a custom [`Service`](tower::Service).
|
1658 + | /// Sets the [`DuplexStreamWithDistinctStreams`](crate::operation_shape::DuplexStreamWithDistinctStreams) to a custom [`Service`](tower::Service).
|
1648 1659 | /// not constrained by the Smithy contract.
|
1649 - | fn endpoint_operation_custom<S>(mut self, svc: S) -> Self
|
1660 + | fn duplex_stream_with_distinct_streams_custom<S>(mut self, svc: S) -> Self
|
1650 1661 | where
|
1651 1662 | S: ::tower::Service<
|
1652 1663 | ::http::Request<Body>,
|
1653 1664 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1654 1665 | Error = ::std::convert::Infallible,
|
1655 1666 | > + Clone
|
1656 1667 | + Send
|
1657 1668 | + 'static,
|
1658 1669 | S::Future: Send + 'static,
|
1659 1670 | {
|
1660 - | self.endpoint_operation = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1671 + | self.duplex_stream_with_distinct_streams =
|
1672 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1661 1673 | self
|
1662 1674 | }
|
1663 1675 |
|
1664 - | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
1676 + | /// Sets the [`DuplexStreamWithInitialMessages`](crate::operation_shape::DuplexStreamWithInitialMessages) operation.
|
1665 1677 | ///
|
1666 1678 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1667 1679 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1668 1680 | ///
|
1669 1681 | /// # Example
|
1670 1682 | ///
|
1671 1683 | /// ```no_run
|
1672 1684 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1673 1685 | ///
|
1674 1686 | /// use rest_json_http0x::{input, output, error};
|
1675 1687 | ///
|
1676 - | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
1688 + | /// async fn handler(input: input::DuplexStreamWithInitialMessagesInput) -> Result<output::DuplexStreamWithInitialMessagesOutput, error::DuplexStreamWithInitialMessagesError> {
|
1677 1689 | /// todo!()
|
1678 1690 | /// }
|
1679 1691 | ///
|
1680 1692 | /// let config = RestJsonConfig::builder().build();
|
1681 1693 | /// let app = RestJson::builder(config)
|
1682 - | /// .endpoint_with_host_label_operation(handler)
|
1694 + | /// .duplex_stream_with_initial_messages(handler)
|
1683 1695 | /// /* Set other handlers */
|
1684 1696 | /// .build()
|
1685 1697 | /// .unwrap();
|
1686 1698 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1687 1699 | /// ```
|
1688 1700 | ///
|
1689 - | pub fn endpoint_with_host_label_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1701 + | pub fn duplex_stream_with_initial_messages<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1690 1702 | where
|
1691 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointWithHostLabelOperation, HandlerExtractors>,
|
1703 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DuplexStreamWithInitialMessages, HandlerExtractors>,
|
1692 1704 |
|
1693 1705 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1694 1706 | RestJson<L>,
|
1695 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1696 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointWithHostLabelOperation, HandlerType>
|
1707 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1708 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DuplexStreamWithInitialMessages, HandlerType>
|
1697 1709 | >,
|
1698 1710 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1699 1711 | RestJson<L>,
|
1700 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1712 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1701 1713 | ModelPl::Output
|
1702 1714 | >,
|
1703 1715 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1704 1716 | RestJson<L>,
|
1705 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1717 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1706 1718 | <
|
1707 1719 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1708 1720 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1709 1721 | RestJson<L>,
|
1710 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1722 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1711 1723 | ModelPl::Output
|
1712 1724 | >
|
1713 1725 | >::Output
|
1714 1726 | >,
|
1715 1727 |
|
1716 1728 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1717 1729 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1718 1730 |
|
1719 1731 | {
|
1720 1732 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1721 1733 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1722 - | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_handler(handler);
|
1734 + | let svc = crate::operation_shape::DuplexStreamWithInitialMessages::from_handler(handler);
|
1723 1735 | let svc = self.model_plugin.apply(svc);
|
1724 1736 | let svc =
|
1725 1737 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1726 1738 | .apply(svc);
|
1727 1739 | let svc = self.http_plugin.apply(svc);
|
1728 - | self.endpoint_with_host_label_operation_custom(svc)
|
1740 + | self.duplex_stream_with_initial_messages_custom(svc)
|
1729 1741 | }
|
1730 1742 |
|
1731 - | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
1743 + | /// Sets the [`DuplexStreamWithInitialMessages`](crate::operation_shape::DuplexStreamWithInitialMessages) operation.
|
1732 1744 | ///
|
1733 1745 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1734 1746 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1735 1747 | ///
|
1736 1748 | /// # Example
|
1737 1749 | ///
|
1738 1750 | /// ```no_run
|
1739 1751 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1740 1752 | ///
|
1741 1753 | /// use rest_json_http0x::{input, output, error};
|
1742 1754 | ///
|
1743 - | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
1755 + | /// async fn handler(input: input::DuplexStreamWithInitialMessagesInput) -> Result<output::DuplexStreamWithInitialMessagesOutput, error::DuplexStreamWithInitialMessagesError> {
|
1744 1756 | /// todo!()
|
1745 1757 | /// }
|
1746 1758 | ///
|
1747 1759 | /// let config = RestJsonConfig::builder().build();
|
1748 1760 | /// let svc = ::tower::util::service_fn(handler);
|
1749 1761 | /// let app = RestJson::builder(config)
|
1750 - | /// .endpoint_with_host_label_operation_service(svc)
|
1762 + | /// .duplex_stream_with_initial_messages_service(svc)
|
1751 1763 | /// /* Set other handlers */
|
1752 1764 | /// .build()
|
1753 1765 | /// .unwrap();
|
1754 1766 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1755 1767 | /// ```
|
1756 1768 | ///
|
1757 - | pub fn endpoint_with_host_label_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1769 + | pub fn duplex_stream_with_initial_messages_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1758 1770 | where
|
1759 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointWithHostLabelOperation, ServiceExtractors>,
|
1771 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DuplexStreamWithInitialMessages, ServiceExtractors>,
|
1760 1772 |
|
1761 1773 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1762 1774 | RestJson<L>,
|
1763 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1764 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointWithHostLabelOperation, S>
|
1775 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1776 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DuplexStreamWithInitialMessages, S>
|
1765 1777 | >,
|
1766 1778 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1767 1779 | RestJson<L>,
|
1768 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1780 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1769 1781 | ModelPl::Output
|
1770 1782 | >,
|
1771 1783 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1772 1784 | RestJson<L>,
|
1773 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1785 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1774 1786 | <
|
1775 1787 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1776 1788 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1777 1789 | RestJson<L>,
|
1778 - | crate::operation_shape::EndpointWithHostLabelOperation,
|
1790 + | crate::operation_shape::DuplexStreamWithInitialMessages,
|
1779 1791 | ModelPl::Output
|
1780 1792 | >
|
1781 1793 | >::Output
|
1782 1794 | >,
|
1783 1795 |
|
1784 1796 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1785 1797 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1786 1798 |
|
1787 1799 | {
|
1788 1800 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1789 1801 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1790 - | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_service(service);
|
1802 + | let svc = crate::operation_shape::DuplexStreamWithInitialMessages::from_service(service);
|
1791 1803 | let svc = self.model_plugin.apply(svc);
|
1792 1804 | let svc =
|
1793 1805 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1794 1806 | .apply(svc);
|
1795 1807 | let svc = self.http_plugin.apply(svc);
|
1796 - | self.endpoint_with_host_label_operation_custom(svc)
|
1808 + | self.duplex_stream_with_initial_messages_custom(svc)
|
1797 1809 | }
|
1798 1810 |
|
1799 - | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) to a custom [`Service`](tower::Service).
|
1811 + | /// Sets the [`DuplexStreamWithInitialMessages`](crate::operation_shape::DuplexStreamWithInitialMessages) to a custom [`Service`](tower::Service).
|
1800 1812 | /// not constrained by the Smithy contract.
|
1801 - | fn endpoint_with_host_label_operation_custom<S>(mut self, svc: S) -> Self
|
1813 + | fn duplex_stream_with_initial_messages_custom<S>(mut self, svc: S) -> Self
|
1802 1814 | where
|
1803 1815 | S: ::tower::Service<
|
1804 1816 | ::http::Request<Body>,
|
1805 1817 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1806 1818 | Error = ::std::convert::Infallible,
|
1807 1819 | > + Clone
|
1808 1820 | + Send
|
1809 1821 | + 'static,
|
1810 1822 | S::Future: Send + 'static,
|
1811 1823 | {
|
1812 - | self.endpoint_with_host_label_operation =
|
1824 + | self.duplex_stream_with_initial_messages =
|
1813 1825 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1814 1826 | self
|
1815 1827 | }
|
1816 1828 |
|
1817 - | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
1829 + | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1818 1830 | ///
|
1819 1831 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1820 1832 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1821 1833 | ///
|
1822 1834 | /// # Example
|
1823 1835 | ///
|
1824 1836 | /// ```no_run
|
1825 1837 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1826 1838 | ///
|
1827 1839 | /// use rest_json_http0x::{input, output, error};
|
1828 1840 | ///
|
1829 - | /// async fn handler(input: input::FractionalSecondsInput) -> output::FractionalSecondsOutput {
|
1841 + | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> output::EmptyInputAndEmptyOutputOutput {
|
1830 1842 | /// todo!()
|
1831 1843 | /// }
|
1832 1844 | ///
|
1833 1845 | /// let config = RestJsonConfig::builder().build();
|
1834 1846 | /// let app = RestJson::builder(config)
|
1835 - | /// .fractional_seconds(handler)
|
1847 + | /// .empty_input_and_empty_output(handler)
|
1836 1848 | /// /* Set other handlers */
|
1837 1849 | /// .build()
|
1838 1850 | /// .unwrap();
|
1839 1851 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1840 1852 | /// ```
|
1841 1853 | ///
|
1842 - | pub fn fractional_seconds<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1854 + | pub fn empty_input_and_empty_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1843 1855 | where
|
1844 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::FractionalSeconds, HandlerExtractors>,
|
1856 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerExtractors>,
|
1845 1857 |
|
1846 1858 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1847 1859 | RestJson<L>,
|
1848 - | crate::operation_shape::FractionalSeconds,
|
1849 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::FractionalSeconds, HandlerType>
|
1860 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1861 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerType>
|
1850 1862 | >,
|
1851 1863 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1852 1864 | RestJson<L>,
|
1853 - | crate::operation_shape::FractionalSeconds,
|
1865 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1854 1866 | ModelPl::Output
|
1855 1867 | >,
|
1856 1868 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1857 1869 | RestJson<L>,
|
1858 - | crate::operation_shape::FractionalSeconds,
|
1870 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1859 1871 | <
|
1860 1872 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1861 1873 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1862 1874 | RestJson<L>,
|
1863 - | crate::operation_shape::FractionalSeconds,
|
1875 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1864 1876 | ModelPl::Output
|
1865 1877 | >
|
1866 1878 | >::Output
|
1867 1879 | >,
|
1868 1880 |
|
1869 1881 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1870 1882 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1871 1883 |
|
1872 1884 | {
|
1873 1885 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1874 1886 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1875 - | let svc = crate::operation_shape::FractionalSeconds::from_handler(handler);
|
1887 + | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_handler(handler);
|
1876 1888 | let svc = self.model_plugin.apply(svc);
|
1877 1889 | let svc =
|
1878 1890 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1879 1891 | .apply(svc);
|
1880 1892 | let svc = self.http_plugin.apply(svc);
|
1881 - | self.fractional_seconds_custom(svc)
|
1893 + | self.empty_input_and_empty_output_custom(svc)
|
1882 1894 | }
|
1883 1895 |
|
1884 - | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
1896 + | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1885 1897 | ///
|
1886 1898 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1887 1899 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1888 1900 | ///
|
1889 1901 | /// # Example
|
1890 1902 | ///
|
1891 1903 | /// ```no_run
|
1892 1904 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1893 1905 | ///
|
1894 1906 | /// use rest_json_http0x::{input, output, error};
|
1895 1907 | ///
|
1896 - | /// async fn handler(input: input::FractionalSecondsInput) -> Result<output::FractionalSecondsOutput, std::convert::Infallible> {
|
1908 + | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> Result<output::EmptyInputAndEmptyOutputOutput, std::convert::Infallible> {
|
1897 1909 | /// todo!()
|
1898 1910 | /// }
|
1899 1911 | ///
|
1900 1912 | /// let config = RestJsonConfig::builder().build();
|
1901 1913 | /// let svc = ::tower::util::service_fn(handler);
|
1902 1914 | /// let app = RestJson::builder(config)
|
1903 - | /// .fractional_seconds_service(svc)
|
1915 + | /// .empty_input_and_empty_output_service(svc)
|
1904 1916 | /// /* Set other handlers */
|
1905 1917 | /// .build()
|
1906 1918 | /// .unwrap();
|
1907 1919 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1908 1920 | /// ```
|
1909 1921 | ///
|
1910 - | pub fn fractional_seconds_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1922 + | pub fn empty_input_and_empty_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1911 1923 | where
|
1912 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::FractionalSeconds, ServiceExtractors>,
|
1924 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EmptyInputAndEmptyOutput, ServiceExtractors>,
|
1913 1925 |
|
1914 1926 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1915 1927 | RestJson<L>,
|
1916 - | crate::operation_shape::FractionalSeconds,
|
1917 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::FractionalSeconds, S>
|
1928 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1929 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EmptyInputAndEmptyOutput, S>
|
1918 1930 | >,
|
1919 1931 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1920 1932 | RestJson<L>,
|
1921 - | crate::operation_shape::FractionalSeconds,
|
1933 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1922 1934 | ModelPl::Output
|
1923 1935 | >,
|
1924 1936 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1925 1937 | RestJson<L>,
|
1926 - | crate::operation_shape::FractionalSeconds,
|
1938 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1927 1939 | <
|
1928 1940 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1929 1941 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1930 1942 | RestJson<L>,
|
1931 - | crate::operation_shape::FractionalSeconds,
|
1943 + | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1932 1944 | ModelPl::Output
|
1933 1945 | >
|
1934 1946 | >::Output
|
1935 1947 | >,
|
1936 1948 |
|
1937 1949 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1938 1950 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1939 1951 |
|
1940 1952 | {
|
1941 1953 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1942 1954 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1943 - | let svc = crate::operation_shape::FractionalSeconds::from_service(service);
|
1955 + | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_service(service);
|
1944 1956 | let svc = self.model_plugin.apply(svc);
|
1945 1957 | let svc =
|
1946 1958 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1947 1959 | .apply(svc);
|
1948 1960 | let svc = self.http_plugin.apply(svc);
|
1949 - | self.fractional_seconds_custom(svc)
|
1961 + | self.empty_input_and_empty_output_custom(svc)
|
1950 1962 | }
|
1951 1963 |
|
1952 - | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) to a custom [`Service`](tower::Service).
|
1964 + | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) to a custom [`Service`](tower::Service).
|
1953 1965 | /// not constrained by the Smithy contract.
|
1954 - | fn fractional_seconds_custom<S>(mut self, svc: S) -> Self
|
1966 + | fn empty_input_and_empty_output_custom<S>(mut self, svc: S) -> Self
|
1955 1967 | where
|
1956 1968 | S: ::tower::Service<
|
1957 1969 | ::http::Request<Body>,
|
1958 1970 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1959 1971 | Error = ::std::convert::Infallible,
|
1960 1972 | > + Clone
|
1961 1973 | + Send
|
1962 1974 | + 'static,
|
1963 1975 | S::Future: Send + 'static,
|
1964 1976 | {
|
1965 - | self.fractional_seconds = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1977 + | self.empty_input_and_empty_output =
|
1978 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1966 1979 | self
|
1967 1980 | }
|
1968 1981 |
|
1969 - | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
1982 + | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
1970 1983 | ///
|
1971 1984 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1972 1985 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1973 1986 | ///
|
1974 1987 | /// # Example
|
1975 1988 | ///
|
1976 1989 | /// ```no_run
|
1977 1990 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
1978 1991 | ///
|
1979 1992 | /// use rest_json_http0x::{input, output, error};
|
1980 1993 | ///
|
1981 - | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
1994 + | /// async fn handler(input: input::EndpointOperationInput) -> output::EndpointOperationOutput {
|
1982 1995 | /// todo!()
|
1983 1996 | /// }
|
1984 1997 | ///
|
1985 1998 | /// let config = RestJsonConfig::builder().build();
|
1986 1999 | /// let app = RestJson::builder(config)
|
1987 - | /// .greeting_with_errors(handler)
|
2000 + | /// .endpoint_operation(handler)
|
1988 2001 | /// /* Set other handlers */
|
1989 2002 | /// .build()
|
1990 2003 | /// .unwrap();
|
1991 2004 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1992 2005 | /// ```
|
1993 2006 | ///
|
1994 - | pub fn greeting_with_errors<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2007 + | pub fn endpoint_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1995 2008 | where
|
1996 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::GreetingWithErrors, HandlerExtractors>,
|
2009 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointOperation, HandlerExtractors>,
|
1997 2010 |
|
1998 2011 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1999 2012 | RestJson<L>,
|
2000 - | crate::operation_shape::GreetingWithErrors,
|
2001 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::GreetingWithErrors, HandlerType>
|
2013 + | crate::operation_shape::EndpointOperation,
|
2014 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointOperation, HandlerType>
|
2002 2015 | >,
|
2003 2016 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2004 2017 | RestJson<L>,
|
2005 - | crate::operation_shape::GreetingWithErrors,
|
2018 + | crate::operation_shape::EndpointOperation,
|
2006 2019 | ModelPl::Output
|
2007 2020 | >,
|
2008 2021 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2009 2022 | RestJson<L>,
|
2010 - | crate::operation_shape::GreetingWithErrors,
|
2023 + | crate::operation_shape::EndpointOperation,
|
2011 2024 | <
|
2012 2025 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2013 2026 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2014 2027 | RestJson<L>,
|
2015 - | crate::operation_shape::GreetingWithErrors,
|
2028 + | crate::operation_shape::EndpointOperation,
|
2016 2029 | ModelPl::Output
|
2017 2030 | >
|
2018 2031 | >::Output
|
2019 2032 | >,
|
2020 2033 |
|
2021 2034 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2022 2035 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2023 2036 |
|
2024 2037 | {
|
2025 2038 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2026 2039 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2027 - | let svc = crate::operation_shape::GreetingWithErrors::from_handler(handler);
|
2040 + | let svc = crate::operation_shape::EndpointOperation::from_handler(handler);
|
2028 2041 | let svc = self.model_plugin.apply(svc);
|
2029 2042 | let svc =
|
2030 2043 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2031 2044 | .apply(svc);
|
2032 2045 | let svc = self.http_plugin.apply(svc);
|
2033 - | self.greeting_with_errors_custom(svc)
|
2046 + | self.endpoint_operation_custom(svc)
|
2034 2047 | }
|
2035 2048 |
|
2036 - | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
2049 + | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
2037 2050 | ///
|
2038 2051 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2039 2052 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2040 2053 | ///
|
2041 2054 | /// # Example
|
2042 2055 | ///
|
2043 2056 | /// ```no_run
|
2044 2057 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2045 2058 | ///
|
2046 2059 | /// use rest_json_http0x::{input, output, error};
|
2047 2060 | ///
|
2048 - | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
2061 + | /// async fn handler(input: input::EndpointOperationInput) -> Result<output::EndpointOperationOutput, std::convert::Infallible> {
|
2049 2062 | /// todo!()
|
2050 2063 | /// }
|
2051 2064 | ///
|
2052 2065 | /// let config = RestJsonConfig::builder().build();
|
2053 2066 | /// let svc = ::tower::util::service_fn(handler);
|
2054 2067 | /// let app = RestJson::builder(config)
|
2055 - | /// .greeting_with_errors_service(svc)
|
2068 + | /// .endpoint_operation_service(svc)
|
2056 2069 | /// /* Set other handlers */
|
2057 2070 | /// .build()
|
2058 2071 | /// .unwrap();
|
2059 2072 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2060 2073 | /// ```
|
2061 2074 | ///
|
2062 - | pub fn greeting_with_errors_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2075 + | pub fn endpoint_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2063 2076 | where
|
2064 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::GreetingWithErrors, ServiceExtractors>,
|
2077 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointOperation, ServiceExtractors>,
|
2065 2078 |
|
2066 2079 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2067 2080 | RestJson<L>,
|
2068 - | crate::operation_shape::GreetingWithErrors,
|
2069 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::GreetingWithErrors, S>
|
2081 + | crate::operation_shape::EndpointOperation,
|
2082 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointOperation, S>
|
2070 2083 | >,
|
2071 2084 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2072 2085 | RestJson<L>,
|
2073 - | crate::operation_shape::GreetingWithErrors,
|
2086 + | crate::operation_shape::EndpointOperation,
|
2074 2087 | ModelPl::Output
|
2075 2088 | >,
|
2076 2089 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2077 2090 | RestJson<L>,
|
2078 - | crate::operation_shape::GreetingWithErrors,
|
2091 + | crate::operation_shape::EndpointOperation,
|
2079 2092 | <
|
2080 2093 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2081 2094 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2082 2095 | RestJson<L>,
|
2083 - | crate::operation_shape::GreetingWithErrors,
|
2096 + | crate::operation_shape::EndpointOperation,
|
2084 2097 | ModelPl::Output
|
2085 2098 | >
|
2086 2099 | >::Output
|
2087 2100 | >,
|
2088 2101 |
|
2089 2102 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2090 2103 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2091 2104 |
|
2092 2105 | {
|
2093 2106 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2094 2107 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2095 - | let svc = crate::operation_shape::GreetingWithErrors::from_service(service);
|
2108 + | let svc = crate::operation_shape::EndpointOperation::from_service(service);
|
2096 2109 | let svc = self.model_plugin.apply(svc);
|
2097 2110 | let svc =
|
2098 2111 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2099 2112 | .apply(svc);
|
2100 2113 | let svc = self.http_plugin.apply(svc);
|
2101 - | self.greeting_with_errors_custom(svc)
|
2114 + | self.endpoint_operation_custom(svc)
|
2102 2115 | }
|
2103 2116 |
|
2104 - | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) to a custom [`Service`](tower::Service).
|
2117 + | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) to a custom [`Service`](tower::Service).
|
2105 2118 | /// not constrained by the Smithy contract.
|
2106 - | fn greeting_with_errors_custom<S>(mut self, svc: S) -> Self
|
2119 + | fn endpoint_operation_custom<S>(mut self, svc: S) -> Self
|
2107 2120 | where
|
2108 2121 | S: ::tower::Service<
|
2109 2122 | ::http::Request<Body>,
|
2110 2123 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2111 2124 | Error = ::std::convert::Infallible,
|
2112 2125 | > + Clone
|
2113 2126 | + Send
|
2114 2127 | + 'static,
|
2115 2128 | S::Future: Send + 'static,
|
2116 2129 | {
|
2117 - | self.greeting_with_errors = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2130 + | self.endpoint_operation = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2118 2131 | self
|
2119 2132 | }
|
2120 2133 |
|
2121 - | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2134 + | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
2122 2135 | ///
|
2123 2136 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2124 2137 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2125 2138 | ///
|
2126 2139 | /// # Example
|
2127 2140 | ///
|
2128 2141 | /// ```no_run
|
2129 2142 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2130 2143 | ///
|
2131 2144 | /// use rest_json_http0x::{input, output, error};
|
2132 2145 | ///
|
2133 - | /// async fn handler(input: input::HostWithPathOperationInput) -> output::HostWithPathOperationOutput {
|
2146 + | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
2134 2147 | /// todo!()
|
2135 2148 | /// }
|
2136 2149 | ///
|
2137 2150 | /// let config = RestJsonConfig::builder().build();
|
2138 2151 | /// let app = RestJson::builder(config)
|
2139 - | /// .host_with_path_operation(handler)
|
2152 + | /// .endpoint_with_host_label_operation(handler)
|
2140 2153 | /// /* Set other handlers */
|
2141 2154 | /// .build()
|
2142 2155 | /// .unwrap();
|
2143 2156 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2144 2157 | /// ```
|
2145 2158 | ///
|
2146 - | pub fn host_with_path_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2159 + | pub fn endpoint_with_host_label_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2147 2160 | where
|
2148 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HostWithPathOperation, HandlerExtractors>,
|
2161 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointWithHostLabelOperation, HandlerExtractors>,
|
2149 2162 |
|
2150 2163 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2151 2164 | RestJson<L>,
|
2152 - | crate::operation_shape::HostWithPathOperation,
|
2153 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HostWithPathOperation, HandlerType>
|
2165 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2166 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointWithHostLabelOperation, HandlerType>
|
2154 2167 | >,
|
2155 2168 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2156 2169 | RestJson<L>,
|
2157 - | crate::operation_shape::HostWithPathOperation,
|
2170 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2158 2171 | ModelPl::Output
|
2159 2172 | >,
|
2160 2173 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2161 2174 | RestJson<L>,
|
2162 - | crate::operation_shape::HostWithPathOperation,
|
2175 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2163 2176 | <
|
2164 2177 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2165 2178 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2166 2179 | RestJson<L>,
|
2167 - | crate::operation_shape::HostWithPathOperation,
|
2180 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2168 2181 | ModelPl::Output
|
2169 2182 | >
|
2170 2183 | >::Output
|
2171 2184 | >,
|
2172 2185 |
|
2173 2186 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2174 2187 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2175 2188 |
|
2176 2189 | {
|
2177 2190 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2178 2191 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2179 - | let svc = crate::operation_shape::HostWithPathOperation::from_handler(handler);
|
2192 + | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_handler(handler);
|
2180 2193 | let svc = self.model_plugin.apply(svc);
|
2181 2194 | let svc =
|
2182 2195 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2183 2196 | .apply(svc);
|
2184 2197 | let svc = self.http_plugin.apply(svc);
|
2185 - | self.host_with_path_operation_custom(svc)
|
2198 + | self.endpoint_with_host_label_operation_custom(svc)
|
2186 2199 | }
|
2187 2200 |
|
2188 - | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2201 + | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
2189 2202 | ///
|
2190 2203 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2191 2204 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2192 2205 | ///
|
2193 2206 | /// # Example
|
2194 2207 | ///
|
2195 2208 | /// ```no_run
|
2196 2209 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2197 2210 | ///
|
2198 2211 | /// use rest_json_http0x::{input, output, error};
|
2199 2212 | ///
|
2200 - | /// async fn handler(input: input::HostWithPathOperationInput) -> Result<output::HostWithPathOperationOutput, std::convert::Infallible> {
|
2213 + | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
2201 2214 | /// todo!()
|
2202 2215 | /// }
|
2203 2216 | ///
|
2204 2217 | /// let config = RestJsonConfig::builder().build();
|
2205 2218 | /// let svc = ::tower::util::service_fn(handler);
|
2206 2219 | /// let app = RestJson::builder(config)
|
2207 - | /// .host_with_path_operation_service(svc)
|
2220 + | /// .endpoint_with_host_label_operation_service(svc)
|
2208 2221 | /// /* Set other handlers */
|
2209 2222 | /// .build()
|
2210 2223 | /// .unwrap();
|
2211 2224 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2212 2225 | /// ```
|
2213 2226 | ///
|
2214 - | pub fn host_with_path_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2227 + | pub fn endpoint_with_host_label_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2215 2228 | where
|
2216 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HostWithPathOperation, ServiceExtractors>,
|
2229 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointWithHostLabelOperation, ServiceExtractors>,
|
2217 2230 |
|
2218 2231 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2219 2232 | RestJson<L>,
|
2220 - | crate::operation_shape::HostWithPathOperation,
|
2221 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HostWithPathOperation, S>
|
2233 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2234 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointWithHostLabelOperation, S>
|
2222 2235 | >,
|
2223 2236 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2224 2237 | RestJson<L>,
|
2225 - | crate::operation_shape::HostWithPathOperation,
|
2238 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2226 2239 | ModelPl::Output
|
2227 2240 | >,
|
2228 2241 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2229 2242 | RestJson<L>,
|
2230 - | crate::operation_shape::HostWithPathOperation,
|
2243 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2231 2244 | <
|
2232 2245 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2233 2246 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2234 2247 | RestJson<L>,
|
2235 - | crate::operation_shape::HostWithPathOperation,
|
2248 + | crate::operation_shape::EndpointWithHostLabelOperation,
|
2236 2249 | ModelPl::Output
|
2237 2250 | >
|
2238 2251 | >::Output
|
2239 2252 | >,
|
2240 2253 |
|
2241 2254 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2242 2255 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2243 2256 |
|
2244 2257 | {
|
2245 2258 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2246 2259 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2247 - | let svc = crate::operation_shape::HostWithPathOperation::from_service(service);
|
2260 + | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_service(service);
|
2248 2261 | let svc = self.model_plugin.apply(svc);
|
2249 2262 | let svc =
|
2250 2263 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2251 2264 | .apply(svc);
|
2252 2265 | let svc = self.http_plugin.apply(svc);
|
2253 - | self.host_with_path_operation_custom(svc)
|
2266 + | self.endpoint_with_host_label_operation_custom(svc)
|
2254 2267 | }
|
2255 2268 |
|
2256 - | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) to a custom [`Service`](tower::Service).
|
2269 + | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) to a custom [`Service`](tower::Service).
|
2257 2270 | /// not constrained by the Smithy contract.
|
2258 - | fn host_with_path_operation_custom<S>(mut self, svc: S) -> Self
|
2271 + | fn endpoint_with_host_label_operation_custom<S>(mut self, svc: S) -> Self
|
2259 2272 | where
|
2260 2273 | S: ::tower::Service<
|
2261 2274 | ::http::Request<Body>,
|
2262 2275 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2263 2276 | Error = ::std::convert::Infallible,
|
2264 2277 | > + Clone
|
2265 2278 | + Send
|
2266 2279 | + 'static,
|
2267 2280 | S::Future: Send + 'static,
|
2268 2281 | {
|
2269 - | self.host_with_path_operation =
|
2282 + | self.endpoint_with_host_label_operation =
|
2270 2283 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2271 2284 | self
|
2272 2285 | }
|
2273 2286 |
|
2274 - | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
2287 + | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
2275 2288 | ///
|
2276 2289 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2277 2290 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2278 2291 | ///
|
2279 2292 | /// # Example
|
2280 2293 | ///
|
2281 2294 | /// ```no_run
|
2282 2295 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2283 2296 | ///
|
2284 2297 | /// use rest_json_http0x::{input, output, error};
|
2285 2298 | ///
|
2286 - | /// async fn handler(input: input::HttpChecksumRequiredInput) -> output::HttpChecksumRequiredOutput {
|
2299 + | /// async fn handler(input: input::FractionalSecondsInput) -> output::FractionalSecondsOutput {
|
2287 2300 | /// todo!()
|
2288 2301 | /// }
|
2289 2302 | ///
|
2290 2303 | /// let config = RestJsonConfig::builder().build();
|
2291 2304 | /// let app = RestJson::builder(config)
|
2292 - | /// .http_checksum_required(handler)
|
2305 + | /// .fractional_seconds(handler)
|
2306 + | /// /* Set other handlers */
|
2307 + | /// .build()
|
2308 + | /// .unwrap();
|
2309 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2310 + | /// ```
|
2311 + | ///
|
2312 + | pub fn fractional_seconds<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2313 + | where
|
2314 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::FractionalSeconds, HandlerExtractors>,
|
2315 + |
|
2316 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2317 + | RestJson<L>,
|
2318 + | crate::operation_shape::FractionalSeconds,
|
2319 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::FractionalSeconds, HandlerType>
|
2320 + | >,
|
2321 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2322 + | RestJson<L>,
|
2323 + | crate::operation_shape::FractionalSeconds,
|
2324 + | ModelPl::Output
|
2325 + | >,
|
2326 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2327 + | RestJson<L>,
|
2328 + | crate::operation_shape::FractionalSeconds,
|
2329 + | <
|
2330 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2331 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2332 + | RestJson<L>,
|
2333 + | crate::operation_shape::FractionalSeconds,
|
2334 + | ModelPl::Output
|
2335 + | >
|
2336 + | >::Output
|
2337 + | >,
|
2338 + |
|
2339 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2340 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2341 + |
|
2342 + | {
|
2343 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2344 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2345 + | let svc = crate::operation_shape::FractionalSeconds::from_handler(handler);
|
2346 + | let svc = self.model_plugin.apply(svc);
|
2347 + | let svc =
|
2348 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2349 + | .apply(svc);
|
2350 + | let svc = self.http_plugin.apply(svc);
|
2351 + | self.fractional_seconds_custom(svc)
|
2352 + | }
|
2353 + |
|
2354 + | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
2355 + | ///
|
2356 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2357 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2358 + | ///
|
2359 + | /// # Example
|
2360 + | ///
|
2361 + | /// ```no_run
|
2362 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2363 + | ///
|
2364 + | /// use rest_json_http0x::{input, output, error};
|
2365 + | ///
|
2366 + | /// async fn handler(input: input::FractionalSecondsInput) -> Result<output::FractionalSecondsOutput, std::convert::Infallible> {
|
2367 + | /// todo!()
|
2368 + | /// }
|
2369 + | ///
|
2370 + | /// let config = RestJsonConfig::builder().build();
|
2371 + | /// let svc = ::tower::util::service_fn(handler);
|
2372 + | /// let app = RestJson::builder(config)
|
2373 + | /// .fractional_seconds_service(svc)
|
2374 + | /// /* Set other handlers */
|
2375 + | /// .build()
|
2376 + | /// .unwrap();
|
2377 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2378 + | /// ```
|
2379 + | ///
|
2380 + | pub fn fractional_seconds_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2381 + | where
|
2382 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::FractionalSeconds, ServiceExtractors>,
|
2383 + |
|
2384 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2385 + | RestJson<L>,
|
2386 + | crate::operation_shape::FractionalSeconds,
|
2387 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::FractionalSeconds, S>
|
2388 + | >,
|
2389 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2390 + | RestJson<L>,
|
2391 + | crate::operation_shape::FractionalSeconds,
|
2392 + | ModelPl::Output
|
2393 + | >,
|
2394 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2395 + | RestJson<L>,
|
2396 + | crate::operation_shape::FractionalSeconds,
|
2397 + | <
|
2398 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2399 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2400 + | RestJson<L>,
|
2401 + | crate::operation_shape::FractionalSeconds,
|
2402 + | ModelPl::Output
|
2403 + | >
|
2404 + | >::Output
|
2405 + | >,
|
2406 + |
|
2407 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2408 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2409 + |
|
2410 + | {
|
2411 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2412 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2413 + | let svc = crate::operation_shape::FractionalSeconds::from_service(service);
|
2414 + | let svc = self.model_plugin.apply(svc);
|
2415 + | let svc =
|
2416 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2417 + | .apply(svc);
|
2418 + | let svc = self.http_plugin.apply(svc);
|
2419 + | self.fractional_seconds_custom(svc)
|
2420 + | }
|
2421 + |
|
2422 + | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) to a custom [`Service`](tower::Service).
|
2423 + | /// not constrained by the Smithy contract.
|
2424 + | fn fractional_seconds_custom<S>(mut self, svc: S) -> Self
|
2425 + | where
|
2426 + | S: ::tower::Service<
|
2427 + | ::http::Request<Body>,
|
2428 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2429 + | Error = ::std::convert::Infallible,
|
2430 + | > + Clone
|
2431 + | + Send
|
2432 + | + 'static,
|
2433 + | S::Future: Send + 'static,
|
2434 + | {
|
2435 + | self.fractional_seconds = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2436 + | self
|
2437 + | }
|
2438 + |
|
2439 + | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
2440 + | ///
|
2441 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2442 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2443 + | ///
|
2444 + | /// # Example
|
2445 + | ///
|
2446 + | /// ```no_run
|
2447 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2448 + | ///
|
2449 + | /// use rest_json_http0x::{input, output, error};
|
2450 + | ///
|
2451 + | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
2452 + | /// todo!()
|
2453 + | /// }
|
2454 + | ///
|
2455 + | /// let config = RestJsonConfig::builder().build();
|
2456 + | /// let app = RestJson::builder(config)
|
2457 + | /// .greeting_with_errors(handler)
|
2458 + | /// /* Set other handlers */
|
2459 + | /// .build()
|
2460 + | /// .unwrap();
|
2461 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2462 + | /// ```
|
2463 + | ///
|
2464 + | pub fn greeting_with_errors<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2465 + | where
|
2466 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::GreetingWithErrors, HandlerExtractors>,
|
2467 + |
|
2468 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2469 + | RestJson<L>,
|
2470 + | crate::operation_shape::GreetingWithErrors,
|
2471 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::GreetingWithErrors, HandlerType>
|
2472 + | >,
|
2473 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2474 + | RestJson<L>,
|
2475 + | crate::operation_shape::GreetingWithErrors,
|
2476 + | ModelPl::Output
|
2477 + | >,
|
2478 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2479 + | RestJson<L>,
|
2480 + | crate::operation_shape::GreetingWithErrors,
|
2481 + | <
|
2482 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2483 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2484 + | RestJson<L>,
|
2485 + | crate::operation_shape::GreetingWithErrors,
|
2486 + | ModelPl::Output
|
2487 + | >
|
2488 + | >::Output
|
2489 + | >,
|
2490 + |
|
2491 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2492 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2493 + |
|
2494 + | {
|
2495 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2496 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2497 + | let svc = crate::operation_shape::GreetingWithErrors::from_handler(handler);
|
2498 + | let svc = self.model_plugin.apply(svc);
|
2499 + | let svc =
|
2500 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2501 + | .apply(svc);
|
2502 + | let svc = self.http_plugin.apply(svc);
|
2503 + | self.greeting_with_errors_custom(svc)
|
2504 + | }
|
2505 + |
|
2506 + | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
2507 + | ///
|
2508 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2509 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2510 + | ///
|
2511 + | /// # Example
|
2512 + | ///
|
2513 + | /// ```no_run
|
2514 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2515 + | ///
|
2516 + | /// use rest_json_http0x::{input, output, error};
|
2517 + | ///
|
2518 + | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
2519 + | /// todo!()
|
2520 + | /// }
|
2521 + | ///
|
2522 + | /// let config = RestJsonConfig::builder().build();
|
2523 + | /// let svc = ::tower::util::service_fn(handler);
|
2524 + | /// let app = RestJson::builder(config)
|
2525 + | /// .greeting_with_errors_service(svc)
|
2526 + | /// /* Set other handlers */
|
2527 + | /// .build()
|
2528 + | /// .unwrap();
|
2529 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2530 + | /// ```
|
2531 + | ///
|
2532 + | pub fn greeting_with_errors_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2533 + | where
|
2534 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::GreetingWithErrors, ServiceExtractors>,
|
2535 + |
|
2536 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2537 + | RestJson<L>,
|
2538 + | crate::operation_shape::GreetingWithErrors,
|
2539 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::GreetingWithErrors, S>
|
2540 + | >,
|
2541 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2542 + | RestJson<L>,
|
2543 + | crate::operation_shape::GreetingWithErrors,
|
2544 + | ModelPl::Output
|
2545 + | >,
|
2546 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2547 + | RestJson<L>,
|
2548 + | crate::operation_shape::GreetingWithErrors,
|
2549 + | <
|
2550 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2551 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2552 + | RestJson<L>,
|
2553 + | crate::operation_shape::GreetingWithErrors,
|
2554 + | ModelPl::Output
|
2555 + | >
|
2556 + | >::Output
|
2557 + | >,
|
2558 + |
|
2559 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2560 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2561 + |
|
2562 + | {
|
2563 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2564 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2565 + | let svc = crate::operation_shape::GreetingWithErrors::from_service(service);
|
2566 + | let svc = self.model_plugin.apply(svc);
|
2567 + | let svc =
|
2568 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2569 + | .apply(svc);
|
2570 + | let svc = self.http_plugin.apply(svc);
|
2571 + | self.greeting_with_errors_custom(svc)
|
2572 + | }
|
2573 + |
|
2574 + | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) to a custom [`Service`](tower::Service).
|
2575 + | /// not constrained by the Smithy contract.
|
2576 + | fn greeting_with_errors_custom<S>(mut self, svc: S) -> Self
|
2577 + | where
|
2578 + | S: ::tower::Service<
|
2579 + | ::http::Request<Body>,
|
2580 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2581 + | Error = ::std::convert::Infallible,
|
2582 + | > + Clone
|
2583 + | + Send
|
2584 + | + 'static,
|
2585 + | S::Future: Send + 'static,
|
2586 + | {
|
2587 + | self.greeting_with_errors = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2588 + | self
|
2589 + | }
|
2590 + |
|
2591 + | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2592 + | ///
|
2593 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2594 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2595 + | ///
|
2596 + | /// # Example
|
2597 + | ///
|
2598 + | /// ```no_run
|
2599 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2600 + | ///
|
2601 + | /// use rest_json_http0x::{input, output, error};
|
2602 + | ///
|
2603 + | /// async fn handler(input: input::HostWithPathOperationInput) -> output::HostWithPathOperationOutput {
|
2604 + | /// todo!()
|
2605 + | /// }
|
2606 + | ///
|
2607 + | /// let config = RestJsonConfig::builder().build();
|
2608 + | /// let app = RestJson::builder(config)
|
2609 + | /// .host_with_path_operation(handler)
|
2610 + | /// /* Set other handlers */
|
2611 + | /// .build()
|
2612 + | /// .unwrap();
|
2613 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2614 + | /// ```
|
2615 + | ///
|
2616 + | pub fn host_with_path_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2617 + | where
|
2618 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HostWithPathOperation, HandlerExtractors>,
|
2619 + |
|
2620 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2621 + | RestJson<L>,
|
2622 + | crate::operation_shape::HostWithPathOperation,
|
2623 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HostWithPathOperation, HandlerType>
|
2624 + | >,
|
2625 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2626 + | RestJson<L>,
|
2627 + | crate::operation_shape::HostWithPathOperation,
|
2628 + | ModelPl::Output
|
2629 + | >,
|
2630 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2631 + | RestJson<L>,
|
2632 + | crate::operation_shape::HostWithPathOperation,
|
2633 + | <
|
2634 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2635 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2636 + | RestJson<L>,
|
2637 + | crate::operation_shape::HostWithPathOperation,
|
2638 + | ModelPl::Output
|
2639 + | >
|
2640 + | >::Output
|
2641 + | >,
|
2642 + |
|
2643 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2644 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2645 + |
|
2646 + | {
|
2647 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2648 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2649 + | let svc = crate::operation_shape::HostWithPathOperation::from_handler(handler);
|
2650 + | let svc = self.model_plugin.apply(svc);
|
2651 + | let svc =
|
2652 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2653 + | .apply(svc);
|
2654 + | let svc = self.http_plugin.apply(svc);
|
2655 + | self.host_with_path_operation_custom(svc)
|
2656 + | }
|
2657 + |
|
2658 + | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2659 + | ///
|
2660 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2661 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2662 + | ///
|
2663 + | /// # Example
|
2664 + | ///
|
2665 + | /// ```no_run
|
2666 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2667 + | ///
|
2668 + | /// use rest_json_http0x::{input, output, error};
|
2669 + | ///
|
2670 + | /// async fn handler(input: input::HostWithPathOperationInput) -> Result<output::HostWithPathOperationOutput, std::convert::Infallible> {
|
2671 + | /// todo!()
|
2672 + | /// }
|
2673 + | ///
|
2674 + | /// let config = RestJsonConfig::builder().build();
|
2675 + | /// let svc = ::tower::util::service_fn(handler);
|
2676 + | /// let app = RestJson::builder(config)
|
2677 + | /// .host_with_path_operation_service(svc)
|
2678 + | /// /* Set other handlers */
|
2679 + | /// .build()
|
2680 + | /// .unwrap();
|
2681 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2682 + | /// ```
|
2683 + | ///
|
2684 + | pub fn host_with_path_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2685 + | where
|
2686 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HostWithPathOperation, ServiceExtractors>,
|
2687 + |
|
2688 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2689 + | RestJson<L>,
|
2690 + | crate::operation_shape::HostWithPathOperation,
|
2691 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HostWithPathOperation, S>
|
2692 + | >,
|
2693 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2694 + | RestJson<L>,
|
2695 + | crate::operation_shape::HostWithPathOperation,
|
2696 + | ModelPl::Output
|
2697 + | >,
|
2698 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2699 + | RestJson<L>,
|
2700 + | crate::operation_shape::HostWithPathOperation,
|
2701 + | <
|
2702 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2703 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2704 + | RestJson<L>,
|
2705 + | crate::operation_shape::HostWithPathOperation,
|
2706 + | ModelPl::Output
|
2707 + | >
|
2708 + | >::Output
|
2709 + | >,
|
2710 + |
|
2711 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2712 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2713 + |
|
2714 + | {
|
2715 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2716 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2717 + | let svc = crate::operation_shape::HostWithPathOperation::from_service(service);
|
2718 + | let svc = self.model_plugin.apply(svc);
|
2719 + | let svc =
|
2720 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2721 + | .apply(svc);
|
2722 + | let svc = self.http_plugin.apply(svc);
|
2723 + | self.host_with_path_operation_custom(svc)
|
2724 + | }
|
2725 + |
|
2726 + | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) to a custom [`Service`](tower::Service).
|
2727 + | /// not constrained by the Smithy contract.
|
2728 + | fn host_with_path_operation_custom<S>(mut self, svc: S) -> Self
|
2729 + | where
|
2730 + | S: ::tower::Service<
|
2731 + | ::http::Request<Body>,
|
2732 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2733 + | Error = ::std::convert::Infallible,
|
2734 + | > + Clone
|
2735 + | + Send
|
2736 + | + 'static,
|
2737 + | S::Future: Send + 'static,
|
2738 + | {
|
2739 + | self.host_with_path_operation =
|
2740 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2741 + | self
|
2742 + | }
|
2743 + |
|
2744 + | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
2745 + | ///
|
2746 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2747 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2748 + | ///
|
2749 + | /// # Example
|
2750 + | ///
|
2751 + | /// ```no_run
|
2752 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2753 + | ///
|
2754 + | /// use rest_json_http0x::{input, output, error};
|
2755 + | ///
|
2756 + | /// async fn handler(input: input::HttpChecksumRequiredInput) -> output::HttpChecksumRequiredOutput {
|
2757 + | /// todo!()
|
2758 + | /// }
|
2759 + | ///
|
2760 + | /// let config = RestJsonConfig::builder().build();
|
2761 + | /// let app = RestJson::builder(config)
|
2762 + | /// .http_checksum_required(handler)
|
2293 2763 | /// /* Set other handlers */
|
2294 2764 | /// .build()
|
2295 2765 | /// .unwrap();
|
2296 2766 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2297 2767 | /// ```
|
2298 2768 | ///
|
2299 2769 | pub fn http_checksum_required<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2300 2770 | where
|
2301 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpChecksumRequired, HandlerExtractors>,
|
2771 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpChecksumRequired, HandlerExtractors>,
|
2772 + |
|
2773 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2774 + | RestJson<L>,
|
2775 + | crate::operation_shape::HttpChecksumRequired,
|
2776 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpChecksumRequired, HandlerType>
|
2777 + | >,
|
2778 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2779 + | RestJson<L>,
|
2780 + | crate::operation_shape::HttpChecksumRequired,
|
2781 + | ModelPl::Output
|
2782 + | >,
|
2783 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2784 + | RestJson<L>,
|
2785 + | crate::operation_shape::HttpChecksumRequired,
|
2786 + | <
|
2787 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2788 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2789 + | RestJson<L>,
|
2790 + | crate::operation_shape::HttpChecksumRequired,
|
2791 + | ModelPl::Output
|
2792 + | >
|
2793 + | >::Output
|
2794 + | >,
|
2795 + |
|
2796 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2797 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2798 + |
|
2799 + | {
|
2800 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2801 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2802 + | let svc = crate::operation_shape::HttpChecksumRequired::from_handler(handler);
|
2803 + | let svc = self.model_plugin.apply(svc);
|
2804 + | let svc =
|
2805 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2806 + | .apply(svc);
|
2807 + | let svc = self.http_plugin.apply(svc);
|
2808 + | self.http_checksum_required_custom(svc)
|
2809 + | }
|
2810 + |
|
2811 + | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
2812 + | ///
|
2813 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2814 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2815 + | ///
|
2816 + | /// # Example
|
2817 + | ///
|
2818 + | /// ```no_run
|
2819 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2820 + | ///
|
2821 + | /// use rest_json_http0x::{input, output, error};
|
2822 + | ///
|
2823 + | /// async fn handler(input: input::HttpChecksumRequiredInput) -> Result<output::HttpChecksumRequiredOutput, std::convert::Infallible> {
|
2824 + | /// todo!()
|
2825 + | /// }
|
2826 + | ///
|
2827 + | /// let config = RestJsonConfig::builder().build();
|
2828 + | /// let svc = ::tower::util::service_fn(handler);
|
2829 + | /// let app = RestJson::builder(config)
|
2830 + | /// .http_checksum_required_service(svc)
|
2831 + | /// /* Set other handlers */
|
2832 + | /// .build()
|
2833 + | /// .unwrap();
|
2834 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2835 + | /// ```
|
2836 + | ///
|
2837 + | pub fn http_checksum_required_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2838 + | where
|
2839 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpChecksumRequired, ServiceExtractors>,
|
2840 + |
|
2841 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2842 + | RestJson<L>,
|
2843 + | crate::operation_shape::HttpChecksumRequired,
|
2844 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpChecksumRequired, S>
|
2845 + | >,
|
2846 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2847 + | RestJson<L>,
|
2848 + | crate::operation_shape::HttpChecksumRequired,
|
2849 + | ModelPl::Output
|
2850 + | >,
|
2851 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2852 + | RestJson<L>,
|
2853 + | crate::operation_shape::HttpChecksumRequired,
|
2854 + | <
|
2855 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2856 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2857 + | RestJson<L>,
|
2858 + | crate::operation_shape::HttpChecksumRequired,
|
2859 + | ModelPl::Output
|
2860 + | >
|
2861 + | >::Output
|
2862 + | >,
|
2863 + |
|
2864 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2865 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2866 + |
|
2867 + | {
|
2868 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2869 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2870 + | let svc = crate::operation_shape::HttpChecksumRequired::from_service(service);
|
2871 + | let svc = self.model_plugin.apply(svc);
|
2872 + | let svc =
|
2873 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2874 + | .apply(svc);
|
2875 + | let svc = self.http_plugin.apply(svc);
|
2876 + | self.http_checksum_required_custom(svc)
|
2877 + | }
|
2878 + |
|
2879 + | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) to a custom [`Service`](tower::Service).
|
2880 + | /// not constrained by the Smithy contract.
|
2881 + | fn http_checksum_required_custom<S>(mut self, svc: S) -> Self
|
2882 + | where
|
2883 + | S: ::tower::Service<
|
2884 + | ::http::Request<Body>,
|
2885 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2886 + | Error = ::std::convert::Infallible,
|
2887 + | > + Clone
|
2888 + | + Send
|
2889 + | + 'static,
|
2890 + | S::Future: Send + 'static,
|
2891 + | {
|
2892 + | self.http_checksum_required =
|
2893 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2894 + | self
|
2895 + | }
|
2896 + |
|
2897 + | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
2898 + | ///
|
2899 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2900 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2901 + | ///
|
2902 + | /// # Example
|
2903 + | ///
|
2904 + | /// ```no_run
|
2905 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2906 + | ///
|
2907 + | /// use rest_json_http0x::{input, output, error};
|
2908 + | ///
|
2909 + | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> output::HttpEmptyPrefixHeadersOutput {
|
2910 + | /// todo!()
|
2911 + | /// }
|
2912 + | ///
|
2913 + | /// let config = RestJsonConfig::builder().build();
|
2914 + | /// let app = RestJson::builder(config)
|
2915 + | /// .http_empty_prefix_headers(handler)
|
2916 + | /// /* Set other handlers */
|
2917 + | /// .build()
|
2918 + | /// .unwrap();
|
2919 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2920 + | /// ```
|
2921 + | ///
|
2922 + | pub fn http_empty_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2923 + | where
|
2924 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerExtractors>,
|
2925 + |
|
2926 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2927 + | RestJson<L>,
|
2928 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2929 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerType>
|
2930 + | >,
|
2931 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2932 + | RestJson<L>,
|
2933 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2934 + | ModelPl::Output
|
2935 + | >,
|
2936 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2937 + | RestJson<L>,
|
2938 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2939 + | <
|
2940 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2941 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2942 + | RestJson<L>,
|
2943 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2944 + | ModelPl::Output
|
2945 + | >
|
2946 + | >::Output
|
2947 + | >,
|
2948 + |
|
2949 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2950 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2951 + |
|
2952 + | {
|
2953 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2954 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2955 + | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_handler(handler);
|
2956 + | let svc = self.model_plugin.apply(svc);
|
2957 + | let svc =
|
2958 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2959 + | .apply(svc);
|
2960 + | let svc = self.http_plugin.apply(svc);
|
2961 + | self.http_empty_prefix_headers_custom(svc)
|
2962 + | }
|
2963 + |
|
2964 + | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
2965 + | ///
|
2966 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2967 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2968 + | ///
|
2969 + | /// # Example
|
2970 + | ///
|
2971 + | /// ```no_run
|
2972 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2973 + | ///
|
2974 + | /// use rest_json_http0x::{input, output, error};
|
2975 + | ///
|
2976 + | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> Result<output::HttpEmptyPrefixHeadersOutput, std::convert::Infallible> {
|
2977 + | /// todo!()
|
2978 + | /// }
|
2979 + | ///
|
2980 + | /// let config = RestJsonConfig::builder().build();
|
2981 + | /// let svc = ::tower::util::service_fn(handler);
|
2982 + | /// let app = RestJson::builder(config)
|
2983 + | /// .http_empty_prefix_headers_service(svc)
|
2984 + | /// /* Set other handlers */
|
2985 + | /// .build()
|
2986 + | /// .unwrap();
|
2987 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2988 + | /// ```
|
2989 + | ///
|
2990 + | pub fn http_empty_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2991 + | where
|
2992 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEmptyPrefixHeaders, ServiceExtractors>,
|
2993 + |
|
2994 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2995 + | RestJson<L>,
|
2996 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2997 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEmptyPrefixHeaders, S>
|
2998 + | >,
|
2999 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3000 + | RestJson<L>,
|
3001 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3002 + | ModelPl::Output
|
3003 + | >,
|
3004 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3005 + | RestJson<L>,
|
3006 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3007 + | <
|
3008 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3009 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3010 + | RestJson<L>,
|
3011 + | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3012 + | ModelPl::Output
|
3013 + | >
|
3014 + | >::Output
|
3015 + | >,
|
3016 + |
|
3017 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3018 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3019 + |
|
3020 + | {
|
3021 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3022 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3023 + | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_service(service);
|
3024 + | let svc = self.model_plugin.apply(svc);
|
3025 + | let svc =
|
3026 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3027 + | .apply(svc);
|
3028 + | let svc = self.http_plugin.apply(svc);
|
3029 + | self.http_empty_prefix_headers_custom(svc)
|
3030 + | }
|
3031 + |
|
3032 + | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) to a custom [`Service`](tower::Service).
|
3033 + | /// not constrained by the Smithy contract.
|
3034 + | fn http_empty_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
3035 + | where
|
3036 + | S: ::tower::Service<
|
3037 + | ::http::Request<Body>,
|
3038 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3039 + | Error = ::std::convert::Infallible,
|
3040 + | > + Clone
|
3041 + | + Send
|
3042 + | + 'static,
|
3043 + | S::Future: Send + 'static,
|
3044 + | {
|
3045 + | self.http_empty_prefix_headers =
|
3046 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3047 + | self
|
3048 + | }
|
3049 + |
|
3050 + | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
3051 + | ///
|
3052 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3053 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3054 + | ///
|
3055 + | /// # Example
|
3056 + | ///
|
3057 + | /// ```no_run
|
3058 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3059 + | ///
|
3060 + | /// use rest_json_http0x::{input, output, error};
|
3061 + | ///
|
3062 + | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
3063 + | /// todo!()
|
3064 + | /// }
|
3065 + | ///
|
3066 + | /// let config = RestJsonConfig::builder().build();
|
3067 + | /// let app = RestJson::builder(config)
|
3068 + | /// .http_enum_payload(handler)
|
3069 + | /// /* Set other handlers */
|
3070 + | /// .build()
|
3071 + | /// .unwrap();
|
3072 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3073 + | /// ```
|
3074 + | ///
|
3075 + | pub fn http_enum_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3076 + | where
|
3077 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEnumPayload, HandlerExtractors>,
|
3078 + |
|
3079 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3080 + | RestJson<L>,
|
3081 + | crate::operation_shape::HttpEnumPayload,
|
3082 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEnumPayload, HandlerType>
|
3083 + | >,
|
3084 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3085 + | RestJson<L>,
|
3086 + | crate::operation_shape::HttpEnumPayload,
|
3087 + | ModelPl::Output
|
3088 + | >,
|
3089 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3090 + | RestJson<L>,
|
3091 + | crate::operation_shape::HttpEnumPayload,
|
3092 + | <
|
3093 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3094 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3095 + | RestJson<L>,
|
3096 + | crate::operation_shape::HttpEnumPayload,
|
3097 + | ModelPl::Output
|
3098 + | >
|
3099 + | >::Output
|
3100 + | >,
|
3101 + |
|
3102 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3103 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3104 + |
|
3105 + | {
|
3106 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3107 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3108 + | let svc = crate::operation_shape::HttpEnumPayload::from_handler(handler);
|
3109 + | let svc = self.model_plugin.apply(svc);
|
3110 + | let svc =
|
3111 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3112 + | .apply(svc);
|
3113 + | let svc = self.http_plugin.apply(svc);
|
3114 + | self.http_enum_payload_custom(svc)
|
3115 + | }
|
3116 + |
|
3117 + | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
3118 + | ///
|
3119 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3120 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3121 + | ///
|
3122 + | /// # Example
|
3123 + | ///
|
3124 + | /// ```no_run
|
3125 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3126 + | ///
|
3127 + | /// use rest_json_http0x::{input, output, error};
|
3128 + | ///
|
3129 + | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
3130 + | /// todo!()
|
3131 + | /// }
|
3132 + | ///
|
3133 + | /// let config = RestJsonConfig::builder().build();
|
3134 + | /// let svc = ::tower::util::service_fn(handler);
|
3135 + | /// let app = RestJson::builder(config)
|
3136 + | /// .http_enum_payload_service(svc)
|
3137 + | /// /* Set other handlers */
|
3138 + | /// .build()
|
3139 + | /// .unwrap();
|
3140 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3141 + | /// ```
|
3142 + | ///
|
3143 + | pub fn http_enum_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3144 + | where
|
3145 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEnumPayload, ServiceExtractors>,
|
3146 + |
|
3147 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3148 + | RestJson<L>,
|
3149 + | crate::operation_shape::HttpEnumPayload,
|
3150 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEnumPayload, S>
|
3151 + | >,
|
3152 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3153 + | RestJson<L>,
|
3154 + | crate::operation_shape::HttpEnumPayload,
|
3155 + | ModelPl::Output
|
3156 + | >,
|
3157 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3158 + | RestJson<L>,
|
3159 + | crate::operation_shape::HttpEnumPayload,
|
3160 + | <
|
3161 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3162 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3163 + | RestJson<L>,
|
3164 + | crate::operation_shape::HttpEnumPayload,
|
3165 + | ModelPl::Output
|
3166 + | >
|
3167 + | >::Output
|
3168 + | >,
|
3169 + |
|
3170 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3171 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3172 + |
|
3173 + | {
|
3174 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3175 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3176 + | let svc = crate::operation_shape::HttpEnumPayload::from_service(service);
|
3177 + | let svc = self.model_plugin.apply(svc);
|
3178 + | let svc =
|
3179 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3180 + | .apply(svc);
|
3181 + | let svc = self.http_plugin.apply(svc);
|
3182 + | self.http_enum_payload_custom(svc)
|
3183 + | }
|
3184 + |
|
3185 + | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) to a custom [`Service`](tower::Service).
|
3186 + | /// not constrained by the Smithy contract.
|
3187 + | fn http_enum_payload_custom<S>(mut self, svc: S) -> Self
|
3188 + | where
|
3189 + | S: ::tower::Service<
|
3190 + | ::http::Request<Body>,
|
3191 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3192 + | Error = ::std::convert::Infallible,
|
3193 + | > + Clone
|
3194 + | + Send
|
3195 + | + 'static,
|
3196 + | S::Future: Send + 'static,
|
3197 + | {
|
3198 + | self.http_enum_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3199 + | self
|
3200 + | }
|
3201 + |
|
3202 + | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
3203 + | ///
|
3204 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3205 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3206 + | ///
|
3207 + | /// # Example
|
3208 + | ///
|
3209 + | /// ```no_run
|
3210 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3211 + | ///
|
3212 + | /// use rest_json_http0x::{input, output, error};
|
3213 + | ///
|
3214 + | /// async fn handler(input: input::HttpPayloadTraitsInput) -> output::HttpPayloadTraitsOutput {
|
3215 + | /// todo!()
|
3216 + | /// }
|
3217 + | ///
|
3218 + | /// let config = RestJsonConfig::builder().build();
|
3219 + | /// let app = RestJson::builder(config)
|
3220 + | /// .http_payload_traits(handler)
|
3221 + | /// /* Set other handlers */
|
3222 + | /// .build()
|
3223 + | /// .unwrap();
|
3224 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3225 + | /// ```
|
3226 + | ///
|
3227 + | pub fn http_payload_traits<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3228 + | where
|
3229 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraits, HandlerExtractors>,
|
3230 + |
|
3231 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3232 + | RestJson<L>,
|
3233 + | crate::operation_shape::HttpPayloadTraits,
|
3234 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraits, HandlerType>
|
3235 + | >,
|
3236 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3237 + | RestJson<L>,
|
3238 + | crate::operation_shape::HttpPayloadTraits,
|
3239 + | ModelPl::Output
|
3240 + | >,
|
3241 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3242 + | RestJson<L>,
|
3243 + | crate::operation_shape::HttpPayloadTraits,
|
3244 + | <
|
3245 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3246 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3247 + | RestJson<L>,
|
3248 + | crate::operation_shape::HttpPayloadTraits,
|
3249 + | ModelPl::Output
|
3250 + | >
|
3251 + | >::Output
|
3252 + | >,
|
3253 + |
|
3254 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3255 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3256 + |
|
3257 + | {
|
3258 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3259 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3260 + | let svc = crate::operation_shape::HttpPayloadTraits::from_handler(handler);
|
3261 + | let svc = self.model_plugin.apply(svc);
|
3262 + | let svc =
|
3263 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3264 + | .apply(svc);
|
3265 + | let svc = self.http_plugin.apply(svc);
|
3266 + | self.http_payload_traits_custom(svc)
|
3267 + | }
|
3268 + |
|
3269 + | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
3270 + | ///
|
3271 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3272 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3273 + | ///
|
3274 + | /// # Example
|
3275 + | ///
|
3276 + | /// ```no_run
|
3277 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3278 + | ///
|
3279 + | /// use rest_json_http0x::{input, output, error};
|
3280 + | ///
|
3281 + | /// async fn handler(input: input::HttpPayloadTraitsInput) -> Result<output::HttpPayloadTraitsOutput, std::convert::Infallible> {
|
3282 + | /// todo!()
|
3283 + | /// }
|
3284 + | ///
|
3285 + | /// let config = RestJsonConfig::builder().build();
|
3286 + | /// let svc = ::tower::util::service_fn(handler);
|
3287 + | /// let app = RestJson::builder(config)
|
3288 + | /// .http_payload_traits_service(svc)
|
3289 + | /// /* Set other handlers */
|
3290 + | /// .build()
|
3291 + | /// .unwrap();
|
3292 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3293 + | /// ```
|
3294 + | ///
|
3295 + | pub fn http_payload_traits_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3296 + | where
|
3297 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraits, ServiceExtractors>,
|
3298 + |
|
3299 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3300 + | RestJson<L>,
|
3301 + | crate::operation_shape::HttpPayloadTraits,
|
3302 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraits, S>
|
3303 + | >,
|
3304 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3305 + | RestJson<L>,
|
3306 + | crate::operation_shape::HttpPayloadTraits,
|
3307 + | ModelPl::Output
|
3308 + | >,
|
3309 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3310 + | RestJson<L>,
|
3311 + | crate::operation_shape::HttpPayloadTraits,
|
3312 + | <
|
3313 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3314 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3315 + | RestJson<L>,
|
3316 + | crate::operation_shape::HttpPayloadTraits,
|
3317 + | ModelPl::Output
|
3318 + | >
|
3319 + | >::Output
|
3320 + | >,
|
3321 + |
|
3322 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3323 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3324 + |
|
3325 + | {
|
3326 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3327 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3328 + | let svc = crate::operation_shape::HttpPayloadTraits::from_service(service);
|
3329 + | let svc = self.model_plugin.apply(svc);
|
3330 + | let svc =
|
3331 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3332 + | .apply(svc);
|
3333 + | let svc = self.http_plugin.apply(svc);
|
3334 + | self.http_payload_traits_custom(svc)
|
3335 + | }
|
3336 + |
|
3337 + | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) to a custom [`Service`](tower::Service).
|
3338 + | /// not constrained by the Smithy contract.
|
3339 + | fn http_payload_traits_custom<S>(mut self, svc: S) -> Self
|
3340 + | where
|
3341 + | S: ::tower::Service<
|
3342 + | ::http::Request<Body>,
|
3343 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3344 + | Error = ::std::convert::Infallible,
|
3345 + | > + Clone
|
3346 + | + Send
|
3347 + | + 'static,
|
3348 + | S::Future: Send + 'static,
|
3349 + | {
|
3350 + | self.http_payload_traits = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3351 + | self
|
3352 + | }
|
3353 + |
|
3354 + | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
3355 + | ///
|
3356 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3357 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3358 + | ///
|
3359 + | /// # Example
|
3360 + | ///
|
3361 + | /// ```no_run
|
3362 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3363 + | ///
|
3364 + | /// use rest_json_http0x::{input, output, error};
|
3365 + | ///
|
3366 + | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> output::HttpPayloadTraitsWithMediaTypeOutput {
|
3367 + | /// todo!()
|
3368 + | /// }
|
3369 + | ///
|
3370 + | /// let config = RestJsonConfig::builder().build();
|
3371 + | /// let app = RestJson::builder(config)
|
3372 + | /// .http_payload_traits_with_media_type(handler)
|
3373 + | /// /* Set other handlers */
|
3374 + | /// .build()
|
3375 + | /// .unwrap();
|
3376 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3377 + | /// ```
|
3378 + | ///
|
3379 + | pub fn http_payload_traits_with_media_type<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3380 + | where
|
3381 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerExtractors>,
|
3382 + |
|
3383 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3384 + | RestJson<L>,
|
3385 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3386 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerType>
|
3387 + | >,
|
3388 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3389 + | RestJson<L>,
|
3390 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3391 + | ModelPl::Output
|
3392 + | >,
|
3393 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3394 + | RestJson<L>,
|
3395 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3396 + | <
|
3397 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3398 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3399 + | RestJson<L>,
|
3400 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3401 + | ModelPl::Output
|
3402 + | >
|
3403 + | >::Output
|
3404 + | >,
|
3405 + |
|
3406 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3407 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3408 + |
|
3409 + | {
|
3410 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3411 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3412 + | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_handler(handler);
|
3413 + | let svc = self.model_plugin.apply(svc);
|
3414 + | let svc =
|
3415 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3416 + | .apply(svc);
|
3417 + | let svc = self.http_plugin.apply(svc);
|
3418 + | self.http_payload_traits_with_media_type_custom(svc)
|
3419 + | }
|
3420 + |
|
3421 + | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
3422 + | ///
|
3423 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3424 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3425 + | ///
|
3426 + | /// # Example
|
3427 + | ///
|
3428 + | /// ```no_run
|
3429 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3430 + | ///
|
3431 + | /// use rest_json_http0x::{input, output, error};
|
3432 + | ///
|
3433 + | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> Result<output::HttpPayloadTraitsWithMediaTypeOutput, std::convert::Infallible> {
|
3434 + | /// todo!()
|
3435 + | /// }
|
3436 + | ///
|
3437 + | /// let config = RestJsonConfig::builder().build();
|
3438 + | /// let svc = ::tower::util::service_fn(handler);
|
3439 + | /// let app = RestJson::builder(config)
|
3440 + | /// .http_payload_traits_with_media_type_service(svc)
|
3441 + | /// /* Set other handlers */
|
3442 + | /// .build()
|
3443 + | /// .unwrap();
|
3444 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3445 + | /// ```
|
3446 + | ///
|
3447 + | pub fn http_payload_traits_with_media_type_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3448 + | where
|
3449 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraitsWithMediaType, ServiceExtractors>,
|
3450 + |
|
3451 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3452 + | RestJson<L>,
|
3453 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3454 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraitsWithMediaType, S>
|
3455 + | >,
|
3456 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3457 + | RestJson<L>,
|
3458 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3459 + | ModelPl::Output
|
3460 + | >,
|
3461 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3462 + | RestJson<L>,
|
3463 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3464 + | <
|
3465 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3466 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3467 + | RestJson<L>,
|
3468 + | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
3469 + | ModelPl::Output
|
3470 + | >
|
3471 + | >::Output
|
3472 + | >,
|
3473 + |
|
3474 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3475 + | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3476 + |
|
3477 + | {
|
3478 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3479 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3480 + | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_service(service);
|
3481 + | let svc = self.model_plugin.apply(svc);
|
3482 + | let svc =
|
3483 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3484 + | .apply(svc);
|
3485 + | let svc = self.http_plugin.apply(svc);
|
3486 + | self.http_payload_traits_with_media_type_custom(svc)
|
3487 + | }
|
3488 + |
|
3489 + | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) to a custom [`Service`](tower::Service).
|
3490 + | /// not constrained by the Smithy contract.
|
3491 + | fn http_payload_traits_with_media_type_custom<S>(mut self, svc: S) -> Self
|
3492 + | where
|
3493 + | S: ::tower::Service<
|
3494 + | ::http::Request<Body>,
|
3495 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3496 + | Error = ::std::convert::Infallible,
|
3497 + | > + Clone
|
3498 + | + Send
|
3499 + | + 'static,
|
3500 + | S::Future: Send + 'static,
|
3501 + | {
|
3502 + | self.http_payload_traits_with_media_type =
|
3503 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3504 + | self
|
3505 + | }
|
3506 + |
|
3507 + | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
3508 + | ///
|
3509 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3510 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3511 + | ///
|
3512 + | /// # Example
|
3513 + | ///
|
3514 + | /// ```no_run
|
3515 + | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3516 + | ///
|
3517 + | /// use rest_json_http0x::{input, output, error};
|
3518 + | ///
|
3519 + | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> output::HttpPayloadWithStructureOutput {
|
3520 + | /// todo!()
|
3521 + | /// }
|
3522 + | ///
|
3523 + | /// let config = RestJsonConfig::builder().build();
|
3524 + | /// let app = RestJson::builder(config)
|
3525 + | /// .http_payload_with_structure(handler)
|
3526 + | /// /* Set other handlers */
|
3527 + | /// .build()
|
3528 + | /// .unwrap();
|
3529 + | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3530 + | /// ```
|
3531 + | ///
|
3532 + | pub fn http_payload_with_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3533 + | where
|
3534 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithStructure, HandlerExtractors>,
|
2302 3535 |
|
2303 3536 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2304 3537 | RestJson<L>,
|
2305 - | crate::operation_shape::HttpChecksumRequired,
|
2306 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpChecksumRequired, HandlerType>
|
3538 + | crate::operation_shape::HttpPayloadWithStructure,
|
3539 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithStructure, HandlerType>
|
2307 3540 | >,
|
2308 3541 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2309 3542 | RestJson<L>,
|
2310 - | crate::operation_shape::HttpChecksumRequired,
|
3543 + | crate::operation_shape::HttpPayloadWithStructure,
|
2311 3544 | ModelPl::Output
|
2312 3545 | >,
|
2313 3546 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2314 3547 | RestJson<L>,
|
2315 - | crate::operation_shape::HttpChecksumRequired,
|
3548 + | crate::operation_shape::HttpPayloadWithStructure,
|
2316 3549 | <
|
2317 3550 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2318 3551 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2319 3552 | RestJson<L>,
|
2320 - | crate::operation_shape::HttpChecksumRequired,
|
3553 + | crate::operation_shape::HttpPayloadWithStructure,
|
2321 3554 | ModelPl::Output
|
2322 3555 | >
|
2323 3556 | >::Output
|
2324 3557 | >,
|
2325 3558 |
|
2326 3559 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2327 3560 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2328 3561 |
|
2329 3562 | {
|
2330 3563 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2331 3564 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2332 - | let svc = crate::operation_shape::HttpChecksumRequired::from_handler(handler);
|
3565 + | let svc = crate::operation_shape::HttpPayloadWithStructure::from_handler(handler);
|
2333 3566 | let svc = self.model_plugin.apply(svc);
|
2334 3567 | let svc =
|
2335 3568 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2336 3569 | .apply(svc);
|
2337 3570 | let svc = self.http_plugin.apply(svc);
|
2338 - | self.http_checksum_required_custom(svc)
|
3571 + | self.http_payload_with_structure_custom(svc)
|
2339 3572 | }
|
2340 3573 |
|
2341 - | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
3574 + | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
2342 3575 | ///
|
2343 3576 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2344 3577 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2345 3578 | ///
|
2346 3579 | /// # Example
|
2347 3580 | ///
|
2348 3581 | /// ```no_run
|
2349 3582 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2350 3583 | ///
|
2351 3584 | /// use rest_json_http0x::{input, output, error};
|
2352 3585 | ///
|
2353 - | /// async fn handler(input: input::HttpChecksumRequiredInput) -> Result<output::HttpChecksumRequiredOutput, std::convert::Infallible> {
|
3586 + | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> Result<output::HttpPayloadWithStructureOutput, std::convert::Infallible> {
|
2354 3587 | /// todo!()
|
2355 3588 | /// }
|
2356 3589 | ///
|
2357 3590 | /// let config = RestJsonConfig::builder().build();
|
2358 3591 | /// let svc = ::tower::util::service_fn(handler);
|
2359 3592 | /// let app = RestJson::builder(config)
|
2360 - | /// .http_checksum_required_service(svc)
|
3593 + | /// .http_payload_with_structure_service(svc)
|
2361 3594 | /// /* Set other handlers */
|
2362 3595 | /// .build()
|
2363 3596 | /// .unwrap();
|
2364 3597 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2365 3598 | /// ```
|
2366 3599 | ///
|
2367 - | pub fn http_checksum_required_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3600 + | pub fn http_payload_with_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2368 3601 | where
|
2369 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpChecksumRequired, ServiceExtractors>,
|
3602 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithStructure, ServiceExtractors>,
|
2370 3603 |
|
2371 3604 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2372 3605 | RestJson<L>,
|
2373 - | crate::operation_shape::HttpChecksumRequired,
|
2374 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpChecksumRequired, S>
|
3606 + | crate::operation_shape::HttpPayloadWithStructure,
|
3607 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithStructure, S>
|
2375 3608 | >,
|
2376 3609 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2377 3610 | RestJson<L>,
|
2378 - | crate::operation_shape::HttpChecksumRequired,
|
3611 + | crate::operation_shape::HttpPayloadWithStructure,
|
2379 3612 | ModelPl::Output
|
2380 3613 | >,
|
2381 3614 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2382 3615 | RestJson<L>,
|
2383 - | crate::operation_shape::HttpChecksumRequired,
|
3616 + | crate::operation_shape::HttpPayloadWithStructure,
|
2384 3617 | <
|
2385 3618 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2386 3619 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2387 3620 | RestJson<L>,
|
2388 - | crate::operation_shape::HttpChecksumRequired,
|
3621 + | crate::operation_shape::HttpPayloadWithStructure,
|
2389 3622 | ModelPl::Output
|
2390 3623 | >
|
2391 3624 | >::Output
|
2392 3625 | >,
|
2393 3626 |
|
2394 3627 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2395 3628 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2396 3629 |
|
2397 3630 | {
|
2398 3631 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2399 3632 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2400 - | let svc = crate::operation_shape::HttpChecksumRequired::from_service(service);
|
3633 + | let svc = crate::operation_shape::HttpPayloadWithStructure::from_service(service);
|
2401 3634 | let svc = self.model_plugin.apply(svc);
|
2402 3635 | let svc =
|
2403 3636 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2404 3637 | .apply(svc);
|
2405 3638 | let svc = self.http_plugin.apply(svc);
|
2406 - | self.http_checksum_required_custom(svc)
|
3639 + | self.http_payload_with_structure_custom(svc)
|
2407 3640 | }
|
2408 3641 |
|
2409 - | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) to a custom [`Service`](tower::Service).
|
3642 + | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) to a custom [`Service`](tower::Service).
|
2410 3643 | /// not constrained by the Smithy contract.
|
2411 - | fn http_checksum_required_custom<S>(mut self, svc: S) -> Self
|
3644 + | fn http_payload_with_structure_custom<S>(mut self, svc: S) -> Self
|
2412 3645 | where
|
2413 3646 | S: ::tower::Service<
|
2414 3647 | ::http::Request<Body>,
|
2415 3648 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2416 3649 | Error = ::std::convert::Infallible,
|
2417 3650 | > + Clone
|
2418 3651 | + Send
|
2419 3652 | + 'static,
|
2420 3653 | S::Future: Send + 'static,
|
2421 3654 | {
|
2422 - | self.http_checksum_required =
|
3655 + | self.http_payload_with_structure =
|
2423 3656 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2424 3657 | self
|
2425 3658 | }
|
2426 3659 |
|
2427 - | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
3660 + | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
2428 3661 | ///
|
2429 3662 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2430 3663 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2431 3664 | ///
|
2432 3665 | /// # Example
|
2433 3666 | ///
|
2434 3667 | /// ```no_run
|
2435 3668 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2436 3669 | ///
|
2437 3670 | /// use rest_json_http0x::{input, output, error};
|
2438 3671 | ///
|
2439 - | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> output::HttpEmptyPrefixHeadersOutput {
|
3672 + | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> output::HttpPayloadWithUnionOutput {
|
2440 3673 | /// todo!()
|
2441 3674 | /// }
|
2442 3675 | ///
|
2443 3676 | /// let config = RestJsonConfig::builder().build();
|
2444 3677 | /// let app = RestJson::builder(config)
|
2445 - | /// .http_empty_prefix_headers(handler)
|
3678 + | /// .http_payload_with_union(handler)
|
2446 3679 | /// /* Set other handlers */
|
2447 3680 | /// .build()
|
2448 3681 | /// .unwrap();
|
2449 3682 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2450 3683 | /// ```
|
2451 3684 | ///
|
2452 - | pub fn http_empty_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3685 + | pub fn http_payload_with_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2453 3686 | where
|
2454 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerExtractors>,
|
3687 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithUnion, HandlerExtractors>,
|
2455 3688 |
|
2456 3689 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2457 3690 | RestJson<L>,
|
2458 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2459 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerType>
|
3691 + | crate::operation_shape::HttpPayloadWithUnion,
|
3692 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithUnion, HandlerType>
|
2460 3693 | >,
|
2461 3694 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2462 3695 | RestJson<L>,
|
2463 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3696 + | crate::operation_shape::HttpPayloadWithUnion,
|
2464 3697 | ModelPl::Output
|
2465 3698 | >,
|
2466 3699 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2467 3700 | RestJson<L>,
|
2468 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3701 + | crate::operation_shape::HttpPayloadWithUnion,
|
2469 3702 | <
|
2470 3703 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2471 3704 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2472 3705 | RestJson<L>,
|
2473 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3706 + | crate::operation_shape::HttpPayloadWithUnion,
|
2474 3707 | ModelPl::Output
|
2475 3708 | >
|
2476 3709 | >::Output
|
2477 3710 | >,
|
2478 3711 |
|
2479 3712 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2480 3713 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2481 3714 |
|
2482 3715 | {
|
2483 3716 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2484 3717 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2485 - | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_handler(handler);
|
3718 + | let svc = crate::operation_shape::HttpPayloadWithUnion::from_handler(handler);
|
2486 3719 | let svc = self.model_plugin.apply(svc);
|
2487 3720 | let svc =
|
2488 3721 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2489 3722 | .apply(svc);
|
2490 3723 | let svc = self.http_plugin.apply(svc);
|
2491 - | self.http_empty_prefix_headers_custom(svc)
|
3724 + | self.http_payload_with_union_custom(svc)
|
2492 3725 | }
|
2493 3726 |
|
2494 - | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
3727 + | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
2495 3728 | ///
|
2496 3729 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2497 3730 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2498 3731 | ///
|
2499 3732 | /// # Example
|
2500 3733 | ///
|
2501 3734 | /// ```no_run
|
2502 3735 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2503 3736 | ///
|
2504 3737 | /// use rest_json_http0x::{input, output, error};
|
2505 3738 | ///
|
2506 - | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> Result<output::HttpEmptyPrefixHeadersOutput, std::convert::Infallible> {
|
3739 + | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> Result<output::HttpPayloadWithUnionOutput, std::convert::Infallible> {
|
2507 3740 | /// todo!()
|
2508 3741 | /// }
|
2509 3742 | ///
|
2510 3743 | /// let config = RestJsonConfig::builder().build();
|
2511 3744 | /// let svc = ::tower::util::service_fn(handler);
|
2512 3745 | /// let app = RestJson::builder(config)
|
2513 - | /// .http_empty_prefix_headers_service(svc)
|
3746 + | /// .http_payload_with_union_service(svc)
|
2514 3747 | /// /* Set other handlers */
|
2515 3748 | /// .build()
|
2516 3749 | /// .unwrap();
|
2517 3750 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2518 3751 | /// ```
|
2519 3752 | ///
|
2520 - | pub fn http_empty_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3753 + | pub fn http_payload_with_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2521 3754 | where
|
2522 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEmptyPrefixHeaders, ServiceExtractors>,
|
3755 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithUnion, ServiceExtractors>,
|
2523 3756 |
|
2524 3757 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2525 3758 | RestJson<L>,
|
2526 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2527 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEmptyPrefixHeaders, S>
|
3759 + | crate::operation_shape::HttpPayloadWithUnion,
|
3760 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithUnion, S>
|
2528 3761 | >,
|
2529 3762 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2530 3763 | RestJson<L>,
|
2531 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3764 + | crate::operation_shape::HttpPayloadWithUnion,
|
2532 3765 | ModelPl::Output
|
2533 3766 | >,
|
2534 3767 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2535 3768 | RestJson<L>,
|
2536 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3769 + | crate::operation_shape::HttpPayloadWithUnion,
|
2537 3770 | <
|
2538 3771 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2539 3772 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2540 3773 | RestJson<L>,
|
2541 - | crate::operation_shape::HttpEmptyPrefixHeaders,
|
3774 + | crate::operation_shape::HttpPayloadWithUnion,
|
2542 3775 | ModelPl::Output
|
2543 3776 | >
|
2544 3777 | >::Output
|
2545 3778 | >,
|
2546 3779 |
|
2547 3780 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2548 3781 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2549 3782 |
|
2550 3783 | {
|
2551 3784 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2552 3785 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2553 - | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_service(service);
|
3786 + | let svc = crate::operation_shape::HttpPayloadWithUnion::from_service(service);
|
2554 3787 | let svc = self.model_plugin.apply(svc);
|
2555 3788 | let svc =
|
2556 3789 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2557 3790 | .apply(svc);
|
2558 3791 | let svc = self.http_plugin.apply(svc);
|
2559 - | self.http_empty_prefix_headers_custom(svc)
|
3792 + | self.http_payload_with_union_custom(svc)
|
2560 3793 | }
|
2561 3794 |
|
2562 - | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) to a custom [`Service`](tower::Service).
|
3795 + | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) to a custom [`Service`](tower::Service).
|
2563 3796 | /// not constrained by the Smithy contract.
|
2564 - | fn http_empty_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
3797 + | fn http_payload_with_union_custom<S>(mut self, svc: S) -> Self
|
2565 3798 | where
|
2566 3799 | S: ::tower::Service<
|
2567 3800 | ::http::Request<Body>,
|
2568 3801 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2569 3802 | Error = ::std::convert::Infallible,
|
2570 3803 | > + Clone
|
2571 3804 | + Send
|
2572 3805 | + 'static,
|
2573 3806 | S::Future: Send + 'static,
|
2574 3807 | {
|
2575 - | self.http_empty_prefix_headers =
|
3808 + | self.http_payload_with_union =
|
2576 3809 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2577 3810 | self
|
2578 3811 | }
|
2579 3812 |
|
2580 - | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
3813 + | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
2581 3814 | ///
|
2582 3815 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2583 3816 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2584 3817 | ///
|
2585 3818 | /// # Example
|
2586 3819 | ///
|
2587 3820 | /// ```no_run
|
2588 3821 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2589 3822 | ///
|
2590 3823 | /// use rest_json_http0x::{input, output, error};
|
2591 3824 | ///
|
2592 - | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
3825 + | /// async fn handler(input: input::HttpPrefixHeadersInput) -> output::HttpPrefixHeadersOutput {
|
2593 3826 | /// todo!()
|
2594 3827 | /// }
|
2595 3828 | ///
|
2596 3829 | /// let config = RestJsonConfig::builder().build();
|
2597 3830 | /// let app = RestJson::builder(config)
|
2598 - | /// .http_enum_payload(handler)
|
3831 + | /// .http_prefix_headers(handler)
|
2599 3832 | /// /* Set other handlers */
|
2600 3833 | /// .build()
|
2601 3834 | /// .unwrap();
|
2602 3835 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2603 3836 | /// ```
|
2604 3837 | ///
|
2605 - | pub fn http_enum_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3838 + | pub fn http_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2606 3839 | where
|
2607 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEnumPayload, HandlerExtractors>,
|
3840 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeaders, HandlerExtractors>,
|
2608 3841 |
|
2609 3842 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2610 3843 | RestJson<L>,
|
2611 - | crate::operation_shape::HttpEnumPayload,
|
2612 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEnumPayload, HandlerType>
|
3844 + | crate::operation_shape::HttpPrefixHeaders,
|
3845 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeaders, HandlerType>
|
2613 3846 | >,
|
2614 3847 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2615 3848 | RestJson<L>,
|
2616 - | crate::operation_shape::HttpEnumPayload,
|
3849 + | crate::operation_shape::HttpPrefixHeaders,
|
2617 3850 | ModelPl::Output
|
2618 3851 | >,
|
2619 3852 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2620 3853 | RestJson<L>,
|
2621 - | crate::operation_shape::HttpEnumPayload,
|
3854 + | crate::operation_shape::HttpPrefixHeaders,
|
2622 3855 | <
|
2623 3856 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2624 3857 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2625 3858 | RestJson<L>,
|
2626 - | crate::operation_shape::HttpEnumPayload,
|
3859 + | crate::operation_shape::HttpPrefixHeaders,
|
2627 3860 | ModelPl::Output
|
2628 3861 | >
|
2629 3862 | >::Output
|
2630 3863 | >,
|
2631 3864 |
|
2632 3865 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2633 3866 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2634 3867 |
|
2635 3868 | {
|
2636 3869 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2637 3870 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2638 - | let svc = crate::operation_shape::HttpEnumPayload::from_handler(handler);
|
3871 + | let svc = crate::operation_shape::HttpPrefixHeaders::from_handler(handler);
|
2639 3872 | let svc = self.model_plugin.apply(svc);
|
2640 3873 | let svc =
|
2641 3874 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2642 3875 | .apply(svc);
|
2643 3876 | let svc = self.http_plugin.apply(svc);
|
2644 - | self.http_enum_payload_custom(svc)
|
3877 + | self.http_prefix_headers_custom(svc)
|
2645 3878 | }
|
2646 3879 |
|
2647 - | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
3880 + | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
2648 3881 | ///
|
2649 3882 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2650 3883 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2651 3884 | ///
|
2652 3885 | /// # Example
|
2653 3886 | ///
|
2654 3887 | /// ```no_run
|
2655 3888 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2656 3889 | ///
|
2657 3890 | /// use rest_json_http0x::{input, output, error};
|
2658 3891 | ///
|
2659 - | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
3892 + | /// async fn handler(input: input::HttpPrefixHeadersInput) -> Result<output::HttpPrefixHeadersOutput, std::convert::Infallible> {
|
2660 3893 | /// todo!()
|
2661 3894 | /// }
|
2662 3895 | ///
|
2663 3896 | /// let config = RestJsonConfig::builder().build();
|
2664 3897 | /// let svc = ::tower::util::service_fn(handler);
|
2665 3898 | /// let app = RestJson::builder(config)
|
2666 - | /// .http_enum_payload_service(svc)
|
3899 + | /// .http_prefix_headers_service(svc)
|
2667 3900 | /// /* Set other handlers */
|
2668 3901 | /// .build()
|
2669 3902 | /// .unwrap();
|
2670 3903 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2671 3904 | /// ```
|
2672 3905 | ///
|
2673 - | pub fn http_enum_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3906 + | pub fn http_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2674 3907 | where
|
2675 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEnumPayload, ServiceExtractors>,
|
3908 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeaders, ServiceExtractors>,
|
2676 3909 |
|
2677 3910 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2678 3911 | RestJson<L>,
|
2679 - | crate::operation_shape::HttpEnumPayload,
|
2680 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEnumPayload, S>
|
3912 + | crate::operation_shape::HttpPrefixHeaders,
|
3913 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeaders, S>
|
2681 3914 | >,
|
2682 3915 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2683 3916 | RestJson<L>,
|
2684 - | crate::operation_shape::HttpEnumPayload,
|
3917 + | crate::operation_shape::HttpPrefixHeaders,
|
2685 3918 | ModelPl::Output
|
2686 3919 | >,
|
2687 3920 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2688 3921 | RestJson<L>,
|
2689 - | crate::operation_shape::HttpEnumPayload,
|
3922 + | crate::operation_shape::HttpPrefixHeaders,
|
2690 3923 | <
|
2691 3924 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2692 3925 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2693 3926 | RestJson<L>,
|
2694 - | crate::operation_shape::HttpEnumPayload,
|
3927 + | crate::operation_shape::HttpPrefixHeaders,
|
2695 3928 | ModelPl::Output
|
2696 3929 | >
|
2697 3930 | >::Output
|
2698 3931 | >,
|
2699 3932 |
|
2700 3933 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2701 3934 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2702 3935 |
|
2703 3936 | {
|
2704 3937 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2705 3938 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2706 - | let svc = crate::operation_shape::HttpEnumPayload::from_service(service);
|
3939 + | let svc = crate::operation_shape::HttpPrefixHeaders::from_service(service);
|
2707 3940 | let svc = self.model_plugin.apply(svc);
|
2708 3941 | let svc =
|
2709 3942 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2710 3943 | .apply(svc);
|
2711 3944 | let svc = self.http_plugin.apply(svc);
|
2712 - | self.http_enum_payload_custom(svc)
|
3945 + | self.http_prefix_headers_custom(svc)
|
2713 3946 | }
|
2714 3947 |
|
2715 - | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) to a custom [`Service`](tower::Service).
|
3948 + | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) to a custom [`Service`](tower::Service).
|
2716 3949 | /// not constrained by the Smithy contract.
|
2717 - | fn http_enum_payload_custom<S>(mut self, svc: S) -> Self
|
3950 + | fn http_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
2718 3951 | where
|
2719 3952 | S: ::tower::Service<
|
2720 3953 | ::http::Request<Body>,
|
2721 3954 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2722 3955 | Error = ::std::convert::Infallible,
|
2723 3956 | > + Clone
|
2724 3957 | + Send
|
2725 3958 | + 'static,
|
2726 3959 | S::Future: Send + 'static,
|
2727 3960 | {
|
2728 - | self.http_enum_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3961 + | self.http_prefix_headers = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2729 3962 | self
|
2730 3963 | }
|
2731 3964 |
|
2732 - | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
3965 + | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
2733 3966 | ///
|
2734 3967 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2735 3968 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2736 3969 | ///
|
2737 3970 | /// # Example
|
2738 3971 | ///
|
2739 3972 | /// ```no_run
|
2740 3973 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2741 3974 | ///
|
2742 3975 | /// use rest_json_http0x::{input, output, error};
|
2743 3976 | ///
|
2744 - | /// async fn handler(input: input::HttpPayloadTraitsInput) -> output::HttpPayloadTraitsOutput {
|
3977 + | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> output::HttpPrefixHeadersInResponseOutput {
|
2745 3978 | /// todo!()
|
2746 3979 | /// }
|
2747 3980 | ///
|
2748 3981 | /// let config = RestJsonConfig::builder().build();
|
2749 3982 | /// let app = RestJson::builder(config)
|
2750 - | /// .http_payload_traits(handler)
|
3983 + | /// .http_prefix_headers_in_response(handler)
|
2751 3984 | /// /* Set other handlers */
|
2752 3985 | /// .build()
|
2753 3986 | /// .unwrap();
|
2754 3987 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2755 3988 | /// ```
|
2756 3989 | ///
|
2757 - | pub fn http_payload_traits<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3990 + | pub fn http_prefix_headers_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2758 3991 | where
|
2759 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraits, HandlerExtractors>,
|
3992 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerExtractors>,
|
2760 3993 |
|
2761 3994 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2762 3995 | RestJson<L>,
|
2763 - | crate::operation_shape::HttpPayloadTraits,
|
2764 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraits, HandlerType>
|
3996 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3997 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerType>
|
2765 3998 | >,
|
2766 3999 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2767 4000 | RestJson<L>,
|
2768 - | crate::operation_shape::HttpPayloadTraits,
|
4001 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2769 4002 | ModelPl::Output
|
2770 4003 | >,
|
2771 4004 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2772 4005 | RestJson<L>,
|
2773 - | crate::operation_shape::HttpPayloadTraits,
|
4006 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2774 4007 | <
|
2775 4008 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2776 4009 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2777 4010 | RestJson<L>,
|
2778 - | crate::operation_shape::HttpPayloadTraits,
|
4011 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2779 4012 | ModelPl::Output
|
2780 4013 | >
|
2781 4014 | >::Output
|
2782 4015 | >,
|
2783 4016 |
|
2784 4017 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2785 4018 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2786 4019 |
|
2787 4020 | {
|
2788 4021 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2789 4022 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2790 - | let svc = crate::operation_shape::HttpPayloadTraits::from_handler(handler);
|
4023 + | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_handler(handler);
|
2791 4024 | let svc = self.model_plugin.apply(svc);
|
2792 4025 | let svc =
|
2793 4026 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2794 4027 | .apply(svc);
|
2795 4028 | let svc = self.http_plugin.apply(svc);
|
2796 - | self.http_payload_traits_custom(svc)
|
4029 + | self.http_prefix_headers_in_response_custom(svc)
|
2797 4030 | }
|
2798 4031 |
|
2799 - | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
4032 + | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
2800 4033 | ///
|
2801 4034 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2802 4035 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2803 4036 | ///
|
2804 4037 | /// # Example
|
2805 4038 | ///
|
2806 4039 | /// ```no_run
|
2807 4040 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2808 4041 | ///
|
2809 4042 | /// use rest_json_http0x::{input, output, error};
|
2810 4043 | ///
|
2811 - | /// async fn handler(input: input::HttpPayloadTraitsInput) -> Result<output::HttpPayloadTraitsOutput, std::convert::Infallible> {
|
4044 + | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> Result<output::HttpPrefixHeadersInResponseOutput, std::convert::Infallible> {
|
2812 4045 | /// todo!()
|
2813 4046 | /// }
|
2814 4047 | ///
|
2815 4048 | /// let config = RestJsonConfig::builder().build();
|
2816 4049 | /// let svc = ::tower::util::service_fn(handler);
|
2817 4050 | /// let app = RestJson::builder(config)
|
2818 - | /// .http_payload_traits_service(svc)
|
4051 + | /// .http_prefix_headers_in_response_service(svc)
|
2819 4052 | /// /* Set other handlers */
|
2820 4053 | /// .build()
|
2821 4054 | /// .unwrap();
|
2822 4055 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2823 4056 | /// ```
|
2824 4057 | ///
|
2825 - | pub fn http_payload_traits_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4058 + | pub fn http_prefix_headers_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2826 4059 | where
|
2827 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraits, ServiceExtractors>,
|
4060 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeadersInResponse, ServiceExtractors>,
|
2828 4061 |
|
2829 4062 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2830 4063 | RestJson<L>,
|
2831 - | crate::operation_shape::HttpPayloadTraits,
|
2832 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraits, S>
|
4064 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4065 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeadersInResponse, S>
|
2833 4066 | >,
|
2834 4067 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2835 4068 | RestJson<L>,
|
2836 - | crate::operation_shape::HttpPayloadTraits,
|
4069 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2837 4070 | ModelPl::Output
|
2838 4071 | >,
|
2839 4072 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2840 4073 | RestJson<L>,
|
2841 - | crate::operation_shape::HttpPayloadTraits,
|
4074 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2842 4075 | <
|
2843 4076 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2844 4077 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2845 4078 | RestJson<L>,
|
2846 - | crate::operation_shape::HttpPayloadTraits,
|
4079 + | crate::operation_shape::HttpPrefixHeadersInResponse,
|
2847 4080 | ModelPl::Output
|
2848 4081 | >
|
2849 4082 | >::Output
|
2850 4083 | >,
|
2851 4084 |
|
2852 4085 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2853 4086 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2854 4087 |
|
2855 4088 | {
|
2856 4089 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2857 4090 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2858 - | let svc = crate::operation_shape::HttpPayloadTraits::from_service(service);
|
4091 + | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_service(service);
|
2859 4092 | let svc = self.model_plugin.apply(svc);
|
2860 4093 | let svc =
|
2861 4094 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2862 4095 | .apply(svc);
|
2863 4096 | let svc = self.http_plugin.apply(svc);
|
2864 - | self.http_payload_traits_custom(svc)
|
4097 + | self.http_prefix_headers_in_response_custom(svc)
|
2865 4098 | }
|
2866 4099 |
|
2867 - | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) to a custom [`Service`](tower::Service).
|
4100 + | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) to a custom [`Service`](tower::Service).
|
2868 4101 | /// not constrained by the Smithy contract.
|
2869 - | fn http_payload_traits_custom<S>(mut self, svc: S) -> Self
|
4102 + | fn http_prefix_headers_in_response_custom<S>(mut self, svc: S) -> Self
|
2870 4103 | where
|
2871 4104 | S: ::tower::Service<
|
2872 4105 | ::http::Request<Body>,
|
2873 4106 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2874 4107 | Error = ::std::convert::Infallible,
|
2875 4108 | > + Clone
|
2876 4109 | + Send
|
2877 4110 | + 'static,
|
2878 4111 | S::Future: Send + 'static,
|
2879 4112 | {
|
2880 - | self.http_payload_traits = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4113 + | self.http_prefix_headers_in_response =
|
4114 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2881 4115 | self
|
2882 4116 | }
|
2883 4117 |
|
2884 - | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
4118 + | /// Sets the [`HttpQueryParamsOnlyOperation`](crate::operation_shape::HttpQueryParamsOnlyOperation) operation.
|
2885 4119 | ///
|
2886 4120 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2887 4121 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2888 4122 | ///
|
2889 4123 | /// # Example
|
2890 4124 | ///
|
2891 4125 | /// ```no_run
|
2892 4126 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2893 4127 | ///
|
2894 4128 | /// use rest_json_http0x::{input, output, error};
|
2895 4129 | ///
|
2896 - | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> output::HttpPayloadTraitsWithMediaTypeOutput {
|
4130 + | /// async fn handler(input: input::HttpQueryParamsOnlyOperationInput) -> output::HttpQueryParamsOnlyOperationOutput {
|
2897 4131 | /// todo!()
|
2898 4132 | /// }
|
2899 4133 | ///
|
2900 4134 | /// let config = RestJsonConfig::builder().build();
|
2901 4135 | /// let app = RestJson::builder(config)
|
2902 - | /// .http_payload_traits_with_media_type(handler)
|
4136 + | /// .http_query_params_only_operation(handler)
|
2903 4137 | /// /* Set other handlers */
|
2904 4138 | /// .build()
|
2905 4139 | /// .unwrap();
|
2906 4140 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2907 4141 | /// ```
|
2908 4142 | ///
|
2909 - | pub fn http_payload_traits_with_media_type<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4143 + | pub fn http_query_params_only_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2910 4144 | where
|
2911 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerExtractors>,
|
4145 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpQueryParamsOnlyOperation, HandlerExtractors>,
|
2912 4146 |
|
2913 4147 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2914 4148 | RestJson<L>,
|
2915 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2916 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerType>
|
4149 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
4150 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpQueryParamsOnlyOperation, HandlerType>
|
2917 4151 | >,
|
2918 4152 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2919 4153 | RestJson<L>,
|
2920 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4154 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2921 4155 | ModelPl::Output
|
2922 4156 | >,
|
2923 4157 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2924 4158 | RestJson<L>,
|
2925 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4159 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2926 4160 | <
|
2927 4161 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2928 4162 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2929 4163 | RestJson<L>,
|
2930 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4164 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2931 4165 | ModelPl::Output
|
2932 4166 | >
|
2933 4167 | >::Output
|
2934 4168 | >,
|
2935 4169 |
|
2936 4170 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2937 4171 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2938 4172 |
|
2939 4173 | {
|
2940 4174 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2941 4175 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2942 - | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_handler(handler);
|
4176 + | let svc = crate::operation_shape::HttpQueryParamsOnlyOperation::from_handler(handler);
|
2943 4177 | let svc = self.model_plugin.apply(svc);
|
2944 4178 | let svc =
|
2945 4179 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2946 4180 | .apply(svc);
|
2947 4181 | let svc = self.http_plugin.apply(svc);
|
2948 - | self.http_payload_traits_with_media_type_custom(svc)
|
4182 + | self.http_query_params_only_operation_custom(svc)
|
2949 4183 | }
|
2950 4184 |
|
2951 - | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
4185 + | /// Sets the [`HttpQueryParamsOnlyOperation`](crate::operation_shape::HttpQueryParamsOnlyOperation) operation.
|
2952 4186 | ///
|
2953 4187 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2954 4188 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2955 4189 | ///
|
2956 4190 | /// # Example
|
2957 4191 | ///
|
2958 4192 | /// ```no_run
|
2959 4193 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
2960 4194 | ///
|
2961 4195 | /// use rest_json_http0x::{input, output, error};
|
2962 4196 | ///
|
2963 - | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> Result<output::HttpPayloadTraitsWithMediaTypeOutput, std::convert::Infallible> {
|
4197 + | /// async fn handler(input: input::HttpQueryParamsOnlyOperationInput) -> Result<output::HttpQueryParamsOnlyOperationOutput, std::convert::Infallible> {
|
2964 4198 | /// todo!()
|
2965 4199 | /// }
|
2966 4200 | ///
|
2967 4201 | /// let config = RestJsonConfig::builder().build();
|
2968 4202 | /// let svc = ::tower::util::service_fn(handler);
|
2969 4203 | /// let app = RestJson::builder(config)
|
2970 - | /// .http_payload_traits_with_media_type_service(svc)
|
4204 + | /// .http_query_params_only_operation_service(svc)
|
2971 4205 | /// /* Set other handlers */
|
2972 4206 | /// .build()
|
2973 4207 | /// .unwrap();
|
2974 4208 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2975 4209 | /// ```
|
2976 4210 | ///
|
2977 - | pub fn http_payload_traits_with_media_type_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4211 + | pub fn http_query_params_only_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2978 4212 | where
|
2979 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraitsWithMediaType, ServiceExtractors>,
|
4213 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpQueryParamsOnlyOperation, ServiceExtractors>,
|
2980 4214 |
|
2981 4215 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2982 4216 | RestJson<L>,
|
2983 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2984 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraitsWithMediaType, S>
|
4217 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
4218 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpQueryParamsOnlyOperation, S>
|
2985 4219 | >,
|
2986 4220 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2987 4221 | RestJson<L>,
|
2988 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4222 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2989 4223 | ModelPl::Output
|
2990 4224 | >,
|
2991 4225 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2992 4226 | RestJson<L>,
|
2993 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4227 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2994 4228 | <
|
2995 4229 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2996 4230 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2997 4231 | RestJson<L>,
|
2998 - | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
4232 + | crate::operation_shape::HttpQueryParamsOnlyOperation,
|
2999 4233 | ModelPl::Output
|
3000 4234 | >
|
3001 4235 | >::Output
|
3002 4236 | >,
|
3003 4237 |
|
3004 4238 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3005 4239 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3006 4240 |
|
3007 4241 | {
|
3008 4242 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3009 4243 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3010 - | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_service(service);
|
4244 + | let svc = crate::operation_shape::HttpQueryParamsOnlyOperation::from_service(service);
|
3011 4245 | let svc = self.model_plugin.apply(svc);
|
3012 4246 | let svc =
|
3013 4247 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3014 4248 | .apply(svc);
|
3015 4249 | let svc = self.http_plugin.apply(svc);
|
3016 - | self.http_payload_traits_with_media_type_custom(svc)
|
4250 + | self.http_query_params_only_operation_custom(svc)
|
3017 4251 | }
|
3018 4252 |
|
3019 - | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) to a custom [`Service`](tower::Service).
|
4253 + | /// Sets the [`HttpQueryParamsOnlyOperation`](crate::operation_shape::HttpQueryParamsOnlyOperation) to a custom [`Service`](tower::Service).
|
3020 4254 | /// not constrained by the Smithy contract.
|
3021 - | fn http_payload_traits_with_media_type_custom<S>(mut self, svc: S) -> Self
|
4255 + | fn http_query_params_only_operation_custom<S>(mut self, svc: S) -> Self
|
3022 4256 | where
|
3023 4257 | S: ::tower::Service<
|
3024 4258 | ::http::Request<Body>,
|
3025 4259 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3026 4260 | Error = ::std::convert::Infallible,
|
3027 4261 | > + Clone
|
3028 4262 | + Send
|
3029 4263 | + 'static,
|
3030 4264 | S::Future: Send + 'static,
|
3031 4265 | {
|
3032 - | self.http_payload_traits_with_media_type =
|
4266 + | self.http_query_params_only_operation =
|
3033 4267 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3034 4268 | self
|
3035 4269 | }
|
3036 4270 |
|
3037 - | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
4271 + | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
3038 4272 | ///
|
3039 4273 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3040 4274 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3041 4275 | ///
|
3042 4276 | /// # Example
|
3043 4277 | ///
|
3044 4278 | /// ```no_run
|
3045 4279 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3046 4280 | ///
|
3047 4281 | /// use rest_json_http0x::{input, output, error};
|
3048 4282 | ///
|
3049 - | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> output::HttpPayloadWithStructureOutput {
|
4283 + | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
3050 4284 | /// todo!()
|
3051 4285 | /// }
|
3052 4286 | ///
|
3053 4287 | /// let config = RestJsonConfig::builder().build();
|
3054 4288 | /// let app = RestJson::builder(config)
|
3055 - | /// .http_payload_with_structure(handler)
|
4289 + | /// .http_request_with_float_labels(handler)
|
3056 4290 | /// /* Set other handlers */
|
3057 4291 | /// .build()
|
3058 4292 | /// .unwrap();
|
3059 4293 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3060 4294 | /// ```
|
3061 4295 | ///
|
3062 - | pub fn http_payload_with_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4296 + | pub fn http_request_with_float_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3063 4297 | where
|
3064 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithStructure, HandlerExtractors>,
|
4298 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithFloatLabels, HandlerExtractors>,
|
3065 4299 |
|
3066 4300 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3067 4301 | RestJson<L>,
|
3068 - | crate::operation_shape::HttpPayloadWithStructure,
|
3069 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithStructure, HandlerType>
|
4302 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
4303 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithFloatLabels, HandlerType>
|
3070 4304 | >,
|
3071 4305 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3072 4306 | RestJson<L>,
|
3073 - | crate::operation_shape::HttpPayloadWithStructure,
|
4307 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3074 4308 | ModelPl::Output
|
3075 4309 | >,
|
3076 4310 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3077 4311 | RestJson<L>,
|
3078 - | crate::operation_shape::HttpPayloadWithStructure,
|
4312 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3079 4313 | <
|
3080 4314 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3081 4315 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3082 4316 | RestJson<L>,
|
3083 - | crate::operation_shape::HttpPayloadWithStructure,
|
4317 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3084 4318 | ModelPl::Output
|
3085 4319 | >
|
3086 4320 | >::Output
|
3087 4321 | >,
|
3088 4322 |
|
3089 4323 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3090 4324 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3091 4325 |
|
3092 4326 | {
|
3093 4327 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3094 4328 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3095 - | let svc = crate::operation_shape::HttpPayloadWithStructure::from_handler(handler);
|
4329 + | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_handler(handler);
|
3096 4330 | let svc = self.model_plugin.apply(svc);
|
3097 4331 | let svc =
|
3098 4332 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3099 4333 | .apply(svc);
|
3100 4334 | let svc = self.http_plugin.apply(svc);
|
3101 - | self.http_payload_with_structure_custom(svc)
|
4335 + | self.http_request_with_float_labels_custom(svc)
|
3102 4336 | }
|
3103 4337 |
|
3104 - | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
4338 + | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
3105 4339 | ///
|
3106 4340 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3107 4341 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3108 4342 | ///
|
3109 4343 | /// # Example
|
3110 4344 | ///
|
3111 4345 | /// ```no_run
|
3112 4346 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3113 4347 | ///
|
3114 4348 | /// use rest_json_http0x::{input, output, error};
|
3115 4349 | ///
|
3116 - | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> Result<output::HttpPayloadWithStructureOutput, std::convert::Infallible> {
|
4350 + | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
3117 4351 | /// todo!()
|
3118 4352 | /// }
|
3119 4353 | ///
|
3120 4354 | /// let config = RestJsonConfig::builder().build();
|
3121 4355 | /// let svc = ::tower::util::service_fn(handler);
|
3122 4356 | /// let app = RestJson::builder(config)
|
3123 - | /// .http_payload_with_structure_service(svc)
|
4357 + | /// .http_request_with_float_labels_service(svc)
|
3124 4358 | /// /* Set other handlers */
|
3125 4359 | /// .build()
|
3126 4360 | /// .unwrap();
|
3127 4361 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3128 4362 | /// ```
|
3129 4363 | ///
|
3130 - | pub fn http_payload_with_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4364 + | pub fn http_request_with_float_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3131 4365 | where
|
3132 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithStructure, ServiceExtractors>,
|
4366 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithFloatLabels, ServiceExtractors>,
|
3133 4367 |
|
3134 4368 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3135 4369 | RestJson<L>,
|
3136 - | crate::operation_shape::HttpPayloadWithStructure,
|
3137 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithStructure, S>
|
4370 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
4371 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithFloatLabels, S>
|
3138 4372 | >,
|
3139 4373 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3140 4374 | RestJson<L>,
|
3141 - | crate::operation_shape::HttpPayloadWithStructure,
|
4375 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3142 4376 | ModelPl::Output
|
3143 4377 | >,
|
3144 4378 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3145 4379 | RestJson<L>,
|
3146 - | crate::operation_shape::HttpPayloadWithStructure,
|
4380 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3147 4381 | <
|
3148 4382 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3149 4383 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3150 4384 | RestJson<L>,
|
3151 - | crate::operation_shape::HttpPayloadWithStructure,
|
4385 + | crate::operation_shape::HttpRequestWithFloatLabels,
|
3152 4386 | ModelPl::Output
|
3153 4387 | >
|
3154 4388 | >::Output
|
3155 4389 | >,
|
3156 4390 |
|
3157 4391 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3158 4392 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3159 4393 |
|
3160 4394 | {
|
3161 4395 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3162 4396 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3163 - | let svc = crate::operation_shape::HttpPayloadWithStructure::from_service(service);
|
4397 + | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_service(service);
|
3164 4398 | let svc = self.model_plugin.apply(svc);
|
3165 4399 | let svc =
|
3166 4400 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3167 4401 | .apply(svc);
|
3168 4402 | let svc = self.http_plugin.apply(svc);
|
3169 - | self.http_payload_with_structure_custom(svc)
|
4403 + | self.http_request_with_float_labels_custom(svc)
|
3170 4404 | }
|
3171 4405 |
|
3172 - | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) to a custom [`Service`](tower::Service).
|
4406 + | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) to a custom [`Service`](tower::Service).
|
3173 4407 | /// not constrained by the Smithy contract.
|
3174 - | fn http_payload_with_structure_custom<S>(mut self, svc: S) -> Self
|
4408 + | fn http_request_with_float_labels_custom<S>(mut self, svc: S) -> Self
|
3175 4409 | where
|
3176 4410 | S: ::tower::Service<
|
3177 4411 | ::http::Request<Body>,
|
3178 4412 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3179 4413 | Error = ::std::convert::Infallible,
|
3180 4414 | > + Clone
|
3181 4415 | + Send
|
3182 4416 | + 'static,
|
3183 4417 | S::Future: Send + 'static,
|
3184 4418 | {
|
3185 - | self.http_payload_with_structure =
|
4419 + | self.http_request_with_float_labels =
|
3186 4420 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3187 4421 | self
|
3188 4422 | }
|
3189 4423 |
|
3190 - | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
4424 + | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
3191 4425 | ///
|
3192 4426 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3193 4427 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3194 4428 | ///
|
3195 4429 | /// # Example
|
3196 4430 | ///
|
3197 4431 | /// ```no_run
|
3198 4432 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3199 4433 | ///
|
3200 4434 | /// use rest_json_http0x::{input, output, error};
|
3201 4435 | ///
|
3202 - | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> output::HttpPayloadWithUnionOutput {
|
4436 + | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
3203 4437 | /// todo!()
|
3204 4438 | /// }
|
3205 4439 | ///
|
3206 4440 | /// let config = RestJsonConfig::builder().build();
|
3207 4441 | /// let app = RestJson::builder(config)
|
3208 - | /// .http_payload_with_union(handler)
|
4442 + | /// .http_request_with_greedy_label_in_path(handler)
|
3209 4443 | /// /* Set other handlers */
|
3210 4444 | /// .build()
|
3211 4445 | /// .unwrap();
|
3212 4446 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3213 4447 | /// ```
|
3214 4448 | ///
|
3215 - | pub fn http_payload_with_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4449 + | pub fn http_request_with_greedy_label_in_path<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3216 4450 | where
|
3217 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithUnion, HandlerExtractors>,
|
4451 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerExtractors>,
|
3218 4452 |
|
3219 4453 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3220 4454 | RestJson<L>,
|
3221 - | crate::operation_shape::HttpPayloadWithUnion,
|
3222 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithUnion, HandlerType>
|
4455 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
4456 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerType>
|
3223 4457 | >,
|
3224 4458 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3225 4459 | RestJson<L>,
|
3226 - | crate::operation_shape::HttpPayloadWithUnion,
|
4460 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3227 4461 | ModelPl::Output
|
3228 4462 | >,
|
3229 4463 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3230 4464 | RestJson<L>,
|
3231 - | crate::operation_shape::HttpPayloadWithUnion,
|
4465 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3232 4466 | <
|
3233 4467 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3234 4468 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3235 4469 | RestJson<L>,
|
3236 - | crate::operation_shape::HttpPayloadWithUnion,
|
4470 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3237 4471 | ModelPl::Output
|
3238 4472 | >
|
3239 4473 | >::Output
|
3240 4474 | >,
|
3241 4475 |
|
3242 4476 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3243 4477 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3244 4478 |
|
3245 4479 | {
|
3246 4480 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3247 4481 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3248 - | let svc = crate::operation_shape::HttpPayloadWithUnion::from_handler(handler);
|
4482 + | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_handler(handler);
|
3249 4483 | let svc = self.model_plugin.apply(svc);
|
3250 4484 | let svc =
|
3251 4485 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3252 4486 | .apply(svc);
|
3253 4487 | let svc = self.http_plugin.apply(svc);
|
3254 - | self.http_payload_with_union_custom(svc)
|
4488 + | self.http_request_with_greedy_label_in_path_custom(svc)
|
3255 4489 | }
|
3256 4490 |
|
3257 - | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
4491 + | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
3258 4492 | ///
|
3259 4493 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3260 4494 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3261 4495 | ///
|
3262 4496 | /// # Example
|
3263 4497 | ///
|
3264 4498 | /// ```no_run
|
3265 4499 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3266 4500 | ///
|
3267 4501 | /// use rest_json_http0x::{input, output, error};
|
3268 4502 | ///
|
3269 - | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> Result<output::HttpPayloadWithUnionOutput, std::convert::Infallible> {
|
4503 + | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
3270 4504 | /// todo!()
|
3271 4505 | /// }
|
3272 4506 | ///
|
3273 4507 | /// let config = RestJsonConfig::builder().build();
|
3274 4508 | /// let svc = ::tower::util::service_fn(handler);
|
3275 4509 | /// let app = RestJson::builder(config)
|
3276 - | /// .http_payload_with_union_service(svc)
|
4510 + | /// .http_request_with_greedy_label_in_path_service(svc)
|
3277 4511 | /// /* Set other handlers */
|
3278 4512 | /// .build()
|
3279 4513 | /// .unwrap();
|
3280 4514 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3281 4515 | /// ```
|
3282 4516 | ///
|
3283 - | pub fn http_payload_with_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4517 + | pub fn http_request_with_greedy_label_in_path_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3284 4518 | where
|
3285 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithUnion, ServiceExtractors>,
|
4519 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, ServiceExtractors>,
|
3286 4520 |
|
3287 4521 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3288 4522 | RestJson<L>,
|
3289 - | crate::operation_shape::HttpPayloadWithUnion,
|
3290 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithUnion, S>
|
4523 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
4524 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithGreedyLabelInPath, S>
|
3291 4525 | >,
|
3292 4526 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3293 4527 | RestJson<L>,
|
3294 - | crate::operation_shape::HttpPayloadWithUnion,
|
4528 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3295 4529 | ModelPl::Output
|
3296 4530 | >,
|
3297 4531 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3298 4532 | RestJson<L>,
|
3299 - | crate::operation_shape::HttpPayloadWithUnion,
|
4533 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3300 4534 | <
|
3301 4535 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3302 4536 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3303 4537 | RestJson<L>,
|
3304 - | crate::operation_shape::HttpPayloadWithUnion,
|
4538 + | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3305 4539 | ModelPl::Output
|
3306 4540 | >
|
3307 4541 | >::Output
|
3308 4542 | >,
|
3309 4543 |
|
3310 4544 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3311 4545 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3312 4546 |
|
3313 4547 | {
|
3314 4548 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3315 4549 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3316 - | let svc = crate::operation_shape::HttpPayloadWithUnion::from_service(service);
|
4550 + | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_service(service);
|
3317 4551 | let svc = self.model_plugin.apply(svc);
|
3318 4552 | let svc =
|
3319 4553 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3320 4554 | .apply(svc);
|
3321 4555 | let svc = self.http_plugin.apply(svc);
|
3322 - | self.http_payload_with_union_custom(svc)
|
4556 + | self.http_request_with_greedy_label_in_path_custom(svc)
|
3323 4557 | }
|
3324 4558 |
|
3325 - | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) to a custom [`Service`](tower::Service).
|
4559 + | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) to a custom [`Service`](tower::Service).
|
3326 4560 | /// not constrained by the Smithy contract.
|
3327 - | fn http_payload_with_union_custom<S>(mut self, svc: S) -> Self
|
4561 + | fn http_request_with_greedy_label_in_path_custom<S>(mut self, svc: S) -> Self
|
3328 4562 | where
|
3329 4563 | S: ::tower::Service<
|
3330 4564 | ::http::Request<Body>,
|
3331 4565 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3332 4566 | Error = ::std::convert::Infallible,
|
3333 4567 | > + Clone
|
3334 4568 | + Send
|
3335 4569 | + 'static,
|
3336 4570 | S::Future: Send + 'static,
|
3337 4571 | {
|
3338 - | self.http_payload_with_union =
|
4572 + | self.http_request_with_greedy_label_in_path =
|
3339 4573 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3340 4574 | self
|
3341 4575 | }
|
3342 4576 |
|
3343 - | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
4577 + | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
3344 4578 | ///
|
3345 4579 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3346 4580 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3347 4581 | ///
|
3348 4582 | /// # Example
|
3349 4583 | ///
|
3350 4584 | /// ```no_run
|
3351 4585 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3352 4586 | ///
|
3353 4587 | /// use rest_json_http0x::{input, output, error};
|
3354 4588 | ///
|
3355 - | /// async fn handler(input: input::HttpPrefixHeadersInput) -> output::HttpPrefixHeadersOutput {
|
4589 + | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
3356 4590 | /// todo!()
|
3357 4591 | /// }
|
3358 4592 | ///
|
3359 4593 | /// let config = RestJsonConfig::builder().build();
|
3360 4594 | /// let app = RestJson::builder(config)
|
3361 - | /// .http_prefix_headers(handler)
|
4595 + | /// .http_request_with_labels(handler)
|
3362 4596 | /// /* Set other handlers */
|
3363 4597 | /// .build()
|
3364 4598 | /// .unwrap();
|
3365 4599 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3366 4600 | /// ```
|
3367 4601 | ///
|
3368 - | pub fn http_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4602 + | pub fn http_request_with_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3369 4603 | where
|
3370 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeaders, HandlerExtractors>,
|
4604 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabels, HandlerExtractors>,
|
3371 4605 |
|
3372 4606 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3373 4607 | RestJson<L>,
|
3374 - | crate::operation_shape::HttpPrefixHeaders,
|
3375 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeaders, HandlerType>
|
4608 + | crate::operation_shape::HttpRequestWithLabels,
|
4609 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabels, HandlerType>
|
3376 4610 | >,
|
3377 4611 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3378 4612 | RestJson<L>,
|
3379 - | crate::operation_shape::HttpPrefixHeaders,
|
4613 + | crate::operation_shape::HttpRequestWithLabels,
|
3380 4614 | ModelPl::Output
|
3381 4615 | >,
|
3382 4616 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3383 4617 | RestJson<L>,
|
3384 - | crate::operation_shape::HttpPrefixHeaders,
|
4618 + | crate::operation_shape::HttpRequestWithLabels,
|
3385 4619 | <
|
3386 4620 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3387 4621 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3388 4622 | RestJson<L>,
|
3389 - | crate::operation_shape::HttpPrefixHeaders,
|
4623 + | crate::operation_shape::HttpRequestWithLabels,
|
3390 4624 | ModelPl::Output
|
3391 4625 | >
|
3392 4626 | >::Output
|
3393 4627 | >,
|
3394 4628 |
|
3395 4629 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3396 4630 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3397 4631 |
|
3398 4632 | {
|
3399 4633 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3400 4634 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3401 - | let svc = crate::operation_shape::HttpPrefixHeaders::from_handler(handler);
|
4635 + | let svc = crate::operation_shape::HttpRequestWithLabels::from_handler(handler);
|
3402 4636 | let svc = self.model_plugin.apply(svc);
|
3403 4637 | let svc =
|
3404 4638 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3405 4639 | .apply(svc);
|
3406 4640 | let svc = self.http_plugin.apply(svc);
|
3407 - | self.http_prefix_headers_custom(svc)
|
4641 + | self.http_request_with_labels_custom(svc)
|
3408 4642 | }
|
3409 4643 |
|
3410 - | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
4644 + | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
3411 4645 | ///
|
3412 4646 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3413 4647 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3414 4648 | ///
|
3415 4649 | /// # Example
|
3416 4650 | ///
|
3417 4651 | /// ```no_run
|
3418 4652 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3419 4653 | ///
|
3420 4654 | /// use rest_json_http0x::{input, output, error};
|
3421 4655 | ///
|
3422 - | /// async fn handler(input: input::HttpPrefixHeadersInput) -> Result<output::HttpPrefixHeadersOutput, std::convert::Infallible> {
|
4656 + | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
3423 4657 | /// todo!()
|
3424 4658 | /// }
|
3425 4659 | ///
|
3426 4660 | /// let config = RestJsonConfig::builder().build();
|
3427 4661 | /// let svc = ::tower::util::service_fn(handler);
|
3428 4662 | /// let app = RestJson::builder(config)
|
3429 - | /// .http_prefix_headers_service(svc)
|
4663 + | /// .http_request_with_labels_service(svc)
|
3430 4664 | /// /* Set other handlers */
|
3431 4665 | /// .build()
|
3432 4666 | /// .unwrap();
|
3433 4667 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3434 4668 | /// ```
|
3435 4669 | ///
|
3436 - | pub fn http_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4670 + | pub fn http_request_with_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3437 4671 | where
|
3438 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeaders, ServiceExtractors>,
|
4672 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabels, ServiceExtractors>,
|
3439 4673 |
|
3440 4674 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3441 4675 | RestJson<L>,
|
3442 - | crate::operation_shape::HttpPrefixHeaders,
|
3443 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeaders, S>
|
4676 + | crate::operation_shape::HttpRequestWithLabels,
|
4677 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabels, S>
|
3444 4678 | >,
|
3445 4679 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3446 4680 | RestJson<L>,
|
3447 - | crate::operation_shape::HttpPrefixHeaders,
|
4681 + | crate::operation_shape::HttpRequestWithLabels,
|
3448 4682 | ModelPl::Output
|
3449 4683 | >,
|
3450 4684 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3451 4685 | RestJson<L>,
|
3452 - | crate::operation_shape::HttpPrefixHeaders,
|
4686 + | crate::operation_shape::HttpRequestWithLabels,
|
3453 4687 | <
|
3454 4688 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3455 4689 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3456 4690 | RestJson<L>,
|
3457 - | crate::operation_shape::HttpPrefixHeaders,
|
4691 + | crate::operation_shape::HttpRequestWithLabels,
|
3458 4692 | ModelPl::Output
|
3459 4693 | >
|
3460 4694 | >::Output
|
3461 4695 | >,
|
3462 4696 |
|
3463 4697 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3464 4698 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3465 4699 |
|
3466 4700 | {
|
3467 4701 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3468 4702 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3469 - | let svc = crate::operation_shape::HttpPrefixHeaders::from_service(service);
|
4703 + | let svc = crate::operation_shape::HttpRequestWithLabels::from_service(service);
|
3470 4704 | let svc = self.model_plugin.apply(svc);
|
3471 4705 | let svc =
|
3472 4706 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3473 4707 | .apply(svc);
|
3474 4708 | let svc = self.http_plugin.apply(svc);
|
3475 - | self.http_prefix_headers_custom(svc)
|
4709 + | self.http_request_with_labels_custom(svc)
|
3476 4710 | }
|
3477 4711 |
|
3478 - | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) to a custom [`Service`](tower::Service).
|
4712 + | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) to a custom [`Service`](tower::Service).
|
3479 4713 | /// not constrained by the Smithy contract.
|
3480 - | fn http_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
4714 + | fn http_request_with_labels_custom<S>(mut self, svc: S) -> Self
|
3481 4715 | where
|
3482 4716 | S: ::tower::Service<
|
3483 4717 | ::http::Request<Body>,
|
3484 4718 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3485 4719 | Error = ::std::convert::Infallible,
|
3486 4720 | > + Clone
|
3487 4721 | + Send
|
3488 4722 | + 'static,
|
3489 4723 | S::Future: Send + 'static,
|
3490 4724 | {
|
3491 - | self.http_prefix_headers = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4725 + | self.http_request_with_labels =
|
4726 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3492 4727 | self
|
3493 4728 | }
|
3494 4729 |
|
3495 - | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
4730 + | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
3496 4731 | ///
|
3497 4732 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3498 4733 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3499 4734 | ///
|
3500 4735 | /// # Example
|
3501 4736 | ///
|
3502 4737 | /// ```no_run
|
3503 4738 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3504 4739 | ///
|
3505 4740 | /// use rest_json_http0x::{input, output, error};
|
3506 4741 | ///
|
3507 - | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> output::HttpPrefixHeadersInResponseOutput {
|
4742 + | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
3508 4743 | /// todo!()
|
3509 4744 | /// }
|
3510 4745 | ///
|
3511 4746 | /// let config = RestJsonConfig::builder().build();
|
3512 4747 | /// let app = RestJson::builder(config)
|
3513 - | /// .http_prefix_headers_in_response(handler)
|
4748 + | /// .http_request_with_labels_and_timestamp_format(handler)
|
3514 4749 | /// /* Set other handlers */
|
3515 4750 | /// .build()
|
3516 4751 | /// .unwrap();
|
3517 4752 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3518 4753 | /// ```
|
3519 4754 | ///
|
3520 - | pub fn http_prefix_headers_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4755 + | pub fn http_request_with_labels_and_timestamp_format<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3521 4756 | where
|
3522 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerExtractors>,
|
4757 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerExtractors>,
|
3523 4758 |
|
3524 4759 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3525 4760 | RestJson<L>,
|
3526 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3527 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerType>
|
4761 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4762 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerType>
|
3528 4763 | >,
|
3529 4764 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3530 4765 | RestJson<L>,
|
3531 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4766 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3532 4767 | ModelPl::Output
|
3533 4768 | >,
|
3534 4769 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3535 4770 | RestJson<L>,
|
3536 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4771 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3537 4772 | <
|
3538 4773 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3539 4774 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3540 4775 | RestJson<L>,
|
3541 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4776 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3542 4777 | ModelPl::Output
|
3543 4778 | >
|
3544 4779 | >::Output
|
3545 4780 | >,
|
3546 4781 |
|
3547 4782 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3548 4783 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3549 4784 |
|
3550 4785 | {
|
3551 4786 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3552 4787 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3553 - | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_handler(handler);
|
4788 + | let svc =
|
4789 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_handler(handler);
|
3554 4790 | let svc = self.model_plugin.apply(svc);
|
3555 4791 | let svc =
|
3556 4792 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3557 4793 | .apply(svc);
|
3558 4794 | let svc = self.http_plugin.apply(svc);
|
3559 - | self.http_prefix_headers_in_response_custom(svc)
|
4795 + | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
3560 4796 | }
|
3561 4797 |
|
3562 - | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
4798 + | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
3563 4799 | ///
|
3564 4800 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3565 4801 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3566 4802 | ///
|
3567 4803 | /// # Example
|
3568 4804 | ///
|
3569 4805 | /// ```no_run
|
3570 4806 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3571 4807 | ///
|
3572 4808 | /// use rest_json_http0x::{input, output, error};
|
3573 4809 | ///
|
3574 - | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> Result<output::HttpPrefixHeadersInResponseOutput, std::convert::Infallible> {
|
4810 + | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
3575 4811 | /// todo!()
|
3576 4812 | /// }
|
3577 4813 | ///
|
3578 4814 | /// let config = RestJsonConfig::builder().build();
|
3579 4815 | /// let svc = ::tower::util::service_fn(handler);
|
3580 4816 | /// let app = RestJson::builder(config)
|
3581 - | /// .http_prefix_headers_in_response_service(svc)
|
4817 + | /// .http_request_with_labels_and_timestamp_format_service(svc)
|
3582 4818 | /// /* Set other handlers */
|
3583 4819 | /// .build()
|
3584 4820 | /// .unwrap();
|
3585 4821 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3586 4822 | /// ```
|
3587 4823 | ///
|
3588 - | pub fn http_prefix_headers_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4824 + | pub fn http_request_with_labels_and_timestamp_format_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3589 4825 | where
|
3590 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeadersInResponse, ServiceExtractors>,
|
4826 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, ServiceExtractors>,
|
3591 4827 |
|
3592 4828 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3593 4829 | RestJson<L>,
|
3594 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3595 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeadersInResponse, S>
|
4830 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4831 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, S>
|
3596 4832 | >,
|
3597 4833 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3598 4834 | RestJson<L>,
|
3599 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4835 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3600 4836 | ModelPl::Output
|
3601 4837 | >,
|
3602 4838 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3603 4839 | RestJson<L>,
|
3604 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4840 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3605 4841 | <
|
3606 4842 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3607 4843 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3608 4844 | RestJson<L>,
|
3609 - | crate::operation_shape::HttpPrefixHeadersInResponse,
|
4845 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
3610 4846 | ModelPl::Output
|
3611 4847 | >
|
3612 4848 | >::Output
|
3613 4849 | >,
|
3614 4850 |
|
3615 4851 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3616 4852 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3617 4853 |
|
3618 4854 | {
|
3619 4855 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3620 4856 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3621 - | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_service(service);
|
4857 + | let svc =
|
4858 + | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_service(service);
|
3622 4859 | let svc = self.model_plugin.apply(svc);
|
3623 4860 | let svc =
|
3624 4861 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3625 4862 | .apply(svc);
|
3626 4863 | let svc = self.http_plugin.apply(svc);
|
3627 - | self.http_prefix_headers_in_response_custom(svc)
|
4864 + | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
3628 4865 | }
|
3629 4866 |
|
3630 - | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) to a custom [`Service`](tower::Service).
|
4867 + | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) to a custom [`Service`](tower::Service).
|
3631 4868 | /// not constrained by the Smithy contract.
|
3632 - | fn http_prefix_headers_in_response_custom<S>(mut self, svc: S) -> Self
|
4869 + | fn http_request_with_labels_and_timestamp_format_custom<S>(mut self, svc: S) -> Self
|
3633 4870 | where
|
3634 4871 | S: ::tower::Service<
|
3635 4872 | ::http::Request<Body>,
|
3636 4873 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3637 4874 | Error = ::std::convert::Infallible,
|
3638 4875 | > + Clone
|
3639 4876 | + Send
|
3640 4877 | + 'static,
|
3641 4878 | S::Future: Send + 'static,
|
3642 4879 | {
|
3643 - | self.http_prefix_headers_in_response =
|
4880 + | self.http_request_with_labels_and_timestamp_format =
|
3644 4881 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3645 4882 | self
|
3646 4883 | }
|
3647 4884 |
|
3648 - | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
4885 + | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
3649 4886 | ///
|
3650 4887 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3651 4888 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3652 4889 | ///
|
3653 4890 | /// # Example
|
3654 4891 | ///
|
3655 4892 | /// ```no_run
|
3656 4893 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3657 4894 | ///
|
3658 4895 | /// use rest_json_http0x::{input, output, error};
|
3659 4896 | ///
|
3660 - | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
4897 + | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
3661 4898 | /// todo!()
|
3662 4899 | /// }
|
3663 4900 | ///
|
3664 4901 | /// let config = RestJsonConfig::builder().build();
|
3665 4902 | /// let app = RestJson::builder(config)
|
3666 - | /// .http_request_with_float_labels(handler)
|
4903 + | /// .http_request_with_regex_literal(handler)
|
3667 4904 | /// /* Set other handlers */
|
3668 4905 | /// .build()
|
3669 4906 | /// .unwrap();
|
3670 4907 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3671 4908 | /// ```
|
3672 4909 | ///
|
3673 - | pub fn http_request_with_float_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4910 + | pub fn http_request_with_regex_literal<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3674 4911 | where
|
3675 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithFloatLabels, HandlerExtractors>,
|
4912 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerExtractors>,
|
3676 4913 |
|
3677 4914 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3678 4915 | RestJson<L>,
|
3679 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
3680 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithFloatLabels, HandlerType>
|
4916 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4917 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerType>
|
3681 4918 | >,
|
3682 4919 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3683 4920 | RestJson<L>,
|
3684 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4921 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3685 4922 | ModelPl::Output
|
3686 4923 | >,
|
3687 4924 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3688 4925 | RestJson<L>,
|
3689 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4926 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3690 4927 | <
|
3691 4928 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3692 4929 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3693 4930 | RestJson<L>,
|
3694 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4931 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3695 4932 | ModelPl::Output
|
3696 4933 | >
|
3697 4934 | >::Output
|
3698 4935 | >,
|
3699 4936 |
|
3700 4937 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3701 4938 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3702 4939 |
|
3703 4940 | {
|
3704 4941 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3705 4942 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3706 - | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_handler(handler);
|
4943 + | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_handler(handler);
|
3707 4944 | let svc = self.model_plugin.apply(svc);
|
3708 4945 | let svc =
|
3709 4946 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3710 4947 | .apply(svc);
|
3711 4948 | let svc = self.http_plugin.apply(svc);
|
3712 - | self.http_request_with_float_labels_custom(svc)
|
4949 + | self.http_request_with_regex_literal_custom(svc)
|
3713 4950 | }
|
3714 4951 |
|
3715 - | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
4952 + | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
3716 4953 | ///
|
3717 4954 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3718 4955 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3719 4956 | ///
|
3720 4957 | /// # Example
|
3721 4958 | ///
|
3722 4959 | /// ```no_run
|
3723 4960 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3724 4961 | ///
|
3725 4962 | /// use rest_json_http0x::{input, output, error};
|
3726 4963 | ///
|
3727 - | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
4964 + | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
3728 4965 | /// todo!()
|
3729 4966 | /// }
|
3730 4967 | ///
|
3731 4968 | /// let config = RestJsonConfig::builder().build();
|
3732 4969 | /// let svc = ::tower::util::service_fn(handler);
|
3733 4970 | /// let app = RestJson::builder(config)
|
3734 - | /// .http_request_with_float_labels_service(svc)
|
4971 + | /// .http_request_with_regex_literal_service(svc)
|
3735 4972 | /// /* Set other handlers */
|
3736 4973 | /// .build()
|
3737 4974 | /// .unwrap();
|
3738 4975 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3739 4976 | /// ```
|
3740 4977 | ///
|
3741 - | pub fn http_request_with_float_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4978 + | pub fn http_request_with_regex_literal_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3742 4979 | where
|
3743 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithFloatLabels, ServiceExtractors>,
|
4980 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithRegexLiteral, ServiceExtractors>,
|
3744 4981 |
|
3745 4982 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3746 4983 | RestJson<L>,
|
3747 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
3748 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithFloatLabels, S>
|
4984 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4985 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithRegexLiteral, S>
|
3749 4986 | >,
|
3750 4987 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3751 4988 | RestJson<L>,
|
3752 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4989 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3753 4990 | ModelPl::Output
|
3754 4991 | >,
|
3755 4992 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3756 4993 | RestJson<L>,
|
3757 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4994 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3758 4995 | <
|
3759 4996 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3760 4997 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3761 4998 | RestJson<L>,
|
3762 - | crate::operation_shape::HttpRequestWithFloatLabels,
|
4999 + | crate::operation_shape::HttpRequestWithRegexLiteral,
|
3763 5000 | ModelPl::Output
|
3764 5001 | >
|
3765 5002 | >::Output
|
3766 5003 | >,
|
3767 5004 |
|
3768 5005 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3769 5006 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3770 5007 |
|
3771 5008 | {
|
3772 5009 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3773 5010 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3774 - | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_service(service);
|
5011 + | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_service(service);
|
3775 5012 | let svc = self.model_plugin.apply(svc);
|
3776 5013 | let svc =
|
3777 5014 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3778 5015 | .apply(svc);
|
3779 5016 | let svc = self.http_plugin.apply(svc);
|
3780 - | self.http_request_with_float_labels_custom(svc)
|
5017 + | self.http_request_with_regex_literal_custom(svc)
|
3781 5018 | }
|
3782 5019 |
|
3783 - | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) to a custom [`Service`](tower::Service).
|
5020 + | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) to a custom [`Service`](tower::Service).
|
3784 5021 | /// not constrained by the Smithy contract.
|
3785 - | fn http_request_with_float_labels_custom<S>(mut self, svc: S) -> Self
|
5022 + | fn http_request_with_regex_literal_custom<S>(mut self, svc: S) -> Self
|
3786 5023 | where
|
3787 5024 | S: ::tower::Service<
|
3788 5025 | ::http::Request<Body>,
|
3789 5026 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3790 5027 | Error = ::std::convert::Infallible,
|
3791 5028 | > + Clone
|
3792 5029 | + Send
|
3793 5030 | + 'static,
|
3794 5031 | S::Future: Send + 'static,
|
3795 5032 | {
|
3796 - | self.http_request_with_float_labels =
|
5033 + | self.http_request_with_regex_literal =
|
3797 5034 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3798 5035 | self
|
3799 5036 | }
|
3800 5037 |
|
3801 - | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
5038 + | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
3802 5039 | ///
|
3803 5040 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3804 5041 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3805 5042 | ///
|
3806 5043 | /// # Example
|
3807 5044 | ///
|
3808 5045 | /// ```no_run
|
3809 5046 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3810 5047 | ///
|
3811 5048 | /// use rest_json_http0x::{input, output, error};
|
3812 5049 | ///
|
3813 - | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
5050 + | /// async fn handler(input: input::HttpResponseCodeInput) -> output::HttpResponseCodeOutput {
|
3814 5051 | /// todo!()
|
3815 5052 | /// }
|
3816 5053 | ///
|
3817 5054 | /// let config = RestJsonConfig::builder().build();
|
3818 5055 | /// let app = RestJson::builder(config)
|
3819 - | /// .http_request_with_greedy_label_in_path(handler)
|
5056 + | /// .http_response_code(handler)
|
3820 5057 | /// /* Set other handlers */
|
3821 5058 | /// .build()
|
3822 5059 | /// .unwrap();
|
3823 5060 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3824 5061 | /// ```
|
3825 5062 | ///
|
3826 - | pub fn http_request_with_greedy_label_in_path<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5063 + | pub fn http_response_code<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3827 5064 | where
|
3828 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerExtractors>,
|
5065 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpResponseCode, HandlerExtractors>,
|
3829 5066 |
|
3830 5067 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3831 5068 | RestJson<L>,
|
3832 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3833 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerType>
|
5069 + | crate::operation_shape::HttpResponseCode,
|
5070 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpResponseCode, HandlerType>
|
3834 5071 | >,
|
3835 5072 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3836 5073 | RestJson<L>,
|
3837 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5074 + | crate::operation_shape::HttpResponseCode,
|
3838 5075 | ModelPl::Output
|
3839 5076 | >,
|
3840 5077 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3841 5078 | RestJson<L>,
|
3842 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5079 + | crate::operation_shape::HttpResponseCode,
|
3843 5080 | <
|
3844 5081 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3845 5082 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3846 5083 | RestJson<L>,
|
3847 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5084 + | crate::operation_shape::HttpResponseCode,
|
3848 5085 | ModelPl::Output
|
3849 5086 | >
|
3850 5087 | >::Output
|
3851 5088 | >,
|
3852 5089 |
|
3853 5090 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3854 5091 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3855 5092 |
|
3856 5093 | {
|
3857 5094 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3858 5095 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3859 - | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_handler(handler);
|
5096 + | let svc = crate::operation_shape::HttpResponseCode::from_handler(handler);
|
3860 5097 | let svc = self.model_plugin.apply(svc);
|
3861 5098 | let svc =
|
3862 5099 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3863 5100 | .apply(svc);
|
3864 5101 | let svc = self.http_plugin.apply(svc);
|
3865 - | self.http_request_with_greedy_label_in_path_custom(svc)
|
5102 + | self.http_response_code_custom(svc)
|
3866 5103 | }
|
3867 5104 |
|
3868 - | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
5105 + | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
3869 5106 | ///
|
3870 5107 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3871 5108 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3872 5109 | ///
|
3873 5110 | /// # Example
|
3874 5111 | ///
|
3875 5112 | /// ```no_run
|
3876 5113 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3877 5114 | ///
|
3878 5115 | /// use rest_json_http0x::{input, output, error};
|
3879 5116 | ///
|
3880 - | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
5117 + | /// async fn handler(input: input::HttpResponseCodeInput) -> Result<output::HttpResponseCodeOutput, std::convert::Infallible> {
|
3881 5118 | /// todo!()
|
3882 5119 | /// }
|
3883 5120 | ///
|
3884 5121 | /// let config = RestJsonConfig::builder().build();
|
3885 5122 | /// let svc = ::tower::util::service_fn(handler);
|
3886 5123 | /// let app = RestJson::builder(config)
|
3887 - | /// .http_request_with_greedy_label_in_path_service(svc)
|
5124 + | /// .http_response_code_service(svc)
|
3888 5125 | /// /* Set other handlers */
|
3889 5126 | /// .build()
|
3890 5127 | /// .unwrap();
|
3891 5128 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3892 5129 | /// ```
|
3893 5130 | ///
|
3894 - | pub fn http_request_with_greedy_label_in_path_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5131 + | pub fn http_response_code_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3895 5132 | where
|
3896 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, ServiceExtractors>,
|
5133 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpResponseCode, ServiceExtractors>,
|
3897 5134 |
|
3898 5135 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3899 5136 | RestJson<L>,
|
3900 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3901 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithGreedyLabelInPath, S>
|
5137 + | crate::operation_shape::HttpResponseCode,
|
5138 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpResponseCode, S>
|
3902 5139 | >,
|
3903 5140 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3904 5141 | RestJson<L>,
|
3905 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5142 + | crate::operation_shape::HttpResponseCode,
|
3906 5143 | ModelPl::Output
|
3907 5144 | >,
|
3908 5145 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3909 5146 | RestJson<L>,
|
3910 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5147 + | crate::operation_shape::HttpResponseCode,
|
3911 5148 | <
|
3912 5149 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3913 5150 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3914 5151 | RestJson<L>,
|
3915 - | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
5152 + | crate::operation_shape::HttpResponseCode,
|
3916 5153 | ModelPl::Output
|
3917 5154 | >
|
3918 5155 | >::Output
|
3919 5156 | >,
|
3920 5157 |
|
3921 5158 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3922 5159 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3923 5160 |
|
3924 5161 | {
|
3925 5162 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3926 5163 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3927 - | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_service(service);
|
5164 + | let svc = crate::operation_shape::HttpResponseCode::from_service(service);
|
3928 5165 | let svc = self.model_plugin.apply(svc);
|
3929 5166 | let svc =
|
3930 5167 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3931 5168 | .apply(svc);
|
3932 5169 | let svc = self.http_plugin.apply(svc);
|
3933 - | self.http_request_with_greedy_label_in_path_custom(svc)
|
5170 + | self.http_response_code_custom(svc)
|
3934 5171 | }
|
3935 5172 |
|
3936 - | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) to a custom [`Service`](tower::Service).
|
5173 + | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) to a custom [`Service`](tower::Service).
|
3937 5174 | /// not constrained by the Smithy contract.
|
3938 - | fn http_request_with_greedy_label_in_path_custom<S>(mut self, svc: S) -> Self
|
5175 + | fn http_response_code_custom<S>(mut self, svc: S) -> Self
|
3939 5176 | where
|
3940 5177 | S: ::tower::Service<
|
3941 5178 | ::http::Request<Body>,
|
3942 5179 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3943 5180 | Error = ::std::convert::Infallible,
|
3944 5181 | > + Clone
|
3945 5182 | + Send
|
3946 5183 | + 'static,
|
3947 5184 | S::Future: Send + 'static,
|
3948 5185 | {
|
3949 - | self.http_request_with_greedy_label_in_path =
|
3950 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5186 + | self.http_response_code = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3951 5187 | self
|
3952 5188 | }
|
3953 5189 |
|
3954 - | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
5190 + | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
3955 5191 | ///
|
3956 5192 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3957 5193 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3958 5194 | ///
|
3959 5195 | /// # Example
|
3960 5196 | ///
|
3961 5197 | /// ```no_run
|
3962 5198 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
3963 5199 | ///
|
3964 5200 | /// use rest_json_http0x::{input, output, error};
|
3965 5201 | ///
|
3966 - | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
5202 + | /// async fn handler(input: input::HttpStringPayloadInput) -> output::HttpStringPayloadOutput {
|
3967 5203 | /// todo!()
|
3968 5204 | /// }
|
3969 5205 | ///
|
3970 5206 | /// let config = RestJsonConfig::builder().build();
|
3971 5207 | /// let app = RestJson::builder(config)
|
3972 - | /// .http_request_with_labels(handler)
|
5208 + | /// .http_string_payload(handler)
|
3973 5209 | /// /* Set other handlers */
|
3974 5210 | /// .build()
|
3975 5211 | /// .unwrap();
|
3976 5212 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3977 5213 | /// ```
|
3978 5214 | ///
|
3979 - | pub fn http_request_with_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5215 + | pub fn http_string_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3980 5216 | where
|
3981 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabels, HandlerExtractors>,
|
5217 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpStringPayload, HandlerExtractors>,
|
3982 5218 |
|
3983 5219 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3984 5220 | RestJson<L>,
|
3985 - | crate::operation_shape::HttpRequestWithLabels,
|
3986 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabels, HandlerType>
|
5221 + | crate::operation_shape::HttpStringPayload,
|
5222 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpStringPayload, HandlerType>
|
3987 5223 | >,
|
3988 5224 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3989 5225 | RestJson<L>,
|
3990 - | crate::operation_shape::HttpRequestWithLabels,
|
5226 + | crate::operation_shape::HttpStringPayload,
|
3991 5227 | ModelPl::Output
|
3992 5228 | >,
|
3993 5229 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3994 5230 | RestJson<L>,
|
3995 - | crate::operation_shape::HttpRequestWithLabels,
|
5231 + | crate::operation_shape::HttpStringPayload,
|
3996 5232 | <
|
3997 5233 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3998 5234 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3999 5235 | RestJson<L>,
|
4000 - | crate::operation_shape::HttpRequestWithLabels,
|
5236 + | crate::operation_shape::HttpStringPayload,
|
4001 5237 | ModelPl::Output
|
4002 5238 | >
|
4003 5239 | >::Output
|
4004 5240 | >,
|
4005 5241 |
|
4006 5242 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4007 5243 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4008 5244 |
|
4009 5245 | {
|
4010 5246 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4011 5247 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4012 - | let svc = crate::operation_shape::HttpRequestWithLabels::from_handler(handler);
|
5248 + | let svc = crate::operation_shape::HttpStringPayload::from_handler(handler);
|
4013 5249 | let svc = self.model_plugin.apply(svc);
|
4014 5250 | let svc =
|
4015 5251 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4016 5252 | .apply(svc);
|
4017 5253 | let svc = self.http_plugin.apply(svc);
|
4018 - | self.http_request_with_labels_custom(svc)
|
5254 + | self.http_string_payload_custom(svc)
|
4019 5255 | }
|
4020 5256 |
|
4021 - | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
5257 + | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
4022 5258 | ///
|
4023 5259 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4024 5260 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4025 5261 | ///
|
4026 5262 | /// # Example
|
4027 5263 | ///
|
4028 5264 | /// ```no_run
|
4029 5265 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4030 5266 | ///
|
4031 5267 | /// use rest_json_http0x::{input, output, error};
|
4032 5268 | ///
|
4033 - | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
5269 + | /// async fn handler(input: input::HttpStringPayloadInput) -> Result<output::HttpStringPayloadOutput, std::convert::Infallible> {
|
4034 5270 | /// todo!()
|
4035 5271 | /// }
|
4036 5272 | ///
|
4037 5273 | /// let config = RestJsonConfig::builder().build();
|
4038 5274 | /// let svc = ::tower::util::service_fn(handler);
|
4039 5275 | /// let app = RestJson::builder(config)
|
4040 - | /// .http_request_with_labels_service(svc)
|
5276 + | /// .http_string_payload_service(svc)
|
4041 5277 | /// /* Set other handlers */
|
4042 5278 | /// .build()
|
4043 5279 | /// .unwrap();
|
4044 5280 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4045 5281 | /// ```
|
4046 5282 | ///
|
4047 - | pub fn http_request_with_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5283 + | pub fn http_string_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4048 5284 | where
|
4049 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabels, ServiceExtractors>,
|
5285 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpStringPayload, ServiceExtractors>,
|
4050 5286 |
|
4051 5287 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4052 5288 | RestJson<L>,
|
4053 - | crate::operation_shape::HttpRequestWithLabels,
|
4054 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabels, S>
|
5289 + | crate::operation_shape::HttpStringPayload,
|
5290 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpStringPayload, S>
|
4055 5291 | >,
|
4056 5292 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4057 5293 | RestJson<L>,
|
4058 - | crate::operation_shape::HttpRequestWithLabels,
|
5294 + | crate::operation_shape::HttpStringPayload,
|
4059 5295 | ModelPl::Output
|
4060 5296 | >,
|
4061 5297 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4062 5298 | RestJson<L>,
|
4063 - | crate::operation_shape::HttpRequestWithLabels,
|
5299 + | crate::operation_shape::HttpStringPayload,
|
4064 5300 | <
|
4065 5301 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4066 5302 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4067 5303 | RestJson<L>,
|
4068 - | crate::operation_shape::HttpRequestWithLabels,
|
5304 + | crate::operation_shape::HttpStringPayload,
|
4069 5305 | ModelPl::Output
|
4070 5306 | >
|
4071 5307 | >::Output
|
4072 5308 | >,
|
4073 5309 |
|
4074 5310 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4075 5311 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4076 5312 |
|
4077 5313 | {
|
4078 5314 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4079 5315 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4080 - | let svc = crate::operation_shape::HttpRequestWithLabels::from_service(service);
|
5316 + | let svc = crate::operation_shape::HttpStringPayload::from_service(service);
|
4081 5317 | let svc = self.model_plugin.apply(svc);
|
4082 5318 | let svc =
|
4083 5319 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4084 5320 | .apply(svc);
|
4085 5321 | let svc = self.http_plugin.apply(svc);
|
4086 - | self.http_request_with_labels_custom(svc)
|
5322 + | self.http_string_payload_custom(svc)
|
4087 5323 | }
|
4088 5324 |
|
4089 - | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) to a custom [`Service`](tower::Service).
|
5325 + | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) to a custom [`Service`](tower::Service).
|
4090 5326 | /// not constrained by the Smithy contract.
|
4091 - | fn http_request_with_labels_custom<S>(mut self, svc: S) -> Self
|
5327 + | fn http_string_payload_custom<S>(mut self, svc: S) -> Self
|
4092 5328 | where
|
4093 5329 | S: ::tower::Service<
|
4094 5330 | ::http::Request<Body>,
|
4095 5331 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4096 5332 | Error = ::std::convert::Infallible,
|
4097 5333 | > + Clone
|
4098 5334 | + Send
|
4099 5335 | + 'static,
|
4100 5336 | S::Future: Send + 'static,
|
4101 5337 | {
|
4102 - | self.http_request_with_labels =
|
4103 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5338 + | self.http_string_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4104 5339 | self
|
4105 5340 | }
|
4106 5341 |
|
4107 - | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
5342 + | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
4108 5343 | ///
|
4109 5344 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4110 5345 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4111 5346 | ///
|
4112 5347 | /// # Example
|
4113 5348 | ///
|
4114 5349 | /// ```no_run
|
4115 5350 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4116 5351 | ///
|
4117 5352 | /// use rest_json_http0x::{input, output, error};
|
4118 5353 | ///
|
4119 - | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
5354 + | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> output::IgnoreQueryParamsInResponseOutput {
|
4120 5355 | /// todo!()
|
4121 5356 | /// }
|
4122 5357 | ///
|
4123 5358 | /// let config = RestJsonConfig::builder().build();
|
4124 5359 | /// let app = RestJson::builder(config)
|
4125 - | /// .http_request_with_labels_and_timestamp_format(handler)
|
5360 + | /// .ignore_query_params_in_response(handler)
|
4126 5361 | /// /* Set other handlers */
|
4127 5362 | /// .build()
|
4128 5363 | /// .unwrap();
|
4129 5364 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4130 5365 | /// ```
|
4131 5366 | ///
|
4132 - | pub fn http_request_with_labels_and_timestamp_format<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5367 + | pub fn ignore_query_params_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4133 5368 | where
|
4134 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerExtractors>,
|
5369 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerExtractors>,
|
4135 5370 |
|
4136 5371 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4137 5372 | RestJson<L>,
|
4138 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4139 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerType>
|
5373 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
5374 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerType>
|
4140 5375 | >,
|
4141 5376 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4142 5377 | RestJson<L>,
|
4143 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5378 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4144 5379 | ModelPl::Output
|
4145 5380 | >,
|
4146 5381 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4147 5382 | RestJson<L>,
|
4148 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5383 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4149 5384 | <
|
4150 5385 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4151 5386 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4152 5387 | RestJson<L>,
|
4153 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5388 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4154 5389 | ModelPl::Output
|
4155 5390 | >
|
4156 5391 | >::Output
|
4157 5392 | >,
|
4158 5393 |
|
4159 5394 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4160 5395 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4161 5396 |
|
4162 5397 | {
|
4163 5398 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4164 5399 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4165 - | let svc =
|
4166 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_handler(handler);
|
5400 + | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_handler(handler);
|
4167 5401 | let svc = self.model_plugin.apply(svc);
|
4168 5402 | let svc =
|
4169 5403 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4170 5404 | .apply(svc);
|
4171 5405 | let svc = self.http_plugin.apply(svc);
|
4172 - | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
5406 + | self.ignore_query_params_in_response_custom(svc)
|
4173 5407 | }
|
4174 5408 |
|
4175 - | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
5409 + | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
4176 5410 | ///
|
4177 5411 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4178 5412 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4179 5413 | ///
|
4180 5414 | /// # Example
|
4181 5415 | ///
|
4182 5416 | /// ```no_run
|
4183 5417 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4184 5418 | ///
|
4185 5419 | /// use rest_json_http0x::{input, output, error};
|
4186 5420 | ///
|
4187 - | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
5421 + | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> Result<output::IgnoreQueryParamsInResponseOutput, std::convert::Infallible> {
|
4188 5422 | /// todo!()
|
4189 5423 | /// }
|
4190 5424 | ///
|
4191 5425 | /// let config = RestJsonConfig::builder().build();
|
4192 5426 | /// let svc = ::tower::util::service_fn(handler);
|
4193 5427 | /// let app = RestJson::builder(config)
|
4194 - | /// .http_request_with_labels_and_timestamp_format_service(svc)
|
5428 + | /// .ignore_query_params_in_response_service(svc)
|
4195 5429 | /// /* Set other handlers */
|
4196 5430 | /// .build()
|
4197 5431 | /// .unwrap();
|
4198 5432 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4199 5433 | /// ```
|
4200 5434 | ///
|
4201 - | pub fn http_request_with_labels_and_timestamp_format_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5435 + | pub fn ignore_query_params_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4202 5436 | where
|
4203 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, ServiceExtractors>,
|
5437 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::IgnoreQueryParamsInResponse, ServiceExtractors>,
|
4204 5438 |
|
4205 5439 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4206 5440 | RestJson<L>,
|
4207 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4208 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, S>
|
5441 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
5442 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::IgnoreQueryParamsInResponse, S>
|
4209 5443 | >,
|
4210 5444 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4211 5445 | RestJson<L>,
|
4212 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5446 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4213 5447 | ModelPl::Output
|
4214 5448 | >,
|
4215 5449 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4216 5450 | RestJson<L>,
|
4217 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5451 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4218 5452 | <
|
4219 5453 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4220 5454 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4221 5455 | RestJson<L>,
|
4222 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
5456 + | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4223 5457 | ModelPl::Output
|
4224 5458 | >
|
4225 5459 | >::Output
|
4226 5460 | >,
|
4227 5461 |
|
4228 5462 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4229 5463 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4230 5464 |
|
4231 5465 | {
|
4232 5466 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4233 5467 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4234 - | let svc =
|
4235 - | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_service(service);
|
5468 + | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_service(service);
|
4236 5469 | let svc = self.model_plugin.apply(svc);
|
4237 5470 | let svc =
|
4238 5471 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4239 5472 | .apply(svc);
|
4240 5473 | let svc = self.http_plugin.apply(svc);
|
4241 - | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
5474 + | self.ignore_query_params_in_response_custom(svc)
|
4242 5475 | }
|
4243 5476 |
|
4244 - | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) to a custom [`Service`](tower::Service).
|
5477 + | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) to a custom [`Service`](tower::Service).
|
4245 5478 | /// not constrained by the Smithy contract.
|
4246 - | fn http_request_with_labels_and_timestamp_format_custom<S>(mut self, svc: S) -> Self
|
5479 + | fn ignore_query_params_in_response_custom<S>(mut self, svc: S) -> Self
|
4247 5480 | where
|
4248 5481 | S: ::tower::Service<
|
4249 5482 | ::http::Request<Body>,
|
4250 5483 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4251 5484 | Error = ::std::convert::Infallible,
|
4252 5485 | > + Clone
|
4253 5486 | + Send
|
4254 5487 | + 'static,
|
4255 5488 | S::Future: Send + 'static,
|
4256 5489 | {
|
4257 - | self.http_request_with_labels_and_timestamp_format =
|
5490 + | self.ignore_query_params_in_response =
|
4258 5491 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4259 5492 | self
|
4260 5493 | }
|
4261 5494 |
|
4262 - | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
5495 + | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
4263 5496 | ///
|
4264 5497 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4265 5498 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4266 5499 | ///
|
4267 5500 | /// # Example
|
4268 5501 | ///
|
4269 5502 | /// ```no_run
|
4270 5503 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4271 5504 | ///
|
4272 5505 | /// use rest_json_http0x::{input, output, error};
|
4273 5506 | ///
|
4274 - | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
5507 + | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
4275 5508 | /// todo!()
|
4276 5509 | /// }
|
4277 5510 | ///
|
4278 5511 | /// let config = RestJsonConfig::builder().build();
|
4279 5512 | /// let app = RestJson::builder(config)
|
4280 - | /// .http_request_with_regex_literal(handler)
|
5513 + | /// .input_and_output_with_headers(handler)
|
4281 5514 | /// /* Set other handlers */
|
4282 5515 | /// .build()
|
4283 5516 | /// .unwrap();
|
4284 5517 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4285 5518 | /// ```
|
4286 5519 | ///
|
4287 - | pub fn http_request_with_regex_literal<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5520 + | pub fn input_and_output_with_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4288 5521 | where
|
4289 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerExtractors>,
|
5522 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::InputAndOutputWithHeaders, HandlerExtractors>,
|
4290 5523 |
|
4291 5524 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4292 5525 | RestJson<L>,
|
4293 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4294 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerType>
|
5526 + | crate::operation_shape::InputAndOutputWithHeaders,
|
5527 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::InputAndOutputWithHeaders, HandlerType>
|
4295 5528 | >,
|
4296 5529 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4297 5530 | RestJson<L>,
|
4298 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5531 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4299 5532 | ModelPl::Output
|
4300 5533 | >,
|
4301 5534 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4302 5535 | RestJson<L>,
|
4303 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5536 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4304 5537 | <
|
4305 5538 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4306 5539 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4307 5540 | RestJson<L>,
|
4308 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5541 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4309 5542 | ModelPl::Output
|
4310 5543 | >
|
4311 5544 | >::Output
|
4312 5545 | >,
|
4313 5546 |
|
4314 5547 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4315 5548 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4316 5549 |
|
4317 5550 | {
|
4318 5551 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4319 5552 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4320 - | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_handler(handler);
|
5553 + | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_handler(handler);
|
4321 5554 | let svc = self.model_plugin.apply(svc);
|
4322 5555 | let svc =
|
4323 5556 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4324 5557 | .apply(svc);
|
4325 5558 | let svc = self.http_plugin.apply(svc);
|
4326 - | self.http_request_with_regex_literal_custom(svc)
|
5559 + | self.input_and_output_with_headers_custom(svc)
|
4327 5560 | }
|
4328 5561 |
|
4329 - | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
5562 + | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
4330 5563 | ///
|
4331 5564 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4332 5565 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4333 5566 | ///
|
4334 5567 | /// # Example
|
4335 5568 | ///
|
4336 5569 | /// ```no_run
|
4337 5570 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4338 5571 | ///
|
4339 5572 | /// use rest_json_http0x::{input, output, error};
|
4340 5573 | ///
|
4341 - | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
5574 + | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
4342 5575 | /// todo!()
|
4343 5576 | /// }
|
4344 5577 | ///
|
4345 5578 | /// let config = RestJsonConfig::builder().build();
|
4346 5579 | /// let svc = ::tower::util::service_fn(handler);
|
4347 5580 | /// let app = RestJson::builder(config)
|
4348 - | /// .http_request_with_regex_literal_service(svc)
|
5581 + | /// .input_and_output_with_headers_service(svc)
|
4349 5582 | /// /* Set other handlers */
|
4350 5583 | /// .build()
|
4351 5584 | /// .unwrap();
|
4352 5585 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4353 5586 | /// ```
|
4354 5587 | ///
|
4355 - | pub fn http_request_with_regex_literal_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5588 + | pub fn input_and_output_with_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4356 5589 | where
|
4357 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithRegexLiteral, ServiceExtractors>,
|
5590 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::InputAndOutputWithHeaders, ServiceExtractors>,
|
4358 5591 |
|
4359 5592 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4360 5593 | RestJson<L>,
|
4361 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4362 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithRegexLiteral, S>
|
5594 + | crate::operation_shape::InputAndOutputWithHeaders,
|
5595 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::InputAndOutputWithHeaders, S>
|
4363 5596 | >,
|
4364 5597 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4365 5598 | RestJson<L>,
|
4366 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5599 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4367 5600 | ModelPl::Output
|
4368 5601 | >,
|
4369 5602 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4370 5603 | RestJson<L>,
|
4371 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5604 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4372 5605 | <
|
4373 5606 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4374 5607 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4375 5608 | RestJson<L>,
|
4376 - | crate::operation_shape::HttpRequestWithRegexLiteral,
|
5609 + | crate::operation_shape::InputAndOutputWithHeaders,
|
4377 5610 | ModelPl::Output
|
4378 5611 | >
|
4379 5612 | >::Output
|
4380 5613 | >,
|
4381 5614 |
|
4382 5615 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4383 5616 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4384 5617 |
|
4385 5618 | {
|
4386 5619 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4387 5620 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4388 - | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_service(service);
|
5621 + | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_service(service);
|
4389 5622 | let svc = self.model_plugin.apply(svc);
|
4390 5623 | let svc =
|
4391 5624 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4392 5625 | .apply(svc);
|
4393 5626 | let svc = self.http_plugin.apply(svc);
|
4394 - | self.http_request_with_regex_literal_custom(svc)
|
5627 + | self.input_and_output_with_headers_custom(svc)
|
4395 5628 | }
|
4396 5629 |
|
4397 - | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) to a custom [`Service`](tower::Service).
|
5630 + | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) to a custom [`Service`](tower::Service).
|
4398 5631 | /// not constrained by the Smithy contract.
|
4399 - | fn http_request_with_regex_literal_custom<S>(mut self, svc: S) -> Self
|
5632 + | fn input_and_output_with_headers_custom<S>(mut self, svc: S) -> Self
|
4400 5633 | where
|
4401 5634 | S: ::tower::Service<
|
4402 5635 | ::http::Request<Body>,
|
4403 5636 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4404 5637 | Error = ::std::convert::Infallible,
|
4405 5638 | > + Clone
|
4406 5639 | + Send
|
4407 5640 | + 'static,
|
4408 5641 | S::Future: Send + 'static,
|
4409 5642 | {
|
4410 - | self.http_request_with_regex_literal =
|
5643 + | self.input_and_output_with_headers =
|
4411 5644 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4412 5645 | self
|
4413 5646 | }
|
4414 5647 |
|
4415 - | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
5648 + | /// Sets the [`InputStream`](crate::operation_shape::InputStream) operation.
|
4416 5649 | ///
|
4417 5650 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4418 5651 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4419 5652 | ///
|
4420 5653 | /// # Example
|
4421 5654 | ///
|
4422 5655 | /// ```no_run
|
4423 5656 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4424 5657 | ///
|
4425 5658 | /// use rest_json_http0x::{input, output, error};
|
4426 5659 | ///
|
4427 - | /// async fn handler(input: input::HttpResponseCodeInput) -> output::HttpResponseCodeOutput {
|
5660 + | /// async fn handler(input: input::InputStreamInput) -> Result<output::InputStreamOutput, error::InputStreamError> {
|
4428 5661 | /// todo!()
|
4429 5662 | /// }
|
4430 5663 | ///
|
4431 5664 | /// let config = RestJsonConfig::builder().build();
|
4432 5665 | /// let app = RestJson::builder(config)
|
4433 - | /// .http_response_code(handler)
|
5666 + | /// .input_stream(handler)
|
4434 5667 | /// /* Set other handlers */
|
4435 5668 | /// .build()
|
4436 5669 | /// .unwrap();
|
4437 5670 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4438 5671 | /// ```
|
4439 5672 | ///
|
4440 - | pub fn http_response_code<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5673 + | pub fn input_stream<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4441 5674 | where
|
4442 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpResponseCode, HandlerExtractors>,
|
5675 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::InputStream, HandlerExtractors>,
|
4443 5676 |
|
4444 5677 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4445 5678 | RestJson<L>,
|
4446 - | crate::operation_shape::HttpResponseCode,
|
4447 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpResponseCode, HandlerType>
|
5679 + | crate::operation_shape::InputStream,
|
5680 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::InputStream, HandlerType>
|
4448 5681 | >,
|
4449 5682 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4450 5683 | RestJson<L>,
|
4451 - | crate::operation_shape::HttpResponseCode,
|
5684 + | crate::operation_shape::InputStream,
|
4452 5685 | ModelPl::Output
|
4453 5686 | >,
|
4454 5687 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4455 5688 | RestJson<L>,
|
4456 - | crate::operation_shape::HttpResponseCode,
|
5689 + | crate::operation_shape::InputStream,
|
4457 5690 | <
|
4458 5691 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4459 5692 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4460 5693 | RestJson<L>,
|
4461 - | crate::operation_shape::HttpResponseCode,
|
5694 + | crate::operation_shape::InputStream,
|
4462 5695 | ModelPl::Output
|
4463 5696 | >
|
4464 5697 | >::Output
|
4465 5698 | >,
|
4466 5699 |
|
4467 5700 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4468 5701 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4469 5702 |
|
4470 5703 | {
|
4471 5704 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4472 5705 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4473 - | let svc = crate::operation_shape::HttpResponseCode::from_handler(handler);
|
5706 + | let svc = crate::operation_shape::InputStream::from_handler(handler);
|
4474 5707 | let svc = self.model_plugin.apply(svc);
|
4475 5708 | let svc =
|
4476 5709 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4477 5710 | .apply(svc);
|
4478 5711 | let svc = self.http_plugin.apply(svc);
|
4479 - | self.http_response_code_custom(svc)
|
5712 + | self.input_stream_custom(svc)
|
4480 5713 | }
|
4481 5714 |
|
4482 - | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
5715 + | /// Sets the [`InputStream`](crate::operation_shape::InputStream) operation.
|
4483 5716 | ///
|
4484 5717 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4485 5718 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4486 5719 | ///
|
4487 5720 | /// # Example
|
4488 5721 | ///
|
4489 5722 | /// ```no_run
|
4490 5723 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4491 5724 | ///
|
4492 5725 | /// use rest_json_http0x::{input, output, error};
|
4493 5726 | ///
|
4494 - | /// async fn handler(input: input::HttpResponseCodeInput) -> Result<output::HttpResponseCodeOutput, std::convert::Infallible> {
|
5727 + | /// async fn handler(input: input::InputStreamInput) -> Result<output::InputStreamOutput, error::InputStreamError> {
|
4495 5728 | /// todo!()
|
4496 5729 | /// }
|
4497 5730 | ///
|
4498 5731 | /// let config = RestJsonConfig::builder().build();
|
4499 5732 | /// let svc = ::tower::util::service_fn(handler);
|
4500 5733 | /// let app = RestJson::builder(config)
|
4501 - | /// .http_response_code_service(svc)
|
5734 + | /// .input_stream_service(svc)
|
4502 5735 | /// /* Set other handlers */
|
4503 5736 | /// .build()
|
4504 5737 | /// .unwrap();
|
4505 5738 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4506 5739 | /// ```
|
4507 5740 | ///
|
4508 - | pub fn http_response_code_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5741 + | pub fn input_stream_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4509 5742 | where
|
4510 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpResponseCode, ServiceExtractors>,
|
5743 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::InputStream, ServiceExtractors>,
|
4511 5744 |
|
4512 5745 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4513 5746 | RestJson<L>,
|
4514 - | crate::operation_shape::HttpResponseCode,
|
4515 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpResponseCode, S>
|
5747 + | crate::operation_shape::InputStream,
|
5748 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::InputStream, S>
|
4516 5749 | >,
|
4517 5750 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4518 5751 | RestJson<L>,
|
4519 - | crate::operation_shape::HttpResponseCode,
|
5752 + | crate::operation_shape::InputStream,
|
4520 5753 | ModelPl::Output
|
4521 5754 | >,
|
4522 5755 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4523 5756 | RestJson<L>,
|
4524 - | crate::operation_shape::HttpResponseCode,
|
5757 + | crate::operation_shape::InputStream,
|
4525 5758 | <
|
4526 5759 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4527 5760 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4528 5761 | RestJson<L>,
|
4529 - | crate::operation_shape::HttpResponseCode,
|
5762 + | crate::operation_shape::InputStream,
|
4530 5763 | ModelPl::Output
|
4531 5764 | >
|
4532 5765 | >::Output
|
4533 5766 | >,
|
4534 5767 |
|
4535 5768 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4536 5769 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4537 5770 |
|
4538 5771 | {
|
4539 5772 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4540 5773 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4541 - | let svc = crate::operation_shape::HttpResponseCode::from_service(service);
|
5774 + | let svc = crate::operation_shape::InputStream::from_service(service);
|
4542 5775 | let svc = self.model_plugin.apply(svc);
|
4543 5776 | let svc =
|
4544 5777 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4545 5778 | .apply(svc);
|
4546 5779 | let svc = self.http_plugin.apply(svc);
|
4547 - | self.http_response_code_custom(svc)
|
5780 + | self.input_stream_custom(svc)
|
4548 5781 | }
|
4549 5782 |
|
4550 - | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) to a custom [`Service`](tower::Service).
|
5783 + | /// Sets the [`InputStream`](crate::operation_shape::InputStream) to a custom [`Service`](tower::Service).
|
4551 5784 | /// not constrained by the Smithy contract.
|
4552 - | fn http_response_code_custom<S>(mut self, svc: S) -> Self
|
5785 + | fn input_stream_custom<S>(mut self, svc: S) -> Self
|
4553 5786 | where
|
4554 5787 | S: ::tower::Service<
|
4555 5788 | ::http::Request<Body>,
|
4556 5789 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4557 5790 | Error = ::std::convert::Infallible,
|
4558 5791 | > + Clone
|
4559 5792 | + Send
|
4560 5793 | + 'static,
|
4561 5794 | S::Future: Send + 'static,
|
4562 5795 | {
|
4563 - | self.http_response_code = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5796 + | self.input_stream = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4564 5797 | self
|
4565 5798 | }
|
4566 5799 |
|
4567 - | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
5800 + | /// Sets the [`InputStreamWithInitialRequest`](crate::operation_shape::InputStreamWithInitialRequest) operation.
|
4568 5801 | ///
|
4569 5802 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4570 5803 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4571 5804 | ///
|
4572 5805 | /// # Example
|
4573 5806 | ///
|
4574 5807 | /// ```no_run
|
4575 5808 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4576 5809 | ///
|
4577 5810 | /// use rest_json_http0x::{input, output, error};
|
4578 5811 | ///
|
4579 - | /// async fn handler(input: input::HttpStringPayloadInput) -> output::HttpStringPayloadOutput {
|
5812 + | /// async fn handler(input: input::InputStreamWithInitialRequestInput) -> Result<output::InputStreamWithInitialRequestOutput, error::InputStreamWithInitialRequestError> {
|
4580 5813 | /// todo!()
|
4581 5814 | /// }
|
4582 5815 | ///
|
4583 5816 | /// let config = RestJsonConfig::builder().build();
|
4584 5817 | /// let app = RestJson::builder(config)
|
4585 - | /// .http_string_payload(handler)
|
5818 + | /// .input_stream_with_initial_request(handler)
|
4586 5819 | /// /* Set other handlers */
|
4587 5820 | /// .build()
|
4588 5821 | /// .unwrap();
|
4589 5822 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4590 5823 | /// ```
|
4591 5824 | ///
|
4592 - | pub fn http_string_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5825 + | pub fn input_stream_with_initial_request<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4593 5826 | where
|
4594 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpStringPayload, HandlerExtractors>,
|
5827 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::InputStreamWithInitialRequest, HandlerExtractors>,
|
4595 5828 |
|
4596 5829 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4597 5830 | RestJson<L>,
|
4598 - | crate::operation_shape::HttpStringPayload,
|
4599 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpStringPayload, HandlerType>
|
5831 + | crate::operation_shape::InputStreamWithInitialRequest,
|
5832 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::InputStreamWithInitialRequest, HandlerType>
|
4600 5833 | >,
|
4601 5834 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4602 5835 | RestJson<L>,
|
4603 - | crate::operation_shape::HttpStringPayload,
|
5836 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4604 5837 | ModelPl::Output
|
4605 5838 | >,
|
4606 5839 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4607 5840 | RestJson<L>,
|
4608 - | crate::operation_shape::HttpStringPayload,
|
5841 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4609 5842 | <
|
4610 5843 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4611 5844 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4612 5845 | RestJson<L>,
|
4613 - | crate::operation_shape::HttpStringPayload,
|
5846 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4614 5847 | ModelPl::Output
|
4615 5848 | >
|
4616 5849 | >::Output
|
4617 5850 | >,
|
4618 5851 |
|
4619 5852 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4620 5853 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4621 5854 |
|
4622 5855 | {
|
4623 5856 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4624 5857 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4625 - | let svc = crate::operation_shape::HttpStringPayload::from_handler(handler);
|
5858 + | let svc = crate::operation_shape::InputStreamWithInitialRequest::from_handler(handler);
|
4626 5859 | let svc = self.model_plugin.apply(svc);
|
4627 5860 | let svc =
|
4628 5861 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4629 5862 | .apply(svc);
|
4630 5863 | let svc = self.http_plugin.apply(svc);
|
4631 - | self.http_string_payload_custom(svc)
|
5864 + | self.input_stream_with_initial_request_custom(svc)
|
4632 5865 | }
|
4633 5866 |
|
4634 - | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
5867 + | /// Sets the [`InputStreamWithInitialRequest`](crate::operation_shape::InputStreamWithInitialRequest) operation.
|
4635 5868 | ///
|
4636 5869 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4637 5870 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4638 5871 | ///
|
4639 5872 | /// # Example
|
4640 5873 | ///
|
4641 5874 | /// ```no_run
|
4642 5875 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4643 5876 | ///
|
4644 5877 | /// use rest_json_http0x::{input, output, error};
|
4645 5878 | ///
|
4646 - | /// async fn handler(input: input::HttpStringPayloadInput) -> Result<output::HttpStringPayloadOutput, std::convert::Infallible> {
|
5879 + | /// async fn handler(input: input::InputStreamWithInitialRequestInput) -> Result<output::InputStreamWithInitialRequestOutput, error::InputStreamWithInitialRequestError> {
|
4647 5880 | /// todo!()
|
4648 5881 | /// }
|
4649 5882 | ///
|
4650 5883 | /// let config = RestJsonConfig::builder().build();
|
4651 5884 | /// let svc = ::tower::util::service_fn(handler);
|
4652 5885 | /// let app = RestJson::builder(config)
|
4653 - | /// .http_string_payload_service(svc)
|
5886 + | /// .input_stream_with_initial_request_service(svc)
|
4654 5887 | /// /* Set other handlers */
|
4655 5888 | /// .build()
|
4656 5889 | /// .unwrap();
|
4657 5890 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4658 5891 | /// ```
|
4659 5892 | ///
|
4660 - | pub fn http_string_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5893 + | pub fn input_stream_with_initial_request_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4661 5894 | where
|
4662 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpStringPayload, ServiceExtractors>,
|
5895 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::InputStreamWithInitialRequest, ServiceExtractors>,
|
4663 5896 |
|
4664 5897 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4665 5898 | RestJson<L>,
|
4666 - | crate::operation_shape::HttpStringPayload,
|
4667 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpStringPayload, S>
|
5899 + | crate::operation_shape::InputStreamWithInitialRequest,
|
5900 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::InputStreamWithInitialRequest, S>
|
4668 5901 | >,
|
4669 5902 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4670 5903 | RestJson<L>,
|
4671 - | crate::operation_shape::HttpStringPayload,
|
5904 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4672 5905 | ModelPl::Output
|
4673 5906 | >,
|
4674 5907 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4675 5908 | RestJson<L>,
|
4676 - | crate::operation_shape::HttpStringPayload,
|
5909 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4677 5910 | <
|
4678 5911 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4679 5912 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4680 5913 | RestJson<L>,
|
4681 - | crate::operation_shape::HttpStringPayload,
|
5914 + | crate::operation_shape::InputStreamWithInitialRequest,
|
4682 5915 | ModelPl::Output
|
4683 5916 | >
|
4684 5917 | >::Output
|
4685 5918 | >,
|
4686 5919 |
|
4687 5920 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4688 5921 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4689 5922 |
|
4690 5923 | {
|
4691 5924 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4692 5925 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4693 - | let svc = crate::operation_shape::HttpStringPayload::from_service(service);
|
5926 + | let svc = crate::operation_shape::InputStreamWithInitialRequest::from_service(service);
|
4694 5927 | let svc = self.model_plugin.apply(svc);
|
4695 5928 | let svc =
|
4696 5929 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4697 5930 | .apply(svc);
|
4698 5931 | let svc = self.http_plugin.apply(svc);
|
4699 - | self.http_string_payload_custom(svc)
|
5932 + | self.input_stream_with_initial_request_custom(svc)
|
4700 5933 | }
|
4701 5934 |
|
4702 - | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) to a custom [`Service`](tower::Service).
|
5935 + | /// Sets the [`InputStreamWithInitialRequest`](crate::operation_shape::InputStreamWithInitialRequest) to a custom [`Service`](tower::Service).
|
4703 5936 | /// not constrained by the Smithy contract.
|
4704 - | fn http_string_payload_custom<S>(mut self, svc: S) -> Self
|
5937 + | fn input_stream_with_initial_request_custom<S>(mut self, svc: S) -> Self
|
4705 5938 | where
|
4706 5939 | S: ::tower::Service<
|
4707 5940 | ::http::Request<Body>,
|
4708 5941 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4709 5942 | Error = ::std::convert::Infallible,
|
4710 5943 | > + Clone
|
4711 5944 | + Send
|
4712 5945 | + 'static,
|
4713 5946 | S::Future: Send + 'static,
|
4714 5947 | {
|
4715 - | self.http_string_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5948 + | self.input_stream_with_initial_request =
|
5949 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4716 5950 | self
|
4717 5951 | }
|
4718 5952 |
|
4719 - | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
5953 + | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
4720 5954 | ///
|
4721 5955 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4722 5956 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4723 5957 | ///
|
4724 5958 | /// # Example
|
4725 5959 | ///
|
4726 5960 | /// ```no_run
|
4727 5961 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4728 5962 | ///
|
4729 5963 | /// use rest_json_http0x::{input, output, error};
|
4730 5964 | ///
|
4731 - | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> output::IgnoreQueryParamsInResponseOutput {
|
5965 + | /// async fn handler(input: input::JsonBlobsInput) -> output::JsonBlobsOutput {
|
4732 5966 | /// todo!()
|
4733 5967 | /// }
|
4734 5968 | ///
|
4735 5969 | /// let config = RestJsonConfig::builder().build();
|
4736 5970 | /// let app = RestJson::builder(config)
|
4737 - | /// .ignore_query_params_in_response(handler)
|
5971 + | /// .json_blobs(handler)
|
4738 5972 | /// /* Set other handlers */
|
4739 5973 | /// .build()
|
4740 5974 | /// .unwrap();
|
4741 5975 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4742 5976 | /// ```
|
4743 5977 | ///
|
4744 - | pub fn ignore_query_params_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5978 + | pub fn json_blobs<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4745 5979 | where
|
4746 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerExtractors>,
|
5980 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonBlobs, HandlerExtractors>,
|
4747 5981 |
|
4748 5982 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4749 5983 | RestJson<L>,
|
4750 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4751 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerType>
|
5984 + | crate::operation_shape::JsonBlobs,
|
5985 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonBlobs, HandlerType>
|
4752 5986 | >,
|
4753 5987 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4754 5988 | RestJson<L>,
|
4755 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
5989 + | crate::operation_shape::JsonBlobs,
|
4756 5990 | ModelPl::Output
|
4757 5991 | >,
|
4758 5992 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4759 5993 | RestJson<L>,
|
4760 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
5994 + | crate::operation_shape::JsonBlobs,
|
4761 5995 | <
|
4762 5996 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4763 5997 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4764 5998 | RestJson<L>,
|
4765 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
5999 + | crate::operation_shape::JsonBlobs,
|
4766 6000 | ModelPl::Output
|
4767 6001 | >
|
4768 6002 | >::Output
|
4769 6003 | >,
|
4770 6004 |
|
4771 6005 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4772 6006 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4773 6007 |
|
4774 6008 | {
|
4775 6009 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4776 6010 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4777 - | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_handler(handler);
|
6011 + | let svc = crate::operation_shape::JsonBlobs::from_handler(handler);
|
4778 6012 | let svc = self.model_plugin.apply(svc);
|
4779 6013 | let svc =
|
4780 6014 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4781 6015 | .apply(svc);
|
4782 6016 | let svc = self.http_plugin.apply(svc);
|
4783 - | self.ignore_query_params_in_response_custom(svc)
|
6017 + | self.json_blobs_custom(svc)
|
4784 6018 | }
|
4785 6019 |
|
4786 - | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
6020 + | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
4787 6021 | ///
|
4788 6022 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4789 6023 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4790 6024 | ///
|
4791 6025 | /// # Example
|
4792 6026 | ///
|
4793 6027 | /// ```no_run
|
4794 6028 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4795 6029 | ///
|
4796 6030 | /// use rest_json_http0x::{input, output, error};
|
4797 6031 | ///
|
4798 - | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> Result<output::IgnoreQueryParamsInResponseOutput, std::convert::Infallible> {
|
6032 + | /// async fn handler(input: input::JsonBlobsInput) -> Result<output::JsonBlobsOutput, std::convert::Infallible> {
|
4799 6033 | /// todo!()
|
4800 6034 | /// }
|
4801 6035 | ///
|
4802 6036 | /// let config = RestJsonConfig::builder().build();
|
4803 6037 | /// let svc = ::tower::util::service_fn(handler);
|
4804 6038 | /// let app = RestJson::builder(config)
|
4805 - | /// .ignore_query_params_in_response_service(svc)
|
6039 + | /// .json_blobs_service(svc)
|
4806 6040 | /// /* Set other handlers */
|
4807 6041 | /// .build()
|
4808 6042 | /// .unwrap();
|
4809 6043 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4810 6044 | /// ```
|
4811 6045 | ///
|
4812 - | pub fn ignore_query_params_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6046 + | pub fn json_blobs_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4813 6047 | where
|
4814 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::IgnoreQueryParamsInResponse, ServiceExtractors>,
|
6048 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonBlobs, ServiceExtractors>,
|
4815 6049 |
|
4816 6050 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4817 6051 | RestJson<L>,
|
4818 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4819 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::IgnoreQueryParamsInResponse, S>
|
6052 + | crate::operation_shape::JsonBlobs,
|
6053 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonBlobs, S>
|
4820 6054 | >,
|
4821 6055 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4822 6056 | RestJson<L>,
|
4823 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
6057 + | crate::operation_shape::JsonBlobs,
|
4824 6058 | ModelPl::Output
|
4825 6059 | >,
|
4826 6060 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4827 6061 | RestJson<L>,
|
4828 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
6062 + | crate::operation_shape::JsonBlobs,
|
4829 6063 | <
|
4830 6064 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4831 6065 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4832 6066 | RestJson<L>,
|
4833 - | crate::operation_shape::IgnoreQueryParamsInResponse,
|
6067 + | crate::operation_shape::JsonBlobs,
|
4834 6068 | ModelPl::Output
|
4835 6069 | >
|
4836 6070 | >::Output
|
4837 6071 | >,
|
4838 6072 |
|
4839 6073 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4840 6074 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4841 6075 |
|
4842 6076 | {
|
4843 6077 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4844 6078 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4845 - | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_service(service);
|
6079 + | let svc = crate::operation_shape::JsonBlobs::from_service(service);
|
4846 6080 | let svc = self.model_plugin.apply(svc);
|
4847 6081 | let svc =
|
4848 6082 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4849 6083 | .apply(svc);
|
4850 6084 | let svc = self.http_plugin.apply(svc);
|
4851 - | self.ignore_query_params_in_response_custom(svc)
|
6085 + | self.json_blobs_custom(svc)
|
4852 6086 | }
|
4853 6087 |
|
4854 - | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) to a custom [`Service`](tower::Service).
|
6088 + | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) to a custom [`Service`](tower::Service).
|
4855 6089 | /// not constrained by the Smithy contract.
|
4856 - | fn ignore_query_params_in_response_custom<S>(mut self, svc: S) -> Self
|
6090 + | fn json_blobs_custom<S>(mut self, svc: S) -> Self
|
4857 6091 | where
|
4858 6092 | S: ::tower::Service<
|
4859 6093 | ::http::Request<Body>,
|
4860 6094 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4861 6095 | Error = ::std::convert::Infallible,
|
4862 6096 | > + Clone
|
4863 6097 | + Send
|
4864 6098 | + 'static,
|
4865 6099 | S::Future: Send + 'static,
|
4866 6100 | {
|
4867 - | self.ignore_query_params_in_response =
|
4868 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6101 + | self.json_blobs = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4869 6102 | self
|
4870 6103 | }
|
4871 6104 |
|
4872 - | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
6105 + | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
4873 6106 | ///
|
4874 6107 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4875 6108 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4876 6109 | ///
|
4877 6110 | /// # Example
|
4878 6111 | ///
|
4879 6112 | /// ```no_run
|
4880 6113 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4881 6114 | ///
|
4882 6115 | /// use rest_json_http0x::{input, output, error};
|
4883 6116 | ///
|
4884 - | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
6117 + | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
4885 6118 | /// todo!()
|
4886 6119 | /// }
|
4887 6120 | ///
|
4888 6121 | /// let config = RestJsonConfig::builder().build();
|
4889 6122 | /// let app = RestJson::builder(config)
|
4890 - | /// .input_and_output_with_headers(handler)
|
6123 + | /// .json_enums(handler)
|
4891 6124 | /// /* Set other handlers */
|
4892 6125 | /// .build()
|
4893 6126 | /// .unwrap();
|
4894 6127 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4895 6128 | /// ```
|
4896 6129 | ///
|
4897 - | pub fn input_and_output_with_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6130 + | pub fn json_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4898 6131 | where
|
4899 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::InputAndOutputWithHeaders, HandlerExtractors>,
|
6132 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonEnums, HandlerExtractors>,
|
4900 6133 |
|
4901 6134 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4902 6135 | RestJson<L>,
|
4903 - | crate::operation_shape::InputAndOutputWithHeaders,
|
4904 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::InputAndOutputWithHeaders, HandlerType>
|
6136 + | crate::operation_shape::JsonEnums,
|
6137 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonEnums, HandlerType>
|
4905 6138 | >,
|
4906 6139 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4907 6140 | RestJson<L>,
|
4908 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6141 + | crate::operation_shape::JsonEnums,
|
4909 6142 | ModelPl::Output
|
4910 6143 | >,
|
4911 6144 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4912 6145 | RestJson<L>,
|
4913 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6146 + | crate::operation_shape::JsonEnums,
|
4914 6147 | <
|
4915 6148 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4916 6149 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4917 6150 | RestJson<L>,
|
4918 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6151 + | crate::operation_shape::JsonEnums,
|
4919 6152 | ModelPl::Output
|
4920 6153 | >
|
4921 6154 | >::Output
|
4922 6155 | >,
|
4923 6156 |
|
4924 6157 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4925 6158 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4926 6159 |
|
4927 6160 | {
|
4928 6161 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4929 6162 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4930 - | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_handler(handler);
|
6163 + | let svc = crate::operation_shape::JsonEnums::from_handler(handler);
|
4931 6164 | let svc = self.model_plugin.apply(svc);
|
4932 6165 | let svc =
|
4933 6166 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4934 6167 | .apply(svc);
|
4935 6168 | let svc = self.http_plugin.apply(svc);
|
4936 - | self.input_and_output_with_headers_custom(svc)
|
6169 + | self.json_enums_custom(svc)
|
4937 6170 | }
|
4938 6171 |
|
4939 - | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
6172 + | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
4940 6173 | ///
|
4941 6174 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4942 6175 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4943 6176 | ///
|
4944 6177 | /// # Example
|
4945 6178 | ///
|
4946 6179 | /// ```no_run
|
4947 6180 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
4948 6181 | ///
|
4949 6182 | /// use rest_json_http0x::{input, output, error};
|
4950 6183 | ///
|
4951 - | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
6184 + | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
4952 6185 | /// todo!()
|
4953 6186 | /// }
|
4954 6187 | ///
|
4955 6188 | /// let config = RestJsonConfig::builder().build();
|
4956 6189 | /// let svc = ::tower::util::service_fn(handler);
|
4957 6190 | /// let app = RestJson::builder(config)
|
4958 - | /// .input_and_output_with_headers_service(svc)
|
6191 + | /// .json_enums_service(svc)
|
4959 6192 | /// /* Set other handlers */
|
4960 6193 | /// .build()
|
4961 6194 | /// .unwrap();
|
4962 6195 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4963 6196 | /// ```
|
4964 6197 | ///
|
4965 - | pub fn input_and_output_with_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6198 + | pub fn json_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4966 6199 | where
|
4967 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::InputAndOutputWithHeaders, ServiceExtractors>,
|
6200 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonEnums, ServiceExtractors>,
|
4968 6201 |
|
4969 6202 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4970 6203 | RestJson<L>,
|
4971 - | crate::operation_shape::InputAndOutputWithHeaders,
|
4972 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::InputAndOutputWithHeaders, S>
|
6204 + | crate::operation_shape::JsonEnums,
|
6205 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonEnums, S>
|
4973 6206 | >,
|
4974 6207 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4975 6208 | RestJson<L>,
|
4976 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6209 + | crate::operation_shape::JsonEnums,
|
4977 6210 | ModelPl::Output
|
4978 6211 | >,
|
4979 6212 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4980 6213 | RestJson<L>,
|
4981 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6214 + | crate::operation_shape::JsonEnums,
|
4982 6215 | <
|
4983 6216 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4984 6217 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4985 6218 | RestJson<L>,
|
4986 - | crate::operation_shape::InputAndOutputWithHeaders,
|
6219 + | crate::operation_shape::JsonEnums,
|
4987 6220 | ModelPl::Output
|
4988 6221 | >
|
4989 6222 | >::Output
|
4990 6223 | >,
|
4991 6224 |
|
4992 6225 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4993 6226 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4994 6227 |
|
4995 6228 | {
|
4996 6229 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4997 6230 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4998 - | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_service(service);
|
6231 + | let svc = crate::operation_shape::JsonEnums::from_service(service);
|
4999 6232 | let svc = self.model_plugin.apply(svc);
|
5000 6233 | let svc =
|
5001 6234 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5002 6235 | .apply(svc);
|
5003 6236 | let svc = self.http_plugin.apply(svc);
|
5004 - | self.input_and_output_with_headers_custom(svc)
|
6237 + | self.json_enums_custom(svc)
|
5005 6238 | }
|
5006 6239 |
|
5007 - | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) to a custom [`Service`](tower::Service).
|
6240 + | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) to a custom [`Service`](tower::Service).
|
5008 6241 | /// not constrained by the Smithy contract.
|
5009 - | fn input_and_output_with_headers_custom<S>(mut self, svc: S) -> Self
|
6242 + | fn json_enums_custom<S>(mut self, svc: S) -> Self
|
5010 6243 | where
|
5011 6244 | S: ::tower::Service<
|
5012 6245 | ::http::Request<Body>,
|
5013 6246 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5014 6247 | Error = ::std::convert::Infallible,
|
5015 6248 | > + Clone
|
5016 6249 | + Send
|
5017 6250 | + 'static,
|
5018 6251 | S::Future: Send + 'static,
|
5019 6252 | {
|
5020 - | self.input_and_output_with_headers =
|
5021 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6253 + | self.json_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5022 6254 | self
|
5023 6255 | }
|
5024 6256 |
|
5025 - | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
6257 + | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
5026 6258 | ///
|
5027 6259 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5028 6260 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5029 6261 | ///
|
5030 6262 | /// # Example
|
5031 6263 | ///
|
5032 6264 | /// ```no_run
|
5033 6265 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5034 6266 | ///
|
5035 6267 | /// use rest_json_http0x::{input, output, error};
|
5036 6268 | ///
|
5037 - | /// async fn handler(input: input::JsonBlobsInput) -> output::JsonBlobsOutput {
|
6269 + | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
5038 6270 | /// todo!()
|
5039 6271 | /// }
|
5040 6272 | ///
|
5041 6273 | /// let config = RestJsonConfig::builder().build();
|
5042 6274 | /// let app = RestJson::builder(config)
|
5043 - | /// .json_blobs(handler)
|
6275 + | /// .json_int_enums(handler)
|
5044 6276 | /// /* Set other handlers */
|
5045 6277 | /// .build()
|
5046 6278 | /// .unwrap();
|
5047 6279 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5048 6280 | /// ```
|
5049 6281 | ///
|
5050 - | pub fn json_blobs<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6282 + | pub fn json_int_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5051 6283 | where
|
5052 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonBlobs, HandlerExtractors>,
|
6284 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonIntEnums, HandlerExtractors>,
|
5053 6285 |
|
5054 6286 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5055 6287 | RestJson<L>,
|
5056 - | crate::operation_shape::JsonBlobs,
|
5057 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonBlobs, HandlerType>
|
6288 + | crate::operation_shape::JsonIntEnums,
|
6289 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonIntEnums, HandlerType>
|
5058 6290 | >,
|
5059 6291 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5060 6292 | RestJson<L>,
|
5061 - | crate::operation_shape::JsonBlobs,
|
6293 + | crate::operation_shape::JsonIntEnums,
|
5062 6294 | ModelPl::Output
|
5063 6295 | >,
|
5064 6296 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5065 6297 | RestJson<L>,
|
5066 - | crate::operation_shape::JsonBlobs,
|
6298 + | crate::operation_shape::JsonIntEnums,
|
5067 6299 | <
|
5068 6300 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5069 6301 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5070 6302 | RestJson<L>,
|
5071 - | crate::operation_shape::JsonBlobs,
|
6303 + | crate::operation_shape::JsonIntEnums,
|
5072 6304 | ModelPl::Output
|
5073 6305 | >
|
5074 6306 | >::Output
|
5075 6307 | >,
|
5076 6308 |
|
5077 6309 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5078 6310 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5079 6311 |
|
5080 6312 | {
|
5081 6313 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5082 6314 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5083 - | let svc = crate::operation_shape::JsonBlobs::from_handler(handler);
|
6315 + | let svc = crate::operation_shape::JsonIntEnums::from_handler(handler);
|
5084 6316 | let svc = self.model_plugin.apply(svc);
|
5085 6317 | let svc =
|
5086 6318 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5087 6319 | .apply(svc);
|
5088 6320 | let svc = self.http_plugin.apply(svc);
|
5089 - | self.json_blobs_custom(svc)
|
6321 + | self.json_int_enums_custom(svc)
|
5090 6322 | }
|
5091 6323 |
|
5092 - | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
6324 + | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
5093 6325 | ///
|
5094 6326 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5095 6327 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5096 6328 | ///
|
5097 6329 | /// # Example
|
5098 6330 | ///
|
5099 6331 | /// ```no_run
|
5100 6332 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5101 6333 | ///
|
5102 6334 | /// use rest_json_http0x::{input, output, error};
|
5103 6335 | ///
|
5104 - | /// async fn handler(input: input::JsonBlobsInput) -> Result<output::JsonBlobsOutput, std::convert::Infallible> {
|
6336 + | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
5105 6337 | /// todo!()
|
5106 6338 | /// }
|
5107 6339 | ///
|
5108 6340 | /// let config = RestJsonConfig::builder().build();
|
5109 6341 | /// let svc = ::tower::util::service_fn(handler);
|
5110 6342 | /// let app = RestJson::builder(config)
|
5111 - | /// .json_blobs_service(svc)
|
6343 + | /// .json_int_enums_service(svc)
|
5112 6344 | /// /* Set other handlers */
|
5113 6345 | /// .build()
|
5114 6346 | /// .unwrap();
|
5115 6347 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5116 6348 | /// ```
|
5117 6349 | ///
|
5118 - | pub fn json_blobs_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6350 + | pub fn json_int_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5119 6351 | where
|
5120 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonBlobs, ServiceExtractors>,
|
6352 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonIntEnums, ServiceExtractors>,
|
5121 6353 |
|
5122 6354 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5123 6355 | RestJson<L>,
|
5124 - | crate::operation_shape::JsonBlobs,
|
5125 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonBlobs, S>
|
6356 + | crate::operation_shape::JsonIntEnums,
|
6357 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonIntEnums, S>
|
5126 6358 | >,
|
5127 6359 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5128 6360 | RestJson<L>,
|
5129 - | crate::operation_shape::JsonBlobs,
|
6361 + | crate::operation_shape::JsonIntEnums,
|
5130 6362 | ModelPl::Output
|
5131 6363 | >,
|
5132 6364 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5133 6365 | RestJson<L>,
|
5134 - | crate::operation_shape::JsonBlobs,
|
6366 + | crate::operation_shape::JsonIntEnums,
|
5135 6367 | <
|
5136 6368 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5137 6369 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5138 6370 | RestJson<L>,
|
5139 - | crate::operation_shape::JsonBlobs,
|
6371 + | crate::operation_shape::JsonIntEnums,
|
5140 6372 | ModelPl::Output
|
5141 6373 | >
|
5142 6374 | >::Output
|
5143 6375 | >,
|
5144 6376 |
|
5145 6377 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5146 6378 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5147 6379 |
|
5148 6380 | {
|
5149 6381 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5150 6382 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5151 - | let svc = crate::operation_shape::JsonBlobs::from_service(service);
|
6383 + | let svc = crate::operation_shape::JsonIntEnums::from_service(service);
|
5152 6384 | let svc = self.model_plugin.apply(svc);
|
5153 6385 | let svc =
|
5154 6386 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5155 6387 | .apply(svc);
|
5156 6388 | let svc = self.http_plugin.apply(svc);
|
5157 - | self.json_blobs_custom(svc)
|
6389 + | self.json_int_enums_custom(svc)
|
5158 6390 | }
|
5159 6391 |
|
5160 - | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) to a custom [`Service`](tower::Service).
|
6392 + | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) to a custom [`Service`](tower::Service).
|
5161 6393 | /// not constrained by the Smithy contract.
|
5162 - | fn json_blobs_custom<S>(mut self, svc: S) -> Self
|
6394 + | fn json_int_enums_custom<S>(mut self, svc: S) -> Self
|
5163 6395 | where
|
5164 6396 | S: ::tower::Service<
|
5165 6397 | ::http::Request<Body>,
|
5166 6398 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5167 6399 | Error = ::std::convert::Infallible,
|
5168 6400 | > + Clone
|
5169 6401 | + Send
|
5170 6402 | + 'static,
|
5171 6403 | S::Future: Send + 'static,
|
5172 6404 | {
|
5173 - | self.json_blobs = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6405 + | self.json_int_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5174 6406 | self
|
5175 6407 | }
|
5176 6408 |
|
5177 - | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
6409 + | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
5178 6410 | ///
|
5179 6411 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5180 6412 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5181 6413 | ///
|
5182 6414 | /// # Example
|
5183 6415 | ///
|
5184 6416 | /// ```no_run
|
5185 6417 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5186 6418 | ///
|
5187 6419 | /// use rest_json_http0x::{input, output, error};
|
5188 6420 | ///
|
5189 - | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
6421 + | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
5190 6422 | /// todo!()
|
5191 6423 | /// }
|
5192 6424 | ///
|
5193 6425 | /// let config = RestJsonConfig::builder().build();
|
5194 6426 | /// let app = RestJson::builder(config)
|
5195 - | /// .json_enums(handler)
|
6427 + | /// .json_lists(handler)
|
5196 6428 | /// /* Set other handlers */
|
5197 6429 | /// .build()
|
5198 6430 | /// .unwrap();
|
5199 6431 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5200 6432 | /// ```
|
5201 6433 | ///
|
5202 - | pub fn json_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6434 + | pub fn json_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5203 6435 | where
|
5204 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonEnums, HandlerExtractors>,
|
6436 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonLists, HandlerExtractors>,
|
5205 6437 |
|
5206 6438 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5207 6439 | RestJson<L>,
|
5208 - | crate::operation_shape::JsonEnums,
|
5209 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonEnums, HandlerType>
|
6440 + | crate::operation_shape::JsonLists,
|
6441 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonLists, HandlerType>
|
5210 6442 | >,
|
5211 6443 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5212 6444 | RestJson<L>,
|
5213 - | crate::operation_shape::JsonEnums,
|
6445 + | crate::operation_shape::JsonLists,
|
5214 6446 | ModelPl::Output
|
5215 6447 | >,
|
5216 6448 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5217 6449 | RestJson<L>,
|
5218 - | crate::operation_shape::JsonEnums,
|
6450 + | crate::operation_shape::JsonLists,
|
5219 6451 | <
|
5220 6452 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5221 6453 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5222 6454 | RestJson<L>,
|
5223 - | crate::operation_shape::JsonEnums,
|
6455 + | crate::operation_shape::JsonLists,
|
5224 6456 | ModelPl::Output
|
5225 6457 | >
|
5226 6458 | >::Output
|
5227 6459 | >,
|
5228 6460 |
|
5229 6461 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5230 6462 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5231 6463 |
|
5232 6464 | {
|
5233 6465 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5234 6466 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5235 - | let svc = crate::operation_shape::JsonEnums::from_handler(handler);
|
6467 + | let svc = crate::operation_shape::JsonLists::from_handler(handler);
|
5236 6468 | let svc = self.model_plugin.apply(svc);
|
5237 6469 | let svc =
|
5238 6470 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5239 6471 | .apply(svc);
|
5240 6472 | let svc = self.http_plugin.apply(svc);
|
5241 - | self.json_enums_custom(svc)
|
6473 + | self.json_lists_custom(svc)
|
5242 6474 | }
|
5243 6475 |
|
5244 - | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
6476 + | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
5245 6477 | ///
|
5246 6478 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5247 6479 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5248 6480 | ///
|
5249 6481 | /// # Example
|
5250 6482 | ///
|
5251 6483 | /// ```no_run
|
5252 6484 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5253 6485 | ///
|
5254 6486 | /// use rest_json_http0x::{input, output, error};
|
5255 6487 | ///
|
5256 - | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
6488 + | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
5257 6489 | /// todo!()
|
5258 6490 | /// }
|
5259 6491 | ///
|
5260 6492 | /// let config = RestJsonConfig::builder().build();
|
5261 6493 | /// let svc = ::tower::util::service_fn(handler);
|
5262 6494 | /// let app = RestJson::builder(config)
|
5263 - | /// .json_enums_service(svc)
|
6495 + | /// .json_lists_service(svc)
|
5264 6496 | /// /* Set other handlers */
|
5265 6497 | /// .build()
|
5266 6498 | /// .unwrap();
|
5267 6499 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5268 6500 | /// ```
|
5269 6501 | ///
|
5270 - | pub fn json_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6502 + | pub fn json_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5271 6503 | where
|
5272 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonEnums, ServiceExtractors>,
|
6504 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonLists, ServiceExtractors>,
|
5273 6505 |
|
5274 6506 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5275 6507 | RestJson<L>,
|
5276 - | crate::operation_shape::JsonEnums,
|
5277 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonEnums, S>
|
6508 + | crate::operation_shape::JsonLists,
|
6509 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonLists, S>
|
5278 6510 | >,
|
5279 6511 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5280 6512 | RestJson<L>,
|
5281 - | crate::operation_shape::JsonEnums,
|
6513 + | crate::operation_shape::JsonLists,
|
5282 6514 | ModelPl::Output
|
5283 6515 | >,
|
5284 6516 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5285 6517 | RestJson<L>,
|
5286 - | crate::operation_shape::JsonEnums,
|
6518 + | crate::operation_shape::JsonLists,
|
5287 6519 | <
|
5288 6520 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5289 6521 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5290 6522 | RestJson<L>,
|
5291 - | crate::operation_shape::JsonEnums,
|
6523 + | crate::operation_shape::JsonLists,
|
5292 6524 | ModelPl::Output
|
5293 6525 | >
|
5294 6526 | >::Output
|
5295 6527 | >,
|
5296 6528 |
|
5297 6529 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5298 6530 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5299 6531 |
|
5300 6532 | {
|
5301 6533 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5302 6534 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5303 - | let svc = crate::operation_shape::JsonEnums::from_service(service);
|
6535 + | let svc = crate::operation_shape::JsonLists::from_service(service);
|
5304 6536 | let svc = self.model_plugin.apply(svc);
|
5305 6537 | let svc =
|
5306 6538 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5307 6539 | .apply(svc);
|
5308 6540 | let svc = self.http_plugin.apply(svc);
|
5309 - | self.json_enums_custom(svc)
|
6541 + | self.json_lists_custom(svc)
|
5310 6542 | }
|
5311 6543 |
|
5312 - | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) to a custom [`Service`](tower::Service).
|
6544 + | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) to a custom [`Service`](tower::Service).
|
5313 6545 | /// not constrained by the Smithy contract.
|
5314 - | fn json_enums_custom<S>(mut self, svc: S) -> Self
|
6546 + | fn json_lists_custom<S>(mut self, svc: S) -> Self
|
5315 6547 | where
|
5316 6548 | S: ::tower::Service<
|
5317 6549 | ::http::Request<Body>,
|
5318 6550 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5319 6551 | Error = ::std::convert::Infallible,
|
5320 6552 | > + Clone
|
5321 6553 | + Send
|
5322 6554 | + 'static,
|
5323 6555 | S::Future: Send + 'static,
|
5324 6556 | {
|
5325 - | self.json_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6557 + | self.json_lists = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5326 6558 | self
|
5327 6559 | }
|
5328 6560 |
|
5329 - | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
6561 + | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
5330 6562 | ///
|
5331 6563 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5332 6564 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5333 6565 | ///
|
5334 6566 | /// # Example
|
5335 6567 | ///
|
5336 6568 | /// ```no_run
|
5337 6569 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5338 6570 | ///
|
5339 6571 | /// use rest_json_http0x::{input, output, error};
|
5340 6572 | ///
|
5341 - | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
6573 + | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
5342 6574 | /// todo!()
|
5343 6575 | /// }
|
5344 6576 | ///
|
5345 6577 | /// let config = RestJsonConfig::builder().build();
|
5346 6578 | /// let app = RestJson::builder(config)
|
5347 - | /// .json_int_enums(handler)
|
6579 + | /// .json_maps(handler)
|
5348 6580 | /// /* Set other handlers */
|
5349 6581 | /// .build()
|
5350 6582 | /// .unwrap();
|
5351 6583 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5352 6584 | /// ```
|
5353 6585 | ///
|
5354 - | pub fn json_int_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6586 + | pub fn json_maps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5355 6587 | where
|
5356 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonIntEnums, HandlerExtractors>,
|
6588 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonMaps, HandlerExtractors>,
|
5357 6589 |
|
5358 6590 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5359 6591 | RestJson<L>,
|
5360 - | crate::operation_shape::JsonIntEnums,
|
5361 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonIntEnums, HandlerType>
|
6592 + | crate::operation_shape::JsonMaps,
|
6593 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonMaps, HandlerType>
|
5362 6594 | >,
|
5363 6595 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5364 6596 | RestJson<L>,
|
5365 - | crate::operation_shape::JsonIntEnums,
|
6597 + | crate::operation_shape::JsonMaps,
|
5366 6598 | ModelPl::Output
|
5367 6599 | >,
|
5368 6600 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5369 6601 | RestJson<L>,
|
5370 - | crate::operation_shape::JsonIntEnums,
|
6602 + | crate::operation_shape::JsonMaps,
|
5371 6603 | <
|
5372 6604 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5373 6605 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5374 6606 | RestJson<L>,
|
5375 - | crate::operation_shape::JsonIntEnums,
|
6607 + | crate::operation_shape::JsonMaps,
|
5376 6608 | ModelPl::Output
|
5377 6609 | >
|
5378 6610 | >::Output
|
5379 6611 | >,
|
5380 6612 |
|
5381 6613 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5382 6614 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5383 6615 |
|
5384 6616 | {
|
5385 6617 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5386 6618 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5387 - | let svc = crate::operation_shape::JsonIntEnums::from_handler(handler);
|
6619 + | let svc = crate::operation_shape::JsonMaps::from_handler(handler);
|
5388 6620 | let svc = self.model_plugin.apply(svc);
|
5389 6621 | let svc =
|
5390 6622 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5391 6623 | .apply(svc);
|
5392 6624 | let svc = self.http_plugin.apply(svc);
|
5393 - | self.json_int_enums_custom(svc)
|
6625 + | self.json_maps_custom(svc)
|
5394 6626 | }
|
5395 6627 |
|
5396 - | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
6628 + | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
5397 6629 | ///
|
5398 6630 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5399 6631 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5400 6632 | ///
|
5401 6633 | /// # Example
|
5402 6634 | ///
|
5403 6635 | /// ```no_run
|
5404 6636 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5405 6637 | ///
|
5406 6638 | /// use rest_json_http0x::{input, output, error};
|
5407 6639 | ///
|
5408 - | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
6640 + | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
5409 6641 | /// todo!()
|
5410 6642 | /// }
|
5411 6643 | ///
|
5412 6644 | /// let config = RestJsonConfig::builder().build();
|
5413 6645 | /// let svc = ::tower::util::service_fn(handler);
|
5414 6646 | /// let app = RestJson::builder(config)
|
5415 - | /// .json_int_enums_service(svc)
|
6647 + | /// .json_maps_service(svc)
|
5416 6648 | /// /* Set other handlers */
|
5417 6649 | /// .build()
|
5418 6650 | /// .unwrap();
|
5419 6651 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5420 6652 | /// ```
|
5421 6653 | ///
|
5422 - | pub fn json_int_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6654 + | pub fn json_maps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5423 6655 | where
|
5424 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonIntEnums, ServiceExtractors>,
|
6656 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonMaps, ServiceExtractors>,
|
5425 6657 |
|
5426 6658 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5427 6659 | RestJson<L>,
|
5428 - | crate::operation_shape::JsonIntEnums,
|
5429 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonIntEnums, S>
|
6660 + | crate::operation_shape::JsonMaps,
|
6661 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonMaps, S>
|
5430 6662 | >,
|
5431 6663 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5432 6664 | RestJson<L>,
|
5433 - | crate::operation_shape::JsonIntEnums,
|
6665 + | crate::operation_shape::JsonMaps,
|
5434 6666 | ModelPl::Output
|
5435 6667 | >,
|
5436 6668 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5437 6669 | RestJson<L>,
|
5438 - | crate::operation_shape::JsonIntEnums,
|
6670 + | crate::operation_shape::JsonMaps,
|
5439 6671 | <
|
5440 6672 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5441 6673 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5442 6674 | RestJson<L>,
|
5443 - | crate::operation_shape::JsonIntEnums,
|
6675 + | crate::operation_shape::JsonMaps,
|
5444 6676 | ModelPl::Output
|
5445 6677 | >
|
5446 6678 | >::Output
|
5447 6679 | >,
|
5448 6680 |
|
5449 6681 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5450 6682 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5451 6683 |
|
5452 6684 | {
|
5453 6685 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5454 6686 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5455 - | let svc = crate::operation_shape::JsonIntEnums::from_service(service);
|
6687 + | let svc = crate::operation_shape::JsonMaps::from_service(service);
|
5456 6688 | let svc = self.model_plugin.apply(svc);
|
5457 6689 | let svc =
|
5458 6690 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5459 6691 | .apply(svc);
|
5460 6692 | let svc = self.http_plugin.apply(svc);
|
5461 - | self.json_int_enums_custom(svc)
|
6693 + | self.json_maps_custom(svc)
|
5462 6694 | }
|
5463 6695 |
|
5464 - | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) to a custom [`Service`](tower::Service).
|
6696 + | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) to a custom [`Service`](tower::Service).
|
5465 6697 | /// not constrained by the Smithy contract.
|
5466 - | fn json_int_enums_custom<S>(mut self, svc: S) -> Self
|
6698 + | fn json_maps_custom<S>(mut self, svc: S) -> Self
|
5467 6699 | where
|
5468 6700 | S: ::tower::Service<
|
5469 6701 | ::http::Request<Body>,
|
5470 6702 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5471 6703 | Error = ::std::convert::Infallible,
|
5472 6704 | > + Clone
|
5473 6705 | + Send
|
5474 6706 | + 'static,
|
5475 6707 | S::Future: Send + 'static,
|
5476 6708 | {
|
5477 - | self.json_int_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6709 + | self.json_maps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5478 6710 | self
|
5479 6711 | }
|
5480 6712 |
|
5481 - | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
6713 + | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
5482 6714 | ///
|
5483 6715 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5484 6716 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5485 6717 | ///
|
5486 6718 | /// # Example
|
5487 6719 | ///
|
5488 6720 | /// ```no_run
|
5489 6721 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5490 6722 | ///
|
5491 6723 | /// use rest_json_http0x::{input, output, error};
|
5492 6724 | ///
|
5493 - | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
6725 + | /// async fn handler(input: input::JsonTimestampsInput) -> output::JsonTimestampsOutput {
|
5494 6726 | /// todo!()
|
5495 6727 | /// }
|
5496 6728 | ///
|
5497 6729 | /// let config = RestJsonConfig::builder().build();
|
5498 6730 | /// let app = RestJson::builder(config)
|
5499 - | /// .json_lists(handler)
|
6731 + | /// .json_timestamps(handler)
|
5500 6732 | /// /* Set other handlers */
|
5501 6733 | /// .build()
|
5502 6734 | /// .unwrap();
|
5503 6735 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5504 6736 | /// ```
|
5505 6737 | ///
|
5506 - | pub fn json_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6738 + | pub fn json_timestamps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5507 6739 | where
|
5508 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonLists, HandlerExtractors>,
|
6740 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonTimestamps, HandlerExtractors>,
|
5509 6741 |
|
5510 6742 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5511 6743 | RestJson<L>,
|
5512 - | crate::operation_shape::JsonLists,
|
5513 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonLists, HandlerType>
|
6744 + | crate::operation_shape::JsonTimestamps,
|
6745 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonTimestamps, HandlerType>
|
5514 6746 | >,
|
5515 6747 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5516 6748 | RestJson<L>,
|
5517 - | crate::operation_shape::JsonLists,
|
6749 + | crate::operation_shape::JsonTimestamps,
|
5518 6750 | ModelPl::Output
|
5519 6751 | >,
|
5520 6752 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5521 6753 | RestJson<L>,
|
5522 - | crate::operation_shape::JsonLists,
|
6754 + | crate::operation_shape::JsonTimestamps,
|
5523 6755 | <
|
5524 6756 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5525 6757 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5526 6758 | RestJson<L>,
|
5527 - | crate::operation_shape::JsonLists,
|
6759 + | crate::operation_shape::JsonTimestamps,
|
5528 6760 | ModelPl::Output
|
5529 6761 | >
|
5530 6762 | >::Output
|
5531 6763 | >,
|
5532 6764 |
|
5533 6765 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5534 6766 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5535 6767 |
|
5536 6768 | {
|
5537 6769 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5538 6770 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5539 - | let svc = crate::operation_shape::JsonLists::from_handler(handler);
|
6771 + | let svc = crate::operation_shape::JsonTimestamps::from_handler(handler);
|
5540 6772 | let svc = self.model_plugin.apply(svc);
|
5541 6773 | let svc =
|
5542 6774 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5543 6775 | .apply(svc);
|
5544 6776 | let svc = self.http_plugin.apply(svc);
|
5545 - | self.json_lists_custom(svc)
|
6777 + | self.json_timestamps_custom(svc)
|
5546 6778 | }
|
5547 6779 |
|
5548 - | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
6780 + | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
5549 6781 | ///
|
5550 6782 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5551 6783 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5552 6784 | ///
|
5553 6785 | /// # Example
|
5554 6786 | ///
|
5555 6787 | /// ```no_run
|
5556 6788 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5557 6789 | ///
|
5558 6790 | /// use rest_json_http0x::{input, output, error};
|
5559 6791 | ///
|
5560 - | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
6792 + | /// async fn handler(input: input::JsonTimestampsInput) -> Result<output::JsonTimestampsOutput, std::convert::Infallible> {
|
5561 6793 | /// todo!()
|
5562 6794 | /// }
|
5563 6795 | ///
|
5564 6796 | /// let config = RestJsonConfig::builder().build();
|
5565 6797 | /// let svc = ::tower::util::service_fn(handler);
|
5566 6798 | /// let app = RestJson::builder(config)
|
5567 - | /// .json_lists_service(svc)
|
6799 + | /// .json_timestamps_service(svc)
|
5568 6800 | /// /* Set other handlers */
|
5569 6801 | /// .build()
|
5570 6802 | /// .unwrap();
|
5571 6803 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5572 6804 | /// ```
|
5573 6805 | ///
|
5574 - | pub fn json_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6806 + | pub fn json_timestamps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5575 6807 | where
|
5576 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonLists, ServiceExtractors>,
|
6808 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonTimestamps, ServiceExtractors>,
|
5577 6809 |
|
5578 6810 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5579 6811 | RestJson<L>,
|
5580 - | crate::operation_shape::JsonLists,
|
5581 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonLists, S>
|
6812 + | crate::operation_shape::JsonTimestamps,
|
6813 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonTimestamps, S>
|
5582 6814 | >,
|
5583 6815 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5584 6816 | RestJson<L>,
|
5585 - | crate::operation_shape::JsonLists,
|
6817 + | crate::operation_shape::JsonTimestamps,
|
5586 6818 | ModelPl::Output
|
5587 6819 | >,
|
5588 6820 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5589 6821 | RestJson<L>,
|
5590 - | crate::operation_shape::JsonLists,
|
6822 + | crate::operation_shape::JsonTimestamps,
|
5591 6823 | <
|
5592 6824 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5593 6825 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5594 6826 | RestJson<L>,
|
5595 - | crate::operation_shape::JsonLists,
|
6827 + | crate::operation_shape::JsonTimestamps,
|
5596 6828 | ModelPl::Output
|
5597 6829 | >
|
5598 6830 | >::Output
|
5599 6831 | >,
|
5600 6832 |
|
5601 6833 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5602 6834 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5603 6835 |
|
5604 6836 | {
|
5605 6837 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5606 6838 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5607 - | let svc = crate::operation_shape::JsonLists::from_service(service);
|
6839 + | let svc = crate::operation_shape::JsonTimestamps::from_service(service);
|
5608 6840 | let svc = self.model_plugin.apply(svc);
|
5609 6841 | let svc =
|
5610 6842 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5611 6843 | .apply(svc);
|
5612 6844 | let svc = self.http_plugin.apply(svc);
|
5613 - | self.json_lists_custom(svc)
|
6845 + | self.json_timestamps_custom(svc)
|
5614 6846 | }
|
5615 6847 |
|
5616 - | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) to a custom [`Service`](tower::Service).
|
6848 + | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) to a custom [`Service`](tower::Service).
|
5617 6849 | /// not constrained by the Smithy contract.
|
5618 - | fn json_lists_custom<S>(mut self, svc: S) -> Self
|
6850 + | fn json_timestamps_custom<S>(mut self, svc: S) -> Self
|
5619 6851 | where
|
5620 6852 | S: ::tower::Service<
|
5621 6853 | ::http::Request<Body>,
|
5622 6854 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5623 6855 | Error = ::std::convert::Infallible,
|
5624 6856 | > + Clone
|
5625 6857 | + Send
|
5626 6858 | + 'static,
|
5627 6859 | S::Future: Send + 'static,
|
5628 6860 | {
|
5629 - | self.json_lists = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6861 + | self.json_timestamps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5630 6862 | self
|
5631 6863 | }
|
5632 6864 |
|
5633 - | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
6865 + | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
5634 6866 | ///
|
5635 6867 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5636 6868 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5637 6869 | ///
|
5638 6870 | /// # Example
|
5639 6871 | ///
|
5640 6872 | /// ```no_run
|
5641 6873 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5642 6874 | ///
|
5643 6875 | /// use rest_json_http0x::{input, output, error};
|
5644 6876 | ///
|
5645 - | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
6877 + | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
5646 6878 | /// todo!()
|
5647 6879 | /// }
|
5648 6880 | ///
|
5649 6881 | /// let config = RestJsonConfig::builder().build();
|
5650 6882 | /// let app = RestJson::builder(config)
|
5651 - | /// .json_maps(handler)
|
6883 + | /// .json_unions(handler)
|
5652 6884 | /// /* Set other handlers */
|
5653 6885 | /// .build()
|
5654 6886 | /// .unwrap();
|
5655 6887 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5656 6888 | /// ```
|
5657 6889 | ///
|
5658 - | pub fn json_maps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6890 + | pub fn json_unions<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5659 6891 | where
|
5660 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonMaps, HandlerExtractors>,
|
6892 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonUnions, HandlerExtractors>,
|
5661 6893 |
|
5662 6894 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5663 6895 | RestJson<L>,
|
5664 - | crate::operation_shape::JsonMaps,
|
5665 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonMaps, HandlerType>
|
6896 + | crate::operation_shape::JsonUnions,
|
6897 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonUnions, HandlerType>
|
5666 6898 | >,
|
5667 6899 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5668 6900 | RestJson<L>,
|
5669 - | crate::operation_shape::JsonMaps,
|
6901 + | crate::operation_shape::JsonUnions,
|
5670 6902 | ModelPl::Output
|
5671 6903 | >,
|
5672 6904 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5673 6905 | RestJson<L>,
|
5674 - | crate::operation_shape::JsonMaps,
|
6906 + | crate::operation_shape::JsonUnions,
|
5675 6907 | <
|
5676 6908 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5677 6909 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5678 6910 | RestJson<L>,
|
5679 - | crate::operation_shape::JsonMaps,
|
6911 + | crate::operation_shape::JsonUnions,
|
5680 6912 | ModelPl::Output
|
5681 6913 | >
|
5682 6914 | >::Output
|
5683 6915 | >,
|
5684 6916 |
|
5685 6917 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5686 6918 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5687 6919 |
|
5688 6920 | {
|
5689 6921 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5690 6922 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5691 - | let svc = crate::operation_shape::JsonMaps::from_handler(handler);
|
6923 + | let svc = crate::operation_shape::JsonUnions::from_handler(handler);
|
5692 6924 | let svc = self.model_plugin.apply(svc);
|
5693 6925 | let svc =
|
5694 6926 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5695 6927 | .apply(svc);
|
5696 6928 | let svc = self.http_plugin.apply(svc);
|
5697 - | self.json_maps_custom(svc)
|
6929 + | self.json_unions_custom(svc)
|
5698 6930 | }
|
5699 6931 |
|
5700 - | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
6932 + | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
5701 6933 | ///
|
5702 6934 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5703 6935 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5704 6936 | ///
|
5705 6937 | /// # Example
|
5706 6938 | ///
|
5707 6939 | /// ```no_run
|
5708 6940 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5709 6941 | ///
|
5710 6942 | /// use rest_json_http0x::{input, output, error};
|
5711 6943 | ///
|
5712 - | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
6944 + | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
5713 6945 | /// todo!()
|
5714 6946 | /// }
|
5715 6947 | ///
|
5716 6948 | /// let config = RestJsonConfig::builder().build();
|
5717 6949 | /// let svc = ::tower::util::service_fn(handler);
|
5718 6950 | /// let app = RestJson::builder(config)
|
5719 - | /// .json_maps_service(svc)
|
6951 + | /// .json_unions_service(svc)
|
5720 6952 | /// /* Set other handlers */
|
5721 6953 | /// .build()
|
5722 6954 | /// .unwrap();
|
5723 6955 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5724 6956 | /// ```
|
5725 6957 | ///
|
5726 - | pub fn json_maps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6958 + | pub fn json_unions_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5727 6959 | where
|
5728 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonMaps, ServiceExtractors>,
|
6960 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonUnions, ServiceExtractors>,
|
5729 6961 |
|
5730 6962 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5731 6963 | RestJson<L>,
|
5732 - | crate::operation_shape::JsonMaps,
|
5733 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonMaps, S>
|
6964 + | crate::operation_shape::JsonUnions,
|
6965 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonUnions, S>
|
5734 6966 | >,
|
5735 6967 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5736 6968 | RestJson<L>,
|
5737 - | crate::operation_shape::JsonMaps,
|
6969 + | crate::operation_shape::JsonUnions,
|
5738 6970 | ModelPl::Output
|
5739 6971 | >,
|
5740 6972 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5741 6973 | RestJson<L>,
|
5742 - | crate::operation_shape::JsonMaps,
|
6974 + | crate::operation_shape::JsonUnions,
|
5743 6975 | <
|
5744 6976 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5745 6977 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5746 6978 | RestJson<L>,
|
5747 - | crate::operation_shape::JsonMaps,
|
6979 + | crate::operation_shape::JsonUnions,
|
5748 6980 | ModelPl::Output
|
5749 6981 | >
|
5750 6982 | >::Output
|
5751 6983 | >,
|
5752 6984 |
|
5753 6985 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5754 6986 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5755 6987 |
|
5756 6988 | {
|
5757 6989 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5758 6990 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5759 - | let svc = crate::operation_shape::JsonMaps::from_service(service);
|
6991 + | let svc = crate::operation_shape::JsonUnions::from_service(service);
|
5760 6992 | let svc = self.model_plugin.apply(svc);
|
5761 6993 | let svc =
|
5762 6994 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5763 6995 | .apply(svc);
|
5764 6996 | let svc = self.http_plugin.apply(svc);
|
5765 - | self.json_maps_custom(svc)
|
6997 + | self.json_unions_custom(svc)
|
5766 6998 | }
|
5767 6999 |
|
5768 - | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) to a custom [`Service`](tower::Service).
|
7000 + | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) to a custom [`Service`](tower::Service).
|
5769 7001 | /// not constrained by the Smithy contract.
|
5770 - | fn json_maps_custom<S>(mut self, svc: S) -> Self
|
7002 + | fn json_unions_custom<S>(mut self, svc: S) -> Self
|
5771 7003 | where
|
5772 7004 | S: ::tower::Service<
|
5773 7005 | ::http::Request<Body>,
|
5774 7006 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5775 7007 | Error = ::std::convert::Infallible,
|
5776 7008 | > + Clone
|
5777 7009 | + Send
|
5778 7010 | + 'static,
|
5779 7011 | S::Future: Send + 'static,
|
5780 7012 | {
|
5781 - | self.json_maps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7013 + | self.json_unions = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5782 7014 | self
|
5783 7015 | }
|
5784 7016 |
|
5785 - | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
7017 + | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
5786 7018 | ///
|
5787 7019 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5788 7020 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5789 7021 | ///
|
5790 7022 | /// # Example
|
5791 7023 | ///
|
5792 7024 | /// ```no_run
|
5793 7025 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5794 7026 | ///
|
5795 7027 | /// use rest_json_http0x::{input, output, error};
|
5796 7028 | ///
|
5797 - | /// async fn handler(input: input::JsonTimestampsInput) -> output::JsonTimestampsOutput {
|
7029 + | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> output::MalformedAcceptWithBodyOutput {
|
5798 7030 | /// todo!()
|
5799 7031 | /// }
|
5800 7032 | ///
|
5801 7033 | /// let config = RestJsonConfig::builder().build();
|
5802 7034 | /// let app = RestJson::builder(config)
|
5803 - | /// .json_timestamps(handler)
|
7035 + | /// .malformed_accept_with_body(handler)
|
5804 7036 | /// /* Set other handlers */
|
5805 7037 | /// .build()
|
5806 7038 | /// .unwrap();
|
5807 7039 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5808 7040 | /// ```
|
5809 7041 | ///
|
5810 - | pub fn json_timestamps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7042 + | pub fn malformed_accept_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5811 7043 | where
|
5812 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonTimestamps, HandlerExtractors>,
|
7044 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithBody, HandlerExtractors>,
|
5813 7045 |
|
5814 7046 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5815 7047 | RestJson<L>,
|
5816 - | crate::operation_shape::JsonTimestamps,
|
5817 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonTimestamps, HandlerType>
|
7048 + | crate::operation_shape::MalformedAcceptWithBody,
|
7049 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithBody, HandlerType>
|
5818 7050 | >,
|
5819 7051 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5820 7052 | RestJson<L>,
|
5821 - | crate::operation_shape::JsonTimestamps,
|
7053 + | crate::operation_shape::MalformedAcceptWithBody,
|
5822 7054 | ModelPl::Output
|
5823 7055 | >,
|
5824 7056 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5825 7057 | RestJson<L>,
|
5826 - | crate::operation_shape::JsonTimestamps,
|
7058 + | crate::operation_shape::MalformedAcceptWithBody,
|
5827 7059 | <
|
5828 7060 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5829 7061 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5830 7062 | RestJson<L>,
|
5831 - | crate::operation_shape::JsonTimestamps,
|
7063 + | crate::operation_shape::MalformedAcceptWithBody,
|
5832 7064 | ModelPl::Output
|
5833 7065 | >
|
5834 7066 | >::Output
|
5835 7067 | >,
|
5836 7068 |
|
5837 7069 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5838 7070 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5839 7071 |
|
5840 7072 | {
|
5841 7073 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5842 7074 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5843 - | let svc = crate::operation_shape::JsonTimestamps::from_handler(handler);
|
7075 + | let svc = crate::operation_shape::MalformedAcceptWithBody::from_handler(handler);
|
5844 7076 | let svc = self.model_plugin.apply(svc);
|
5845 7077 | let svc =
|
5846 7078 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5847 7079 | .apply(svc);
|
5848 7080 | let svc = self.http_plugin.apply(svc);
|
5849 - | self.json_timestamps_custom(svc)
|
7081 + | self.malformed_accept_with_body_custom(svc)
|
5850 7082 | }
|
5851 7083 |
|
5852 - | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
7084 + | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
5853 7085 | ///
|
5854 7086 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5855 7087 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5856 7088 | ///
|
5857 7089 | /// # Example
|
5858 7090 | ///
|
5859 7091 | /// ```no_run
|
5860 7092 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5861 7093 | ///
|
5862 7094 | /// use rest_json_http0x::{input, output, error};
|
5863 7095 | ///
|
5864 - | /// async fn handler(input: input::JsonTimestampsInput) -> Result<output::JsonTimestampsOutput, std::convert::Infallible> {
|
7096 + | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> Result<output::MalformedAcceptWithBodyOutput, std::convert::Infallible> {
|
5865 7097 | /// todo!()
|
5866 7098 | /// }
|
5867 7099 | ///
|
5868 7100 | /// let config = RestJsonConfig::builder().build();
|
5869 7101 | /// let svc = ::tower::util::service_fn(handler);
|
5870 7102 | /// let app = RestJson::builder(config)
|
5871 - | /// .json_timestamps_service(svc)
|
7103 + | /// .malformed_accept_with_body_service(svc)
|
5872 7104 | /// /* Set other handlers */
|
5873 7105 | /// .build()
|
5874 7106 | /// .unwrap();
|
5875 7107 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5876 7108 | /// ```
|
5877 7109 | ///
|
5878 - | pub fn json_timestamps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7110 + | pub fn malformed_accept_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5879 7111 | where
|
5880 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonTimestamps, ServiceExtractors>,
|
7112 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithBody, ServiceExtractors>,
|
5881 7113 |
|
5882 7114 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5883 7115 | RestJson<L>,
|
5884 - | crate::operation_shape::JsonTimestamps,
|
5885 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonTimestamps, S>
|
7116 + | crate::operation_shape::MalformedAcceptWithBody,
|
7117 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithBody, S>
|
5886 7118 | >,
|
5887 7119 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5888 7120 | RestJson<L>,
|
5889 - | crate::operation_shape::JsonTimestamps,
|
7121 + | crate::operation_shape::MalformedAcceptWithBody,
|
5890 7122 | ModelPl::Output
|
5891 7123 | >,
|
5892 7124 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5893 7125 | RestJson<L>,
|
5894 - | crate::operation_shape::JsonTimestamps,
|
7126 + | crate::operation_shape::MalformedAcceptWithBody,
|
5895 7127 | <
|
5896 7128 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5897 7129 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5898 7130 | RestJson<L>,
|
5899 - | crate::operation_shape::JsonTimestamps,
|
7131 + | crate::operation_shape::MalformedAcceptWithBody,
|
5900 7132 | ModelPl::Output
|
5901 7133 | >
|
5902 7134 | >::Output
|
5903 7135 | >,
|
5904 7136 |
|
5905 7137 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5906 7138 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5907 7139 |
|
5908 7140 | {
|
5909 7141 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5910 7142 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5911 - | let svc = crate::operation_shape::JsonTimestamps::from_service(service);
|
7143 + | let svc = crate::operation_shape::MalformedAcceptWithBody::from_service(service);
|
5912 7144 | let svc = self.model_plugin.apply(svc);
|
5913 7145 | let svc =
|
5914 7146 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5915 7147 | .apply(svc);
|
5916 7148 | let svc = self.http_plugin.apply(svc);
|
5917 - | self.json_timestamps_custom(svc)
|
7149 + | self.malformed_accept_with_body_custom(svc)
|
5918 7150 | }
|
5919 7151 |
|
5920 - | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) to a custom [`Service`](tower::Service).
|
7152 + | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) to a custom [`Service`](tower::Service).
|
5921 7153 | /// not constrained by the Smithy contract.
|
5922 - | fn json_timestamps_custom<S>(mut self, svc: S) -> Self
|
7154 + | fn malformed_accept_with_body_custom<S>(mut self, svc: S) -> Self
|
5923 7155 | where
|
5924 7156 | S: ::tower::Service<
|
5925 7157 | ::http::Request<Body>,
|
5926 7158 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5927 7159 | Error = ::std::convert::Infallible,
|
5928 7160 | > + Clone
|
5929 7161 | + Send
|
5930 7162 | + 'static,
|
5931 7163 | S::Future: Send + 'static,
|
5932 7164 | {
|
5933 - | self.json_timestamps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7165 + | self.malformed_accept_with_body =
|
7166 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5934 7167 | self
|
5935 7168 | }
|
5936 7169 |
|
5937 - | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
7170 + | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
5938 7171 | ///
|
5939 7172 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5940 7173 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5941 7174 | ///
|
5942 7175 | /// # Example
|
5943 7176 | ///
|
5944 7177 | /// ```no_run
|
5945 7178 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
5946 7179 | ///
|
5947 7180 | /// use rest_json_http0x::{input, output, error};
|
5948 7181 | ///
|
5949 - | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
7182 + | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> output::MalformedAcceptWithGenericStringOutput {
|
5950 7183 | /// todo!()
|
5951 7184 | /// }
|
5952 7185 | ///
|
5953 7186 | /// let config = RestJsonConfig::builder().build();
|
5954 7187 | /// let app = RestJson::builder(config)
|
5955 - | /// .json_unions(handler)
|
7188 + | /// .malformed_accept_with_generic_string(handler)
|
5956 7189 | /// /* Set other handlers */
|
5957 7190 | /// .build()
|
5958 7191 | /// .unwrap();
|
5959 7192 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5960 7193 | /// ```
|
5961 7194 | ///
|
5962 - | pub fn json_unions<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7195 + | pub fn malformed_accept_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5963 7196 | where
|
5964 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonUnions, HandlerExtractors>,
|
7197 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithGenericString, HandlerExtractors>,
|
5965 7198 |
|
5966 7199 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5967 7200 | RestJson<L>,
|
5968 - | crate::operation_shape::JsonUnions,
|
5969 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonUnions, HandlerType>
|
7201 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
7202 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithGenericString, HandlerType>
|
5970 7203 | >,
|
5971 7204 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5972 7205 | RestJson<L>,
|
5973 - | crate::operation_shape::JsonUnions,
|
7206 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
5974 7207 | ModelPl::Output
|
5975 7208 | >,
|
5976 7209 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5977 7210 | RestJson<L>,
|
5978 - | crate::operation_shape::JsonUnions,
|
7211 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
5979 7212 | <
|
5980 7213 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5981 7214 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5982 7215 | RestJson<L>,
|
5983 - | crate::operation_shape::JsonUnions,
|
7216 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
5984 7217 | ModelPl::Output
|
5985 7218 | >
|
5986 7219 | >::Output
|
5987 7220 | >,
|
5988 7221 |
|
5989 7222 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5990 7223 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5991 7224 |
|
5992 7225 | {
|
5993 7226 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5994 7227 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5995 - | let svc = crate::operation_shape::JsonUnions::from_handler(handler);
|
7228 + | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_handler(handler);
|
5996 7229 | let svc = self.model_plugin.apply(svc);
|
5997 7230 | let svc =
|
5998 7231 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5999 7232 | .apply(svc);
|
6000 7233 | let svc = self.http_plugin.apply(svc);
|
6001 - | self.json_unions_custom(svc)
|
7234 + | self.malformed_accept_with_generic_string_custom(svc)
|
6002 7235 | }
|
6003 7236 |
|
6004 - | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
7237 + | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
6005 7238 | ///
|
6006 7239 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6007 7240 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6008 7241 | ///
|
6009 7242 | /// # Example
|
6010 7243 | ///
|
6011 7244 | /// ```no_run
|
6012 7245 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6013 7246 | ///
|
6014 7247 | /// use rest_json_http0x::{input, output, error};
|
6015 7248 | ///
|
6016 - | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
7249 + | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> Result<output::MalformedAcceptWithGenericStringOutput, std::convert::Infallible> {
|
6017 7250 | /// todo!()
|
6018 7251 | /// }
|
6019 7252 | ///
|
6020 7253 | /// let config = RestJsonConfig::builder().build();
|
6021 7254 | /// let svc = ::tower::util::service_fn(handler);
|
6022 7255 | /// let app = RestJson::builder(config)
|
6023 - | /// .json_unions_service(svc)
|
7256 + | /// .malformed_accept_with_generic_string_service(svc)
|
6024 7257 | /// /* Set other handlers */
|
6025 7258 | /// .build()
|
6026 7259 | /// .unwrap();
|
6027 7260 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6028 7261 | /// ```
|
6029 7262 | ///
|
6030 - | pub fn json_unions_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7263 + | pub fn malformed_accept_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6031 7264 | where
|
6032 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonUnions, ServiceExtractors>,
|
7265 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithGenericString, ServiceExtractors>,
|
6033 7266 |
|
6034 7267 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6035 7268 | RestJson<L>,
|
6036 - | crate::operation_shape::JsonUnions,
|
6037 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonUnions, S>
|
7269 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
7270 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithGenericString, S>
|
6038 7271 | >,
|
6039 7272 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6040 7273 | RestJson<L>,
|
6041 - | crate::operation_shape::JsonUnions,
|
7274 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
6042 7275 | ModelPl::Output
|
6043 7276 | >,
|
6044 7277 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6045 7278 | RestJson<L>,
|
6046 - | crate::operation_shape::JsonUnions,
|
7279 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
6047 7280 | <
|
6048 7281 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6049 7282 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6050 7283 | RestJson<L>,
|
6051 - | crate::operation_shape::JsonUnions,
|
7284 + | crate::operation_shape::MalformedAcceptWithGenericString,
|
6052 7285 | ModelPl::Output
|
6053 7286 | >
|
6054 7287 | >::Output
|
6055 7288 | >,
|
6056 7289 |
|
6057 7290 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6058 7291 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6059 7292 |
|
6060 7293 | {
|
6061 7294 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6062 7295 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6063 - | let svc = crate::operation_shape::JsonUnions::from_service(service);
|
7296 + | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_service(service);
|
6064 7297 | let svc = self.model_plugin.apply(svc);
|
6065 7298 | let svc =
|
6066 7299 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6067 7300 | .apply(svc);
|
6068 7301 | let svc = self.http_plugin.apply(svc);
|
6069 - | self.json_unions_custom(svc)
|
7302 + | self.malformed_accept_with_generic_string_custom(svc)
|
6070 7303 | }
|
6071 7304 |
|
6072 - | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) to a custom [`Service`](tower::Service).
|
7305 + | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) to a custom [`Service`](tower::Service).
|
6073 7306 | /// not constrained by the Smithy contract.
|
6074 - | fn json_unions_custom<S>(mut self, svc: S) -> Self
|
7307 + | fn malformed_accept_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
6075 7308 | where
|
6076 7309 | S: ::tower::Service<
|
6077 7310 | ::http::Request<Body>,
|
6078 7311 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6079 7312 | Error = ::std::convert::Infallible,
|
6080 7313 | > + Clone
|
6081 7314 | + Send
|
6082 7315 | + 'static,
|
6083 7316 | S::Future: Send + 'static,
|
6084 7317 | {
|
6085 - | self.json_unions = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7318 + | self.malformed_accept_with_generic_string =
|
7319 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6086 7320 | self
|
6087 7321 | }
|
6088 7322 |
|
6089 - | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
7323 + | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
6090 7324 | ///
|
6091 7325 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6092 7326 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6093 7327 | ///
|
6094 7328 | /// # Example
|
6095 7329 | ///
|
6096 7330 | /// ```no_run
|
6097 7331 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6098 7332 | ///
|
6099 7333 | /// use rest_json_http0x::{input, output, error};
|
6100 7334 | ///
|
6101 - | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> output::MalformedAcceptWithBodyOutput {
|
7335 + | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> output::MalformedAcceptWithPayloadOutput {
|
6102 7336 | /// todo!()
|
6103 7337 | /// }
|
6104 7338 | ///
|
6105 7339 | /// let config = RestJsonConfig::builder().build();
|
6106 7340 | /// let app = RestJson::builder(config)
|
6107 - | /// .malformed_accept_with_body(handler)
|
7341 + | /// .malformed_accept_with_payload(handler)
|
6108 7342 | /// /* Set other handlers */
|
6109 7343 | /// .build()
|
6110 7344 | /// .unwrap();
|
6111 7345 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6112 7346 | /// ```
|
6113 7347 | ///
|
6114 - | pub fn malformed_accept_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7348 + | pub fn malformed_accept_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6115 7349 | where
|
6116 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithBody, HandlerExtractors>,
|
7350 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithPayload, HandlerExtractors>,
|
6117 7351 |
|
6118 7352 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6119 7353 | RestJson<L>,
|
6120 - | crate::operation_shape::MalformedAcceptWithBody,
|
6121 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithBody, HandlerType>
|
7354 + | crate::operation_shape::MalformedAcceptWithPayload,
|
7355 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithPayload, HandlerType>
|
6122 7356 | >,
|
6123 7357 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6124 7358 | RestJson<L>,
|
6125 - | crate::operation_shape::MalformedAcceptWithBody,
|
7359 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6126 7360 | ModelPl::Output
|
6127 7361 | >,
|
6128 7362 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6129 7363 | RestJson<L>,
|
6130 - | crate::operation_shape::MalformedAcceptWithBody,
|
7364 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6131 7365 | <
|
6132 7366 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6133 7367 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6134 7368 | RestJson<L>,
|
6135 - | crate::operation_shape::MalformedAcceptWithBody,
|
7369 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6136 7370 | ModelPl::Output
|
6137 7371 | >
|
6138 7372 | >::Output
|
6139 7373 | >,
|
6140 7374 |
|
6141 7375 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6142 7376 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6143 7377 |
|
6144 7378 | {
|
6145 7379 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6146 7380 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6147 - | let svc = crate::operation_shape::MalformedAcceptWithBody::from_handler(handler);
|
7381 + | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_handler(handler);
|
6148 7382 | let svc = self.model_plugin.apply(svc);
|
6149 7383 | let svc =
|
6150 7384 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6151 7385 | .apply(svc);
|
6152 7386 | let svc = self.http_plugin.apply(svc);
|
6153 - | self.malformed_accept_with_body_custom(svc)
|
7387 + | self.malformed_accept_with_payload_custom(svc)
|
6154 7388 | }
|
6155 7389 |
|
6156 - | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
7390 + | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
6157 7391 | ///
|
6158 7392 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6159 7393 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6160 7394 | ///
|
6161 7395 | /// # Example
|
6162 7396 | ///
|
6163 7397 | /// ```no_run
|
6164 7398 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6165 7399 | ///
|
6166 7400 | /// use rest_json_http0x::{input, output, error};
|
6167 7401 | ///
|
6168 - | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> Result<output::MalformedAcceptWithBodyOutput, std::convert::Infallible> {
|
7402 + | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> Result<output::MalformedAcceptWithPayloadOutput, std::convert::Infallible> {
|
6169 7403 | /// todo!()
|
6170 7404 | /// }
|
6171 7405 | ///
|
6172 7406 | /// let config = RestJsonConfig::builder().build();
|
6173 7407 | /// let svc = ::tower::util::service_fn(handler);
|
6174 7408 | /// let app = RestJson::builder(config)
|
6175 - | /// .malformed_accept_with_body_service(svc)
|
7409 + | /// .malformed_accept_with_payload_service(svc)
|
6176 7410 | /// /* Set other handlers */
|
6177 7411 | /// .build()
|
6178 7412 | /// .unwrap();
|
6179 7413 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6180 7414 | /// ```
|
6181 7415 | ///
|
6182 - | pub fn malformed_accept_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7416 + | pub fn malformed_accept_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6183 7417 | where
|
6184 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithBody, ServiceExtractors>,
|
7418 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithPayload, ServiceExtractors>,
|
6185 7419 |
|
6186 7420 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6187 7421 | RestJson<L>,
|
6188 - | crate::operation_shape::MalformedAcceptWithBody,
|
6189 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithBody, S>
|
7422 + | crate::operation_shape::MalformedAcceptWithPayload,
|
7423 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithPayload, S>
|
6190 7424 | >,
|
6191 7425 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6192 7426 | RestJson<L>,
|
6193 - | crate::operation_shape::MalformedAcceptWithBody,
|
7427 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6194 7428 | ModelPl::Output
|
6195 7429 | >,
|
6196 7430 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6197 7431 | RestJson<L>,
|
6198 - | crate::operation_shape::MalformedAcceptWithBody,
|
7432 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6199 7433 | <
|
6200 7434 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6201 7435 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6202 7436 | RestJson<L>,
|
6203 - | crate::operation_shape::MalformedAcceptWithBody,
|
7437 + | crate::operation_shape::MalformedAcceptWithPayload,
|
6204 7438 | ModelPl::Output
|
6205 7439 | >
|
6206 7440 | >::Output
|
6207 7441 | >,
|
6208 7442 |
|
6209 7443 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6210 7444 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6211 7445 |
|
6212 7446 | {
|
6213 7447 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6214 7448 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6215 - | let svc = crate::operation_shape::MalformedAcceptWithBody::from_service(service);
|
7449 + | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_service(service);
|
6216 7450 | let svc = self.model_plugin.apply(svc);
|
6217 7451 | let svc =
|
6218 7452 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6219 7453 | .apply(svc);
|
6220 7454 | let svc = self.http_plugin.apply(svc);
|
6221 - | self.malformed_accept_with_body_custom(svc)
|
7455 + | self.malformed_accept_with_payload_custom(svc)
|
6222 7456 | }
|
6223 7457 |
|
6224 - | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) to a custom [`Service`](tower::Service).
|
7458 + | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) to a custom [`Service`](tower::Service).
|
6225 7459 | /// not constrained by the Smithy contract.
|
6226 - | fn malformed_accept_with_body_custom<S>(mut self, svc: S) -> Self
|
7460 + | fn malformed_accept_with_payload_custom<S>(mut self, svc: S) -> Self
|
6227 7461 | where
|
6228 7462 | S: ::tower::Service<
|
6229 7463 | ::http::Request<Body>,
|
6230 7464 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6231 7465 | Error = ::std::convert::Infallible,
|
6232 7466 | > + Clone
|
6233 7467 | + Send
|
6234 7468 | + 'static,
|
6235 7469 | S::Future: Send + 'static,
|
6236 7470 | {
|
6237 - | self.malformed_accept_with_body =
|
7471 + | self.malformed_accept_with_payload =
|
6238 7472 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6239 7473 | self
|
6240 7474 | }
|
6241 7475 |
|
6242 - | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
7476 + | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
6243 7477 | ///
|
6244 7478 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6245 7479 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6246 7480 | ///
|
6247 7481 | /// # Example
|
6248 7482 | ///
|
6249 7483 | /// ```no_run
|
6250 7484 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6251 7485 | ///
|
6252 7486 | /// use rest_json_http0x::{input, output, error};
|
6253 7487 | ///
|
6254 - | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> output::MalformedAcceptWithGenericStringOutput {
|
7488 + | /// async fn handler(input: input::MalformedBlobInput) -> output::MalformedBlobOutput {
|
6255 7489 | /// todo!()
|
6256 7490 | /// }
|
6257 7491 | ///
|
6258 7492 | /// let config = RestJsonConfig::builder().build();
|
6259 7493 | /// let app = RestJson::builder(config)
|
6260 - | /// .malformed_accept_with_generic_string(handler)
|
7494 + | /// .malformed_blob(handler)
|
6261 7495 | /// /* Set other handlers */
|
6262 7496 | /// .build()
|
6263 7497 | /// .unwrap();
|
6264 7498 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6265 7499 | /// ```
|
6266 7500 | ///
|
6267 - | pub fn malformed_accept_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7501 + | pub fn malformed_blob<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6268 7502 | where
|
6269 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithGenericString, HandlerExtractors>,
|
7503 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBlob, HandlerExtractors>,
|
6270 7504 |
|
6271 7505 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6272 7506 | RestJson<L>,
|
6273 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
6274 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithGenericString, HandlerType>
|
7507 + | crate::operation_shape::MalformedBlob,
|
7508 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBlob, HandlerType>
|
6275 7509 | >,
|
6276 7510 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6277 7511 | RestJson<L>,
|
6278 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7512 + | crate::operation_shape::MalformedBlob,
|
6279 7513 | ModelPl::Output
|
6280 7514 | >,
|
6281 7515 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6282 7516 | RestJson<L>,
|
6283 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7517 + | crate::operation_shape::MalformedBlob,
|
6284 7518 | <
|
6285 7519 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6286 7520 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6287 7521 | RestJson<L>,
|
6288 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7522 + | crate::operation_shape::MalformedBlob,
|
6289 7523 | ModelPl::Output
|
6290 7524 | >
|
6291 7525 | >::Output
|
6292 7526 | >,
|
6293 7527 |
|
6294 7528 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6295 7529 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6296 7530 |
|
6297 7531 | {
|
6298 7532 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6299 7533 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6300 - | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_handler(handler);
|
7534 + | let svc = crate::operation_shape::MalformedBlob::from_handler(handler);
|
6301 7535 | let svc = self.model_plugin.apply(svc);
|
6302 7536 | let svc =
|
6303 7537 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6304 7538 | .apply(svc);
|
6305 7539 | let svc = self.http_plugin.apply(svc);
|
6306 - | self.malformed_accept_with_generic_string_custom(svc)
|
7540 + | self.malformed_blob_custom(svc)
|
6307 7541 | }
|
6308 7542 |
|
6309 - | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
7543 + | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
6310 7544 | ///
|
6311 7545 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6312 7546 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6313 7547 | ///
|
6314 7548 | /// # Example
|
6315 7549 | ///
|
6316 7550 | /// ```no_run
|
6317 7551 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6318 7552 | ///
|
6319 7553 | /// use rest_json_http0x::{input, output, error};
|
6320 7554 | ///
|
6321 - | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> Result<output::MalformedAcceptWithGenericStringOutput, std::convert::Infallible> {
|
7555 + | /// async fn handler(input: input::MalformedBlobInput) -> Result<output::MalformedBlobOutput, std::convert::Infallible> {
|
6322 7556 | /// todo!()
|
6323 7557 | /// }
|
6324 7558 | ///
|
6325 7559 | /// let config = RestJsonConfig::builder().build();
|
6326 7560 | /// let svc = ::tower::util::service_fn(handler);
|
6327 7561 | /// let app = RestJson::builder(config)
|
6328 - | /// .malformed_accept_with_generic_string_service(svc)
|
7562 + | /// .malformed_blob_service(svc)
|
6329 7563 | /// /* Set other handlers */
|
6330 7564 | /// .build()
|
6331 7565 | /// .unwrap();
|
6332 7566 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6333 7567 | /// ```
|
6334 7568 | ///
|
6335 - | pub fn malformed_accept_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7569 + | pub fn malformed_blob_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6336 7570 | where
|
6337 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithGenericString, ServiceExtractors>,
|
7571 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBlob, ServiceExtractors>,
|
6338 7572 |
|
6339 7573 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6340 7574 | RestJson<L>,
|
6341 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
6342 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithGenericString, S>
|
7575 + | crate::operation_shape::MalformedBlob,
|
7576 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBlob, S>
|
6343 7577 | >,
|
6344 7578 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6345 7579 | RestJson<L>,
|
6346 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7580 + | crate::operation_shape::MalformedBlob,
|
6347 7581 | ModelPl::Output
|
6348 7582 | >,
|
6349 7583 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6350 7584 | RestJson<L>,
|
6351 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7585 + | crate::operation_shape::MalformedBlob,
|
6352 7586 | <
|
6353 7587 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6354 7588 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6355 7589 | RestJson<L>,
|
6356 - | crate::operation_shape::MalformedAcceptWithGenericString,
|
7590 + | crate::operation_shape::MalformedBlob,
|
6357 7591 | ModelPl::Output
|
6358 7592 | >
|
6359 7593 | >::Output
|
6360 7594 | >,
|
6361 7595 |
|
6362 7596 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6363 7597 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6364 7598 |
|
6365 7599 | {
|
6366 7600 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6367 7601 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6368 - | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_service(service);
|
7602 + | let svc = crate::operation_shape::MalformedBlob::from_service(service);
|
6369 7603 | let svc = self.model_plugin.apply(svc);
|
6370 7604 | let svc =
|
6371 7605 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6372 7606 | .apply(svc);
|
6373 7607 | let svc = self.http_plugin.apply(svc);
|
6374 - | self.malformed_accept_with_generic_string_custom(svc)
|
7608 + | self.malformed_blob_custom(svc)
|
6375 7609 | }
|
6376 7610 |
|
6377 - | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) to a custom [`Service`](tower::Service).
|
7611 + | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) to a custom [`Service`](tower::Service).
|
6378 7612 | /// not constrained by the Smithy contract.
|
6379 - | fn malformed_accept_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
7613 + | fn malformed_blob_custom<S>(mut self, svc: S) -> Self
|
6380 7614 | where
|
6381 7615 | S: ::tower::Service<
|
6382 7616 | ::http::Request<Body>,
|
6383 7617 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6384 7618 | Error = ::std::convert::Infallible,
|
6385 7619 | > + Clone
|
6386 7620 | + Send
|
6387 7621 | + 'static,
|
6388 7622 | S::Future: Send + 'static,
|
6389 7623 | {
|
6390 - | self.malformed_accept_with_generic_string =
|
6391 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7624 + | self.malformed_blob = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6392 7625 | self
|
6393 7626 | }
|
6394 7627 |
|
6395 - | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
7628 + | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
6396 7629 | ///
|
6397 7630 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6398 7631 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6399 7632 | ///
|
6400 7633 | /// # Example
|
6401 7634 | ///
|
6402 7635 | /// ```no_run
|
6403 7636 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6404 7637 | ///
|
6405 7638 | /// use rest_json_http0x::{input, output, error};
|
6406 7639 | ///
|
6407 - | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> output::MalformedAcceptWithPayloadOutput {
|
7640 + | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
6408 7641 | /// todo!()
|
6409 7642 | /// }
|
6410 7643 | ///
|
6411 7644 | /// let config = RestJsonConfig::builder().build();
|
6412 7645 | /// let app = RestJson::builder(config)
|
6413 - | /// .malformed_accept_with_payload(handler)
|
7646 + | /// .malformed_boolean(handler)
|
6414 7647 | /// /* Set other handlers */
|
6415 7648 | /// .build()
|
6416 7649 | /// .unwrap();
|
6417 7650 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6418 7651 | /// ```
|
6419 7652 | ///
|
6420 - | pub fn malformed_accept_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7653 + | pub fn malformed_boolean<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6421 7654 | where
|
6422 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithPayload, HandlerExtractors>,
|
7655 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBoolean, HandlerExtractors>,
|
6423 7656 |
|
6424 7657 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6425 7658 | RestJson<L>,
|
6426 - | crate::operation_shape::MalformedAcceptWithPayload,
|
6427 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithPayload, HandlerType>
|
7659 + | crate::operation_shape::MalformedBoolean,
|
7660 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBoolean, HandlerType>
|
6428 7661 | >,
|
6429 7662 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6430 7663 | RestJson<L>,
|
6431 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7664 + | crate::operation_shape::MalformedBoolean,
|
6432 7665 | ModelPl::Output
|
6433 7666 | >,
|
6434 7667 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6435 7668 | RestJson<L>,
|
6436 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7669 + | crate::operation_shape::MalformedBoolean,
|
6437 7670 | <
|
6438 7671 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6439 7672 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6440 7673 | RestJson<L>,
|
6441 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7674 + | crate::operation_shape::MalformedBoolean,
|
6442 7675 | ModelPl::Output
|
6443 7676 | >
|
6444 7677 | >::Output
|
6445 7678 | >,
|
6446 7679 |
|
6447 7680 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6448 7681 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6449 7682 |
|
6450 7683 | {
|
6451 7684 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6452 7685 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6453 - | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_handler(handler);
|
7686 + | let svc = crate::operation_shape::MalformedBoolean::from_handler(handler);
|
6454 7687 | let svc = self.model_plugin.apply(svc);
|
6455 7688 | let svc =
|
6456 7689 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6457 7690 | .apply(svc);
|
6458 7691 | let svc = self.http_plugin.apply(svc);
|
6459 - | self.malformed_accept_with_payload_custom(svc)
|
7692 + | self.malformed_boolean_custom(svc)
|
6460 7693 | }
|
6461 7694 |
|
6462 - | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
7695 + | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
6463 7696 | ///
|
6464 7697 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6465 7698 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6466 7699 | ///
|
6467 7700 | /// # Example
|
6468 7701 | ///
|
6469 7702 | /// ```no_run
|
6470 7703 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6471 7704 | ///
|
6472 7705 | /// use rest_json_http0x::{input, output, error};
|
6473 7706 | ///
|
6474 - | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> Result<output::MalformedAcceptWithPayloadOutput, std::convert::Infallible> {
|
7707 + | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
6475 7708 | /// todo!()
|
6476 7709 | /// }
|
6477 7710 | ///
|
6478 7711 | /// let config = RestJsonConfig::builder().build();
|
6479 7712 | /// let svc = ::tower::util::service_fn(handler);
|
6480 7713 | /// let app = RestJson::builder(config)
|
6481 - | /// .malformed_accept_with_payload_service(svc)
|
7714 + | /// .malformed_boolean_service(svc)
|
6482 7715 | /// /* Set other handlers */
|
6483 7716 | /// .build()
|
6484 7717 | /// .unwrap();
|
6485 7718 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6486 7719 | /// ```
|
6487 7720 | ///
|
6488 - | pub fn malformed_accept_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7721 + | pub fn malformed_boolean_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6489 7722 | where
|
6490 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithPayload, ServiceExtractors>,
|
7723 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBoolean, ServiceExtractors>,
|
6491 7724 |
|
6492 7725 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6493 7726 | RestJson<L>,
|
6494 - | crate::operation_shape::MalformedAcceptWithPayload,
|
6495 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithPayload, S>
|
7727 + | crate::operation_shape::MalformedBoolean,
|
7728 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBoolean, S>
|
6496 7729 | >,
|
6497 7730 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6498 7731 | RestJson<L>,
|
6499 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7732 + | crate::operation_shape::MalformedBoolean,
|
6500 7733 | ModelPl::Output
|
6501 7734 | >,
|
6502 7735 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6503 7736 | RestJson<L>,
|
6504 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7737 + | crate::operation_shape::MalformedBoolean,
|
6505 7738 | <
|
6506 7739 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6507 7740 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6508 7741 | RestJson<L>,
|
6509 - | crate::operation_shape::MalformedAcceptWithPayload,
|
7742 + | crate::operation_shape::MalformedBoolean,
|
6510 7743 | ModelPl::Output
|
6511 7744 | >
|
6512 7745 | >::Output
|
6513 7746 | >,
|
6514 7747 |
|
6515 7748 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6516 7749 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6517 7750 |
|
6518 7751 | {
|
6519 7752 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6520 7753 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6521 - | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_service(service);
|
7754 + | let svc = crate::operation_shape::MalformedBoolean::from_service(service);
|
6522 7755 | let svc = self.model_plugin.apply(svc);
|
6523 7756 | let svc =
|
6524 7757 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6525 7758 | .apply(svc);
|
6526 7759 | let svc = self.http_plugin.apply(svc);
|
6527 - | self.malformed_accept_with_payload_custom(svc)
|
7760 + | self.malformed_boolean_custom(svc)
|
6528 7761 | }
|
6529 7762 |
|
6530 - | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) to a custom [`Service`](tower::Service).
|
7763 + | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) to a custom [`Service`](tower::Service).
|
6531 7764 | /// not constrained by the Smithy contract.
|
6532 - | fn malformed_accept_with_payload_custom<S>(mut self, svc: S) -> Self
|
7765 + | fn malformed_boolean_custom<S>(mut self, svc: S) -> Self
|
6533 7766 | where
|
6534 7767 | S: ::tower::Service<
|
6535 7768 | ::http::Request<Body>,
|
6536 7769 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6537 7770 | Error = ::std::convert::Infallible,
|
6538 7771 | > + Clone
|
6539 7772 | + Send
|
6540 7773 | + 'static,
|
6541 7774 | S::Future: Send + 'static,
|
6542 7775 | {
|
6543 - | self.malformed_accept_with_payload =
|
6544 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7776 + | self.malformed_boolean = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6545 7777 | self
|
6546 7778 | }
|
6547 7779 |
|
6548 - | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
7780 + | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
6549 7781 | ///
|
6550 7782 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6551 7783 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6552 7784 | ///
|
6553 7785 | /// # Example
|
6554 7786 | ///
|
6555 7787 | /// ```no_run
|
6556 7788 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6557 7789 | ///
|
6558 7790 | /// use rest_json_http0x::{input, output, error};
|
6559 7791 | ///
|
6560 - | /// async fn handler(input: input::MalformedBlobInput) -> output::MalformedBlobOutput {
|
7792 + | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
6561 7793 | /// todo!()
|
6562 7794 | /// }
|
6563 7795 | ///
|
6564 7796 | /// let config = RestJsonConfig::builder().build();
|
6565 7797 | /// let app = RestJson::builder(config)
|
6566 - | /// .malformed_blob(handler)
|
7798 + | /// .malformed_byte(handler)
|
6567 7799 | /// /* Set other handlers */
|
6568 7800 | /// .build()
|
6569 7801 | /// .unwrap();
|
6570 7802 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6571 7803 | /// ```
|
6572 7804 | ///
|
6573 - | pub fn malformed_blob<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7805 + | pub fn malformed_byte<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6574 7806 | where
|
6575 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBlob, HandlerExtractors>,
|
7807 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedByte, HandlerExtractors>,
|
6576 7808 |
|
6577 7809 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6578 7810 | RestJson<L>,
|
6579 - | crate::operation_shape::MalformedBlob,
|
6580 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBlob, HandlerType>
|
7811 + | crate::operation_shape::MalformedByte,
|
7812 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedByte, HandlerType>
|
6581 7813 | >,
|
6582 7814 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6583 7815 | RestJson<L>,
|
6584 - | crate::operation_shape::MalformedBlob,
|
7816 + | crate::operation_shape::MalformedByte,
|
6585 7817 | ModelPl::Output
|
6586 7818 | >,
|
6587 7819 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6588 7820 | RestJson<L>,
|
6589 - | crate::operation_shape::MalformedBlob,
|
7821 + | crate::operation_shape::MalformedByte,
|
6590 7822 | <
|
6591 7823 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6592 7824 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6593 7825 | RestJson<L>,
|
6594 - | crate::operation_shape::MalformedBlob,
|
7826 + | crate::operation_shape::MalformedByte,
|
6595 7827 | ModelPl::Output
|
6596 7828 | >
|
6597 7829 | >::Output
|
6598 7830 | >,
|
6599 7831 |
|
6600 7832 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6601 7833 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6602 7834 |
|
6603 7835 | {
|
6604 7836 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6605 7837 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6606 - | let svc = crate::operation_shape::MalformedBlob::from_handler(handler);
|
7838 + | let svc = crate::operation_shape::MalformedByte::from_handler(handler);
|
6607 7839 | let svc = self.model_plugin.apply(svc);
|
6608 7840 | let svc =
|
6609 7841 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6610 7842 | .apply(svc);
|
6611 7843 | let svc = self.http_plugin.apply(svc);
|
6612 - | self.malformed_blob_custom(svc)
|
7844 + | self.malformed_byte_custom(svc)
|
6613 7845 | }
|
6614 7846 |
|
6615 - | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
7847 + | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
6616 7848 | ///
|
6617 7849 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6618 7850 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6619 7851 | ///
|
6620 7852 | /// # Example
|
6621 7853 | ///
|
6622 7854 | /// ```no_run
|
6623 7855 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6624 7856 | ///
|
6625 7857 | /// use rest_json_http0x::{input, output, error};
|
6626 7858 | ///
|
6627 - | /// async fn handler(input: input::MalformedBlobInput) -> Result<output::MalformedBlobOutput, std::convert::Infallible> {
|
7859 + | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
6628 7860 | /// todo!()
|
6629 7861 | /// }
|
6630 7862 | ///
|
6631 7863 | /// let config = RestJsonConfig::builder().build();
|
6632 7864 | /// let svc = ::tower::util::service_fn(handler);
|
6633 7865 | /// let app = RestJson::builder(config)
|
6634 - | /// .malformed_blob_service(svc)
|
7866 + | /// .malformed_byte_service(svc)
|
6635 7867 | /// /* Set other handlers */
|
6636 7868 | /// .build()
|
6637 7869 | /// .unwrap();
|
6638 7870 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6639 7871 | /// ```
|
6640 7872 | ///
|
6641 - | pub fn malformed_blob_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7873 + | pub fn malformed_byte_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6642 7874 | where
|
6643 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBlob, ServiceExtractors>,
|
7875 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedByte, ServiceExtractors>,
|
6644 7876 |
|
6645 7877 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6646 7878 | RestJson<L>,
|
6647 - | crate::operation_shape::MalformedBlob,
|
6648 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBlob, S>
|
7879 + | crate::operation_shape::MalformedByte,
|
7880 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedByte, S>
|
6649 7881 | >,
|
6650 7882 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6651 7883 | RestJson<L>,
|
6652 - | crate::operation_shape::MalformedBlob,
|
7884 + | crate::operation_shape::MalformedByte,
|
6653 7885 | ModelPl::Output
|
6654 7886 | >,
|
6655 7887 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6656 7888 | RestJson<L>,
|
6657 - | crate::operation_shape::MalformedBlob,
|
7889 + | crate::operation_shape::MalformedByte,
|
6658 7890 | <
|
6659 7891 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6660 7892 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6661 7893 | RestJson<L>,
|
6662 - | crate::operation_shape::MalformedBlob,
|
7894 + | crate::operation_shape::MalformedByte,
|
6663 7895 | ModelPl::Output
|
6664 7896 | >
|
6665 7897 | >::Output
|
6666 7898 | >,
|
6667 7899 |
|
6668 7900 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6669 7901 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6670 7902 |
|
6671 7903 | {
|
6672 7904 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6673 7905 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6674 - | let svc = crate::operation_shape::MalformedBlob::from_service(service);
|
7906 + | let svc = crate::operation_shape::MalformedByte::from_service(service);
|
6675 7907 | let svc = self.model_plugin.apply(svc);
|
6676 7908 | let svc =
|
6677 7909 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6678 7910 | .apply(svc);
|
6679 7911 | let svc = self.http_plugin.apply(svc);
|
6680 - | self.malformed_blob_custom(svc)
|
7912 + | self.malformed_byte_custom(svc)
|
6681 7913 | }
|
6682 7914 |
|
6683 - | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) to a custom [`Service`](tower::Service).
|
7915 + | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) to a custom [`Service`](tower::Service).
|
6684 7916 | /// not constrained by the Smithy contract.
|
6685 - | fn malformed_blob_custom<S>(mut self, svc: S) -> Self
|
7917 + | fn malformed_byte_custom<S>(mut self, svc: S) -> Self
|
6686 7918 | where
|
6687 7919 | S: ::tower::Service<
|
6688 7920 | ::http::Request<Body>,
|
6689 7921 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6690 7922 | Error = ::std::convert::Infallible,
|
6691 7923 | > + Clone
|
6692 7924 | + Send
|
6693 7925 | + 'static,
|
6694 7926 | S::Future: Send + 'static,
|
6695 7927 | {
|
6696 - | self.malformed_blob = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7928 + | self.malformed_byte = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6697 7929 | self
|
6698 7930 | }
|
6699 7931 |
|
6700 - | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
7932 + | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
6701 7933 | ///
|
6702 7934 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6703 7935 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6704 7936 | ///
|
6705 7937 | /// # Example
|
6706 7938 | ///
|
6707 7939 | /// ```no_run
|
6708 7940 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6709 7941 | ///
|
6710 7942 | /// use rest_json_http0x::{input, output, error};
|
6711 7943 | ///
|
6712 - | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
7944 + | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> output::MalformedContentTypeWithBodyOutput {
|
6713 7945 | /// todo!()
|
6714 7946 | /// }
|
6715 7947 | ///
|
6716 7948 | /// let config = RestJsonConfig::builder().build();
|
6717 7949 | /// let app = RestJson::builder(config)
|
6718 - | /// .malformed_boolean(handler)
|
7950 + | /// .malformed_content_type_with_body(handler)
|
6719 7951 | /// /* Set other handlers */
|
6720 7952 | /// .build()
|
6721 7953 | /// .unwrap();
|
6722 7954 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6723 7955 | /// ```
|
6724 7956 | ///
|
6725 - | pub fn malformed_boolean<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7957 + | pub fn malformed_content_type_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6726 7958 | where
|
6727 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBoolean, HandlerExtractors>,
|
7959 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithBody, HandlerExtractors>,
|
6728 7960 |
|
6729 7961 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6730 7962 | RestJson<L>,
|
6731 - | crate::operation_shape::MalformedBoolean,
|
6732 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBoolean, HandlerType>
|
7963 + | crate::operation_shape::MalformedContentTypeWithBody,
|
7964 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithBody, HandlerType>
|
6733 7965 | >,
|
6734 7966 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6735 7967 | RestJson<L>,
|
6736 - | crate::operation_shape::MalformedBoolean,
|
7968 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6737 7969 | ModelPl::Output
|
6738 7970 | >,
|
6739 7971 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6740 7972 | RestJson<L>,
|
6741 - | crate::operation_shape::MalformedBoolean,
|
7973 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6742 7974 | <
|
6743 7975 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6744 7976 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6745 7977 | RestJson<L>,
|
6746 - | crate::operation_shape::MalformedBoolean,
|
7978 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6747 7979 | ModelPl::Output
|
6748 7980 | >
|
6749 7981 | >::Output
|
6750 7982 | >,
|
6751 7983 |
|
6752 7984 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6753 7985 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6754 7986 |
|
6755 7987 | {
|
6756 7988 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6757 7989 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6758 - | let svc = crate::operation_shape::MalformedBoolean::from_handler(handler);
|
7990 + | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_handler(handler);
|
6759 7991 | let svc = self.model_plugin.apply(svc);
|
6760 7992 | let svc =
|
6761 7993 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6762 7994 | .apply(svc);
|
6763 7995 | let svc = self.http_plugin.apply(svc);
|
6764 - | self.malformed_boolean_custom(svc)
|
7996 + | self.malformed_content_type_with_body_custom(svc)
|
6765 7997 | }
|
6766 7998 |
|
6767 - | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
7999 + | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
6768 8000 | ///
|
6769 8001 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6770 8002 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6771 8003 | ///
|
6772 8004 | /// # Example
|
6773 8005 | ///
|
6774 8006 | /// ```no_run
|
6775 8007 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6776 8008 | ///
|
6777 8009 | /// use rest_json_http0x::{input, output, error};
|
6778 8010 | ///
|
6779 - | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
8011 + | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> Result<output::MalformedContentTypeWithBodyOutput, std::convert::Infallible> {
|
6780 8012 | /// todo!()
|
6781 8013 | /// }
|
6782 8014 | ///
|
6783 8015 | /// let config = RestJsonConfig::builder().build();
|
6784 8016 | /// let svc = ::tower::util::service_fn(handler);
|
6785 8017 | /// let app = RestJson::builder(config)
|
6786 - | /// .malformed_boolean_service(svc)
|
8018 + | /// .malformed_content_type_with_body_service(svc)
|
6787 8019 | /// /* Set other handlers */
|
6788 8020 | /// .build()
|
6789 8021 | /// .unwrap();
|
6790 8022 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6791 8023 | /// ```
|
6792 8024 | ///
|
6793 - | pub fn malformed_boolean_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8025 + | pub fn malformed_content_type_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6794 8026 | where
|
6795 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBoolean, ServiceExtractors>,
|
8027 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithBody, ServiceExtractors>,
|
6796 8028 |
|
6797 8029 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6798 8030 | RestJson<L>,
|
6799 - | crate::operation_shape::MalformedBoolean,
|
6800 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBoolean, S>
|
8031 + | crate::operation_shape::MalformedContentTypeWithBody,
|
8032 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithBody, S>
|
6801 8033 | >,
|
6802 8034 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6803 8035 | RestJson<L>,
|
6804 - | crate::operation_shape::MalformedBoolean,
|
8036 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6805 8037 | ModelPl::Output
|
6806 8038 | >,
|
6807 8039 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6808 8040 | RestJson<L>,
|
6809 - | crate::operation_shape::MalformedBoolean,
|
8041 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6810 8042 | <
|
6811 8043 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6812 8044 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6813 8045 | RestJson<L>,
|
6814 - | crate::operation_shape::MalformedBoolean,
|
8046 + | crate::operation_shape::MalformedContentTypeWithBody,
|
6815 8047 | ModelPl::Output
|
6816 8048 | >
|
6817 8049 | >::Output
|
6818 8050 | >,
|
6819 8051 |
|
6820 8052 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6821 8053 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6822 8054 |
|
6823 8055 | {
|
6824 8056 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6825 8057 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6826 - | let svc = crate::operation_shape::MalformedBoolean::from_service(service);
|
8058 + | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_service(service);
|
6827 8059 | let svc = self.model_plugin.apply(svc);
|
6828 8060 | let svc =
|
6829 8061 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6830 8062 | .apply(svc);
|
6831 8063 | let svc = self.http_plugin.apply(svc);
|
6832 - | self.malformed_boolean_custom(svc)
|
8064 + | self.malformed_content_type_with_body_custom(svc)
|
6833 8065 | }
|
6834 8066 |
|
6835 - | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) to a custom [`Service`](tower::Service).
|
8067 + | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) to a custom [`Service`](tower::Service).
|
6836 8068 | /// not constrained by the Smithy contract.
|
6837 - | fn malformed_boolean_custom<S>(mut self, svc: S) -> Self
|
8069 + | fn malformed_content_type_with_body_custom<S>(mut self, svc: S) -> Self
|
6838 8070 | where
|
6839 8071 | S: ::tower::Service<
|
6840 8072 | ::http::Request<Body>,
|
6841 8073 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6842 8074 | Error = ::std::convert::Infallible,
|
6843 8075 | > + Clone
|
6844 8076 | + Send
|
6845 8077 | + 'static,
|
6846 8078 | S::Future: Send + 'static,
|
6847 8079 | {
|
6848 - | self.malformed_boolean = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8080 + | self.malformed_content_type_with_body =
|
8081 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6849 8082 | self
|
6850 8083 | }
|
6851 8084 |
|
6852 - | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
8085 + | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
6853 8086 | ///
|
6854 8087 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6855 8088 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6856 8089 | ///
|
6857 8090 | /// # Example
|
6858 8091 | ///
|
6859 8092 | /// ```no_run
|
6860 8093 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6861 8094 | ///
|
6862 8095 | /// use rest_json_http0x::{input, output, error};
|
6863 8096 | ///
|
6864 - | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
8097 + | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> output::MalformedContentTypeWithGenericStringOutput {
|
6865 8098 | /// todo!()
|
6866 8099 | /// }
|
6867 8100 | ///
|
6868 8101 | /// let config = RestJsonConfig::builder().build();
|
6869 8102 | /// let app = RestJson::builder(config)
|
6870 - | /// .malformed_byte(handler)
|
8103 + | /// .malformed_content_type_with_generic_string(handler)
|
6871 8104 | /// /* Set other handlers */
|
6872 8105 | /// .build()
|
6873 8106 | /// .unwrap();
|
6874 8107 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6875 8108 | /// ```
|
6876 8109 | ///
|
6877 - | pub fn malformed_byte<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8110 + | pub fn malformed_content_type_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6878 8111 | where
|
6879 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedByte, HandlerExtractors>,
|
8112 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerExtractors>,
|
6880 8113 |
|
6881 8114 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6882 8115 | RestJson<L>,
|
6883 - | crate::operation_shape::MalformedByte,
|
6884 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedByte, HandlerType>
|
8116 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8117 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerType>
|
6885 8118 | >,
|
6886 8119 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6887 8120 | RestJson<L>,
|
6888 - | crate::operation_shape::MalformedByte,
|
8121 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6889 8122 | ModelPl::Output
|
6890 8123 | >,
|
6891 8124 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6892 8125 | RestJson<L>,
|
6893 - | crate::operation_shape::MalformedByte,
|
8126 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6894 8127 | <
|
6895 8128 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6896 8129 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6897 8130 | RestJson<L>,
|
6898 - | crate::operation_shape::MalformedByte,
|
8131 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6899 8132 | ModelPl::Output
|
6900 8133 | >
|
6901 8134 | >::Output
|
6902 8135 | >,
|
6903 8136 |
|
6904 8137 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6905 8138 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6906 8139 |
|
6907 8140 | {
|
6908 8141 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6909 8142 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6910 - | let svc = crate::operation_shape::MalformedByte::from_handler(handler);
|
8143 + | let svc =
|
8144 + | crate::operation_shape::MalformedContentTypeWithGenericString::from_handler(handler);
|
6911 8145 | let svc = self.model_plugin.apply(svc);
|
6912 8146 | let svc =
|
6913 8147 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6914 8148 | .apply(svc);
|
6915 8149 | let svc = self.http_plugin.apply(svc);
|
6916 - | self.malformed_byte_custom(svc)
|
8150 + | self.malformed_content_type_with_generic_string_custom(svc)
|
6917 8151 | }
|
6918 8152 |
|
6919 - | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
8153 + | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
6920 8154 | ///
|
6921 8155 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6922 8156 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6923 8157 | ///
|
6924 8158 | /// # Example
|
6925 8159 | ///
|
6926 8160 | /// ```no_run
|
6927 8161 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
6928 8162 | ///
|
6929 8163 | /// use rest_json_http0x::{input, output, error};
|
6930 8164 | ///
|
6931 - | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
8165 + | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> Result<output::MalformedContentTypeWithGenericStringOutput, std::convert::Infallible> {
|
6932 8166 | /// todo!()
|
6933 8167 | /// }
|
6934 8168 | ///
|
6935 8169 | /// let config = RestJsonConfig::builder().build();
|
6936 8170 | /// let svc = ::tower::util::service_fn(handler);
|
6937 8171 | /// let app = RestJson::builder(config)
|
6938 - | /// .malformed_byte_service(svc)
|
8172 + | /// .malformed_content_type_with_generic_string_service(svc)
|
6939 8173 | /// /* Set other handlers */
|
6940 8174 | /// .build()
|
6941 8175 | /// .unwrap();
|
6942 8176 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6943 8177 | /// ```
|
6944 8178 | ///
|
6945 - | pub fn malformed_byte_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8179 + | pub fn malformed_content_type_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6946 8180 | where
|
6947 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedByte, ServiceExtractors>,
|
8181 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithGenericString, ServiceExtractors>,
|
6948 8182 |
|
6949 8183 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6950 8184 | RestJson<L>,
|
6951 - | crate::operation_shape::MalformedByte,
|
6952 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedByte, S>
|
8185 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8186 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithGenericString, S>
|
6953 8187 | >,
|
6954 8188 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6955 8189 | RestJson<L>,
|
6956 - | crate::operation_shape::MalformedByte,
|
8190 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6957 8191 | ModelPl::Output
|
6958 8192 | >,
|
6959 8193 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6960 8194 | RestJson<L>,
|
6961 - | crate::operation_shape::MalformedByte,
|
8195 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6962 8196 | <
|
6963 8197 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6964 8198 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6965 8199 | RestJson<L>,
|
6966 - | crate::operation_shape::MalformedByte,
|
8200 + | crate::operation_shape::MalformedContentTypeWithGenericString,
|
6967 8201 | ModelPl::Output
|
6968 8202 | >
|
6969 8203 | >::Output
|
6970 8204 | >,
|
6971 8205 |
|
6972 8206 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6973 8207 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6974 8208 |
|
6975 8209 | {
|
6976 8210 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6977 8211 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6978 - | let svc = crate::operation_shape::MalformedByte::from_service(service);
|
8212 + | let svc =
|
8213 + | crate::operation_shape::MalformedContentTypeWithGenericString::from_service(service);
|
6979 8214 | let svc = self.model_plugin.apply(svc);
|
6980 8215 | let svc =
|
6981 8216 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6982 8217 | .apply(svc);
|
6983 8218 | let svc = self.http_plugin.apply(svc);
|
6984 - | self.malformed_byte_custom(svc)
|
8219 + | self.malformed_content_type_with_generic_string_custom(svc)
|
6985 8220 | }
|
6986 8221 |
|
6987 - | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) to a custom [`Service`](tower::Service).
|
8222 + | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) to a custom [`Service`](tower::Service).
|
6988 8223 | /// not constrained by the Smithy contract.
|
6989 - | fn malformed_byte_custom<S>(mut self, svc: S) -> Self
|
8224 + | fn malformed_content_type_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
6990 8225 | where
|
6991 8226 | S: ::tower::Service<
|
6992 8227 | ::http::Request<Body>,
|
6993 8228 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6994 8229 | Error = ::std::convert::Infallible,
|
6995 8230 | > + Clone
|
6996 8231 | + Send
|
6997 8232 | + 'static,
|
6998 8233 | S::Future: Send + 'static,
|
6999 8234 | {
|
7000 - | self.malformed_byte = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8235 + | self.malformed_content_type_with_generic_string =
|
8236 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7001 8237 | self
|
7002 8238 | }
|
7003 8239 |
|
7004 - | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
8240 + | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
7005 8241 | ///
|
7006 8242 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7007 8243 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7008 8244 | ///
|
7009 8245 | /// # Example
|
7010 8246 | ///
|
7011 8247 | /// ```no_run
|
7012 8248 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7013 8249 | ///
|
7014 8250 | /// use rest_json_http0x::{input, output, error};
|
7015 8251 | ///
|
7016 - | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> output::MalformedContentTypeWithBodyOutput {
|
8252 + | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> output::MalformedContentTypeWithoutBodyOutput {
|
7017 8253 | /// todo!()
|
7018 8254 | /// }
|
7019 8255 | ///
|
7020 8256 | /// let config = RestJsonConfig::builder().build();
|
7021 8257 | /// let app = RestJson::builder(config)
|
7022 - | /// .malformed_content_type_with_body(handler)
|
8258 + | /// .malformed_content_type_without_body(handler)
|
7023 8259 | /// /* Set other handlers */
|
7024 8260 | /// .build()
|
7025 8261 | /// .unwrap();
|
7026 8262 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7027 8263 | /// ```
|
7028 8264 | ///
|
7029 - | pub fn malformed_content_type_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8265 + | pub fn malformed_content_type_without_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7030 8266 | where
|
7031 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithBody, HandlerExtractors>,
|
8267 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerExtractors>,
|
7032 8268 |
|
7033 8269 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7034 8270 | RestJson<L>,
|
7035 - | crate::operation_shape::MalformedContentTypeWithBody,
|
7036 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithBody, HandlerType>
|
8271 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8272 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerType>
|
7037 8273 | >,
|
7038 8274 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7039 8275 | RestJson<L>,
|
7040 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8276 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7041 8277 | ModelPl::Output
|
7042 8278 | >,
|
7043 8279 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7044 8280 | RestJson<L>,
|
7045 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8281 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7046 8282 | <
|
7047 8283 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7048 8284 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7049 8285 | RestJson<L>,
|
7050 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8286 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7051 8287 | ModelPl::Output
|
7052 8288 | >
|
7053 8289 | >::Output
|
7054 8290 | >,
|
7055 8291 |
|
7056 8292 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7057 8293 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7058 8294 |
|
7059 8295 | {
|
7060 8296 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7061 8297 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7062 - | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_handler(handler);
|
8298 + | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_handler(handler);
|
7063 8299 | let svc = self.model_plugin.apply(svc);
|
7064 8300 | let svc =
|
7065 8301 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7066 8302 | .apply(svc);
|
7067 8303 | let svc = self.http_plugin.apply(svc);
|
7068 - | self.malformed_content_type_with_body_custom(svc)
|
8304 + | self.malformed_content_type_without_body_custom(svc)
|
7069 8305 | }
|
7070 8306 |
|
7071 - | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
8307 + | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
7072 8308 | ///
|
7073 8309 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7074 8310 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7075 8311 | ///
|
7076 8312 | /// # Example
|
7077 8313 | ///
|
7078 8314 | /// ```no_run
|
7079 8315 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7080 8316 | ///
|
7081 8317 | /// use rest_json_http0x::{input, output, error};
|
7082 8318 | ///
|
7083 - | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> Result<output::MalformedContentTypeWithBodyOutput, std::convert::Infallible> {
|
8319 + | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> Result<output::MalformedContentTypeWithoutBodyOutput, std::convert::Infallible> {
|
7084 8320 | /// todo!()
|
7085 8321 | /// }
|
7086 8322 | ///
|
7087 8323 | /// let config = RestJsonConfig::builder().build();
|
7088 8324 | /// let svc = ::tower::util::service_fn(handler);
|
7089 8325 | /// let app = RestJson::builder(config)
|
7090 - | /// .malformed_content_type_with_body_service(svc)
|
8326 + | /// .malformed_content_type_without_body_service(svc)
|
7091 8327 | /// /* Set other handlers */
|
7092 8328 | /// .build()
|
7093 8329 | /// .unwrap();
|
7094 8330 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7095 8331 | /// ```
|
7096 8332 | ///
|
7097 - | pub fn malformed_content_type_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8333 + | pub fn malformed_content_type_without_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7098 8334 | where
|
7099 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithBody, ServiceExtractors>,
|
8335 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBody, ServiceExtractors>,
|
7100 8336 |
|
7101 8337 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7102 8338 | RestJson<L>,
|
7103 - | crate::operation_shape::MalformedContentTypeWithBody,
|
7104 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithBody, S>
|
8339 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8340 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBody, S>
|
7105 8341 | >,
|
7106 8342 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7107 8343 | RestJson<L>,
|
7108 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8344 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7109 8345 | ModelPl::Output
|
7110 8346 | >,
|
7111 8347 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7112 8348 | RestJson<L>,
|
7113 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8349 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7114 8350 | <
|
7115 8351 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7116 8352 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7117 8353 | RestJson<L>,
|
7118 - | crate::operation_shape::MalformedContentTypeWithBody,
|
8354 + | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7119 8355 | ModelPl::Output
|
7120 8356 | >
|
7121 8357 | >::Output
|
7122 8358 | >,
|
7123 8359 |
|
7124 8360 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7125 8361 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7126 8362 |
|
7127 8363 | {
|
7128 8364 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7129 8365 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7130 - | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_service(service);
|
8366 + | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_service(service);
|
7131 8367 | let svc = self.model_plugin.apply(svc);
|
7132 8368 | let svc =
|
7133 8369 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7134 8370 | .apply(svc);
|
7135 8371 | let svc = self.http_plugin.apply(svc);
|
7136 - | self.malformed_content_type_with_body_custom(svc)
|
8372 + | self.malformed_content_type_without_body_custom(svc)
|
7137 8373 | }
|
7138 8374 |
|
7139 - | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) to a custom [`Service`](tower::Service).
|
8375 + | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) to a custom [`Service`](tower::Service).
|
7140 8376 | /// not constrained by the Smithy contract.
|
7141 - | fn malformed_content_type_with_body_custom<S>(mut self, svc: S) -> Self
|
8377 + | fn malformed_content_type_without_body_custom<S>(mut self, svc: S) -> Self
|
7142 8378 | where
|
7143 8379 | S: ::tower::Service<
|
7144 8380 | ::http::Request<Body>,
|
7145 8381 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7146 8382 | Error = ::std::convert::Infallible,
|
7147 8383 | > + Clone
|
7148 8384 | + Send
|
7149 8385 | + 'static,
|
7150 8386 | S::Future: Send + 'static,
|
7151 8387 | {
|
7152 - | self.malformed_content_type_with_body =
|
8388 + | self.malformed_content_type_without_body =
|
7153 8389 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7154 8390 | self
|
7155 8391 | }
|
7156 8392 |
|
7157 - | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
8393 + | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
7158 8394 | ///
|
7159 8395 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7160 8396 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7161 8397 | ///
|
7162 8398 | /// # Example
|
7163 8399 | ///
|
7164 8400 | /// ```no_run
|
7165 8401 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7166 8402 | ///
|
7167 8403 | /// use rest_json_http0x::{input, output, error};
|
7168 8404 | ///
|
7169 - | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> output::MalformedContentTypeWithGenericStringOutput {
|
8405 + | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> output::MalformedContentTypeWithoutBodyEmptyInputOutput {
|
7170 8406 | /// todo!()
|
7171 8407 | /// }
|
7172 8408 | ///
|
7173 8409 | /// let config = RestJsonConfig::builder().build();
|
7174 8410 | /// let app = RestJson::builder(config)
|
7175 - | /// .malformed_content_type_with_generic_string(handler)
|
8411 + | /// .malformed_content_type_without_body_empty_input(handler)
|
7176 8412 | /// /* Set other handlers */
|
7177 8413 | /// .build()
|
7178 8414 | /// .unwrap();
|
7179 8415 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7180 8416 | /// ```
|
7181 8417 | ///
|
7182 - | pub fn malformed_content_type_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8418 + | pub fn malformed_content_type_without_body_empty_input<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7183 8419 | where
|
7184 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerExtractors>,
|
8420 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerExtractors>,
|
7185 8421 |
|
7186 8422 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7187 8423 | RestJson<L>,
|
7188 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7189 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerType>
|
8424 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8425 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerType>
|
7190 8426 | >,
|
7191 8427 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7192 8428 | RestJson<L>,
|
7193 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8429 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7194 8430 | ModelPl::Output
|
7195 8431 | >,
|
7196 8432 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7197 8433 | RestJson<L>,
|
7198 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8434 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7199 8435 | <
|
7200 8436 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7201 8437 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7202 8438 | RestJson<L>,
|
7203 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8439 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7204 8440 | ModelPl::Output
|
7205 8441 | >
|
7206 8442 | >::Output
|
7207 8443 | >,
|
7208 8444 |
|
7209 8445 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7210 8446 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7211 8447 |
|
7212 8448 | {
|
7213 8449 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7214 8450 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7215 - | let svc =
|
7216 - | crate::operation_shape::MalformedContentTypeWithGenericString::from_handler(handler);
|
8451 + | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_handler(
|
8452 + | handler,
|
8453 + | );
|
7217 8454 | let svc = self.model_plugin.apply(svc);
|
7218 8455 | let svc =
|
7219 8456 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7220 8457 | .apply(svc);
|
7221 8458 | let svc = self.http_plugin.apply(svc);
|
7222 - | self.malformed_content_type_with_generic_string_custom(svc)
|
8459 + | self.malformed_content_type_without_body_empty_input_custom(svc)
|
7223 8460 | }
|
7224 8461 |
|
7225 - | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
8462 + | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
7226 8463 | ///
|
7227 8464 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7228 8465 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7229 8466 | ///
|
7230 8467 | /// # Example
|
7231 8468 | ///
|
7232 8469 | /// ```no_run
|
7233 8470 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7234 8471 | ///
|
7235 8472 | /// use rest_json_http0x::{input, output, error};
|
7236 8473 | ///
|
7237 - | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> Result<output::MalformedContentTypeWithGenericStringOutput, std::convert::Infallible> {
|
8474 + | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> Result<output::MalformedContentTypeWithoutBodyEmptyInputOutput, std::convert::Infallible> {
|
7238 8475 | /// todo!()
|
7239 8476 | /// }
|
7240 8477 | ///
|
7241 8478 | /// let config = RestJsonConfig::builder().build();
|
7242 8479 | /// let svc = ::tower::util::service_fn(handler);
|
7243 8480 | /// let app = RestJson::builder(config)
|
7244 - | /// .malformed_content_type_with_generic_string_service(svc)
|
8481 + | /// .malformed_content_type_without_body_empty_input_service(svc)
|
7245 8482 | /// /* Set other handlers */
|
7246 8483 | /// .build()
|
7247 8484 | /// .unwrap();
|
7248 8485 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7249 8486 | /// ```
|
7250 8487 | ///
|
7251 - | pub fn malformed_content_type_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8488 + | pub fn malformed_content_type_without_body_empty_input_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7252 8489 | where
|
7253 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithGenericString, ServiceExtractors>,
|
8490 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, ServiceExtractors>,
|
7254 8491 |
|
7255 8492 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7256 8493 | RestJson<L>,
|
7257 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7258 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithGenericString, S>
|
8494 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8495 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, S>
|
7259 8496 | >,
|
7260 8497 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7261 8498 | RestJson<L>,
|
7262 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8499 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7263 8500 | ModelPl::Output
|
7264 8501 | >,
|
7265 8502 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7266 8503 | RestJson<L>,
|
7267 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8504 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7268 8505 | <
|
7269 8506 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7270 8507 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7271 8508 | RestJson<L>,
|
7272 - | crate::operation_shape::MalformedContentTypeWithGenericString,
|
8509 + | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7273 8510 | ModelPl::Output
|
7274 8511 | >
|
7275 8512 | >::Output
|
7276 8513 | >,
|
7277 8514 |
|
7278 8515 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7279 8516 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7280 8517 |
|
7281 8518 | {
|
7282 8519 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7283 8520 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7284 - | let svc =
|
7285 - | crate::operation_shape::MalformedContentTypeWithGenericString::from_service(service);
|
8521 + | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_service(
|
8522 + | service,
|
8523 + | );
|
7286 8524 | let svc = self.model_plugin.apply(svc);
|
7287 8525 | let svc =
|
7288 8526 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7289 8527 | .apply(svc);
|
7290 8528 | let svc = self.http_plugin.apply(svc);
|
7291 - | self.malformed_content_type_with_generic_string_custom(svc)
|
8529 + | self.malformed_content_type_without_body_empty_input_custom(svc)
|
7292 8530 | }
|
7293 8531 |
|
7294 - | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) to a custom [`Service`](tower::Service).
|
8532 + | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) to a custom [`Service`](tower::Service).
|
7295 8533 | /// not constrained by the Smithy contract.
|
7296 - | fn malformed_content_type_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
8534 + | fn malformed_content_type_without_body_empty_input_custom<S>(mut self, svc: S) -> Self
|
7297 8535 | where
|
7298 8536 | S: ::tower::Service<
|
7299 8537 | ::http::Request<Body>,
|
7300 8538 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7301 8539 | Error = ::std::convert::Infallible,
|
7302 8540 | > + Clone
|
7303 8541 | + Send
|
7304 8542 | + 'static,
|
7305 8543 | S::Future: Send + 'static,
|
7306 8544 | {
|
7307 - | self.malformed_content_type_with_generic_string =
|
8545 + | self.malformed_content_type_without_body_empty_input =
|
7308 8546 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7309 8547 | self
|
7310 8548 | }
|
7311 8549 |
|
7312 - | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
8550 + | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
7313 8551 | ///
|
7314 8552 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7315 8553 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7316 8554 | ///
|
7317 8555 | /// # Example
|
7318 8556 | ///
|
7319 8557 | /// ```no_run
|
7320 8558 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7321 8559 | ///
|
7322 8560 | /// use rest_json_http0x::{input, output, error};
|
7323 8561 | ///
|
7324 - | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> output::MalformedContentTypeWithoutBodyOutput {
|
8562 + | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> output::MalformedContentTypeWithPayloadOutput {
|
7325 8563 | /// todo!()
|
7326 8564 | /// }
|
7327 8565 | ///
|
7328 8566 | /// let config = RestJsonConfig::builder().build();
|
7329 8567 | /// let app = RestJson::builder(config)
|
7330 - | /// .malformed_content_type_without_body(handler)
|
8568 + | /// .malformed_content_type_with_payload(handler)
|
7331 8569 | /// /* Set other handlers */
|
7332 8570 | /// .build()
|
7333 8571 | /// .unwrap();
|
7334 8572 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7335 8573 | /// ```
|
7336 8574 | ///
|
7337 - | pub fn malformed_content_type_without_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8575 + | pub fn malformed_content_type_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7338 8576 | where
|
7339 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerExtractors>,
|
8577 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithPayload, HandlerExtractors>,
|
7340 8578 |
|
7341 8579 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7342 8580 | RestJson<L>,
|
7343 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7344 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerType>
|
8581 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
8582 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithPayload, HandlerType>
|
7345 8583 | >,
|
7346 8584 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7347 8585 | RestJson<L>,
|
7348 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8586 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7349 8587 | ModelPl::Output
|
7350 8588 | >,
|
7351 8589 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7352 8590 | RestJson<L>,
|
7353 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8591 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7354 8592 | <
|
7355 8593 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7356 8594 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7357 8595 | RestJson<L>,
|
7358 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8596 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7359 8597 | ModelPl::Output
|
7360 8598 | >
|
7361 8599 | >::Output
|
7362 8600 | >,
|
7363 8601 |
|
7364 8602 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7365 8603 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7366 8604 |
|
7367 8605 | {
|
7368 8606 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7369 8607 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7370 - | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_handler(handler);
|
8608 + | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_handler(handler);
|
7371 8609 | let svc = self.model_plugin.apply(svc);
|
7372 8610 | let svc =
|
7373 8611 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7374 8612 | .apply(svc);
|
7375 8613 | let svc = self.http_plugin.apply(svc);
|
7376 - | self.malformed_content_type_without_body_custom(svc)
|
8614 + | self.malformed_content_type_with_payload_custom(svc)
|
7377 8615 | }
|
7378 8616 |
|
7379 - | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
8617 + | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
7380 8618 | ///
|
7381 8619 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7382 8620 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7383 8621 | ///
|
7384 8622 | /// # Example
|
7385 8623 | ///
|
7386 8624 | /// ```no_run
|
7387 8625 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7388 8626 | ///
|
7389 8627 | /// use rest_json_http0x::{input, output, error};
|
7390 8628 | ///
|
7391 - | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> Result<output::MalformedContentTypeWithoutBodyOutput, std::convert::Infallible> {
|
8629 + | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> Result<output::MalformedContentTypeWithPayloadOutput, std::convert::Infallible> {
|
7392 8630 | /// todo!()
|
7393 8631 | /// }
|
7394 8632 | ///
|
7395 8633 | /// let config = RestJsonConfig::builder().build();
|
7396 8634 | /// let svc = ::tower::util::service_fn(handler);
|
7397 8635 | /// let app = RestJson::builder(config)
|
7398 - | /// .malformed_content_type_without_body_service(svc)
|
8636 + | /// .malformed_content_type_with_payload_service(svc)
|
7399 8637 | /// /* Set other handlers */
|
7400 8638 | /// .build()
|
7401 8639 | /// .unwrap();
|
7402 8640 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7403 8641 | /// ```
|
7404 8642 | ///
|
7405 - | pub fn malformed_content_type_without_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8643 + | pub fn malformed_content_type_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7406 8644 | where
|
7407 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBody, ServiceExtractors>,
|
8645 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithPayload, ServiceExtractors>,
|
7408 8646 |
|
7409 8647 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7410 8648 | RestJson<L>,
|
7411 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7412 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBody, S>
|
8649 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
8650 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithPayload, S>
|
7413 8651 | >,
|
7414 8652 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7415 8653 | RestJson<L>,
|
7416 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8654 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7417 8655 | ModelPl::Output
|
7418 8656 | >,
|
7419 8657 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7420 8658 | RestJson<L>,
|
7421 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8659 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7422 8660 | <
|
7423 8661 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7424 8662 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7425 8663 | RestJson<L>,
|
7426 - | crate::operation_shape::MalformedContentTypeWithoutBody,
|
8664 + | crate::operation_shape::MalformedContentTypeWithPayload,
|
7427 8665 | ModelPl::Output
|
7428 8666 | >
|
7429 8667 | >::Output
|
7430 8668 | >,
|
7431 8669 |
|
7432 8670 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7433 8671 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7434 8672 |
|
7435 8673 | {
|
7436 8674 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7437 8675 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7438 - | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_service(service);
|
8676 + | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_service(service);
|
7439 8677 | let svc = self.model_plugin.apply(svc);
|
7440 8678 | let svc =
|
7441 8679 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7442 8680 | .apply(svc);
|
7443 8681 | let svc = self.http_plugin.apply(svc);
|
7444 - | self.malformed_content_type_without_body_custom(svc)
|
8682 + | self.malformed_content_type_with_payload_custom(svc)
|
7445 8683 | }
|
7446 8684 |
|
7447 - | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) to a custom [`Service`](tower::Service).
|
8685 + | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) to a custom [`Service`](tower::Service).
|
7448 8686 | /// not constrained by the Smithy contract.
|
7449 - | fn malformed_content_type_without_body_custom<S>(mut self, svc: S) -> Self
|
8687 + | fn malformed_content_type_with_payload_custom<S>(mut self, svc: S) -> Self
|
7450 8688 | where
|
7451 8689 | S: ::tower::Service<
|
7452 8690 | ::http::Request<Body>,
|
7453 8691 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7454 8692 | Error = ::std::convert::Infallible,
|
7455 8693 | > + Clone
|
7456 8694 | + Send
|
7457 8695 | + 'static,
|
7458 8696 | S::Future: Send + 'static,
|
7459 8697 | {
|
7460 - | self.malformed_content_type_without_body =
|
8698 + | self.malformed_content_type_with_payload =
|
7461 8699 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7462 8700 | self
|
7463 8701 | }
|
7464 8702 |
|
7465 - | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
8703 + | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
7466 8704 | ///
|
7467 8705 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7468 8706 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7469 8707 | ///
|
7470 8708 | /// # Example
|
7471 8709 | ///
|
7472 8710 | /// ```no_run
|
7473 8711 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7474 8712 | ///
|
7475 8713 | /// use rest_json_http0x::{input, output, error};
|
7476 8714 | ///
|
7477 - | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> output::MalformedContentTypeWithoutBodyEmptyInputOutput {
|
8715 + | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
7478 8716 | /// todo!()
|
7479 8717 | /// }
|
7480 8718 | ///
|
7481 8719 | /// let config = RestJsonConfig::builder().build();
|
7482 8720 | /// let app = RestJson::builder(config)
|
7483 - | /// .malformed_content_type_without_body_empty_input(handler)
|
8721 + | /// .malformed_double(handler)
|
7484 8722 | /// /* Set other handlers */
|
7485 8723 | /// .build()
|
7486 8724 | /// .unwrap();
|
7487 8725 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7488 8726 | /// ```
|
7489 8727 | ///
|
7490 - | pub fn malformed_content_type_without_body_empty_input<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8728 + | pub fn malformed_double<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7491 8729 | where
|
7492 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerExtractors>,
|
8730 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedDouble, HandlerExtractors>,
|
7493 8731 |
|
7494 8732 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7495 8733 | RestJson<L>,
|
7496 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7497 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerType>
|
8734 + | crate::operation_shape::MalformedDouble,
|
8735 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedDouble, HandlerType>
|
7498 8736 | >,
|
7499 8737 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7500 8738 | RestJson<L>,
|
7501 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8739 + | crate::operation_shape::MalformedDouble,
|
7502 8740 | ModelPl::Output
|
7503 8741 | >,
|
7504 8742 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7505 8743 | RestJson<L>,
|
7506 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8744 + | crate::operation_shape::MalformedDouble,
|
7507 8745 | <
|
7508 8746 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7509 8747 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7510 8748 | RestJson<L>,
|
7511 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8749 + | crate::operation_shape::MalformedDouble,
|
7512 8750 | ModelPl::Output
|
7513 8751 | >
|
7514 8752 | >::Output
|
7515 8753 | >,
|
7516 8754 |
|
7517 8755 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7518 8756 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7519 8757 |
|
7520 8758 | {
|
7521 8759 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7522 8760 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7523 - | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_handler(
|
7524 - | handler,
|
7525 - | );
|
8761 + | let svc = crate::operation_shape::MalformedDouble::from_handler(handler);
|
7526 8762 | let svc = self.model_plugin.apply(svc);
|
7527 8763 | let svc =
|
7528 8764 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7529 8765 | .apply(svc);
|
7530 8766 | let svc = self.http_plugin.apply(svc);
|
7531 - | self.malformed_content_type_without_body_empty_input_custom(svc)
|
8767 + | self.malformed_double_custom(svc)
|
7532 8768 | }
|
7533 8769 |
|
7534 - | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
8770 + | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
7535 8771 | ///
|
7536 8772 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7537 8773 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7538 8774 | ///
|
7539 8775 | /// # Example
|
7540 8776 | ///
|
7541 8777 | /// ```no_run
|
7542 8778 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7543 8779 | ///
|
7544 8780 | /// use rest_json_http0x::{input, output, error};
|
7545 8781 | ///
|
7546 - | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> Result<output::MalformedContentTypeWithoutBodyEmptyInputOutput, std::convert::Infallible> {
|
8782 + | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
7547 8783 | /// todo!()
|
7548 8784 | /// }
|
7549 8785 | ///
|
7550 8786 | /// let config = RestJsonConfig::builder().build();
|
7551 8787 | /// let svc = ::tower::util::service_fn(handler);
|
7552 8788 | /// let app = RestJson::builder(config)
|
7553 - | /// .malformed_content_type_without_body_empty_input_service(svc)
|
8789 + | /// .malformed_double_service(svc)
|
7554 8790 | /// /* Set other handlers */
|
7555 8791 | /// .build()
|
7556 8792 | /// .unwrap();
|
7557 8793 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7558 8794 | /// ```
|
7559 8795 | ///
|
7560 - | pub fn malformed_content_type_without_body_empty_input_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8796 + | pub fn malformed_double_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7561 8797 | where
|
7562 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, ServiceExtractors>,
|
8798 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedDouble, ServiceExtractors>,
|
7563 8799 |
|
7564 8800 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7565 8801 | RestJson<L>,
|
7566 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7567 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, S>
|
8802 + | crate::operation_shape::MalformedDouble,
|
8803 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedDouble, S>
|
7568 8804 | >,
|
7569 8805 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7570 8806 | RestJson<L>,
|
7571 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8807 + | crate::operation_shape::MalformedDouble,
|
7572 8808 | ModelPl::Output
|
7573 8809 | >,
|
7574 8810 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7575 8811 | RestJson<L>,
|
7576 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8812 + | crate::operation_shape::MalformedDouble,
|
7577 8813 | <
|
7578 8814 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7579 8815 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7580 8816 | RestJson<L>,
|
7581 - | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
8817 + | crate::operation_shape::MalformedDouble,
|
7582 8818 | ModelPl::Output
|
7583 8819 | >
|
7584 8820 | >::Output
|
7585 8821 | >,
|
7586 8822 |
|
7587 8823 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7588 8824 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7589 8825 |
|
7590 8826 | {
|
7591 8827 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7592 8828 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7593 - | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_service(
|
7594 - | service,
|
7595 - | );
|
8829 + | let svc = crate::operation_shape::MalformedDouble::from_service(service);
|
7596 8830 | let svc = self.model_plugin.apply(svc);
|
7597 8831 | let svc =
|
7598 8832 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7599 8833 | .apply(svc);
|
7600 8834 | let svc = self.http_plugin.apply(svc);
|
7601 - | self.malformed_content_type_without_body_empty_input_custom(svc)
|
8835 + | self.malformed_double_custom(svc)
|
7602 8836 | }
|
7603 8837 |
|
7604 - | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) to a custom [`Service`](tower::Service).
|
8838 + | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) to a custom [`Service`](tower::Service).
|
7605 8839 | /// not constrained by the Smithy contract.
|
7606 - | fn malformed_content_type_without_body_empty_input_custom<S>(mut self, svc: S) -> Self
|
8840 + | fn malformed_double_custom<S>(mut self, svc: S) -> Self
|
7607 8841 | where
|
7608 8842 | S: ::tower::Service<
|
7609 8843 | ::http::Request<Body>,
|
7610 8844 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7611 8845 | Error = ::std::convert::Infallible,
|
7612 8846 | > + Clone
|
7613 8847 | + Send
|
7614 8848 | + 'static,
|
7615 8849 | S::Future: Send + 'static,
|
7616 8850 | {
|
7617 - | self.malformed_content_type_without_body_empty_input =
|
7618 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8851 + | self.malformed_double = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7619 8852 | self
|
7620 8853 | }
|
7621 8854 |
|
7622 - | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
8855 + | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
7623 8856 | ///
|
7624 8857 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7625 8858 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7626 8859 | ///
|
7627 8860 | /// # Example
|
7628 8861 | ///
|
7629 8862 | /// ```no_run
|
7630 8863 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7631 8864 | ///
|
7632 8865 | /// use rest_json_http0x::{input, output, error};
|
7633 8866 | ///
|
7634 - | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> output::MalformedContentTypeWithPayloadOutput {
|
8867 + | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
7635 8868 | /// todo!()
|
7636 8869 | /// }
|
7637 8870 | ///
|
7638 8871 | /// let config = RestJsonConfig::builder().build();
|
7639 8872 | /// let app = RestJson::builder(config)
|
7640 - | /// .malformed_content_type_with_payload(handler)
|
8873 + | /// .malformed_float(handler)
|
7641 8874 | /// /* Set other handlers */
|
7642 8875 | /// .build()
|
7643 8876 | /// .unwrap();
|
7644 8877 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7645 8878 | /// ```
|
7646 8879 | ///
|
7647 - | pub fn malformed_content_type_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8880 + | pub fn malformed_float<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7648 8881 | where
|
7649 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithPayload, HandlerExtractors>,
|
8882 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedFloat, HandlerExtractors>,
|
7650 8883 |
|
7651 8884 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7652 8885 | RestJson<L>,
|
7653 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
7654 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithPayload, HandlerType>
|
8886 + | crate::operation_shape::MalformedFloat,
|
8887 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedFloat, HandlerType>
|
7655 8888 | >,
|
7656 8889 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7657 8890 | RestJson<L>,
|
7658 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8891 + | crate::operation_shape::MalformedFloat,
|
7659 8892 | ModelPl::Output
|
7660 8893 | >,
|
7661 8894 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7662 8895 | RestJson<L>,
|
7663 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8896 + | crate::operation_shape::MalformedFloat,
|
7664 8897 | <
|
7665 8898 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7666 8899 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7667 8900 | RestJson<L>,
|
7668 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8901 + | crate::operation_shape::MalformedFloat,
|
7669 8902 | ModelPl::Output
|
7670 8903 | >
|
7671 8904 | >::Output
|
7672 8905 | >,
|
7673 8906 |
|
7674 8907 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7675 8908 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7676 8909 |
|
7677 8910 | {
|
7678 8911 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7679 8912 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7680 - | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_handler(handler);
|
8913 + | let svc = crate::operation_shape::MalformedFloat::from_handler(handler);
|
7681 8914 | let svc = self.model_plugin.apply(svc);
|
7682 8915 | let svc =
|
7683 8916 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7684 8917 | .apply(svc);
|
7685 8918 | let svc = self.http_plugin.apply(svc);
|
7686 - | self.malformed_content_type_with_payload_custom(svc)
|
8919 + | self.malformed_float_custom(svc)
|
7687 8920 | }
|
7688 8921 |
|
7689 - | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
8922 + | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
7690 8923 | ///
|
7691 8924 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7692 8925 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7693 8926 | ///
|
7694 8927 | /// # Example
|
7695 8928 | ///
|
7696 8929 | /// ```no_run
|
7697 8930 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7698 8931 | ///
|
7699 8932 | /// use rest_json_http0x::{input, output, error};
|
7700 8933 | ///
|
7701 - | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> Result<output::MalformedContentTypeWithPayloadOutput, std::convert::Infallible> {
|
8934 + | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
7702 8935 | /// todo!()
|
7703 8936 | /// }
|
7704 8937 | ///
|
7705 8938 | /// let config = RestJsonConfig::builder().build();
|
7706 8939 | /// let svc = ::tower::util::service_fn(handler);
|
7707 8940 | /// let app = RestJson::builder(config)
|
7708 - | /// .malformed_content_type_with_payload_service(svc)
|
8941 + | /// .malformed_float_service(svc)
|
7709 8942 | /// /* Set other handlers */
|
7710 8943 | /// .build()
|
7711 8944 | /// .unwrap();
|
7712 8945 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7713 8946 | /// ```
|
7714 8947 | ///
|
7715 - | pub fn malformed_content_type_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8948 + | pub fn malformed_float_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7716 8949 | where
|
7717 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithPayload, ServiceExtractors>,
|
8950 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedFloat, ServiceExtractors>,
|
7718 8951 |
|
7719 8952 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7720 8953 | RestJson<L>,
|
7721 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
7722 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithPayload, S>
|
8954 + | crate::operation_shape::MalformedFloat,
|
8955 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedFloat, S>
|
7723 8956 | >,
|
7724 8957 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7725 8958 | RestJson<L>,
|
7726 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8959 + | crate::operation_shape::MalformedFloat,
|
7727 8960 | ModelPl::Output
|
7728 8961 | >,
|
7729 8962 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7730 8963 | RestJson<L>,
|
7731 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8964 + | crate::operation_shape::MalformedFloat,
|
7732 8965 | <
|
7733 8966 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7734 8967 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7735 8968 | RestJson<L>,
|
7736 - | crate::operation_shape::MalformedContentTypeWithPayload,
|
8969 + | crate::operation_shape::MalformedFloat,
|
7737 8970 | ModelPl::Output
|
7738 8971 | >
|
7739 8972 | >::Output
|
7740 8973 | >,
|
7741 8974 |
|
7742 8975 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7743 8976 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7744 8977 |
|
7745 8978 | {
|
7746 8979 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7747 8980 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7748 - | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_service(service);
|
8981 + | let svc = crate::operation_shape::MalformedFloat::from_service(service);
|
7749 8982 | let svc = self.model_plugin.apply(svc);
|
7750 8983 | let svc =
|
7751 8984 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7752 8985 | .apply(svc);
|
7753 8986 | let svc = self.http_plugin.apply(svc);
|
7754 - | self.malformed_content_type_with_payload_custom(svc)
|
8987 + | self.malformed_float_custom(svc)
|
7755 8988 | }
|
7756 8989 |
|
7757 - | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) to a custom [`Service`](tower::Service).
|
8990 + | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) to a custom [`Service`](tower::Service).
|
7758 8991 | /// not constrained by the Smithy contract.
|
7759 - | fn malformed_content_type_with_payload_custom<S>(mut self, svc: S) -> Self
|
8992 + | fn malformed_float_custom<S>(mut self, svc: S) -> Self
|
7760 8993 | where
|
7761 8994 | S: ::tower::Service<
|
7762 8995 | ::http::Request<Body>,
|
7763 8996 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7764 8997 | Error = ::std::convert::Infallible,
|
7765 8998 | > + Clone
|
7766 8999 | + Send
|
7767 9000 | + 'static,
|
7768 9001 | S::Future: Send + 'static,
|
7769 9002 | {
|
7770 - | self.malformed_content_type_with_payload =
|
7771 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9003 + | self.malformed_float = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7772 9004 | self
|
7773 9005 | }
|
7774 9006 |
|
7775 - | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
9007 + | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
7776 9008 | ///
|
7777 9009 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7778 9010 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7779 9011 | ///
|
7780 9012 | /// # Example
|
7781 9013 | ///
|
7782 9014 | /// ```no_run
|
7783 9015 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7784 9016 | ///
|
7785 9017 | /// use rest_json_http0x::{input, output, error};
|
7786 9018 | ///
|
7787 - | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
9019 + | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
7788 9020 | /// todo!()
|
7789 9021 | /// }
|
7790 9022 | ///
|
7791 9023 | /// let config = RestJsonConfig::builder().build();
|
7792 9024 | /// let app = RestJson::builder(config)
|
7793 - | /// .malformed_double(handler)
|
9025 + | /// .malformed_integer(handler)
|
7794 9026 | /// /* Set other handlers */
|
7795 9027 | /// .build()
|
7796 9028 | /// .unwrap();
|
7797 9029 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7798 9030 | /// ```
|
7799 9031 | ///
|
7800 - | pub fn malformed_double<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9032 + | pub fn malformed_integer<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7801 9033 | where
|
7802 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedDouble, HandlerExtractors>,
|
9034 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedInteger, HandlerExtractors>,
|
7803 9035 |
|
7804 9036 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7805 9037 | RestJson<L>,
|
7806 - | crate::operation_shape::MalformedDouble,
|
7807 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedDouble, HandlerType>
|
9038 + | crate::operation_shape::MalformedInteger,
|
9039 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedInteger, HandlerType>
|
7808 9040 | >,
|
7809 9041 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7810 9042 | RestJson<L>,
|
7811 - | crate::operation_shape::MalformedDouble,
|
9043 + | crate::operation_shape::MalformedInteger,
|
7812 9044 | ModelPl::Output
|
7813 9045 | >,
|
7814 9046 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7815 9047 | RestJson<L>,
|
7816 - | crate::operation_shape::MalformedDouble,
|
9048 + | crate::operation_shape::MalformedInteger,
|
7817 9049 | <
|
7818 9050 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7819 9051 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7820 9052 | RestJson<L>,
|
7821 - | crate::operation_shape::MalformedDouble,
|
9053 + | crate::operation_shape::MalformedInteger,
|
7822 9054 | ModelPl::Output
|
7823 9055 | >
|
7824 9056 | >::Output
|
7825 9057 | >,
|
7826 9058 |
|
7827 9059 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7828 9060 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7829 9061 |
|
7830 9062 | {
|
7831 9063 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7832 9064 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7833 - | let svc = crate::operation_shape::MalformedDouble::from_handler(handler);
|
9065 + | let svc = crate::operation_shape::MalformedInteger::from_handler(handler);
|
7834 9066 | let svc = self.model_plugin.apply(svc);
|
7835 9067 | let svc =
|
7836 9068 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7837 9069 | .apply(svc);
|
7838 9070 | let svc = self.http_plugin.apply(svc);
|
7839 - | self.malformed_double_custom(svc)
|
9071 + | self.malformed_integer_custom(svc)
|
7840 9072 | }
|
7841 9073 |
|
7842 - | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
9074 + | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
7843 9075 | ///
|
7844 9076 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7845 9077 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7846 9078 | ///
|
7847 9079 | /// # Example
|
7848 9080 | ///
|
7849 9081 | /// ```no_run
|
7850 9082 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7851 9083 | ///
|
7852 9084 | /// use rest_json_http0x::{input, output, error};
|
7853 9085 | ///
|
7854 - | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
9086 + | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
7855 9087 | /// todo!()
|
7856 9088 | /// }
|
7857 9089 | ///
|
7858 9090 | /// let config = RestJsonConfig::builder().build();
|
7859 9091 | /// let svc = ::tower::util::service_fn(handler);
|
7860 9092 | /// let app = RestJson::builder(config)
|
7861 - | /// .malformed_double_service(svc)
|
9093 + | /// .malformed_integer_service(svc)
|
7862 9094 | /// /* Set other handlers */
|
7863 9095 | /// .build()
|
7864 9096 | /// .unwrap();
|
7865 9097 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7866 9098 | /// ```
|
7867 9099 | ///
|
7868 - | pub fn malformed_double_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9100 + | pub fn malformed_integer_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7869 9101 | where
|
7870 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedDouble, ServiceExtractors>,
|
9102 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedInteger, ServiceExtractors>,
|
7871 9103 |
|
7872 9104 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7873 9105 | RestJson<L>,
|
7874 - | crate::operation_shape::MalformedDouble,
|
7875 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedDouble, S>
|
9106 + | crate::operation_shape::MalformedInteger,
|
9107 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedInteger, S>
|
7876 9108 | >,
|
7877 9109 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7878 9110 | RestJson<L>,
|
7879 - | crate::operation_shape::MalformedDouble,
|
9111 + | crate::operation_shape::MalformedInteger,
|
7880 9112 | ModelPl::Output
|
7881 9113 | >,
|
7882 9114 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7883 9115 | RestJson<L>,
|
7884 - | crate::operation_shape::MalformedDouble,
|
9116 + | crate::operation_shape::MalformedInteger,
|
7885 9117 | <
|
7886 9118 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7887 9119 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7888 9120 | RestJson<L>,
|
7889 - | crate::operation_shape::MalformedDouble,
|
9121 + | crate::operation_shape::MalformedInteger,
|
7890 9122 | ModelPl::Output
|
7891 9123 | >
|
7892 9124 | >::Output
|
7893 9125 | >,
|
7894 9126 |
|
7895 9127 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7896 9128 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7897 9129 |
|
7898 9130 | {
|
7899 9131 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7900 9132 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7901 - | let svc = crate::operation_shape::MalformedDouble::from_service(service);
|
9133 + | let svc = crate::operation_shape::MalformedInteger::from_service(service);
|
7902 9134 | let svc = self.model_plugin.apply(svc);
|
7903 9135 | let svc =
|
7904 9136 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7905 9137 | .apply(svc);
|
7906 9138 | let svc = self.http_plugin.apply(svc);
|
7907 - | self.malformed_double_custom(svc)
|
9139 + | self.malformed_integer_custom(svc)
|
7908 9140 | }
|
7909 9141 |
|
7910 - | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) to a custom [`Service`](tower::Service).
|
9142 + | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) to a custom [`Service`](tower::Service).
|
7911 9143 | /// not constrained by the Smithy contract.
|
7912 - | fn malformed_double_custom<S>(mut self, svc: S) -> Self
|
9144 + | fn malformed_integer_custom<S>(mut self, svc: S) -> Self
|
7913 9145 | where
|
7914 9146 | S: ::tower::Service<
|
7915 9147 | ::http::Request<Body>,
|
7916 9148 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7917 9149 | Error = ::std::convert::Infallible,
|
7918 9150 | > + Clone
|
7919 9151 | + Send
|
7920 9152 | + 'static,
|
7921 9153 | S::Future: Send + 'static,
|
7922 9154 | {
|
7923 - | self.malformed_double = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9155 + | self.malformed_integer = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7924 9156 | self
|
7925 9157 | }
|
7926 9158 |
|
7927 - | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
9159 + | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
7928 9160 | ///
|
7929 9161 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7930 9162 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7931 9163 | ///
|
7932 9164 | /// # Example
|
7933 9165 | ///
|
7934 9166 | /// ```no_run
|
7935 9167 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
7936 9168 | ///
|
7937 9169 | /// use rest_json_http0x::{input, output, error};
|
7938 9170 | ///
|
7939 - | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
9171 + | /// async fn handler(input: input::MalformedListInput) -> output::MalformedListOutput {
|
7940 9172 | /// todo!()
|
7941 9173 | /// }
|
7942 9174 | ///
|
7943 9175 | /// let config = RestJsonConfig::builder().build();
|
7944 9176 | /// let app = RestJson::builder(config)
|
7945 - | /// .malformed_float(handler)
|
9177 + | /// .malformed_list(handler)
|
7946 9178 | /// /* Set other handlers */
|
7947 9179 | /// .build()
|
7948 9180 | /// .unwrap();
|
7949 9181 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7950 9182 | /// ```
|
7951 9183 | ///
|
7952 - | pub fn malformed_float<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9184 + | pub fn malformed_list<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7953 9185 | where
|
7954 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedFloat, HandlerExtractors>,
|
9186 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedList, HandlerExtractors>,
|
7955 9187 |
|
7956 9188 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7957 9189 | RestJson<L>,
|
7958 - | crate::operation_shape::MalformedFloat,
|
7959 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedFloat, HandlerType>
|
9190 + | crate::operation_shape::MalformedList,
|
9191 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedList, HandlerType>
|
7960 9192 | >,
|
7961 9193 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7962 9194 | RestJson<L>,
|
7963 - | crate::operation_shape::MalformedFloat,
|
9195 + | crate::operation_shape::MalformedList,
|
7964 9196 | ModelPl::Output
|
7965 9197 | >,
|
7966 9198 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7967 9199 | RestJson<L>,
|
7968 - | crate::operation_shape::MalformedFloat,
|
9200 + | crate::operation_shape::MalformedList,
|
7969 9201 | <
|
7970 9202 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7971 9203 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7972 9204 | RestJson<L>,
|
7973 - | crate::operation_shape::MalformedFloat,
|
9205 + | crate::operation_shape::MalformedList,
|
7974 9206 | ModelPl::Output
|
7975 9207 | >
|
7976 9208 | >::Output
|
7977 9209 | >,
|
7978 9210 |
|
7979 9211 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7980 9212 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7981 9213 |
|
7982 9214 | {
|
7983 9215 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7984 9216 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7985 - | let svc = crate::operation_shape::MalformedFloat::from_handler(handler);
|
9217 + | let svc = crate::operation_shape::MalformedList::from_handler(handler);
|
7986 9218 | let svc = self.model_plugin.apply(svc);
|
7987 9219 | let svc =
|
7988 9220 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7989 9221 | .apply(svc);
|
7990 9222 | let svc = self.http_plugin.apply(svc);
|
7991 - | self.malformed_float_custom(svc)
|
9223 + | self.malformed_list_custom(svc)
|
7992 9224 | }
|
7993 9225 |
|
7994 - | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
9226 + | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
7995 9227 | ///
|
7996 9228 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7997 9229 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7998 9230 | ///
|
7999 9231 | /// # Example
|
8000 9232 | ///
|
8001 9233 | /// ```no_run
|
8002 9234 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8003 9235 | ///
|
8004 9236 | /// use rest_json_http0x::{input, output, error};
|
8005 9237 | ///
|
8006 - | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
9238 + | /// async fn handler(input: input::MalformedListInput) -> Result<output::MalformedListOutput, std::convert::Infallible> {
|
8007 9239 | /// todo!()
|
8008 9240 | /// }
|
8009 9241 | ///
|
8010 9242 | /// let config = RestJsonConfig::builder().build();
|
8011 9243 | /// let svc = ::tower::util::service_fn(handler);
|
8012 9244 | /// let app = RestJson::builder(config)
|
8013 - | /// .malformed_float_service(svc)
|
9245 + | /// .malformed_list_service(svc)
|
8014 9246 | /// /* Set other handlers */
|
8015 9247 | /// .build()
|
8016 9248 | /// .unwrap();
|
8017 9249 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8018 9250 | /// ```
|
8019 9251 | ///
|
8020 - | pub fn malformed_float_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9252 + | pub fn malformed_list_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8021 9253 | where
|
8022 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedFloat, ServiceExtractors>,
|
9254 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedList, ServiceExtractors>,
|
8023 9255 |
|
8024 9256 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8025 9257 | RestJson<L>,
|
8026 - | crate::operation_shape::MalformedFloat,
|
8027 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedFloat, S>
|
9258 + | crate::operation_shape::MalformedList,
|
9259 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedList, S>
|
8028 9260 | >,
|
8029 9261 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8030 9262 | RestJson<L>,
|
8031 - | crate::operation_shape::MalformedFloat,
|
9263 + | crate::operation_shape::MalformedList,
|
8032 9264 | ModelPl::Output
|
8033 9265 | >,
|
8034 9266 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8035 9267 | RestJson<L>,
|
8036 - | crate::operation_shape::MalformedFloat,
|
9268 + | crate::operation_shape::MalformedList,
|
8037 9269 | <
|
8038 9270 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8039 9271 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8040 9272 | RestJson<L>,
|
8041 - | crate::operation_shape::MalformedFloat,
|
9273 + | crate::operation_shape::MalformedList,
|
8042 9274 | ModelPl::Output
|
8043 9275 | >
|
8044 9276 | >::Output
|
8045 9277 | >,
|
8046 9278 |
|
8047 9279 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8048 9280 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8049 9281 |
|
8050 9282 | {
|
8051 9283 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8052 9284 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8053 - | let svc = crate::operation_shape::MalformedFloat::from_service(service);
|
9285 + | let svc = crate::operation_shape::MalformedList::from_service(service);
|
8054 9286 | let svc = self.model_plugin.apply(svc);
|
8055 9287 | let svc =
|
8056 9288 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8057 9289 | .apply(svc);
|
8058 9290 | let svc = self.http_plugin.apply(svc);
|
8059 - | self.malformed_float_custom(svc)
|
9291 + | self.malformed_list_custom(svc)
|
8060 9292 | }
|
8061 9293 |
|
8062 - | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) to a custom [`Service`](tower::Service).
|
9294 + | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) to a custom [`Service`](tower::Service).
|
8063 9295 | /// not constrained by the Smithy contract.
|
8064 - | fn malformed_float_custom<S>(mut self, svc: S) -> Self
|
9296 + | fn malformed_list_custom<S>(mut self, svc: S) -> Self
|
8065 9297 | where
|
8066 9298 | S: ::tower::Service<
|
8067 9299 | ::http::Request<Body>,
|
8068 9300 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8069 9301 | Error = ::std::convert::Infallible,
|
8070 9302 | > + Clone
|
8071 9303 | + Send
|
8072 9304 | + 'static,
|
8073 9305 | S::Future: Send + 'static,
|
8074 9306 | {
|
8075 - | self.malformed_float = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9307 + | self.malformed_list = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8076 9308 | self
|
8077 9309 | }
|
8078 9310 |
|
8079 - | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
9311 + | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
8080 9312 | ///
|
8081 9313 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8082 9314 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8083 9315 | ///
|
8084 9316 | /// # Example
|
8085 9317 | ///
|
8086 9318 | /// ```no_run
|
8087 9319 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8088 9320 | ///
|
8089 9321 | /// use rest_json_http0x::{input, output, error};
|
8090 9322 | ///
|
8091 - | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
9323 + | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
8092 9324 | /// todo!()
|
8093 9325 | /// }
|
8094 9326 | ///
|
8095 9327 | /// let config = RestJsonConfig::builder().build();
|
8096 9328 | /// let app = RestJson::builder(config)
|
8097 - | /// .malformed_integer(handler)
|
9329 + | /// .malformed_long(handler)
|
8098 9330 | /// /* Set other handlers */
|
8099 9331 | /// .build()
|
8100 9332 | /// .unwrap();
|
8101 9333 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8102 9334 | /// ```
|
8103 9335 | ///
|
8104 - | pub fn malformed_integer<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9336 + | pub fn malformed_long<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8105 9337 | where
|
8106 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedInteger, HandlerExtractors>,
|
9338 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedLong, HandlerExtractors>,
|
8107 9339 |
|
8108 9340 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8109 9341 | RestJson<L>,
|
8110 - | crate::operation_shape::MalformedInteger,
|
8111 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedInteger, HandlerType>
|
9342 + | crate::operation_shape::MalformedLong,
|
9343 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedLong, HandlerType>
|
8112 9344 | >,
|
8113 9345 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8114 9346 | RestJson<L>,
|
8115 - | crate::operation_shape::MalformedInteger,
|
9347 + | crate::operation_shape::MalformedLong,
|
8116 9348 | ModelPl::Output
|
8117 9349 | >,
|
8118 9350 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8119 9351 | RestJson<L>,
|
8120 - | crate::operation_shape::MalformedInteger,
|
9352 + | crate::operation_shape::MalformedLong,
|
8121 9353 | <
|
8122 9354 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8123 9355 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8124 9356 | RestJson<L>,
|
8125 - | crate::operation_shape::MalformedInteger,
|
9357 + | crate::operation_shape::MalformedLong,
|
8126 9358 | ModelPl::Output
|
8127 9359 | >
|
8128 9360 | >::Output
|
8129 9361 | >,
|
8130 9362 |
|
8131 9363 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8132 9364 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8133 9365 |
|
8134 9366 | {
|
8135 9367 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8136 9368 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8137 - | let svc = crate::operation_shape::MalformedInteger::from_handler(handler);
|
9369 + | let svc = crate::operation_shape::MalformedLong::from_handler(handler);
|
8138 9370 | let svc = self.model_plugin.apply(svc);
|
8139 9371 | let svc =
|
8140 9372 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8141 9373 | .apply(svc);
|
8142 9374 | let svc = self.http_plugin.apply(svc);
|
8143 - | self.malformed_integer_custom(svc)
|
9375 + | self.malformed_long_custom(svc)
|
8144 9376 | }
|
8145 9377 |
|
8146 - | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
9378 + | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
8147 9379 | ///
|
8148 9380 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8149 9381 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8150 9382 | ///
|
8151 9383 | /// # Example
|
8152 9384 | ///
|
8153 9385 | /// ```no_run
|
8154 9386 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8155 9387 | ///
|
8156 9388 | /// use rest_json_http0x::{input, output, error};
|
8157 9389 | ///
|
8158 - | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
9390 + | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
8159 9391 | /// todo!()
|
8160 9392 | /// }
|
8161 9393 | ///
|
8162 9394 | /// let config = RestJsonConfig::builder().build();
|
8163 9395 | /// let svc = ::tower::util::service_fn(handler);
|
8164 9396 | /// let app = RestJson::builder(config)
|
8165 - | /// .malformed_integer_service(svc)
|
9397 + | /// .malformed_long_service(svc)
|
8166 9398 | /// /* Set other handlers */
|
8167 9399 | /// .build()
|
8168 9400 | /// .unwrap();
|
8169 9401 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8170 9402 | /// ```
|
8171 9403 | ///
|
8172 - | pub fn malformed_integer_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9404 + | pub fn malformed_long_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8173 9405 | where
|
8174 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedInteger, ServiceExtractors>,
|
9406 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedLong, ServiceExtractors>,
|
8175 9407 |
|
8176 9408 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8177 9409 | RestJson<L>,
|
8178 - | crate::operation_shape::MalformedInteger,
|
8179 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedInteger, S>
|
9410 + | crate::operation_shape::MalformedLong,
|
9411 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedLong, S>
|
8180 9412 | >,
|
8181 9413 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8182 9414 | RestJson<L>,
|
8183 - | crate::operation_shape::MalformedInteger,
|
9415 + | crate::operation_shape::MalformedLong,
|
8184 9416 | ModelPl::Output
|
8185 9417 | >,
|
8186 9418 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8187 9419 | RestJson<L>,
|
8188 - | crate::operation_shape::MalformedInteger,
|
9420 + | crate::operation_shape::MalformedLong,
|
8189 9421 | <
|
8190 9422 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8191 9423 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8192 9424 | RestJson<L>,
|
8193 - | crate::operation_shape::MalformedInteger,
|
9425 + | crate::operation_shape::MalformedLong,
|
8194 9426 | ModelPl::Output
|
8195 9427 | >
|
8196 9428 | >::Output
|
8197 9429 | >,
|
8198 9430 |
|
8199 9431 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8200 9432 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8201 9433 |
|
8202 9434 | {
|
8203 9435 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8204 9436 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8205 - | let svc = crate::operation_shape::MalformedInteger::from_service(service);
|
9437 + | let svc = crate::operation_shape::MalformedLong::from_service(service);
|
8206 9438 | let svc = self.model_plugin.apply(svc);
|
8207 9439 | let svc =
|
8208 9440 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8209 9441 | .apply(svc);
|
8210 9442 | let svc = self.http_plugin.apply(svc);
|
8211 - | self.malformed_integer_custom(svc)
|
9443 + | self.malformed_long_custom(svc)
|
8212 9444 | }
|
8213 9445 |
|
8214 - | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) to a custom [`Service`](tower::Service).
|
9446 + | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) to a custom [`Service`](tower::Service).
|
8215 9447 | /// not constrained by the Smithy contract.
|
8216 - | fn malformed_integer_custom<S>(mut self, svc: S) -> Self
|
9448 + | fn malformed_long_custom<S>(mut self, svc: S) -> Self
|
8217 9449 | where
|
8218 9450 | S: ::tower::Service<
|
8219 9451 | ::http::Request<Body>,
|
8220 9452 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8221 9453 | Error = ::std::convert::Infallible,
|
8222 9454 | > + Clone
|
8223 9455 | + Send
|
8224 9456 | + 'static,
|
8225 9457 | S::Future: Send + 'static,
|
8226 9458 | {
|
8227 - | self.malformed_integer = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9459 + | self.malformed_long = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8228 9460 | self
|
8229 9461 | }
|
8230 9462 |
|
8231 - | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
9463 + | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
8232 9464 | ///
|
8233 9465 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8234 9466 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8235 9467 | ///
|
8236 9468 | /// # Example
|
8237 9469 | ///
|
8238 9470 | /// ```no_run
|
8239 9471 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8240 9472 | ///
|
8241 9473 | /// use rest_json_http0x::{input, output, error};
|
8242 9474 | ///
|
8243 - | /// async fn handler(input: input::MalformedListInput) -> output::MalformedListOutput {
|
9475 + | /// async fn handler(input: input::MalformedMapInput) -> output::MalformedMapOutput {
|
8244 9476 | /// todo!()
|
8245 9477 | /// }
|
8246 9478 | ///
|
8247 9479 | /// let config = RestJsonConfig::builder().build();
|
8248 9480 | /// let app = RestJson::builder(config)
|
8249 - | /// .malformed_list(handler)
|
9481 + | /// .malformed_map(handler)
|
8250 9482 | /// /* Set other handlers */
|
8251 9483 | /// .build()
|
8252 9484 | /// .unwrap();
|
8253 9485 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8254 9486 | /// ```
|
8255 9487 | ///
|
8256 - | pub fn malformed_list<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9488 + | pub fn malformed_map<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8257 9489 | where
|
8258 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedList, HandlerExtractors>,
|
9490 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedMap, HandlerExtractors>,
|
8259 9491 |
|
8260 9492 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8261 9493 | RestJson<L>,
|
8262 - | crate::operation_shape::MalformedList,
|
8263 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedList, HandlerType>
|
9494 + | crate::operation_shape::MalformedMap,
|
9495 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedMap, HandlerType>
|
8264 9496 | >,
|
8265 9497 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8266 9498 | RestJson<L>,
|
8267 - | crate::operation_shape::MalformedList,
|
9499 + | crate::operation_shape::MalformedMap,
|
8268 9500 | ModelPl::Output
|
8269 9501 | >,
|
8270 9502 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8271 9503 | RestJson<L>,
|
8272 - | crate::operation_shape::MalformedList,
|
9504 + | crate::operation_shape::MalformedMap,
|
8273 9505 | <
|
8274 9506 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8275 9507 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8276 9508 | RestJson<L>,
|
8277 - | crate::operation_shape::MalformedList,
|
9509 + | crate::operation_shape::MalformedMap,
|
8278 9510 | ModelPl::Output
|
8279 9511 | >
|
8280 9512 | >::Output
|
8281 9513 | >,
|
8282 9514 |
|
8283 9515 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8284 9516 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8285 9517 |
|
8286 9518 | {
|
8287 9519 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8288 9520 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8289 - | let svc = crate::operation_shape::MalformedList::from_handler(handler);
|
9521 + | let svc = crate::operation_shape::MalformedMap::from_handler(handler);
|
8290 9522 | let svc = self.model_plugin.apply(svc);
|
8291 9523 | let svc =
|
8292 9524 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8293 9525 | .apply(svc);
|
8294 9526 | let svc = self.http_plugin.apply(svc);
|
8295 - | self.malformed_list_custom(svc)
|
9527 + | self.malformed_map_custom(svc)
|
8296 9528 | }
|
8297 9529 |
|
8298 - | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
9530 + | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
8299 9531 | ///
|
8300 9532 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8301 9533 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8302 9534 | ///
|
8303 9535 | /// # Example
|
8304 9536 | ///
|
8305 9537 | /// ```no_run
|
8306 9538 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8307 9539 | ///
|
8308 9540 | /// use rest_json_http0x::{input, output, error};
|
8309 9541 | ///
|
8310 - | /// async fn handler(input: input::MalformedListInput) -> Result<output::MalformedListOutput, std::convert::Infallible> {
|
9542 + | /// async fn handler(input: input::MalformedMapInput) -> Result<output::MalformedMapOutput, std::convert::Infallible> {
|
8311 9543 | /// todo!()
|
8312 9544 | /// }
|
8313 9545 | ///
|
8314 9546 | /// let config = RestJsonConfig::builder().build();
|
8315 9547 | /// let svc = ::tower::util::service_fn(handler);
|
8316 9548 | /// let app = RestJson::builder(config)
|
8317 - | /// .malformed_list_service(svc)
|
9549 + | /// .malformed_map_service(svc)
|
8318 9550 | /// /* Set other handlers */
|
8319 9551 | /// .build()
|
8320 9552 | /// .unwrap();
|
8321 9553 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8322 9554 | /// ```
|
8323 9555 | ///
|
8324 - | pub fn malformed_list_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9556 + | pub fn malformed_map_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8325 9557 | where
|
8326 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedList, ServiceExtractors>,
|
9558 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedMap, ServiceExtractors>,
|
8327 9559 |
|
8328 9560 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8329 9561 | RestJson<L>,
|
8330 - | crate::operation_shape::MalformedList,
|
8331 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedList, S>
|
9562 + | crate::operation_shape::MalformedMap,
|
9563 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedMap, S>
|
8332 9564 | >,
|
8333 9565 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8334 9566 | RestJson<L>,
|
8335 - | crate::operation_shape::MalformedList,
|
9567 + | crate::operation_shape::MalformedMap,
|
8336 9568 | ModelPl::Output
|
8337 9569 | >,
|
8338 9570 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8339 9571 | RestJson<L>,
|
8340 - | crate::operation_shape::MalformedList,
|
9572 + | crate::operation_shape::MalformedMap,
|
8341 9573 | <
|
8342 9574 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8343 9575 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8344 9576 | RestJson<L>,
|
8345 - | crate::operation_shape::MalformedList,
|
9577 + | crate::operation_shape::MalformedMap,
|
8346 9578 | ModelPl::Output
|
8347 9579 | >
|
8348 9580 | >::Output
|
8349 9581 | >,
|
8350 9582 |
|
8351 9583 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8352 9584 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8353 9585 |
|
8354 9586 | {
|
8355 9587 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8356 9588 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8357 - | let svc = crate::operation_shape::MalformedList::from_service(service);
|
9589 + | let svc = crate::operation_shape::MalformedMap::from_service(service);
|
8358 9590 | let svc = self.model_plugin.apply(svc);
|
8359 9591 | let svc =
|
8360 9592 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8361 9593 | .apply(svc);
|
8362 9594 | let svc = self.http_plugin.apply(svc);
|
8363 - | self.malformed_list_custom(svc)
|
9595 + | self.malformed_map_custom(svc)
|
8364 9596 | }
|
8365 9597 |
|
8366 - | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) to a custom [`Service`](tower::Service).
|
9598 + | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) to a custom [`Service`](tower::Service).
|
8367 9599 | /// not constrained by the Smithy contract.
|
8368 - | fn malformed_list_custom<S>(mut self, svc: S) -> Self
|
9600 + | fn malformed_map_custom<S>(mut self, svc: S) -> Self
|
8369 9601 | where
|
8370 9602 | S: ::tower::Service<
|
8371 9603 | ::http::Request<Body>,
|
8372 9604 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8373 9605 | Error = ::std::convert::Infallible,
|
8374 9606 | > + Clone
|
8375 9607 | + Send
|
8376 9608 | + 'static,
|
8377 9609 | S::Future: Send + 'static,
|
8378 9610 | {
|
8379 - | self.malformed_list = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9611 + | self.malformed_map = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8380 9612 | self
|
8381 9613 | }
|
8382 9614 |
|
8383 - | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
9615 + | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
8384 9616 | ///
|
8385 9617 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8386 9618 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8387 9619 | ///
|
8388 9620 | /// # Example
|
8389 9621 | ///
|
8390 9622 | /// ```no_run
|
8391 9623 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8392 9624 | ///
|
8393 9625 | /// use rest_json_http0x::{input, output, error};
|
8394 9626 | ///
|
8395 - | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
9627 + | /// async fn handler(input: input::MalformedRequestBodyInput) -> output::MalformedRequestBodyOutput {
|
8396 9628 | /// todo!()
|
8397 9629 | /// }
|
8398 9630 | ///
|
8399 9631 | /// let config = RestJsonConfig::builder().build();
|
8400 9632 | /// let app = RestJson::builder(config)
|
8401 - | /// .malformed_long(handler)
|
9633 + | /// .malformed_request_body(handler)
|
8402 9634 | /// /* Set other handlers */
|
8403 9635 | /// .build()
|
8404 9636 | /// .unwrap();
|
8405 9637 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8406 9638 | /// ```
|
8407 9639 | ///
|
8408 - | pub fn malformed_long<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9640 + | pub fn malformed_request_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8409 9641 | where
|
8410 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedLong, HandlerExtractors>,
|
9642 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedRequestBody, HandlerExtractors>,
|
8411 9643 |
|
8412 9644 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8413 9645 | RestJson<L>,
|
8414 - | crate::operation_shape::MalformedLong,
|
8415 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedLong, HandlerType>
|
9646 + | crate::operation_shape::MalformedRequestBody,
|
9647 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedRequestBody, HandlerType>
|
8416 9648 | >,
|
8417 9649 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8418 9650 | RestJson<L>,
|
8419 - | crate::operation_shape::MalformedLong,
|
9651 + | crate::operation_shape::MalformedRequestBody,
|
8420 9652 | ModelPl::Output
|
8421 9653 | >,
|
8422 9654 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8423 9655 | RestJson<L>,
|
8424 - | crate::operation_shape::MalformedLong,
|
9656 + | crate::operation_shape::MalformedRequestBody,
|
8425 9657 | <
|
8426 9658 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8427 9659 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8428 9660 | RestJson<L>,
|
8429 - | crate::operation_shape::MalformedLong,
|
9661 + | crate::operation_shape::MalformedRequestBody,
|
8430 9662 | ModelPl::Output
|
8431 9663 | >
|
8432 9664 | >::Output
|
8433 9665 | >,
|
8434 9666 |
|
8435 9667 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8436 9668 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8437 9669 |
|
8438 9670 | {
|
8439 9671 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8440 9672 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8441 - | let svc = crate::operation_shape::MalformedLong::from_handler(handler);
|
9673 + | let svc = crate::operation_shape::MalformedRequestBody::from_handler(handler);
|
8442 9674 | let svc = self.model_plugin.apply(svc);
|
8443 9675 | let svc =
|
8444 9676 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8445 9677 | .apply(svc);
|
8446 9678 | let svc = self.http_plugin.apply(svc);
|
8447 - | self.malformed_long_custom(svc)
|
9679 + | self.malformed_request_body_custom(svc)
|
8448 9680 | }
|
8449 9681 |
|
8450 - | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
9682 + | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
8451 9683 | ///
|
8452 9684 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8453 9685 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8454 9686 | ///
|
8455 9687 | /// # Example
|
8456 9688 | ///
|
8457 9689 | /// ```no_run
|
8458 9690 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8459 9691 | ///
|
8460 9692 | /// use rest_json_http0x::{input, output, error};
|
8461 9693 | ///
|
8462 - | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
9694 + | /// async fn handler(input: input::MalformedRequestBodyInput) -> Result<output::MalformedRequestBodyOutput, std::convert::Infallible> {
|
8463 9695 | /// todo!()
|
8464 9696 | /// }
|
8465 9697 | ///
|
8466 9698 | /// let config = RestJsonConfig::builder().build();
|
8467 9699 | /// let svc = ::tower::util::service_fn(handler);
|
8468 9700 | /// let app = RestJson::builder(config)
|
8469 - | /// .malformed_long_service(svc)
|
9701 + | /// .malformed_request_body_service(svc)
|
8470 9702 | /// /* Set other handlers */
|
8471 9703 | /// .build()
|
8472 9704 | /// .unwrap();
|
8473 9705 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8474 9706 | /// ```
|
8475 9707 | ///
|
8476 - | pub fn malformed_long_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9708 + | pub fn malformed_request_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8477 9709 | where
|
8478 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedLong, ServiceExtractors>,
|
9710 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedRequestBody, ServiceExtractors>,
|
8479 9711 |
|
8480 9712 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8481 9713 | RestJson<L>,
|
8482 - | crate::operation_shape::MalformedLong,
|
8483 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedLong, S>
|
9714 + | crate::operation_shape::MalformedRequestBody,
|
9715 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedRequestBody, S>
|
8484 9716 | >,
|
8485 9717 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8486 9718 | RestJson<L>,
|
8487 - | crate::operation_shape::MalformedLong,
|
9719 + | crate::operation_shape::MalformedRequestBody,
|
8488 9720 | ModelPl::Output
|
8489 9721 | >,
|
8490 9722 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8491 9723 | RestJson<L>,
|
8492 - | crate::operation_shape::MalformedLong,
|
9724 + | crate::operation_shape::MalformedRequestBody,
|
8493 9725 | <
|
8494 9726 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8495 9727 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8496 9728 | RestJson<L>,
|
8497 - | crate::operation_shape::MalformedLong,
|
9729 + | crate::operation_shape::MalformedRequestBody,
|
8498 9730 | ModelPl::Output
|
8499 9731 | >
|
8500 9732 | >::Output
|
8501 9733 | >,
|
8502 9734 |
|
8503 9735 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8504 9736 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8505 9737 |
|
8506 9738 | {
|
8507 9739 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8508 9740 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8509 - | let svc = crate::operation_shape::MalformedLong::from_service(service);
|
9741 + | let svc = crate::operation_shape::MalformedRequestBody::from_service(service);
|
8510 9742 | let svc = self.model_plugin.apply(svc);
|
8511 9743 | let svc =
|
8512 9744 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8513 9745 | .apply(svc);
|
8514 9746 | let svc = self.http_plugin.apply(svc);
|
8515 - | self.malformed_long_custom(svc)
|
9747 + | self.malformed_request_body_custom(svc)
|
8516 9748 | }
|
8517 9749 |
|
8518 - | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) to a custom [`Service`](tower::Service).
|
9750 + | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) to a custom [`Service`](tower::Service).
|
8519 9751 | /// not constrained by the Smithy contract.
|
8520 - | fn malformed_long_custom<S>(mut self, svc: S) -> Self
|
9752 + | fn malformed_request_body_custom<S>(mut self, svc: S) -> Self
|
8521 9753 | where
|
8522 9754 | S: ::tower::Service<
|
8523 9755 | ::http::Request<Body>,
|
8524 9756 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8525 9757 | Error = ::std::convert::Infallible,
|
8526 9758 | > + Clone
|
8527 9759 | + Send
|
8528 9760 | + 'static,
|
8529 9761 | S::Future: Send + 'static,
|
8530 9762 | {
|
8531 - | self.malformed_long = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9763 + | self.malformed_request_body =
|
9764 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8532 9765 | self
|
8533 9766 | }
|
8534 9767 |
|
8535 - | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
9768 + | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
8536 9769 | ///
|
8537 9770 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8538 9771 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8539 9772 | ///
|
8540 9773 | /// # Example
|
8541 9774 | ///
|
8542 9775 | /// ```no_run
|
8543 9776 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8544 9777 | ///
|
8545 9778 | /// use rest_json_http0x::{input, output, error};
|
8546 9779 | ///
|
8547 - | /// async fn handler(input: input::MalformedMapInput) -> output::MalformedMapOutput {
|
9780 + | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
8548 9781 | /// todo!()
|
8549 9782 | /// }
|
8550 9783 | ///
|
8551 9784 | /// let config = RestJsonConfig::builder().build();
|
8552 9785 | /// let app = RestJson::builder(config)
|
8553 - | /// .malformed_map(handler)
|
9786 + | /// .malformed_short(handler)
|
8554 9787 | /// /* Set other handlers */
|
8555 9788 | /// .build()
|
8556 9789 | /// .unwrap();
|
8557 9790 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8558 9791 | /// ```
|
8559 9792 | ///
|
8560 - | pub fn malformed_map<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9793 + | pub fn malformed_short<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8561 9794 | where
|
8562 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedMap, HandlerExtractors>,
|
9795 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedShort, HandlerExtractors>,
|
8563 9796 |
|
8564 9797 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8565 9798 | RestJson<L>,
|
8566 - | crate::operation_shape::MalformedMap,
|
8567 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedMap, HandlerType>
|
9799 + | crate::operation_shape::MalformedShort,
|
9800 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedShort, HandlerType>
|
8568 9801 | >,
|
8569 9802 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8570 9803 | RestJson<L>,
|
8571 - | crate::operation_shape::MalformedMap,
|
9804 + | crate::operation_shape::MalformedShort,
|
8572 9805 | ModelPl::Output
|
8573 9806 | >,
|
8574 9807 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8575 9808 | RestJson<L>,
|
8576 - | crate::operation_shape::MalformedMap,
|
9809 + | crate::operation_shape::MalformedShort,
|
8577 9810 | <
|
8578 9811 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8579 9812 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8580 9813 | RestJson<L>,
|
8581 - | crate::operation_shape::MalformedMap,
|
9814 + | crate::operation_shape::MalformedShort,
|
8582 9815 | ModelPl::Output
|
8583 9816 | >
|
8584 9817 | >::Output
|
8585 9818 | >,
|
8586 9819 |
|
8587 9820 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8588 9821 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8589 9822 |
|
8590 9823 | {
|
8591 9824 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8592 9825 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8593 - | let svc = crate::operation_shape::MalformedMap::from_handler(handler);
|
9826 + | let svc = crate::operation_shape::MalformedShort::from_handler(handler);
|
8594 9827 | let svc = self.model_plugin.apply(svc);
|
8595 9828 | let svc =
|
8596 9829 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8597 9830 | .apply(svc);
|
8598 9831 | let svc = self.http_plugin.apply(svc);
|
8599 - | self.malformed_map_custom(svc)
|
9832 + | self.malformed_short_custom(svc)
|
8600 9833 | }
|
8601 9834 |
|
8602 - | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
9835 + | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
8603 9836 | ///
|
8604 9837 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8605 9838 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8606 9839 | ///
|
8607 9840 | /// # Example
|
8608 9841 | ///
|
8609 9842 | /// ```no_run
|
8610 9843 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8611 9844 | ///
|
8612 9845 | /// use rest_json_http0x::{input, output, error};
|
8613 9846 | ///
|
8614 - | /// async fn handler(input: input::MalformedMapInput) -> Result<output::MalformedMapOutput, std::convert::Infallible> {
|
9847 + | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
8615 9848 | /// todo!()
|
8616 9849 | /// }
|
8617 9850 | ///
|
8618 9851 | /// let config = RestJsonConfig::builder().build();
|
8619 9852 | /// let svc = ::tower::util::service_fn(handler);
|
8620 9853 | /// let app = RestJson::builder(config)
|
8621 - | /// .malformed_map_service(svc)
|
9854 + | /// .malformed_short_service(svc)
|
8622 9855 | /// /* Set other handlers */
|
8623 9856 | /// .build()
|
8624 9857 | /// .unwrap();
|
8625 9858 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8626 9859 | /// ```
|
8627 9860 | ///
|
8628 - | pub fn malformed_map_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9861 + | pub fn malformed_short_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8629 9862 | where
|
8630 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedMap, ServiceExtractors>,
|
9863 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedShort, ServiceExtractors>,
|
8631 9864 |
|
8632 9865 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8633 9866 | RestJson<L>,
|
8634 - | crate::operation_shape::MalformedMap,
|
8635 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedMap, S>
|
9867 + | crate::operation_shape::MalformedShort,
|
9868 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedShort, S>
|
8636 9869 | >,
|
8637 9870 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8638 9871 | RestJson<L>,
|
8639 - | crate::operation_shape::MalformedMap,
|
9872 + | crate::operation_shape::MalformedShort,
|
8640 9873 | ModelPl::Output
|
8641 9874 | >,
|
8642 9875 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8643 9876 | RestJson<L>,
|
8644 - | crate::operation_shape::MalformedMap,
|
9877 + | crate::operation_shape::MalformedShort,
|
8645 9878 | <
|
8646 9879 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8647 9880 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8648 9881 | RestJson<L>,
|
8649 - | crate::operation_shape::MalformedMap,
|
9882 + | crate::operation_shape::MalformedShort,
|
8650 9883 | ModelPl::Output
|
8651 9884 | >
|
8652 9885 | >::Output
|
8653 9886 | >,
|
8654 9887 |
|
8655 9888 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8656 9889 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8657 9890 |
|
8658 9891 | {
|
8659 9892 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8660 9893 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8661 - | let svc = crate::operation_shape::MalformedMap::from_service(service);
|
9894 + | let svc = crate::operation_shape::MalformedShort::from_service(service);
|
8662 9895 | let svc = self.model_plugin.apply(svc);
|
8663 9896 | let svc =
|
8664 9897 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8665 9898 | .apply(svc);
|
8666 9899 | let svc = self.http_plugin.apply(svc);
|
8667 - | self.malformed_map_custom(svc)
|
9900 + | self.malformed_short_custom(svc)
|
8668 9901 | }
|
8669 9902 |
|
8670 - | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) to a custom [`Service`](tower::Service).
|
9903 + | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) to a custom [`Service`](tower::Service).
|
8671 9904 | /// not constrained by the Smithy contract.
|
8672 - | fn malformed_map_custom<S>(mut self, svc: S) -> Self
|
9905 + | fn malformed_short_custom<S>(mut self, svc: S) -> Self
|
8673 9906 | where
|
8674 9907 | S: ::tower::Service<
|
8675 9908 | ::http::Request<Body>,
|
8676 9909 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8677 9910 | Error = ::std::convert::Infallible,
|
8678 9911 | > + Clone
|
8679 9912 | + Send
|
8680 9913 | + 'static,
|
8681 9914 | S::Future: Send + 'static,
|
8682 9915 | {
|
8683 - | self.malformed_map = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9916 + | self.malformed_short = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8684 9917 | self
|
8685 9918 | }
|
8686 9919 |
|
8687 - | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
9920 + | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
8688 9921 | ///
|
8689 9922 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8690 9923 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8691 9924 | ///
|
8692 9925 | /// # Example
|
8693 9926 | ///
|
8694 9927 | /// ```no_run
|
8695 9928 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8696 9929 | ///
|
8697 9930 | /// use rest_json_http0x::{input, output, error};
|
8698 9931 | ///
|
8699 - | /// async fn handler(input: input::MalformedRequestBodyInput) -> output::MalformedRequestBodyOutput {
|
9932 + | /// async fn handler(input: input::MalformedStringInput) -> output::MalformedStringOutput {
|
8700 9933 | /// todo!()
|
8701 9934 | /// }
|
8702 9935 | ///
|
8703 9936 | /// let config = RestJsonConfig::builder().build();
|
8704 9937 | /// let app = RestJson::builder(config)
|
8705 - | /// .malformed_request_body(handler)
|
9938 + | /// .malformed_string(handler)
|
8706 9939 | /// /* Set other handlers */
|
8707 9940 | /// .build()
|
8708 9941 | /// .unwrap();
|
8709 9942 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8710 9943 | /// ```
|
8711 9944 | ///
|
8712 - | pub fn malformed_request_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9945 + | pub fn malformed_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8713 9946 | where
|
8714 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedRequestBody, HandlerExtractors>,
|
9947 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedString, HandlerExtractors>,
|
8715 9948 |
|
8716 9949 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8717 9950 | RestJson<L>,
|
8718 - | crate::operation_shape::MalformedRequestBody,
|
8719 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedRequestBody, HandlerType>
|
9951 + | crate::operation_shape::MalformedString,
|
9952 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedString, HandlerType>
|
8720 9953 | >,
|
8721 9954 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8722 9955 | RestJson<L>,
|
8723 - | crate::operation_shape::MalformedRequestBody,
|
9956 + | crate::operation_shape::MalformedString,
|
8724 9957 | ModelPl::Output
|
8725 9958 | >,
|
8726 9959 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8727 9960 | RestJson<L>,
|
8728 - | crate::operation_shape::MalformedRequestBody,
|
9961 + | crate::operation_shape::MalformedString,
|
8729 9962 | <
|
8730 9963 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8731 9964 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8732 9965 | RestJson<L>,
|
8733 - | crate::operation_shape::MalformedRequestBody,
|
9966 + | crate::operation_shape::MalformedString,
|
8734 9967 | ModelPl::Output
|
8735 9968 | >
|
8736 9969 | >::Output
|
8737 9970 | >,
|
8738 9971 |
|
8739 9972 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8740 9973 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8741 9974 |
|
8742 9975 | {
|
8743 9976 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8744 9977 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8745 - | let svc = crate::operation_shape::MalformedRequestBody::from_handler(handler);
|
9978 + | let svc = crate::operation_shape::MalformedString::from_handler(handler);
|
8746 9979 | let svc = self.model_plugin.apply(svc);
|
8747 9980 | let svc =
|
8748 9981 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8749 9982 | .apply(svc);
|
8750 9983 | let svc = self.http_plugin.apply(svc);
|
8751 - | self.malformed_request_body_custom(svc)
|
9984 + | self.malformed_string_custom(svc)
|
8752 9985 | }
|
8753 9986 |
|
8754 - | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
9987 + | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
8755 9988 | ///
|
8756 9989 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8757 9990 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8758 9991 | ///
|
8759 9992 | /// # Example
|
8760 9993 | ///
|
8761 9994 | /// ```no_run
|
8762 9995 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8763 9996 | ///
|
8764 9997 | /// use rest_json_http0x::{input, output, error};
|
8765 9998 | ///
|
8766 - | /// async fn handler(input: input::MalformedRequestBodyInput) -> Result<output::MalformedRequestBodyOutput, std::convert::Infallible> {
|
9999 + | /// async fn handler(input: input::MalformedStringInput) -> Result<output::MalformedStringOutput, std::convert::Infallible> {
|
8767 10000 | /// todo!()
|
8768 10001 | /// }
|
8769 10002 | ///
|
8770 10003 | /// let config = RestJsonConfig::builder().build();
|
8771 10004 | /// let svc = ::tower::util::service_fn(handler);
|
8772 10005 | /// let app = RestJson::builder(config)
|
8773 - | /// .malformed_request_body_service(svc)
|
10006 + | /// .malformed_string_service(svc)
|
8774 10007 | /// /* Set other handlers */
|
8775 10008 | /// .build()
|
8776 10009 | /// .unwrap();
|
8777 10010 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8778 10011 | /// ```
|
8779 10012 | ///
|
8780 - | pub fn malformed_request_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10013 + | pub fn malformed_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8781 10014 | where
|
8782 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedRequestBody, ServiceExtractors>,
|
10015 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedString, ServiceExtractors>,
|
8783 10016 |
|
8784 10017 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8785 10018 | RestJson<L>,
|
8786 - | crate::operation_shape::MalformedRequestBody,
|
8787 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedRequestBody, S>
|
10019 + | crate::operation_shape::MalformedString,
|
10020 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedString, S>
|
8788 10021 | >,
|
8789 10022 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8790 10023 | RestJson<L>,
|
8791 - | crate::operation_shape::MalformedRequestBody,
|
10024 + | crate::operation_shape::MalformedString,
|
8792 10025 | ModelPl::Output
|
8793 10026 | >,
|
8794 10027 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8795 10028 | RestJson<L>,
|
8796 - | crate::operation_shape::MalformedRequestBody,
|
10029 + | crate::operation_shape::MalformedString,
|
8797 10030 | <
|
8798 10031 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8799 10032 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8800 10033 | RestJson<L>,
|
8801 - | crate::operation_shape::MalformedRequestBody,
|
10034 + | crate::operation_shape::MalformedString,
|
8802 10035 | ModelPl::Output
|
8803 10036 | >
|
8804 10037 | >::Output
|
8805 10038 | >,
|
8806 10039 |
|
8807 10040 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8808 10041 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8809 10042 |
|
8810 10043 | {
|
8811 10044 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8812 10045 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8813 - | let svc = crate::operation_shape::MalformedRequestBody::from_service(service);
|
10046 + | let svc = crate::operation_shape::MalformedString::from_service(service);
|
8814 10047 | let svc = self.model_plugin.apply(svc);
|
8815 10048 | let svc =
|
8816 10049 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8817 10050 | .apply(svc);
|
8818 10051 | let svc = self.http_plugin.apply(svc);
|
8819 - | self.malformed_request_body_custom(svc)
|
10052 + | self.malformed_string_custom(svc)
|
8820 10053 | }
|
8821 10054 |
|
8822 - | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) to a custom [`Service`](tower::Service).
|
10055 + | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) to a custom [`Service`](tower::Service).
|
8823 10056 | /// not constrained by the Smithy contract.
|
8824 - | fn malformed_request_body_custom<S>(mut self, svc: S) -> Self
|
10057 + | fn malformed_string_custom<S>(mut self, svc: S) -> Self
|
8825 10058 | where
|
8826 10059 | S: ::tower::Service<
|
8827 10060 | ::http::Request<Body>,
|
8828 10061 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8829 10062 | Error = ::std::convert::Infallible,
|
8830 10063 | > + Clone
|
8831 10064 | + Send
|
8832 10065 | + 'static,
|
8833 10066 | S::Future: Send + 'static,
|
8834 10067 | {
|
8835 - | self.malformed_request_body =
|
8836 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10068 + | self.malformed_string = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8837 10069 | self
|
8838 10070 | }
|
8839 10071 |
|
8840 - | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
10072 + | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
8841 10073 | ///
|
8842 10074 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8843 10075 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8844 10076 | ///
|
8845 10077 | /// # Example
|
8846 10078 | ///
|
8847 10079 | /// ```no_run
|
8848 10080 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8849 10081 | ///
|
8850 10082 | /// use rest_json_http0x::{input, output, error};
|
8851 10083 | ///
|
8852 - | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
10084 + | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
8853 10085 | /// todo!()
|
8854 10086 | /// }
|
8855 10087 | ///
|
8856 10088 | /// let config = RestJsonConfig::builder().build();
|
8857 10089 | /// let app = RestJson::builder(config)
|
8858 - | /// .malformed_short(handler)
|
10090 + | /// .malformed_timestamp_body_date_time(handler)
|
8859 10091 | /// /* Set other handlers */
|
8860 10092 | /// .build()
|
8861 10093 | /// .unwrap();
|
8862 10094 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8863 10095 | /// ```
|
8864 10096 | ///
|
8865 - | pub fn malformed_short<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10097 + | pub fn malformed_timestamp_body_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8866 10098 | where
|
8867 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedShort, HandlerExtractors>,
|
10099 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerExtractors>,
|
8868 10100 |
|
8869 10101 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8870 10102 | RestJson<L>,
|
8871 - | crate::operation_shape::MalformedShort,
|
8872 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedShort, HandlerType>
|
10103 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10104 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerType>
|
8873 10105 | >,
|
8874 10106 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8875 10107 | RestJson<L>,
|
8876 - | crate::operation_shape::MalformedShort,
|
10108 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8877 10109 | ModelPl::Output
|
8878 10110 | >,
|
8879 10111 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8880 10112 | RestJson<L>,
|
8881 - | crate::operation_shape::MalformedShort,
|
10113 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8882 10114 | <
|
8883 10115 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8884 10116 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8885 10117 | RestJson<L>,
|
8886 - | crate::operation_shape::MalformedShort,
|
10118 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8887 10119 | ModelPl::Output
|
8888 10120 | >
|
8889 10121 | >::Output
|
8890 10122 | >,
|
8891 10123 |
|
8892 10124 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8893 10125 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8894 10126 |
|
8895 10127 | {
|
8896 10128 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8897 10129 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8898 - | let svc = crate::operation_shape::MalformedShort::from_handler(handler);
|
10130 + | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_handler(handler);
|
8899 10131 | let svc = self.model_plugin.apply(svc);
|
8900 10132 | let svc =
|
8901 10133 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8902 10134 | .apply(svc);
|
8903 10135 | let svc = self.http_plugin.apply(svc);
|
8904 - | self.malformed_short_custom(svc)
|
10136 + | self.malformed_timestamp_body_date_time_custom(svc)
|
8905 10137 | }
|
8906 10138 |
|
8907 - | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
10139 + | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
8908 10140 | ///
|
8909 10141 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8910 10142 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8911 10143 | ///
|
8912 10144 | /// # Example
|
8913 10145 | ///
|
8914 10146 | /// ```no_run
|
8915 10147 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
8916 10148 | ///
|
8917 10149 | /// use rest_json_http0x::{input, output, error};
|
8918 10150 | ///
|
8919 - | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
10151 + | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
8920 10152 | /// todo!()
|
8921 10153 | /// }
|
8922 10154 | ///
|
8923 10155 | /// let config = RestJsonConfig::builder().build();
|
8924 10156 | /// let svc = ::tower::util::service_fn(handler);
|
8925 10157 | /// let app = RestJson::builder(config)
|
8926 - | /// .malformed_short_service(svc)
|
10158 + | /// .malformed_timestamp_body_date_time_service(svc)
|
8927 10159 | /// /* Set other handlers */
|
8928 10160 | /// .build()
|
8929 10161 | /// .unwrap();
|
8930 10162 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8931 10163 | /// ```
|
8932 10164 | ///
|
8933 - | pub fn malformed_short_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10165 + | pub fn malformed_timestamp_body_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8934 10166 | where
|
8935 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedShort, ServiceExtractors>,
|
10167 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDateTime, ServiceExtractors>,
|
8936 10168 |
|
8937 10169 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8938 10170 | RestJson<L>,
|
8939 - | crate::operation_shape::MalformedShort,
|
8940 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedShort, S>
|
10171 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10172 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDateTime, S>
|
8941 10173 | >,
|
8942 10174 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8943 10175 | RestJson<L>,
|
8944 - | crate::operation_shape::MalformedShort,
|
10176 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8945 10177 | ModelPl::Output
|
8946 10178 | >,
|
8947 10179 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8948 10180 | RestJson<L>,
|
8949 - | crate::operation_shape::MalformedShort,
|
10181 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8950 10182 | <
|
8951 10183 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8952 10184 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8953 10185 | RestJson<L>,
|
8954 - | crate::operation_shape::MalformedShort,
|
10186 + | crate::operation_shape::MalformedTimestampBodyDateTime,
|
8955 10187 | ModelPl::Output
|
8956 10188 | >
|
8957 10189 | >::Output
|
8958 10190 | >,
|
8959 10191 |
|
8960 10192 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8961 10193 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8962 10194 |
|
8963 10195 | {
|
8964 10196 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8965 10197 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8966 - | let svc = crate::operation_shape::MalformedShort::from_service(service);
|
10198 + | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_service(service);
|
8967 10199 | let svc = self.model_plugin.apply(svc);
|
8968 10200 | let svc =
|
8969 10201 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8970 10202 | .apply(svc);
|
8971 10203 | let svc = self.http_plugin.apply(svc);
|
8972 - | self.malformed_short_custom(svc)
|
10204 + | self.malformed_timestamp_body_date_time_custom(svc)
|
8973 10205 | }
|
8974 10206 |
|
8975 - | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) to a custom [`Service`](tower::Service).
|
10207 + | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) to a custom [`Service`](tower::Service).
|
8976 10208 | /// not constrained by the Smithy contract.
|
8977 - | fn malformed_short_custom<S>(mut self, svc: S) -> Self
|
10209 + | fn malformed_timestamp_body_date_time_custom<S>(mut self, svc: S) -> Self
|
8978 10210 | where
|
8979 10211 | S: ::tower::Service<
|
8980 10212 | ::http::Request<Body>,
|
8981 10213 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8982 10214 | Error = ::std::convert::Infallible,
|
8983 10215 | > + Clone
|
8984 10216 | + Send
|
8985 10217 | + 'static,
|
8986 10218 | S::Future: Send + 'static,
|
8987 10219 | {
|
8988 - | self.malformed_short = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10220 + | self.malformed_timestamp_body_date_time =
|
10221 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8989 10222 | self
|
8990 10223 | }
|
8991 10224 |
|
8992 - | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
10225 + | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
8993 10226 | ///
|
8994 10227 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8995 10228 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8996 10229 | ///
|
8997 10230 | /// # Example
|
8998 10231 | ///
|
8999 10232 | /// ```no_run
|
9000 10233 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9001 10234 | ///
|
9002 10235 | /// use rest_json_http0x::{input, output, error};
|
9003 10236 | ///
|
9004 - | /// async fn handler(input: input::MalformedStringInput) -> output::MalformedStringOutput {
|
10237 + | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
9005 10238 | /// todo!()
|
9006 10239 | /// }
|
9007 10240 | ///
|
9008 10241 | /// let config = RestJsonConfig::builder().build();
|
9009 10242 | /// let app = RestJson::builder(config)
|
9010 - | /// .malformed_string(handler)
|
10243 + | /// .malformed_timestamp_body_default(handler)
|
9011 10244 | /// /* Set other handlers */
|
9012 10245 | /// .build()
|
9013 10246 | /// .unwrap();
|
9014 10247 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9015 10248 | /// ```
|
9016 10249 | ///
|
9017 - | pub fn malformed_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10250 + | pub fn malformed_timestamp_body_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9018 10251 | where
|
9019 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedString, HandlerExtractors>,
|
10252 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDefault, HandlerExtractors>,
|
9020 10253 |
|
9021 10254 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9022 10255 | RestJson<L>,
|
9023 - | crate::operation_shape::MalformedString,
|
9024 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedString, HandlerType>
|
10256 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
10257 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDefault, HandlerType>
|
9025 10258 | >,
|
9026 10259 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9027 10260 | RestJson<L>,
|
9028 - | crate::operation_shape::MalformedString,
|
10261 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9029 10262 | ModelPl::Output
|
9030 10263 | >,
|
9031 10264 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9032 10265 | RestJson<L>,
|
9033 - | crate::operation_shape::MalformedString,
|
10266 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9034 10267 | <
|
9035 10268 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9036 10269 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9037 10270 | RestJson<L>,
|
9038 - | crate::operation_shape::MalformedString,
|
10271 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9039 10272 | ModelPl::Output
|
9040 10273 | >
|
9041 10274 | >::Output
|
9042 10275 | >,
|
9043 10276 |
|
9044 10277 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9045 10278 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9046 10279 |
|
9047 10280 | {
|
9048 10281 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9049 10282 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9050 - | let svc = crate::operation_shape::MalformedString::from_handler(handler);
|
10283 + | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_handler(handler);
|
9051 10284 | let svc = self.model_plugin.apply(svc);
|
9052 10285 | let svc =
|
9053 10286 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9054 10287 | .apply(svc);
|
9055 10288 | let svc = self.http_plugin.apply(svc);
|
9056 - | self.malformed_string_custom(svc)
|
10289 + | self.malformed_timestamp_body_default_custom(svc)
|
9057 10290 | }
|
9058 10291 |
|
9059 - | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
10292 + | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
9060 10293 | ///
|
9061 10294 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9062 10295 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9063 10296 | ///
|
9064 10297 | /// # Example
|
9065 10298 | ///
|
9066 10299 | /// ```no_run
|
9067 10300 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9068 10301 | ///
|
9069 10302 | /// use rest_json_http0x::{input, output, error};
|
9070 10303 | ///
|
9071 - | /// async fn handler(input: input::MalformedStringInput) -> Result<output::MalformedStringOutput, std::convert::Infallible> {
|
10304 + | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
9072 10305 | /// todo!()
|
9073 10306 | /// }
|
9074 10307 | ///
|
9075 10308 | /// let config = RestJsonConfig::builder().build();
|
9076 10309 | /// let svc = ::tower::util::service_fn(handler);
|
9077 10310 | /// let app = RestJson::builder(config)
|
9078 - | /// .malformed_string_service(svc)
|
10311 + | /// .malformed_timestamp_body_default_service(svc)
|
9079 10312 | /// /* Set other handlers */
|
9080 10313 | /// .build()
|
9081 10314 | /// .unwrap();
|
9082 10315 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9083 10316 | /// ```
|
9084 10317 | ///
|
9085 - | pub fn malformed_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10318 + | pub fn malformed_timestamp_body_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9086 10319 | where
|
9087 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedString, ServiceExtractors>,
|
10320 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDefault, ServiceExtractors>,
|
9088 10321 |
|
9089 10322 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9090 10323 | RestJson<L>,
|
9091 - | crate::operation_shape::MalformedString,
|
9092 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedString, S>
|
10324 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
10325 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDefault, S>
|
9093 10326 | >,
|
9094 10327 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9095 10328 | RestJson<L>,
|
9096 - | crate::operation_shape::MalformedString,
|
10329 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9097 10330 | ModelPl::Output
|
9098 10331 | >,
|
9099 10332 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9100 10333 | RestJson<L>,
|
9101 - | crate::operation_shape::MalformedString,
|
10334 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9102 10335 | <
|
9103 10336 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9104 10337 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9105 10338 | RestJson<L>,
|
9106 - | crate::operation_shape::MalformedString,
|
10339 + | crate::operation_shape::MalformedTimestampBodyDefault,
|
9107 10340 | ModelPl::Output
|
9108 10341 | >
|
9109 10342 | >::Output
|
9110 10343 | >,
|
9111 10344 |
|
9112 10345 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9113 10346 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9114 10347 |
|
9115 10348 | {
|
9116 10349 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9117 10350 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9118 - | let svc = crate::operation_shape::MalformedString::from_service(service);
|
10351 + | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_service(service);
|
9119 10352 | let svc = self.model_plugin.apply(svc);
|
9120 10353 | let svc =
|
9121 10354 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9122 10355 | .apply(svc);
|
9123 10356 | let svc = self.http_plugin.apply(svc);
|
9124 - | self.malformed_string_custom(svc)
|
10357 + | self.malformed_timestamp_body_default_custom(svc)
|
9125 10358 | }
|
9126 10359 |
|
9127 - | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) to a custom [`Service`](tower::Service).
|
10360 + | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) to a custom [`Service`](tower::Service).
|
9128 10361 | /// not constrained by the Smithy contract.
|
9129 - | fn malformed_string_custom<S>(mut self, svc: S) -> Self
|
10362 + | fn malformed_timestamp_body_default_custom<S>(mut self, svc: S) -> Self
|
9130 10363 | where
|
9131 10364 | S: ::tower::Service<
|
9132 10365 | ::http::Request<Body>,
|
9133 10366 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9134 10367 | Error = ::std::convert::Infallible,
|
9135 10368 | > + Clone
|
9136 10369 | + Send
|
9137 10370 | + 'static,
|
9138 10371 | S::Future: Send + 'static,
|
9139 10372 | {
|
9140 - | self.malformed_string = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10373 + | self.malformed_timestamp_body_default =
|
10374 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9141 10375 | self
|
9142 10376 | }
|
9143 10377 |
|
9144 - | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
10378 + | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
9145 10379 | ///
|
9146 10380 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9147 10381 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9148 10382 | ///
|
9149 10383 | /// # Example
|
9150 10384 | ///
|
9151 10385 | /// ```no_run
|
9152 10386 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9153 10387 | ///
|
9154 10388 | /// use rest_json_http0x::{input, output, error};
|
9155 10389 | ///
|
9156 - | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
10390 + | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
9157 10391 | /// todo!()
|
9158 10392 | /// }
|
9159 10393 | ///
|
9160 10394 | /// let config = RestJsonConfig::builder().build();
|
9161 10395 | /// let app = RestJson::builder(config)
|
9162 - | /// .malformed_timestamp_body_date_time(handler)
|
10396 + | /// .malformed_timestamp_body_http_date(handler)
|
9163 10397 | /// /* Set other handlers */
|
9164 10398 | /// .build()
|
9165 10399 | /// .unwrap();
|
9166 10400 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9167 10401 | /// ```
|
9168 10402 | ///
|
9169 - | pub fn malformed_timestamp_body_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10403 + | pub fn malformed_timestamp_body_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9170 10404 | where
|
9171 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerExtractors>,
|
10405 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerExtractors>,
|
9172 10406 |
|
9173 10407 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9174 10408 | RestJson<L>,
|
9175 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9176 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerType>
|
10409 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10410 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerType>
|
9177 10411 | >,
|
9178 10412 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9179 10413 | RestJson<L>,
|
9180 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10414 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9181 10415 | ModelPl::Output
|
9182 10416 | >,
|
9183 10417 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9184 10418 | RestJson<L>,
|
9185 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10419 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9186 10420 | <
|
9187 10421 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9188 10422 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9189 10423 | RestJson<L>,
|
9190 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10424 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9191 10425 | ModelPl::Output
|
9192 10426 | >
|
9193 10427 | >::Output
|
9194 10428 | >,
|
9195 10429 |
|
9196 10430 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9197 10431 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9198 10432 |
|
9199 10433 | {
|
9200 10434 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9201 10435 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9202 - | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_handler(handler);
|
10436 + | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_handler(handler);
|
9203 10437 | let svc = self.model_plugin.apply(svc);
|
9204 10438 | let svc =
|
9205 10439 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9206 10440 | .apply(svc);
|
9207 10441 | let svc = self.http_plugin.apply(svc);
|
9208 - | self.malformed_timestamp_body_date_time_custom(svc)
|
10442 + | self.malformed_timestamp_body_http_date_custom(svc)
|
9209 10443 | }
|
9210 10444 |
|
9211 - | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
10445 + | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
9212 10446 | ///
|
9213 10447 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9214 10448 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9215 10449 | ///
|
9216 10450 | /// # Example
|
9217 10451 | ///
|
9218 10452 | /// ```no_run
|
9219 10453 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9220 10454 | ///
|
9221 10455 | /// use rest_json_http0x::{input, output, error};
|
9222 10456 | ///
|
9223 - | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
10457 + | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
9224 10458 | /// todo!()
|
9225 10459 | /// }
|
9226 10460 | ///
|
9227 10461 | /// let config = RestJsonConfig::builder().build();
|
9228 10462 | /// let svc = ::tower::util::service_fn(handler);
|
9229 10463 | /// let app = RestJson::builder(config)
|
9230 - | /// .malformed_timestamp_body_date_time_service(svc)
|
10464 + | /// .malformed_timestamp_body_http_date_service(svc)
|
9231 10465 | /// /* Set other handlers */
|
9232 10466 | /// .build()
|
9233 10467 | /// .unwrap();
|
9234 10468 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9235 10469 | /// ```
|
9236 10470 | ///
|
9237 - | pub fn malformed_timestamp_body_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10471 + | pub fn malformed_timestamp_body_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9238 10472 | where
|
9239 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDateTime, ServiceExtractors>,
|
10473 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyHttpDate, ServiceExtractors>,
|
9240 10474 |
|
9241 10475 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9242 10476 | RestJson<L>,
|
9243 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9244 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDateTime, S>
|
10477 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10478 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyHttpDate, S>
|
9245 10479 | >,
|
9246 10480 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9247 10481 | RestJson<L>,
|
9248 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10482 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9249 10483 | ModelPl::Output
|
9250 10484 | >,
|
9251 10485 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9252 10486 | RestJson<L>,
|
9253 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10487 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9254 10488 | <
|
9255 10489 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9256 10490 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9257 10491 | RestJson<L>,
|
9258 - | crate::operation_shape::MalformedTimestampBodyDateTime,
|
10492 + | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9259 10493 | ModelPl::Output
|
9260 10494 | >
|
9261 10495 | >::Output
|
9262 10496 | >,
|
9263 10497 |
|
9264 10498 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9265 10499 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9266 10500 |
|
9267 10501 | {
|
9268 10502 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9269 10503 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9270 - | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_service(service);
|
10504 + | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_service(service);
|
9271 10505 | let svc = self.model_plugin.apply(svc);
|
9272 10506 | let svc =
|
9273 10507 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9274 10508 | .apply(svc);
|
9275 10509 | let svc = self.http_plugin.apply(svc);
|
9276 - | self.malformed_timestamp_body_date_time_custom(svc)
|
10510 + | self.malformed_timestamp_body_http_date_custom(svc)
|
9277 10511 | }
|
9278 10512 |
|
9279 - | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) to a custom [`Service`](tower::Service).
|
10513 + | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) to a custom [`Service`](tower::Service).
|
9280 10514 | /// not constrained by the Smithy contract.
|
9281 - | fn malformed_timestamp_body_date_time_custom<S>(mut self, svc: S) -> Self
|
10515 + | fn malformed_timestamp_body_http_date_custom<S>(mut self, svc: S) -> Self
|
9282 10516 | where
|
9283 10517 | S: ::tower::Service<
|
9284 10518 | ::http::Request<Body>,
|
9285 10519 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9286 10520 | Error = ::std::convert::Infallible,
|
9287 10521 | > + Clone
|
9288 10522 | + Send
|
9289 10523 | + 'static,
|
9290 10524 | S::Future: Send + 'static,
|
9291 10525 | {
|
9292 - | self.malformed_timestamp_body_date_time =
|
10526 + | self.malformed_timestamp_body_http_date =
|
9293 10527 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9294 10528 | self
|
9295 10529 | }
|
9296 10530 |
|
9297 - | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
10531 + | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
9298 10532 | ///
|
9299 10533 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9300 10534 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9301 10535 | ///
|
9302 10536 | /// # Example
|
9303 10537 | ///
|
9304 10538 | /// ```no_run
|
9305 10539 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9306 10540 | ///
|
9307 10541 | /// use rest_json_http0x::{input, output, error};
|
9308 10542 | ///
|
9309 - | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
10543 + | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
9310 10544 | /// todo!()
|
9311 10545 | /// }
|
9312 10546 | ///
|
9313 10547 | /// let config = RestJsonConfig::builder().build();
|
9314 10548 | /// let app = RestJson::builder(config)
|
9315 - | /// .malformed_timestamp_body_default(handler)
|
10549 + | /// .malformed_timestamp_header_date_time(handler)
|
9316 10550 | /// /* Set other handlers */
|
9317 10551 | /// .build()
|
9318 10552 | /// .unwrap();
|
9319 10553 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9320 10554 | /// ```
|
9321 10555 | ///
|
9322 - | pub fn malformed_timestamp_body_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10556 + | pub fn malformed_timestamp_header_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9323 10557 | where
|
9324 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDefault, HandlerExtractors>,
|
10558 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerExtractors>,
|
9325 10559 |
|
9326 10560 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9327 10561 | RestJson<L>,
|
9328 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
9329 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDefault, HandlerType>
|
10562 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10563 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerType>
|
9330 10564 | >,
|
9331 10565 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9332 10566 | RestJson<L>,
|
9333 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10567 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9334 10568 | ModelPl::Output
|
9335 10569 | >,
|
9336 10570 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9337 10571 | RestJson<L>,
|
9338 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10572 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9339 10573 | <
|
9340 10574 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9341 10575 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9342 10576 | RestJson<L>,
|
9343 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10577 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9344 10578 | ModelPl::Output
|
9345 10579 | >
|
9346 10580 | >::Output
|
9347 10581 | >,
|
9348 10582 |
|
9349 10583 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9350 10584 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9351 10585 |
|
9352 10586 | {
|
9353 10587 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9354 10588 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9355 - | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_handler(handler);
|
10589 + | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_handler(handler);
|
9356 10590 | let svc = self.model_plugin.apply(svc);
|
9357 10591 | let svc =
|
9358 10592 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9359 10593 | .apply(svc);
|
9360 10594 | let svc = self.http_plugin.apply(svc);
|
9361 - | self.malformed_timestamp_body_default_custom(svc)
|
10595 + | self.malformed_timestamp_header_date_time_custom(svc)
|
9362 10596 | }
|
9363 10597 |
|
9364 - | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
10598 + | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
9365 10599 | ///
|
9366 10600 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9367 10601 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9368 10602 | ///
|
9369 10603 | /// # Example
|
9370 10604 | ///
|
9371 10605 | /// ```no_run
|
9372 10606 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9373 10607 | ///
|
9374 10608 | /// use rest_json_http0x::{input, output, error};
|
9375 10609 | ///
|
9376 - | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
10610 + | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
9377 10611 | /// todo!()
|
9378 10612 | /// }
|
9379 10613 | ///
|
9380 10614 | /// let config = RestJsonConfig::builder().build();
|
9381 10615 | /// let svc = ::tower::util::service_fn(handler);
|
9382 10616 | /// let app = RestJson::builder(config)
|
9383 - | /// .malformed_timestamp_body_default_service(svc)
|
10617 + | /// .malformed_timestamp_header_date_time_service(svc)
|
9384 10618 | /// /* Set other handlers */
|
9385 10619 | /// .build()
|
9386 10620 | /// .unwrap();
|
9387 10621 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9388 10622 | /// ```
|
9389 10623 | ///
|
9390 - | pub fn malformed_timestamp_body_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10624 + | pub fn malformed_timestamp_header_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9391 10625 | where
|
9392 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDefault, ServiceExtractors>,
|
10626 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDateTime, ServiceExtractors>,
|
9393 10627 |
|
9394 10628 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9395 10629 | RestJson<L>,
|
9396 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
9397 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDefault, S>
|
10630 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10631 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDateTime, S>
|
9398 10632 | >,
|
9399 10633 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9400 10634 | RestJson<L>,
|
9401 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10635 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9402 10636 | ModelPl::Output
|
9403 10637 | >,
|
9404 10638 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9405 10639 | RestJson<L>,
|
9406 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10640 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9407 10641 | <
|
9408 10642 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9409 10643 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9410 10644 | RestJson<L>,
|
9411 - | crate::operation_shape::MalformedTimestampBodyDefault,
|
10645 + | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9412 10646 | ModelPl::Output
|
9413 10647 | >
|
9414 10648 | >::Output
|
9415 10649 | >,
|
9416 10650 |
|
9417 10651 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9418 10652 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9419 10653 |
|
9420 10654 | {
|
9421 10655 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9422 10656 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9423 - | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_service(service);
|
10657 + | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_service(service);
|
9424 10658 | let svc = self.model_plugin.apply(svc);
|
9425 10659 | let svc =
|
9426 10660 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9427 10661 | .apply(svc);
|
9428 10662 | let svc = self.http_plugin.apply(svc);
|
9429 - | self.malformed_timestamp_body_default_custom(svc)
|
10663 + | self.malformed_timestamp_header_date_time_custom(svc)
|
9430 10664 | }
|
9431 10665 |
|
9432 - | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) to a custom [`Service`](tower::Service).
|
10666 + | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) to a custom [`Service`](tower::Service).
|
9433 10667 | /// not constrained by the Smithy contract.
|
9434 - | fn malformed_timestamp_body_default_custom<S>(mut self, svc: S) -> Self
|
10668 + | fn malformed_timestamp_header_date_time_custom<S>(mut self, svc: S) -> Self
|
9435 10669 | where
|
9436 10670 | S: ::tower::Service<
|
9437 10671 | ::http::Request<Body>,
|
9438 10672 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9439 10673 | Error = ::std::convert::Infallible,
|
9440 10674 | > + Clone
|
9441 10675 | + Send
|
9442 10676 | + 'static,
|
9443 10677 | S::Future: Send + 'static,
|
9444 10678 | {
|
9445 - | self.malformed_timestamp_body_default =
|
10679 + | self.malformed_timestamp_header_date_time =
|
9446 10680 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9447 10681 | self
|
9448 10682 | }
|
9449 10683 |
|
9450 - | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
10684 + | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
9451 10685 | ///
|
9452 10686 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9453 10687 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9454 10688 | ///
|
9455 10689 | /// # Example
|
9456 10690 | ///
|
9457 10691 | /// ```no_run
|
9458 10692 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9459 10693 | ///
|
9460 10694 | /// use rest_json_http0x::{input, output, error};
|
9461 10695 | ///
|
9462 - | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
10696 + | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
9463 10697 | /// todo!()
|
9464 10698 | /// }
|
9465 10699 | ///
|
9466 10700 | /// let config = RestJsonConfig::builder().build();
|
9467 10701 | /// let app = RestJson::builder(config)
|
9468 - | /// .malformed_timestamp_body_http_date(handler)
|
10702 + | /// .malformed_timestamp_header_default(handler)
|
9469 10703 | /// /* Set other handlers */
|
9470 10704 | /// .build()
|
9471 10705 | /// .unwrap();
|
9472 10706 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9473 10707 | /// ```
|
9474 10708 | ///
|
9475 - | pub fn malformed_timestamp_body_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10709 + | pub fn malformed_timestamp_header_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9476 10710 | where
|
9477 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerExtractors>,
|
10711 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerExtractors>,
|
9478 10712 |
|
9479 10713 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9480 10714 | RestJson<L>,
|
9481 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9482 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerType>
|
10715 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
10716 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerType>
|
9483 10717 | >,
|
9484 10718 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9485 10719 | RestJson<L>,
|
9486 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10720 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9487 10721 | ModelPl::Output
|
9488 10722 | >,
|
9489 10723 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9490 10724 | RestJson<L>,
|
9491 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10725 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9492 10726 | <
|
9493 10727 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9494 10728 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9495 10729 | RestJson<L>,
|
9496 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10730 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9497 10731 | ModelPl::Output
|
9498 10732 | >
|
9499 10733 | >::Output
|
9500 10734 | >,
|
9501 10735 |
|
9502 10736 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9503 10737 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9504 10738 |
|
9505 10739 | {
|
9506 10740 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9507 10741 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9508 - | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_handler(handler);
|
10742 + | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_handler(handler);
|
9509 10743 | let svc = self.model_plugin.apply(svc);
|
9510 10744 | let svc =
|
9511 10745 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9512 10746 | .apply(svc);
|
9513 10747 | let svc = self.http_plugin.apply(svc);
|
9514 - | self.malformed_timestamp_body_http_date_custom(svc)
|
10748 + | self.malformed_timestamp_header_default_custom(svc)
|
9515 10749 | }
|
9516 10750 |
|
9517 - | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
10751 + | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
9518 10752 | ///
|
9519 10753 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9520 10754 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9521 10755 | ///
|
9522 10756 | /// # Example
|
9523 10757 | ///
|
9524 10758 | /// ```no_run
|
9525 10759 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9526 10760 | ///
|
9527 10761 | /// use rest_json_http0x::{input, output, error};
|
9528 10762 | ///
|
9529 - | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
10763 + | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
9530 10764 | /// todo!()
|
9531 10765 | /// }
|
9532 10766 | ///
|
9533 10767 | /// let config = RestJsonConfig::builder().build();
|
9534 10768 | /// let svc = ::tower::util::service_fn(handler);
|
9535 10769 | /// let app = RestJson::builder(config)
|
9536 - | /// .malformed_timestamp_body_http_date_service(svc)
|
10770 + | /// .malformed_timestamp_header_default_service(svc)
|
9537 10771 | /// /* Set other handlers */
|
9538 10772 | /// .build()
|
9539 10773 | /// .unwrap();
|
9540 10774 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9541 10775 | /// ```
|
9542 10776 | ///
|
9543 - | pub fn malformed_timestamp_body_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10777 + | pub fn malformed_timestamp_header_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9544 10778 | where
|
9545 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyHttpDate, ServiceExtractors>,
|
10779 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDefault, ServiceExtractors>,
|
9546 10780 |
|
9547 10781 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9548 10782 | RestJson<L>,
|
9549 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9550 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyHttpDate, S>
|
10783 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
10784 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDefault, S>
|
9551 10785 | >,
|
9552 10786 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9553 10787 | RestJson<L>,
|
9554 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10788 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9555 10789 | ModelPl::Output
|
9556 10790 | >,
|
9557 10791 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9558 10792 | RestJson<L>,
|
9559 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10793 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9560 10794 | <
|
9561 10795 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9562 10796 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9563 10797 | RestJson<L>,
|
9564 - | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
10798 + | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9565 10799 | ModelPl::Output
|
9566 10800 | >
|
9567 10801 | >::Output
|
9568 10802 | >,
|
9569 10803 |
|
9570 10804 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9571 10805 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9572 10806 |
|
9573 10807 | {
|
9574 10808 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9575 10809 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9576 - | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_service(service);
|
10810 + | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_service(service);
|
9577 10811 | let svc = self.model_plugin.apply(svc);
|
9578 10812 | let svc =
|
9579 10813 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9580 10814 | .apply(svc);
|
9581 10815 | let svc = self.http_plugin.apply(svc);
|
9582 - | self.malformed_timestamp_body_http_date_custom(svc)
|
10816 + | self.malformed_timestamp_header_default_custom(svc)
|
9583 10817 | }
|
9584 10818 |
|
9585 - | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) to a custom [`Service`](tower::Service).
|
10819 + | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) to a custom [`Service`](tower::Service).
|
9586 10820 | /// not constrained by the Smithy contract.
|
9587 - | fn malformed_timestamp_body_http_date_custom<S>(mut self, svc: S) -> Self
|
10821 + | fn malformed_timestamp_header_default_custom<S>(mut self, svc: S) -> Self
|
9588 10822 | where
|
9589 10823 | S: ::tower::Service<
|
9590 10824 | ::http::Request<Body>,
|
9591 10825 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9592 10826 | Error = ::std::convert::Infallible,
|
9593 10827 | > + Clone
|
9594 10828 | + Send
|
9595 10829 | + 'static,
|
9596 10830 | S::Future: Send + 'static,
|
9597 10831 | {
|
9598 - | self.malformed_timestamp_body_http_date =
|
10832 + | self.malformed_timestamp_header_default =
|
9599 10833 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9600 10834 | self
|
9601 10835 | }
|
9602 10836 |
|
9603 - | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
10837 + | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
9604 10838 | ///
|
9605 10839 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9606 10840 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9607 10841 | ///
|
9608 10842 | /// # Example
|
9609 10843 | ///
|
9610 10844 | /// ```no_run
|
9611 10845 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9612 10846 | ///
|
9613 10847 | /// use rest_json_http0x::{input, output, error};
|
9614 10848 | ///
|
9615 - | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
10849 + | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
9616 10850 | /// todo!()
|
9617 10851 | /// }
|
9618 10852 | ///
|
9619 10853 | /// let config = RestJsonConfig::builder().build();
|
9620 10854 | /// let app = RestJson::builder(config)
|
9621 - | /// .malformed_timestamp_header_date_time(handler)
|
10855 + | /// .malformed_timestamp_header_epoch(handler)
|
9622 10856 | /// /* Set other handlers */
|
9623 10857 | /// .build()
|
9624 10858 | /// .unwrap();
|
9625 10859 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9626 10860 | /// ```
|
9627 10861 | ///
|
9628 - | pub fn malformed_timestamp_header_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10862 + | pub fn malformed_timestamp_header_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9629 10863 | where
|
9630 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerExtractors>,
|
10864 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerExtractors>,
|
9631 10865 |
|
9632 10866 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9633 10867 | RestJson<L>,
|
9634 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9635 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerType>
|
10868 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
10869 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerType>
|
9636 10870 | >,
|
9637 10871 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9638 10872 | RestJson<L>,
|
9639 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10873 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9640 10874 | ModelPl::Output
|
9641 10875 | >,
|
9642 10876 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9643 10877 | RestJson<L>,
|
9644 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10878 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9645 10879 | <
|
9646 10880 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9647 10881 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9648 10882 | RestJson<L>,
|
9649 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10883 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9650 10884 | ModelPl::Output
|
9651 10885 | >
|
9652 10886 | >::Output
|
9653 10887 | >,
|
9654 10888 |
|
9655 10889 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9656 10890 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9657 10891 |
|
9658 10892 | {
|
9659 10893 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9660 10894 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9661 - | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_handler(handler);
|
10895 + | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_handler(handler);
|
9662 10896 | let svc = self.model_plugin.apply(svc);
|
9663 10897 | let svc =
|
9664 10898 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9665 10899 | .apply(svc);
|
9666 10900 | let svc = self.http_plugin.apply(svc);
|
9667 - | self.malformed_timestamp_header_date_time_custom(svc)
|
10901 + | self.malformed_timestamp_header_epoch_custom(svc)
|
9668 10902 | }
|
9669 10903 |
|
9670 - | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
10904 + | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
9671 10905 | ///
|
9672 10906 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9673 10907 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9674 10908 | ///
|
9675 10909 | /// # Example
|
9676 10910 | ///
|
9677 10911 | /// ```no_run
|
9678 10912 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9679 10913 | ///
|
9680 10914 | /// use rest_json_http0x::{input, output, error};
|
9681 10915 | ///
|
9682 - | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
10916 + | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
9683 10917 | /// todo!()
|
9684 10918 | /// }
|
9685 10919 | ///
|
9686 10920 | /// let config = RestJsonConfig::builder().build();
|
9687 10921 | /// let svc = ::tower::util::service_fn(handler);
|
9688 10922 | /// let app = RestJson::builder(config)
|
9689 - | /// .malformed_timestamp_header_date_time_service(svc)
|
10923 + | /// .malformed_timestamp_header_epoch_service(svc)
|
9690 10924 | /// /* Set other handlers */
|
9691 10925 | /// .build()
|
9692 10926 | /// .unwrap();
|
9693 10927 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9694 10928 | /// ```
|
9695 10929 | ///
|
9696 - | pub fn malformed_timestamp_header_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10930 + | pub fn malformed_timestamp_header_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9697 10931 | where
|
9698 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDateTime, ServiceExtractors>,
|
10932 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderEpoch, ServiceExtractors>,
|
9699 10933 |
|
9700 10934 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9701 10935 | RestJson<L>,
|
9702 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9703 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDateTime, S>
|
10936 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
10937 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderEpoch, S>
|
9704 10938 | >,
|
9705 10939 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9706 10940 | RestJson<L>,
|
9707 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10941 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9708 10942 | ModelPl::Output
|
9709 10943 | >,
|
9710 10944 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9711 10945 | RestJson<L>,
|
9712 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10946 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9713 10947 | <
|
9714 10948 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9715 10949 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9716 10950 | RestJson<L>,
|
9717 - | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
10951 + | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9718 10952 | ModelPl::Output
|
9719 10953 | >
|
9720 10954 | >::Output
|
9721 10955 | >,
|
9722 10956 |
|
9723 10957 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9724 10958 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9725 10959 |
|
9726 10960 | {
|
9727 10961 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9728 10962 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9729 - | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_service(service);
|
10963 + | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_service(service);
|
9730 10964 | let svc = self.model_plugin.apply(svc);
|
9731 10965 | let svc =
|
9732 10966 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9733 10967 | .apply(svc);
|
9734 10968 | let svc = self.http_plugin.apply(svc);
|
9735 - | self.malformed_timestamp_header_date_time_custom(svc)
|
10969 + | self.malformed_timestamp_header_epoch_custom(svc)
|
9736 10970 | }
|
9737 10971 |
|
9738 - | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) to a custom [`Service`](tower::Service).
|
10972 + | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) to a custom [`Service`](tower::Service).
|
9739 10973 | /// not constrained by the Smithy contract.
|
9740 - | fn malformed_timestamp_header_date_time_custom<S>(mut self, svc: S) -> Self
|
10974 + | fn malformed_timestamp_header_epoch_custom<S>(mut self, svc: S) -> Self
|
9741 10975 | where
|
9742 10976 | S: ::tower::Service<
|
9743 10977 | ::http::Request<Body>,
|
9744 10978 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9745 10979 | Error = ::std::convert::Infallible,
|
9746 10980 | > + Clone
|
9747 10981 | + Send
|
9748 10982 | + 'static,
|
9749 10983 | S::Future: Send + 'static,
|
9750 10984 | {
|
9751 - | self.malformed_timestamp_header_date_time =
|
10985 + | self.malformed_timestamp_header_epoch =
|
9752 10986 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9753 10987 | self
|
9754 10988 | }
|
9755 10989 |
|
9756 - | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
10990 + | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
9757 10991 | ///
|
9758 10992 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9759 10993 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9760 10994 | ///
|
9761 10995 | /// # Example
|
9762 10996 | ///
|
9763 10997 | /// ```no_run
|
9764 10998 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9765 10999 | ///
|
9766 11000 | /// use rest_json_http0x::{input, output, error};
|
9767 11001 | ///
|
9768 - | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
11002 + | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
9769 11003 | /// todo!()
|
9770 11004 | /// }
|
9771 11005 | ///
|
9772 11006 | /// let config = RestJsonConfig::builder().build();
|
9773 11007 | /// let app = RestJson::builder(config)
|
9774 - | /// .malformed_timestamp_header_default(handler)
|
11008 + | /// .malformed_timestamp_path_default(handler)
|
9775 11009 | /// /* Set other handlers */
|
9776 11010 | /// .build()
|
9777 11011 | /// .unwrap();
|
9778 11012 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9779 11013 | /// ```
|
9780 11014 | ///
|
9781 - | pub fn malformed_timestamp_header_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11015 + | pub fn malformed_timestamp_path_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9782 11016 | where
|
9783 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerExtractors>,
|
11017 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathDefault, HandlerExtractors>,
|
9784 11018 |
|
9785 11019 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9786 11020 | RestJson<L>,
|
9787 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9788 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerType>
|
11021 + | crate::operation_shape::MalformedTimestampPathDefault,
|
11022 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathDefault, HandlerType>
|
9789 11023 | >,
|
9790 11024 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9791 11025 | RestJson<L>,
|
9792 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11026 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9793 11027 | ModelPl::Output
|
9794 11028 | >,
|
9795 11029 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9796 11030 | RestJson<L>,
|
9797 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11031 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9798 11032 | <
|
9799 11033 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9800 11034 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9801 11035 | RestJson<L>,
|
9802 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11036 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9803 11037 | ModelPl::Output
|
9804 11038 | >
|
9805 11039 | >::Output
|
9806 11040 | >,
|
9807 11041 |
|
9808 11042 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9809 11043 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9810 11044 |
|
9811 11045 | {
|
9812 11046 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9813 11047 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9814 - | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_handler(handler);
|
11048 + | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_handler(handler);
|
9815 11049 | let svc = self.model_plugin.apply(svc);
|
9816 11050 | let svc =
|
9817 11051 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9818 11052 | .apply(svc);
|
9819 11053 | let svc = self.http_plugin.apply(svc);
|
9820 - | self.malformed_timestamp_header_default_custom(svc)
|
11054 + | self.malformed_timestamp_path_default_custom(svc)
|
9821 11055 | }
|
9822 11056 |
|
9823 - | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
11057 + | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
9824 11058 | ///
|
9825 11059 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9826 11060 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9827 11061 | ///
|
9828 11062 | /// # Example
|
9829 11063 | ///
|
9830 11064 | /// ```no_run
|
9831 11065 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9832 11066 | ///
|
9833 11067 | /// use rest_json_http0x::{input, output, error};
|
9834 11068 | ///
|
9835 - | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
11069 + | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
9836 11070 | /// todo!()
|
9837 11071 | /// }
|
9838 11072 | ///
|
9839 11073 | /// let config = RestJsonConfig::builder().build();
|
9840 11074 | /// let svc = ::tower::util::service_fn(handler);
|
9841 11075 | /// let app = RestJson::builder(config)
|
9842 - | /// .malformed_timestamp_header_default_service(svc)
|
11076 + | /// .malformed_timestamp_path_default_service(svc)
|
9843 11077 | /// /* Set other handlers */
|
9844 11078 | /// .build()
|
9845 11079 | /// .unwrap();
|
9846 11080 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9847 11081 | /// ```
|
9848 11082 | ///
|
9849 - | pub fn malformed_timestamp_header_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11083 + | pub fn malformed_timestamp_path_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9850 11084 | where
|
9851 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDefault, ServiceExtractors>,
|
11085 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathDefault, ServiceExtractors>,
|
9852 11086 |
|
9853 11087 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9854 11088 | RestJson<L>,
|
9855 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9856 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDefault, S>
|
11089 + | crate::operation_shape::MalformedTimestampPathDefault,
|
11090 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathDefault, S>
|
9857 11091 | >,
|
9858 11092 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9859 11093 | RestJson<L>,
|
9860 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11094 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9861 11095 | ModelPl::Output
|
9862 11096 | >,
|
9863 11097 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9864 11098 | RestJson<L>,
|
9865 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11099 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9866 11100 | <
|
9867 11101 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9868 11102 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9869 11103 | RestJson<L>,
|
9870 - | crate::operation_shape::MalformedTimestampHeaderDefault,
|
11104 + | crate::operation_shape::MalformedTimestampPathDefault,
|
9871 11105 | ModelPl::Output
|
9872 11106 | >
|
9873 11107 | >::Output
|
9874 11108 | >,
|
9875 11109 |
|
9876 11110 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9877 11111 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9878 11112 |
|
9879 11113 | {
|
9880 11114 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9881 11115 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9882 - | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_service(service);
|
11116 + | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_service(service);
|
9883 11117 | let svc = self.model_plugin.apply(svc);
|
9884 11118 | let svc =
|
9885 11119 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9886 11120 | .apply(svc);
|
9887 11121 | let svc = self.http_plugin.apply(svc);
|
9888 - | self.malformed_timestamp_header_default_custom(svc)
|
11122 + | self.malformed_timestamp_path_default_custom(svc)
|
9889 11123 | }
|
9890 11124 |
|
9891 - | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) to a custom [`Service`](tower::Service).
|
11125 + | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) to a custom [`Service`](tower::Service).
|
9892 11126 | /// not constrained by the Smithy contract.
|
9893 - | fn malformed_timestamp_header_default_custom<S>(mut self, svc: S) -> Self
|
11127 + | fn malformed_timestamp_path_default_custom<S>(mut self, svc: S) -> Self
|
9894 11128 | where
|
9895 11129 | S: ::tower::Service<
|
9896 11130 | ::http::Request<Body>,
|
9897 11131 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9898 11132 | Error = ::std::convert::Infallible,
|
9899 11133 | > + Clone
|
9900 11134 | + Send
|
9901 11135 | + 'static,
|
9902 11136 | S::Future: Send + 'static,
|
9903 11137 | {
|
9904 - | self.malformed_timestamp_header_default =
|
11138 + | self.malformed_timestamp_path_default =
|
9905 11139 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9906 11140 | self
|
9907 11141 | }
|
9908 11142 |
|
9909 - | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
11143 + | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
9910 11144 | ///
|
9911 11145 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9912 11146 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9913 11147 | ///
|
9914 11148 | /// # Example
|
9915 11149 | ///
|
9916 11150 | /// ```no_run
|
9917 11151 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9918 11152 | ///
|
9919 11153 | /// use rest_json_http0x::{input, output, error};
|
9920 11154 | ///
|
9921 - | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
11155 + | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
9922 11156 | /// todo!()
|
9923 11157 | /// }
|
9924 11158 | ///
|
9925 11159 | /// let config = RestJsonConfig::builder().build();
|
9926 11160 | /// let app = RestJson::builder(config)
|
9927 - | /// .malformed_timestamp_header_epoch(handler)
|
11161 + | /// .malformed_timestamp_path_epoch(handler)
|
9928 11162 | /// /* Set other handlers */
|
9929 11163 | /// .build()
|
9930 11164 | /// .unwrap();
|
9931 11165 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9932 11166 | /// ```
|
9933 11167 | ///
|
9934 - | pub fn malformed_timestamp_header_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11168 + | pub fn malformed_timestamp_path_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9935 11169 | where
|
9936 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerExtractors>,
|
11170 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathEpoch, HandlerExtractors>,
|
9937 11171 |
|
9938 11172 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9939 11173 | RestJson<L>,
|
9940 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9941 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerType>
|
11174 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
11175 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathEpoch, HandlerType>
|
9942 11176 | >,
|
9943 11177 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9944 11178 | RestJson<L>,
|
9945 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11179 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
9946 11180 | ModelPl::Output
|
9947 11181 | >,
|
9948 11182 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9949 11183 | RestJson<L>,
|
9950 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11184 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
9951 11185 | <
|
9952 11186 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9953 11187 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9954 11188 | RestJson<L>,
|
9955 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11189 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
9956 11190 | ModelPl::Output
|
9957 11191 | >
|
9958 11192 | >::Output
|
9959 11193 | >,
|
9960 11194 |
|
9961 11195 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9962 11196 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9963 11197 |
|
9964 11198 | {
|
9965 11199 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9966 11200 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9967 - | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_handler(handler);
|
11201 + | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_handler(handler);
|
9968 11202 | let svc = self.model_plugin.apply(svc);
|
9969 11203 | let svc =
|
9970 11204 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9971 11205 | .apply(svc);
|
9972 11206 | let svc = self.http_plugin.apply(svc);
|
9973 - | self.malformed_timestamp_header_epoch_custom(svc)
|
11207 + | self.malformed_timestamp_path_epoch_custom(svc)
|
9974 11208 | }
|
9975 11209 |
|
9976 - | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
11210 + | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
9977 11211 | ///
|
9978 11212 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9979 11213 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9980 11214 | ///
|
9981 11215 | /// # Example
|
9982 11216 | ///
|
9983 11217 | /// ```no_run
|
9984 11218 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
9985 11219 | ///
|
9986 11220 | /// use rest_json_http0x::{input, output, error};
|
9987 11221 | ///
|
9988 - | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
11222 + | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
9989 11223 | /// todo!()
|
9990 11224 | /// }
|
9991 11225 | ///
|
9992 11226 | /// let config = RestJsonConfig::builder().build();
|
9993 11227 | /// let svc = ::tower::util::service_fn(handler);
|
9994 11228 | /// let app = RestJson::builder(config)
|
9995 - | /// .malformed_timestamp_header_epoch_service(svc)
|
11229 + | /// .malformed_timestamp_path_epoch_service(svc)
|
9996 11230 | /// /* Set other handlers */
|
9997 11231 | /// .build()
|
9998 11232 | /// .unwrap();
|
9999 11233 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10000 11234 | /// ```
|
10001 11235 | ///
|
10002 - | pub fn malformed_timestamp_header_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11236 + | pub fn malformed_timestamp_path_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10003 11237 | where
|
10004 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderEpoch, ServiceExtractors>,
|
11238 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathEpoch, ServiceExtractors>,
|
10005 11239 |
|
10006 11240 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10007 11241 | RestJson<L>,
|
10008 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
10009 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderEpoch, S>
|
11242 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
11243 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathEpoch, S>
|
10010 11244 | >,
|
10011 11245 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10012 11246 | RestJson<L>,
|
10013 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11247 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
10014 11248 | ModelPl::Output
|
10015 11249 | >,
|
10016 11250 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10017 11251 | RestJson<L>,
|
10018 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11252 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
10019 11253 | <
|
10020 11254 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10021 11255 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10022 11256 | RestJson<L>,
|
10023 - | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
11257 + | crate::operation_shape::MalformedTimestampPathEpoch,
|
10024 11258 | ModelPl::Output
|
10025 11259 | >
|
10026 11260 | >::Output
|
10027 11261 | >,
|
10028 11262 |
|
10029 11263 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10030 11264 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10031 11265 |
|
10032 11266 | {
|
10033 11267 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10034 11268 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10035 - | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_service(service);
|
11269 + | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_service(service);
|
10036 11270 | let svc = self.model_plugin.apply(svc);
|
10037 11271 | let svc =
|
10038 11272 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10039 11273 | .apply(svc);
|
10040 11274 | let svc = self.http_plugin.apply(svc);
|
10041 - | self.malformed_timestamp_header_epoch_custom(svc)
|
11275 + | self.malformed_timestamp_path_epoch_custom(svc)
|
10042 11276 | }
|
10043 11277 |
|
10044 - | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) to a custom [`Service`](tower::Service).
|
11278 + | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) to a custom [`Service`](tower::Service).
|
10045 11279 | /// not constrained by the Smithy contract.
|
10046 - | fn malformed_timestamp_header_epoch_custom<S>(mut self, svc: S) -> Self
|
11280 + | fn malformed_timestamp_path_epoch_custom<S>(mut self, svc: S) -> Self
|
10047 11281 | where
|
10048 11282 | S: ::tower::Service<
|
10049 11283 | ::http::Request<Body>,
|
10050 11284 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10051 11285 | Error = ::std::convert::Infallible,
|
10052 11286 | > + Clone
|
10053 11287 | + Send
|
10054 11288 | + 'static,
|
10055 11289 | S::Future: Send + 'static,
|
10056 11290 | {
|
10057 - | self.malformed_timestamp_header_epoch =
|
11291 + | self.malformed_timestamp_path_epoch =
|
10058 11292 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10059 11293 | self
|
10060 11294 | }
|
10061 11295 |
|
10062 - | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
11296 + | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
10063 11297 | ///
|
10064 11298 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10065 11299 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10066 11300 | ///
|
10067 11301 | /// # Example
|
10068 11302 | ///
|
10069 11303 | /// ```no_run
|
10070 11304 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10071 11305 | ///
|
10072 11306 | /// use rest_json_http0x::{input, output, error};
|
10073 11307 | ///
|
10074 - | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
11308 + | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
10075 11309 | /// todo!()
|
10076 11310 | /// }
|
10077 11311 | ///
|
10078 11312 | /// let config = RestJsonConfig::builder().build();
|
10079 11313 | /// let app = RestJson::builder(config)
|
10080 - | /// .malformed_timestamp_path_default(handler)
|
11314 + | /// .malformed_timestamp_path_http_date(handler)
|
10081 11315 | /// /* Set other handlers */
|
10082 11316 | /// .build()
|
10083 11317 | /// .unwrap();
|
10084 11318 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10085 11319 | /// ```
|
10086 11320 | ///
|
10087 - | pub fn malformed_timestamp_path_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11321 + | pub fn malformed_timestamp_path_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10088 11322 | where
|
10089 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathDefault, HandlerExtractors>,
|
11323 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerExtractors>,
|
10090 11324 |
|
10091 11325 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10092 11326 | RestJson<L>,
|
10093 - | crate::operation_shape::MalformedTimestampPathDefault,
|
10094 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathDefault, HandlerType>
|
11327 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11328 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerType>
|
10095 11329 | >,
|
10096 11330 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10097 11331 | RestJson<L>,
|
10098 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11332 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10099 11333 | ModelPl::Output
|
10100 11334 | >,
|
10101 11335 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10102 11336 | RestJson<L>,
|
10103 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11337 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10104 11338 | <
|
10105 11339 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10106 11340 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10107 11341 | RestJson<L>,
|
10108 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11342 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10109 11343 | ModelPl::Output
|
10110 11344 | >
|
10111 11345 | >::Output
|
10112 11346 | >,
|
10113 11347 |
|
10114 11348 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10115 11349 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10116 11350 |
|
10117 11351 | {
|
10118 11352 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10119 11353 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10120 - | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_handler(handler);
|
11354 + | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_handler(handler);
|
10121 11355 | let svc = self.model_plugin.apply(svc);
|
10122 11356 | let svc =
|
10123 11357 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10124 11358 | .apply(svc);
|
10125 11359 | let svc = self.http_plugin.apply(svc);
|
10126 - | self.malformed_timestamp_path_default_custom(svc)
|
11360 + | self.malformed_timestamp_path_http_date_custom(svc)
|
10127 11361 | }
|
10128 11362 |
|
10129 - | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
11363 + | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
10130 11364 | ///
|
10131 11365 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10132 11366 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10133 11367 | ///
|
10134 11368 | /// # Example
|
10135 11369 | ///
|
10136 11370 | /// ```no_run
|
10137 11371 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10138 11372 | ///
|
10139 11373 | /// use rest_json_http0x::{input, output, error};
|
10140 11374 | ///
|
10141 - | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
11375 + | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
10142 11376 | /// todo!()
|
10143 11377 | /// }
|
10144 11378 | ///
|
10145 11379 | /// let config = RestJsonConfig::builder().build();
|
10146 11380 | /// let svc = ::tower::util::service_fn(handler);
|
10147 11381 | /// let app = RestJson::builder(config)
|
10148 - | /// .malformed_timestamp_path_default_service(svc)
|
11382 + | /// .malformed_timestamp_path_http_date_service(svc)
|
10149 11383 | /// /* Set other handlers */
|
10150 11384 | /// .build()
|
10151 11385 | /// .unwrap();
|
10152 11386 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10153 11387 | /// ```
|
10154 11388 | ///
|
10155 - | pub fn malformed_timestamp_path_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11389 + | pub fn malformed_timestamp_path_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10156 11390 | where
|
10157 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathDefault, ServiceExtractors>,
|
11391 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathHttpDate, ServiceExtractors>,
|
10158 11392 |
|
10159 11393 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10160 11394 | RestJson<L>,
|
10161 - | crate::operation_shape::MalformedTimestampPathDefault,
|
10162 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathDefault, S>
|
11395 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11396 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathHttpDate, S>
|
10163 11397 | >,
|
10164 11398 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10165 11399 | RestJson<L>,
|
10166 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11400 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10167 11401 | ModelPl::Output
|
10168 11402 | >,
|
10169 11403 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10170 11404 | RestJson<L>,
|
10171 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11405 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10172 11406 | <
|
10173 11407 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10174 11408 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10175 11409 | RestJson<L>,
|
10176 - | crate::operation_shape::MalformedTimestampPathDefault,
|
11410 + | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10177 11411 | ModelPl::Output
|
10178 11412 | >
|
10179 11413 | >::Output
|
10180 11414 | >,
|
10181 11415 |
|
10182 11416 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10183 11417 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10184 11418 |
|
10185 11419 | {
|
10186 11420 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10187 11421 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10188 - | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_service(service);
|
11422 + | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_service(service);
|
10189 11423 | let svc = self.model_plugin.apply(svc);
|
10190 11424 | let svc =
|
10191 11425 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10192 11426 | .apply(svc);
|
10193 11427 | let svc = self.http_plugin.apply(svc);
|
10194 - | self.malformed_timestamp_path_default_custom(svc)
|
11428 + | self.malformed_timestamp_path_http_date_custom(svc)
|
10195 11429 | }
|
10196 11430 |
|
10197 - | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) to a custom [`Service`](tower::Service).
|
11431 + | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) to a custom [`Service`](tower::Service).
|
10198 11432 | /// not constrained by the Smithy contract.
|
10199 - | fn malformed_timestamp_path_default_custom<S>(mut self, svc: S) -> Self
|
11433 + | fn malformed_timestamp_path_http_date_custom<S>(mut self, svc: S) -> Self
|
10200 11434 | where
|
10201 11435 | S: ::tower::Service<
|
10202 11436 | ::http::Request<Body>,
|
10203 11437 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10204 11438 | Error = ::std::convert::Infallible,
|
10205 11439 | > + Clone
|
10206 11440 | + Send
|
10207 11441 | + 'static,
|
10208 11442 | S::Future: Send + 'static,
|
10209 11443 | {
|
10210 - | self.malformed_timestamp_path_default =
|
11444 + | self.malformed_timestamp_path_http_date =
|
10211 11445 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10212 11446 | self
|
10213 11447 | }
|
10214 11448 |
|
10215 - | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
11449 + | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
10216 11450 | ///
|
10217 11451 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10218 11452 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10219 11453 | ///
|
10220 11454 | /// # Example
|
10221 11455 | ///
|
10222 11456 | /// ```no_run
|
10223 11457 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10224 11458 | ///
|
10225 11459 | /// use rest_json_http0x::{input, output, error};
|
10226 11460 | ///
|
10227 - | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
11461 + | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
10228 11462 | /// todo!()
|
10229 11463 | /// }
|
10230 11464 | ///
|
10231 11465 | /// let config = RestJsonConfig::builder().build();
|
10232 11466 | /// let app = RestJson::builder(config)
|
10233 - | /// .malformed_timestamp_path_epoch(handler)
|
11467 + | /// .malformed_timestamp_query_default(handler)
|
10234 11468 | /// /* Set other handlers */
|
10235 11469 | /// .build()
|
10236 11470 | /// .unwrap();
|
10237 11471 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10238 11472 | /// ```
|
10239 11473 | ///
|
10240 - | pub fn malformed_timestamp_path_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11474 + | pub fn malformed_timestamp_query_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10241 11475 | where
|
10242 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathEpoch, HandlerExtractors>,
|
11476 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryDefault, HandlerExtractors>,
|
10243 11477 |
|
10244 11478 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10245 11479 | RestJson<L>,
|
10246 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
10247 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathEpoch, HandlerType>
|
11480 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
11481 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryDefault, HandlerType>
|
10248 11482 | >,
|
10249 11483 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10250 11484 | RestJson<L>,
|
10251 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11485 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10252 11486 | ModelPl::Output
|
10253 11487 | >,
|
10254 11488 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10255 11489 | RestJson<L>,
|
10256 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11490 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10257 11491 | <
|
10258 11492 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10259 11493 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10260 11494 | RestJson<L>,
|
10261 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11495 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10262 11496 | ModelPl::Output
|
10263 11497 | >
|
10264 11498 | >::Output
|
10265 11499 | >,
|
10266 11500 |
|
10267 11501 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10268 11502 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10269 11503 |
|
10270 11504 | {
|
10271 11505 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10272 11506 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10273 - | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_handler(handler);
|
11507 + | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_handler(handler);
|
10274 11508 | let svc = self.model_plugin.apply(svc);
|
10275 11509 | let svc =
|
10276 11510 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10277 11511 | .apply(svc);
|
10278 11512 | let svc = self.http_plugin.apply(svc);
|
10279 - | self.malformed_timestamp_path_epoch_custom(svc)
|
11513 + | self.malformed_timestamp_query_default_custom(svc)
|
10280 11514 | }
|
10281 11515 |
|
10282 - | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
11516 + | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
10283 11517 | ///
|
10284 11518 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10285 11519 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10286 11520 | ///
|
10287 11521 | /// # Example
|
10288 11522 | ///
|
10289 11523 | /// ```no_run
|
10290 11524 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10291 11525 | ///
|
10292 11526 | /// use rest_json_http0x::{input, output, error};
|
10293 11527 | ///
|
10294 - | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
11528 + | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
10295 11529 | /// todo!()
|
10296 11530 | /// }
|
10297 11531 | ///
|
10298 11532 | /// let config = RestJsonConfig::builder().build();
|
10299 11533 | /// let svc = ::tower::util::service_fn(handler);
|
10300 11534 | /// let app = RestJson::builder(config)
|
10301 - | /// .malformed_timestamp_path_epoch_service(svc)
|
11535 + | /// .malformed_timestamp_query_default_service(svc)
|
10302 11536 | /// /* Set other handlers */
|
10303 11537 | /// .build()
|
10304 11538 | /// .unwrap();
|
10305 11539 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10306 11540 | /// ```
|
10307 11541 | ///
|
10308 - | pub fn malformed_timestamp_path_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11542 + | pub fn malformed_timestamp_query_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10309 11543 | where
|
10310 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathEpoch, ServiceExtractors>,
|
11544 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryDefault, ServiceExtractors>,
|
10311 11545 |
|
10312 11546 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10313 11547 | RestJson<L>,
|
10314 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
10315 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathEpoch, S>
|
11548 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
11549 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryDefault, S>
|
10316 11550 | >,
|
10317 11551 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10318 11552 | RestJson<L>,
|
10319 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11553 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10320 11554 | ModelPl::Output
|
10321 11555 | >,
|
10322 11556 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10323 11557 | RestJson<L>,
|
10324 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11558 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10325 11559 | <
|
10326 11560 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10327 11561 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10328 11562 | RestJson<L>,
|
10329 - | crate::operation_shape::MalformedTimestampPathEpoch,
|
11563 + | crate::operation_shape::MalformedTimestampQueryDefault,
|
10330 11564 | ModelPl::Output
|
10331 11565 | >
|
10332 11566 | >::Output
|
10333 11567 | >,
|
10334 11568 |
|
10335 11569 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10336 11570 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10337 11571 |
|
10338 11572 | {
|
10339 11573 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10340 11574 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10341 - | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_service(service);
|
11575 + | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_service(service);
|
10342 11576 | let svc = self.model_plugin.apply(svc);
|
10343 11577 | let svc =
|
10344 11578 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10345 11579 | .apply(svc);
|
10346 11580 | let svc = self.http_plugin.apply(svc);
|
10347 - | self.malformed_timestamp_path_epoch_custom(svc)
|
11581 + | self.malformed_timestamp_query_default_custom(svc)
|
10348 11582 | }
|
10349 11583 |
|
10350 - | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) to a custom [`Service`](tower::Service).
|
11584 + | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) to a custom [`Service`](tower::Service).
|
10351 11585 | /// not constrained by the Smithy contract.
|
10352 - | fn malformed_timestamp_path_epoch_custom<S>(mut self, svc: S) -> Self
|
11586 + | fn malformed_timestamp_query_default_custom<S>(mut self, svc: S) -> Self
|
10353 11587 | where
|
10354 11588 | S: ::tower::Service<
|
10355 11589 | ::http::Request<Body>,
|
10356 11590 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10357 11591 | Error = ::std::convert::Infallible,
|
10358 11592 | > + Clone
|
10359 11593 | + Send
|
10360 11594 | + 'static,
|
10361 11595 | S::Future: Send + 'static,
|
10362 11596 | {
|
10363 - | self.malformed_timestamp_path_epoch =
|
11597 + | self.malformed_timestamp_query_default =
|
10364 11598 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10365 11599 | self
|
10366 11600 | }
|
10367 11601 |
|
10368 - | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
11602 + | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
10369 11603 | ///
|
10370 11604 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10371 11605 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10372 11606 | ///
|
10373 11607 | /// # Example
|
10374 11608 | ///
|
10375 11609 | /// ```no_run
|
10376 11610 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10377 11611 | ///
|
10378 11612 | /// use rest_json_http0x::{input, output, error};
|
10379 11613 | ///
|
10380 - | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
11614 + | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
10381 11615 | /// todo!()
|
10382 11616 | /// }
|
10383 11617 | ///
|
10384 11618 | /// let config = RestJsonConfig::builder().build();
|
10385 11619 | /// let app = RestJson::builder(config)
|
10386 - | /// .malformed_timestamp_path_http_date(handler)
|
11620 + | /// .malformed_timestamp_query_epoch(handler)
|
10387 11621 | /// /* Set other handlers */
|
10388 11622 | /// .build()
|
10389 11623 | /// .unwrap();
|
10390 11624 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10391 11625 | /// ```
|
10392 11626 | ///
|
10393 - | pub fn malformed_timestamp_path_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11627 + | pub fn malformed_timestamp_query_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10394 11628 | where
|
10395 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerExtractors>,
|
11629 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerExtractors>,
|
10396 11630 |
|
10397 11631 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10398 11632 | RestJson<L>,
|
10399 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10400 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerType>
|
11633 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
11634 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerType>
|
10401 11635 | >,
|
10402 11636 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10403 11637 | RestJson<L>,
|
10404 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11638 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10405 11639 | ModelPl::Output
|
10406 11640 | >,
|
10407 11641 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10408 11642 | RestJson<L>,
|
10409 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11643 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10410 11644 | <
|
10411 11645 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10412 11646 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10413 11647 | RestJson<L>,
|
10414 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11648 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10415 11649 | ModelPl::Output
|
10416 11650 | >
|
10417 11651 | >::Output
|
10418 11652 | >,
|
10419 11653 |
|
10420 11654 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10421 11655 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10422 11656 |
|
10423 11657 | {
|
10424 11658 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10425 11659 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10426 - | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_handler(handler);
|
11660 + | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_handler(handler);
|
10427 11661 | let svc = self.model_plugin.apply(svc);
|
10428 11662 | let svc =
|
10429 11663 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10430 11664 | .apply(svc);
|
10431 11665 | let svc = self.http_plugin.apply(svc);
|
10432 - | self.malformed_timestamp_path_http_date_custom(svc)
|
11666 + | self.malformed_timestamp_query_epoch_custom(svc)
|
10433 11667 | }
|
10434 11668 |
|
10435 - | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
11669 + | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
10436 11670 | ///
|
10437 11671 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10438 11672 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10439 11673 | ///
|
10440 11674 | /// # Example
|
10441 11675 | ///
|
10442 11676 | /// ```no_run
|
10443 11677 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10444 11678 | ///
|
10445 11679 | /// use rest_json_http0x::{input, output, error};
|
10446 11680 | ///
|
10447 - | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
11681 + | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
10448 11682 | /// todo!()
|
10449 11683 | /// }
|
10450 11684 | ///
|
10451 11685 | /// let config = RestJsonConfig::builder().build();
|
10452 11686 | /// let svc = ::tower::util::service_fn(handler);
|
10453 11687 | /// let app = RestJson::builder(config)
|
10454 - | /// .malformed_timestamp_path_http_date_service(svc)
|
11688 + | /// .malformed_timestamp_query_epoch_service(svc)
|
10455 11689 | /// /* Set other handlers */
|
10456 11690 | /// .build()
|
10457 11691 | /// .unwrap();
|
10458 11692 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10459 11693 | /// ```
|
10460 11694 | ///
|
10461 - | pub fn malformed_timestamp_path_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11695 + | pub fn malformed_timestamp_query_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10462 11696 | where
|
10463 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathHttpDate, ServiceExtractors>,
|
11697 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryEpoch, ServiceExtractors>,
|
10464 11698 |
|
10465 11699 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10466 11700 | RestJson<L>,
|
10467 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10468 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathHttpDate, S>
|
11701 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
11702 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryEpoch, S>
|
10469 11703 | >,
|
10470 11704 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10471 11705 | RestJson<L>,
|
10472 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11706 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10473 11707 | ModelPl::Output
|
10474 11708 | >,
|
10475 11709 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10476 11710 | RestJson<L>,
|
10477 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11711 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10478 11712 | <
|
10479 11713 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10480 11714 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10481 11715 | RestJson<L>,
|
10482 - | crate::operation_shape::MalformedTimestampPathHttpDate,
|
11716 + | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10483 11717 | ModelPl::Output
|
10484 11718 | >
|
10485 11719 | >::Output
|
10486 11720 | >,
|
10487 11721 |
|
10488 11722 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10489 11723 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10490 11724 |
|
10491 11725 | {
|
10492 11726 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10493 11727 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10494 - | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_service(service);
|
11728 + | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_service(service);
|
10495 11729 | let svc = self.model_plugin.apply(svc);
|
10496 11730 | let svc =
|
10497 11731 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10498 11732 | .apply(svc);
|
10499 11733 | let svc = self.http_plugin.apply(svc);
|
10500 - | self.malformed_timestamp_path_http_date_custom(svc)
|
11734 + | self.malformed_timestamp_query_epoch_custom(svc)
|
10501 11735 | }
|
10502 11736 |
|
10503 - | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) to a custom [`Service`](tower::Service).
|
11737 + | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) to a custom [`Service`](tower::Service).
|
10504 11738 | /// not constrained by the Smithy contract.
|
10505 - | fn malformed_timestamp_path_http_date_custom<S>(mut self, svc: S) -> Self
|
11739 + | fn malformed_timestamp_query_epoch_custom<S>(mut self, svc: S) -> Self
|
10506 11740 | where
|
10507 11741 | S: ::tower::Service<
|
10508 11742 | ::http::Request<Body>,
|
10509 11743 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10510 11744 | Error = ::std::convert::Infallible,
|
10511 11745 | > + Clone
|
10512 11746 | + Send
|
10513 11747 | + 'static,
|
10514 11748 | S::Future: Send + 'static,
|
10515 11749 | {
|
10516 - | self.malformed_timestamp_path_http_date =
|
11750 + | self.malformed_timestamp_query_epoch =
|
10517 11751 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10518 11752 | self
|
10519 11753 | }
|
10520 11754 |
|
10521 - | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
11755 + | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
10522 11756 | ///
|
10523 11757 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10524 11758 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10525 11759 | ///
|
10526 11760 | /// # Example
|
10527 11761 | ///
|
10528 11762 | /// ```no_run
|
10529 11763 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10530 11764 | ///
|
10531 11765 | /// use rest_json_http0x::{input, output, error};
|
10532 11766 | ///
|
10533 - | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
11767 + | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
10534 11768 | /// todo!()
|
10535 11769 | /// }
|
10536 11770 | ///
|
10537 11771 | /// let config = RestJsonConfig::builder().build();
|
10538 11772 | /// let app = RestJson::builder(config)
|
10539 - | /// .malformed_timestamp_query_default(handler)
|
11773 + | /// .malformed_timestamp_query_http_date(handler)
|
10540 11774 | /// /* Set other handlers */
|
10541 11775 | /// .build()
|
10542 11776 | /// .unwrap();
|
10543 11777 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10544 11778 | /// ```
|
10545 11779 | ///
|
10546 - | pub fn malformed_timestamp_query_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11780 + | pub fn malformed_timestamp_query_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10547 11781 | where
|
10548 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryDefault, HandlerExtractors>,
|
11782 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerExtractors>,
|
10549 11783 |
|
10550 11784 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10551 11785 | RestJson<L>,
|
10552 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
10553 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryDefault, HandlerType>
|
11786 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
11787 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerType>
|
10554 11788 | >,
|
10555 11789 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10556 11790 | RestJson<L>,
|
10557 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11791 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10558 11792 | ModelPl::Output
|
10559 11793 | >,
|
10560 11794 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10561 11795 | RestJson<L>,
|
10562 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11796 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10563 11797 | <
|
10564 11798 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10565 11799 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10566 11800 | RestJson<L>,
|
10567 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11801 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10568 11802 | ModelPl::Output
|
10569 11803 | >
|
10570 11804 | >::Output
|
10571 11805 | >,
|
10572 11806 |
|
10573 11807 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10574 11808 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10575 11809 |
|
10576 11810 | {
|
10577 11811 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10578 11812 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10579 - | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_handler(handler);
|
11813 + | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_handler(handler);
|
10580 11814 | let svc = self.model_plugin.apply(svc);
|
10581 11815 | let svc =
|
10582 11816 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10583 11817 | .apply(svc);
|
10584 11818 | let svc = self.http_plugin.apply(svc);
|
10585 - | self.malformed_timestamp_query_default_custom(svc)
|
11819 + | self.malformed_timestamp_query_http_date_custom(svc)
|
10586 11820 | }
|
10587 11821 |
|
10588 - | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
11822 + | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
10589 11823 | ///
|
10590 11824 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10591 11825 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10592 11826 | ///
|
10593 11827 | /// # Example
|
10594 11828 | ///
|
10595 11829 | /// ```no_run
|
10596 11830 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10597 11831 | ///
|
10598 11832 | /// use rest_json_http0x::{input, output, error};
|
10599 11833 | ///
|
10600 - | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
11834 + | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
10601 11835 | /// todo!()
|
10602 11836 | /// }
|
10603 11837 | ///
|
10604 11838 | /// let config = RestJsonConfig::builder().build();
|
10605 11839 | /// let svc = ::tower::util::service_fn(handler);
|
10606 11840 | /// let app = RestJson::builder(config)
|
10607 - | /// .malformed_timestamp_query_default_service(svc)
|
11841 + | /// .malformed_timestamp_query_http_date_service(svc)
|
10608 11842 | /// /* Set other handlers */
|
10609 11843 | /// .build()
|
10610 11844 | /// .unwrap();
|
10611 11845 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10612 11846 | /// ```
|
10613 11847 | ///
|
10614 - | pub fn malformed_timestamp_query_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11848 + | pub fn malformed_timestamp_query_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10615 11849 | where
|
10616 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryDefault, ServiceExtractors>,
|
11850 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryHttpDate, ServiceExtractors>,
|
10617 11851 |
|
10618 11852 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10619 11853 | RestJson<L>,
|
10620 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
10621 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryDefault, S>
|
11854 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
11855 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryHttpDate, S>
|
10622 11856 | >,
|
10623 11857 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10624 11858 | RestJson<L>,
|
10625 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11859 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10626 11860 | ModelPl::Output
|
10627 11861 | >,
|
10628 11862 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10629 11863 | RestJson<L>,
|
10630 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11864 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10631 11865 | <
|
10632 11866 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10633 11867 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10634 11868 | RestJson<L>,
|
10635 - | crate::operation_shape::MalformedTimestampQueryDefault,
|
11869 + | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10636 11870 | ModelPl::Output
|
10637 11871 | >
|
10638 11872 | >::Output
|
10639 11873 | >,
|
10640 11874 |
|
10641 11875 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10642 11876 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10643 11877 |
|
10644 11878 | {
|
10645 11879 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10646 11880 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10647 - | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_service(service);
|
11881 + | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_service(service);
|
10648 11882 | let svc = self.model_plugin.apply(svc);
|
10649 11883 | let svc =
|
10650 11884 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10651 11885 | .apply(svc);
|
10652 11886 | let svc = self.http_plugin.apply(svc);
|
10653 - | self.malformed_timestamp_query_default_custom(svc)
|
11887 + | self.malformed_timestamp_query_http_date_custom(svc)
|
10654 11888 | }
|
10655 11889 |
|
10656 - | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) to a custom [`Service`](tower::Service).
|
11890 + | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) to a custom [`Service`](tower::Service).
|
10657 11891 | /// not constrained by the Smithy contract.
|
10658 - | fn malformed_timestamp_query_default_custom<S>(mut self, svc: S) -> Self
|
11892 + | fn malformed_timestamp_query_http_date_custom<S>(mut self, svc: S) -> Self
|
10659 11893 | where
|
10660 11894 | S: ::tower::Service<
|
10661 11895 | ::http::Request<Body>,
|
10662 11896 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10663 11897 | Error = ::std::convert::Infallible,
|
10664 11898 | > + Clone
|
10665 11899 | + Send
|
10666 11900 | + 'static,
|
10667 11901 | S::Future: Send + 'static,
|
10668 11902 | {
|
10669 - | self.malformed_timestamp_query_default =
|
11903 + | self.malformed_timestamp_query_http_date =
|
10670 11904 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10671 11905 | self
|
10672 11906 | }
|
10673 11907 |
|
10674 - | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
11908 + | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
10675 11909 | ///
|
10676 11910 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10677 11911 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10678 11912 | ///
|
10679 11913 | /// # Example
|
10680 11914 | ///
|
10681 11915 | /// ```no_run
|
10682 11916 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10683 11917 | ///
|
10684 11918 | /// use rest_json_http0x::{input, output, error};
|
10685 11919 | ///
|
10686 - | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
11920 + | /// async fn handler(input: input::MalformedUnionInput) -> output::MalformedUnionOutput {
|
10687 11921 | /// todo!()
|
10688 11922 | /// }
|
10689 11923 | ///
|
10690 11924 | /// let config = RestJsonConfig::builder().build();
|
10691 11925 | /// let app = RestJson::builder(config)
|
10692 - | /// .malformed_timestamp_query_epoch(handler)
|
11926 + | /// .malformed_union(handler)
|
10693 11927 | /// /* Set other handlers */
|
10694 11928 | /// .build()
|
10695 11929 | /// .unwrap();
|
10696 11930 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10697 11931 | /// ```
|
10698 11932 | ///
|
10699 - | pub fn malformed_timestamp_query_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11933 + | pub fn malformed_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10700 11934 | where
|
10701 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerExtractors>,
|
11935 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedUnion, HandlerExtractors>,
|
10702 11936 |
|
10703 11937 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10704 11938 | RestJson<L>,
|
10705 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10706 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerType>
|
11939 + | crate::operation_shape::MalformedUnion,
|
11940 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedUnion, HandlerType>
|
10707 11941 | >,
|
10708 11942 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10709 11943 | RestJson<L>,
|
10710 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
11944 + | crate::operation_shape::MalformedUnion,
|
10711 11945 | ModelPl::Output
|
10712 11946 | >,
|
10713 11947 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10714 11948 | RestJson<L>,
|
10715 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
11949 + | crate::operation_shape::MalformedUnion,
|
10716 11950 | <
|
10717 11951 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10718 11952 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10719 11953 | RestJson<L>,
|
10720 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
11954 + | crate::operation_shape::MalformedUnion,
|
10721 11955 | ModelPl::Output
|
10722 11956 | >
|
10723 11957 | >::Output
|
10724 11958 | >,
|
10725 11959 |
|
10726 11960 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10727 11961 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10728 11962 |
|
10729 11963 | {
|
10730 11964 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10731 11965 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10732 - | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_handler(handler);
|
11966 + | let svc = crate::operation_shape::MalformedUnion::from_handler(handler);
|
10733 11967 | let svc = self.model_plugin.apply(svc);
|
10734 11968 | let svc =
|
10735 11969 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10736 11970 | .apply(svc);
|
10737 11971 | let svc = self.http_plugin.apply(svc);
|
10738 - | self.malformed_timestamp_query_epoch_custom(svc)
|
11972 + | self.malformed_union_custom(svc)
|
10739 11973 | }
|
10740 11974 |
|
10741 - | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
11975 + | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
10742 11976 | ///
|
10743 11977 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10744 11978 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10745 11979 | ///
|
10746 11980 | /// # Example
|
10747 11981 | ///
|
10748 11982 | /// ```no_run
|
10749 11983 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10750 11984 | ///
|
10751 11985 | /// use rest_json_http0x::{input, output, error};
|
10752 11986 | ///
|
10753 - | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
11987 + | /// async fn handler(input: input::MalformedUnionInput) -> Result<output::MalformedUnionOutput, std::convert::Infallible> {
|
10754 11988 | /// todo!()
|
10755 11989 | /// }
|
10756 11990 | ///
|
10757 11991 | /// let config = RestJsonConfig::builder().build();
|
10758 11992 | /// let svc = ::tower::util::service_fn(handler);
|
10759 11993 | /// let app = RestJson::builder(config)
|
10760 - | /// .malformed_timestamp_query_epoch_service(svc)
|
11994 + | /// .malformed_union_service(svc)
|
10761 11995 | /// /* Set other handlers */
|
10762 11996 | /// .build()
|
10763 11997 | /// .unwrap();
|
10764 11998 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10765 11999 | /// ```
|
10766 12000 | ///
|
10767 - | pub fn malformed_timestamp_query_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12001 + | pub fn malformed_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10768 12002 | where
|
10769 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryEpoch, ServiceExtractors>,
|
12003 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedUnion, ServiceExtractors>,
|
10770 12004 |
|
10771 12005 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10772 12006 | RestJson<L>,
|
10773 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10774 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryEpoch, S>
|
12007 + | crate::operation_shape::MalformedUnion,
|
12008 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedUnion, S>
|
10775 12009 | >,
|
10776 12010 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10777 12011 | RestJson<L>,
|
10778 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
12012 + | crate::operation_shape::MalformedUnion,
|
10779 12013 | ModelPl::Output
|
10780 12014 | >,
|
10781 12015 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10782 12016 | RestJson<L>,
|
10783 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
12017 + | crate::operation_shape::MalformedUnion,
|
10784 12018 | <
|
10785 12019 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10786 12020 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10787 12021 | RestJson<L>,
|
10788 - | crate::operation_shape::MalformedTimestampQueryEpoch,
|
12022 + | crate::operation_shape::MalformedUnion,
|
10789 12023 | ModelPl::Output
|
10790 12024 | >
|
10791 12025 | >::Output
|
10792 12026 | >,
|
10793 12027 |
|
10794 12028 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10795 12029 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10796 12030 |
|
10797 12031 | {
|
10798 12032 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10799 12033 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10800 - | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_service(service);
|
12034 + | let svc = crate::operation_shape::MalformedUnion::from_service(service);
|
10801 12035 | let svc = self.model_plugin.apply(svc);
|
10802 12036 | let svc =
|
10803 12037 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10804 12038 | .apply(svc);
|
10805 12039 | let svc = self.http_plugin.apply(svc);
|
10806 - | self.malformed_timestamp_query_epoch_custom(svc)
|
12040 + | self.malformed_union_custom(svc)
|
10807 12041 | }
|
10808 12042 |
|
10809 - | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) to a custom [`Service`](tower::Service).
|
12043 + | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) to a custom [`Service`](tower::Service).
|
10810 12044 | /// not constrained by the Smithy contract.
|
10811 - | fn malformed_timestamp_query_epoch_custom<S>(mut self, svc: S) -> Self
|
12045 + | fn malformed_union_custom<S>(mut self, svc: S) -> Self
|
10812 12046 | where
|
10813 12047 | S: ::tower::Service<
|
10814 12048 | ::http::Request<Body>,
|
10815 12049 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10816 12050 | Error = ::std::convert::Infallible,
|
10817 12051 | > + Clone
|
10818 12052 | + Send
|
10819 12053 | + 'static,
|
10820 12054 | S::Future: Send + 'static,
|
10821 12055 | {
|
10822 - | self.malformed_timestamp_query_epoch =
|
10823 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12056 + | self.malformed_union = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10824 12057 | self
|
10825 12058 | }
|
10826 12059 |
|
10827 - | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
12060 + | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
10828 12061 | ///
|
10829 12062 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10830 12063 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10831 12064 | ///
|
10832 12065 | /// # Example
|
10833 12066 | ///
|
10834 12067 | /// ```no_run
|
10835 12068 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10836 12069 | ///
|
10837 12070 | /// use rest_json_http0x::{input, output, error};
|
10838 12071 | ///
|
10839 - | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
12072 + | /// async fn handler(input: input::MediaTypeHeaderInput) -> output::MediaTypeHeaderOutput {
|
10840 12073 | /// todo!()
|
10841 12074 | /// }
|
10842 12075 | ///
|
10843 12076 | /// let config = RestJsonConfig::builder().build();
|
10844 12077 | /// let app = RestJson::builder(config)
|
10845 - | /// .malformed_timestamp_query_http_date(handler)
|
12078 + | /// .media_type_header(handler)
|
10846 12079 | /// /* Set other handlers */
|
10847 12080 | /// .build()
|
10848 12081 | /// .unwrap();
|
10849 12082 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10850 12083 | /// ```
|
10851 12084 | ///
|
10852 - | pub fn malformed_timestamp_query_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12085 + | pub fn media_type_header<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10853 12086 | where
|
10854 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerExtractors>,
|
12087 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MediaTypeHeader, HandlerExtractors>,
|
10855 12088 |
|
10856 12089 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10857 12090 | RestJson<L>,
|
10858 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10859 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerType>
|
12091 + | crate::operation_shape::MediaTypeHeader,
|
12092 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MediaTypeHeader, HandlerType>
|
10860 12093 | >,
|
10861 12094 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10862 12095 | RestJson<L>,
|
10863 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12096 + | crate::operation_shape::MediaTypeHeader,
|
10864 12097 | ModelPl::Output
|
10865 12098 | >,
|
10866 12099 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10867 12100 | RestJson<L>,
|
10868 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12101 + | crate::operation_shape::MediaTypeHeader,
|
10869 12102 | <
|
10870 12103 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10871 12104 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10872 12105 | RestJson<L>,
|
10873 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12106 + | crate::operation_shape::MediaTypeHeader,
|
10874 12107 | ModelPl::Output
|
10875 12108 | >
|
10876 12109 | >::Output
|
10877 12110 | >,
|
10878 12111 |
|
10879 12112 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10880 12113 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10881 12114 |
|
10882 12115 | {
|
10883 12116 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10884 12117 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10885 - | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_handler(handler);
|
12118 + | let svc = crate::operation_shape::MediaTypeHeader::from_handler(handler);
|
10886 12119 | let svc = self.model_plugin.apply(svc);
|
10887 12120 | let svc =
|
10888 12121 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10889 12122 | .apply(svc);
|
10890 12123 | let svc = self.http_plugin.apply(svc);
|
10891 - | self.malformed_timestamp_query_http_date_custom(svc)
|
12124 + | self.media_type_header_custom(svc)
|
10892 12125 | }
|
10893 12126 |
|
10894 - | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
12127 + | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
10895 12128 | ///
|
10896 12129 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10897 12130 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10898 12131 | ///
|
10899 12132 | /// # Example
|
10900 12133 | ///
|
10901 12134 | /// ```no_run
|
10902 12135 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10903 12136 | ///
|
10904 12137 | /// use rest_json_http0x::{input, output, error};
|
10905 12138 | ///
|
10906 - | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
12139 + | /// async fn handler(input: input::MediaTypeHeaderInput) -> Result<output::MediaTypeHeaderOutput, std::convert::Infallible> {
|
10907 12140 | /// todo!()
|
10908 12141 | /// }
|
10909 12142 | ///
|
10910 12143 | /// let config = RestJsonConfig::builder().build();
|
10911 12144 | /// let svc = ::tower::util::service_fn(handler);
|
10912 12145 | /// let app = RestJson::builder(config)
|
10913 - | /// .malformed_timestamp_query_http_date_service(svc)
|
12146 + | /// .media_type_header_service(svc)
|
10914 12147 | /// /* Set other handlers */
|
10915 12148 | /// .build()
|
10916 12149 | /// .unwrap();
|
10917 12150 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10918 12151 | /// ```
|
10919 12152 | ///
|
10920 - | pub fn malformed_timestamp_query_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12153 + | pub fn media_type_header_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10921 12154 | where
|
10922 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryHttpDate, ServiceExtractors>,
|
12155 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MediaTypeHeader, ServiceExtractors>,
|
10923 12156 |
|
10924 12157 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10925 12158 | RestJson<L>,
|
10926 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10927 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryHttpDate, S>
|
12159 + | crate::operation_shape::MediaTypeHeader,
|
12160 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MediaTypeHeader, S>
|
10928 12161 | >,
|
10929 12162 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10930 12163 | RestJson<L>,
|
10931 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12164 + | crate::operation_shape::MediaTypeHeader,
|
10932 12165 | ModelPl::Output
|
10933 12166 | >,
|
10934 12167 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10935 12168 | RestJson<L>,
|
10936 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12169 + | crate::operation_shape::MediaTypeHeader,
|
10937 12170 | <
|
10938 12171 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10939 12172 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10940 12173 | RestJson<L>,
|
10941 - | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
12174 + | crate::operation_shape::MediaTypeHeader,
|
10942 12175 | ModelPl::Output
|
10943 12176 | >
|
10944 12177 | >::Output
|
10945 12178 | >,
|
10946 12179 |
|
10947 12180 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10948 12181 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10949 12182 |
|
10950 12183 | {
|
10951 12184 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10952 12185 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10953 - | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_service(service);
|
12186 + | let svc = crate::operation_shape::MediaTypeHeader::from_service(service);
|
10954 12187 | let svc = self.model_plugin.apply(svc);
|
10955 12188 | let svc =
|
10956 12189 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10957 12190 | .apply(svc);
|
10958 12191 | let svc = self.http_plugin.apply(svc);
|
10959 - | self.malformed_timestamp_query_http_date_custom(svc)
|
12192 + | self.media_type_header_custom(svc)
|
10960 12193 | }
|
10961 12194 |
|
10962 - | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) to a custom [`Service`](tower::Service).
|
12195 + | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) to a custom [`Service`](tower::Service).
|
10963 12196 | /// not constrained by the Smithy contract.
|
10964 - | fn malformed_timestamp_query_http_date_custom<S>(mut self, svc: S) -> Self
|
12197 + | fn media_type_header_custom<S>(mut self, svc: S) -> Self
|
10965 12198 | where
|
10966 12199 | S: ::tower::Service<
|
10967 12200 | ::http::Request<Body>,
|
10968 12201 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10969 12202 | Error = ::std::convert::Infallible,
|
10970 12203 | > + Clone
|
10971 12204 | + Send
|
10972 12205 | + 'static,
|
10973 12206 | S::Future: Send + 'static,
|
10974 12207 | {
|
10975 - | self.malformed_timestamp_query_http_date =
|
10976 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12208 + | self.media_type_header = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10977 12209 | self
|
10978 12210 | }
|
10979 12211 |
|
10980 - | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
12212 + | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
10981 12213 | ///
|
10982 12214 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10983 12215 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10984 12216 | ///
|
10985 12217 | /// # Example
|
10986 12218 | ///
|
10987 12219 | /// ```no_run
|
10988 12220 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
10989 12221 | ///
|
10990 12222 | /// use rest_json_http0x::{input, output, error};
|
10991 12223 | ///
|
10992 - | /// async fn handler(input: input::MalformedUnionInput) -> output::MalformedUnionOutput {
|
12224 + | /// async fn handler(input: input::NoInputAndNoOutputInput) -> output::NoInputAndNoOutputOutput {
|
10993 12225 | /// todo!()
|
10994 12226 | /// }
|
10995 12227 | ///
|
10996 12228 | /// let config = RestJsonConfig::builder().build();
|
10997 12229 | /// let app = RestJson::builder(config)
|
10998 - | /// .malformed_union(handler)
|
12230 + | /// .no_input_and_no_output(handler)
|
10999 12231 | /// /* Set other handlers */
|
11000 12232 | /// .build()
|
11001 12233 | /// .unwrap();
|
11002 12234 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11003 12235 | /// ```
|
11004 12236 | ///
|
11005 - | pub fn malformed_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12237 + | pub fn no_input_and_no_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11006 12238 | where
|
11007 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedUnion, HandlerExtractors>,
|
12239 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndNoOutput, HandlerExtractors>,
|
11008 12240 |
|
11009 12241 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11010 12242 | RestJson<L>,
|
11011 - | crate::operation_shape::MalformedUnion,
|
11012 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedUnion, HandlerType>
|
12243 + | crate::operation_shape::NoInputAndNoOutput,
|
12244 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndNoOutput, HandlerType>
|
11013 12245 | >,
|
11014 12246 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11015 12247 | RestJson<L>,
|
11016 - | crate::operation_shape::MalformedUnion,
|
12248 + | crate::operation_shape::NoInputAndNoOutput,
|
11017 12249 | ModelPl::Output
|
11018 12250 | >,
|
11019 12251 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11020 12252 | RestJson<L>,
|
11021 - | crate::operation_shape::MalformedUnion,
|
12253 + | crate::operation_shape::NoInputAndNoOutput,
|
11022 12254 | <
|
11023 12255 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11024 12256 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11025 12257 | RestJson<L>,
|
11026 - | crate::operation_shape::MalformedUnion,
|
12258 + | crate::operation_shape::NoInputAndNoOutput,
|
11027 12259 | ModelPl::Output
|
11028 12260 | >
|
11029 12261 | >::Output
|
11030 12262 | >,
|
11031 12263 |
|
11032 12264 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11033 12265 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11034 12266 |
|
11035 12267 | {
|
11036 12268 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11037 12269 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11038 - | let svc = crate::operation_shape::MalformedUnion::from_handler(handler);
|
12270 + | let svc = crate::operation_shape::NoInputAndNoOutput::from_handler(handler);
|
11039 12271 | let svc = self.model_plugin.apply(svc);
|
11040 12272 | let svc =
|
11041 12273 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11042 12274 | .apply(svc);
|
11043 12275 | let svc = self.http_plugin.apply(svc);
|
11044 - | self.malformed_union_custom(svc)
|
12276 + | self.no_input_and_no_output_custom(svc)
|
11045 12277 | }
|
11046 12278 |
|
11047 - | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
12279 + | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
11048 12280 | ///
|
11049 12281 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11050 12282 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11051 12283 | ///
|
11052 12284 | /// # Example
|
11053 12285 | ///
|
11054 12286 | /// ```no_run
|
11055 12287 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11056 12288 | ///
|
11057 12289 | /// use rest_json_http0x::{input, output, error};
|
11058 12290 | ///
|
11059 - | /// async fn handler(input: input::MalformedUnionInput) -> Result<output::MalformedUnionOutput, std::convert::Infallible> {
|
12291 + | /// async fn handler(input: input::NoInputAndNoOutputInput) -> Result<output::NoInputAndNoOutputOutput, std::convert::Infallible> {
|
11060 12292 | /// todo!()
|
11061 12293 | /// }
|
11062 12294 | ///
|
11063 12295 | /// let config = RestJsonConfig::builder().build();
|
11064 12296 | /// let svc = ::tower::util::service_fn(handler);
|
11065 12297 | /// let app = RestJson::builder(config)
|
11066 - | /// .malformed_union_service(svc)
|
12298 + | /// .no_input_and_no_output_service(svc)
|
11067 12299 | /// /* Set other handlers */
|
11068 12300 | /// .build()
|
11069 12301 | /// .unwrap();
|
11070 12302 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11071 12303 | /// ```
|
11072 12304 | ///
|
11073 - | pub fn malformed_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12305 + | pub fn no_input_and_no_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11074 12306 | where
|
11075 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedUnion, ServiceExtractors>,
|
12307 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndNoOutput, ServiceExtractors>,
|
11076 12308 |
|
11077 12309 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11078 12310 | RestJson<L>,
|
11079 - | crate::operation_shape::MalformedUnion,
|
11080 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedUnion, S>
|
12311 + | crate::operation_shape::NoInputAndNoOutput,
|
12312 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndNoOutput, S>
|
11081 12313 | >,
|
11082 12314 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11083 12315 | RestJson<L>,
|
11084 - | crate::operation_shape::MalformedUnion,
|
12316 + | crate::operation_shape::NoInputAndNoOutput,
|
11085 12317 | ModelPl::Output
|
11086 12318 | >,
|
11087 12319 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11088 12320 | RestJson<L>,
|
11089 - | crate::operation_shape::MalformedUnion,
|
12321 + | crate::operation_shape::NoInputAndNoOutput,
|
11090 12322 | <
|
11091 12323 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11092 12324 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11093 12325 | RestJson<L>,
|
11094 - | crate::operation_shape::MalformedUnion,
|
12326 + | crate::operation_shape::NoInputAndNoOutput,
|
11095 12327 | ModelPl::Output
|
11096 12328 | >
|
11097 12329 | >::Output
|
11098 12330 | >,
|
11099 12331 |
|
11100 12332 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11101 12333 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11102 12334 |
|
11103 12335 | {
|
11104 12336 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11105 12337 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11106 - | let svc = crate::operation_shape::MalformedUnion::from_service(service);
|
12338 + | let svc = crate::operation_shape::NoInputAndNoOutput::from_service(service);
|
11107 12339 | let svc = self.model_plugin.apply(svc);
|
11108 12340 | let svc =
|
11109 12341 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11110 12342 | .apply(svc);
|
11111 12343 | let svc = self.http_plugin.apply(svc);
|
11112 - | self.malformed_union_custom(svc)
|
12344 + | self.no_input_and_no_output_custom(svc)
|
11113 12345 | }
|
11114 12346 |
|
11115 - | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) to a custom [`Service`](tower::Service).
|
12347 + | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) to a custom [`Service`](tower::Service).
|
11116 12348 | /// not constrained by the Smithy contract.
|
11117 - | fn malformed_union_custom<S>(mut self, svc: S) -> Self
|
12349 + | fn no_input_and_no_output_custom<S>(mut self, svc: S) -> Self
|
11118 12350 | where
|
11119 12351 | S: ::tower::Service<
|
11120 12352 | ::http::Request<Body>,
|
11121 12353 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11122 12354 | Error = ::std::convert::Infallible,
|
11123 12355 | > + Clone
|
11124 12356 | + Send
|
11125 12357 | + 'static,
|
11126 12358 | S::Future: Send + 'static,
|
11127 12359 | {
|
11128 - | self.malformed_union = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12360 + | self.no_input_and_no_output =
|
12361 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11129 12362 | self
|
11130 12363 | }
|
11131 12364 |
|
11132 - | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
12365 + | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
11133 12366 | ///
|
11134 12367 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11135 12368 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11136 12369 | ///
|
11137 12370 | /// # Example
|
11138 12371 | ///
|
11139 12372 | /// ```no_run
|
11140 12373 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11141 12374 | ///
|
11142 12375 | /// use rest_json_http0x::{input, output, error};
|
11143 12376 | ///
|
11144 - | /// async fn handler(input: input::MediaTypeHeaderInput) -> output::MediaTypeHeaderOutput {
|
12377 + | /// async fn handler(input: input::NoInputAndOutputInput) -> output::NoInputAndOutputOutput {
|
11145 12378 | /// todo!()
|
11146 12379 | /// }
|
11147 12380 | ///
|
11148 12381 | /// let config = RestJsonConfig::builder().build();
|
11149 12382 | /// let app = RestJson::builder(config)
|
11150 - | /// .media_type_header(handler)
|
12383 + | /// .no_input_and_output(handler)
|
11151 12384 | /// /* Set other handlers */
|
11152 12385 | /// .build()
|
11153 12386 | /// .unwrap();
|
11154 12387 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11155 12388 | /// ```
|
11156 12389 | ///
|
11157 - | pub fn media_type_header<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12390 + | pub fn no_input_and_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11158 12391 | where
|
11159 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MediaTypeHeader, HandlerExtractors>,
|
12392 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndOutput, HandlerExtractors>,
|
11160 12393 |
|
11161 12394 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11162 12395 | RestJson<L>,
|
11163 - | crate::operation_shape::MediaTypeHeader,
|
11164 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MediaTypeHeader, HandlerType>
|
12396 + | crate::operation_shape::NoInputAndOutput,
|
12397 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndOutput, HandlerType>
|
11165 12398 | >,
|
11166 12399 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11167 12400 | RestJson<L>,
|
11168 - | crate::operation_shape::MediaTypeHeader,
|
12401 + | crate::operation_shape::NoInputAndOutput,
|
11169 12402 | ModelPl::Output
|
11170 12403 | >,
|
11171 12404 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11172 12405 | RestJson<L>,
|
11173 - | crate::operation_shape::MediaTypeHeader,
|
12406 + | crate::operation_shape::NoInputAndOutput,
|
11174 12407 | <
|
11175 12408 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11176 12409 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11177 12410 | RestJson<L>,
|
11178 - | crate::operation_shape::MediaTypeHeader,
|
12411 + | crate::operation_shape::NoInputAndOutput,
|
11179 12412 | ModelPl::Output
|
11180 12413 | >
|
11181 12414 | >::Output
|
11182 12415 | >,
|
11183 12416 |
|
11184 12417 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11185 12418 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11186 12419 |
|
11187 12420 | {
|
11188 12421 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11189 12422 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11190 - | let svc = crate::operation_shape::MediaTypeHeader::from_handler(handler);
|
12423 + | let svc = crate::operation_shape::NoInputAndOutput::from_handler(handler);
|
11191 12424 | let svc = self.model_plugin.apply(svc);
|
11192 12425 | let svc =
|
11193 12426 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11194 12427 | .apply(svc);
|
11195 12428 | let svc = self.http_plugin.apply(svc);
|
11196 - | self.media_type_header_custom(svc)
|
12429 + | self.no_input_and_output_custom(svc)
|
11197 12430 | }
|
11198 12431 |
|
11199 - | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
12432 + | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
11200 12433 | ///
|
11201 12434 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11202 12435 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11203 12436 | ///
|
11204 12437 | /// # Example
|
11205 12438 | ///
|
11206 12439 | /// ```no_run
|
11207 12440 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11208 12441 | ///
|
11209 12442 | /// use rest_json_http0x::{input, output, error};
|
11210 12443 | ///
|
11211 - | /// async fn handler(input: input::MediaTypeHeaderInput) -> Result<output::MediaTypeHeaderOutput, std::convert::Infallible> {
|
12444 + | /// async fn handler(input: input::NoInputAndOutputInput) -> Result<output::NoInputAndOutputOutput, std::convert::Infallible> {
|
11212 12445 | /// todo!()
|
11213 12446 | /// }
|
11214 12447 | ///
|
11215 12448 | /// let config = RestJsonConfig::builder().build();
|
11216 12449 | /// let svc = ::tower::util::service_fn(handler);
|
11217 12450 | /// let app = RestJson::builder(config)
|
11218 - | /// .media_type_header_service(svc)
|
12451 + | /// .no_input_and_output_service(svc)
|
11219 12452 | /// /* Set other handlers */
|
11220 12453 | /// .build()
|
11221 12454 | /// .unwrap();
|
11222 12455 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11223 12456 | /// ```
|
11224 12457 | ///
|
11225 - | pub fn media_type_header_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12458 + | pub fn no_input_and_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11226 12459 | where
|
11227 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MediaTypeHeader, ServiceExtractors>,
|
12460 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndOutput, ServiceExtractors>,
|
11228 12461 |
|
11229 12462 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11230 12463 | RestJson<L>,
|
11231 - | crate::operation_shape::MediaTypeHeader,
|
11232 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MediaTypeHeader, S>
|
12464 + | crate::operation_shape::NoInputAndOutput,
|
12465 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndOutput, S>
|
11233 12466 | >,
|
11234 12467 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11235 12468 | RestJson<L>,
|
11236 - | crate::operation_shape::MediaTypeHeader,
|
12469 + | crate::operation_shape::NoInputAndOutput,
|
11237 12470 | ModelPl::Output
|
11238 12471 | >,
|
11239 12472 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11240 12473 | RestJson<L>,
|
11241 - | crate::operation_shape::MediaTypeHeader,
|
12474 + | crate::operation_shape::NoInputAndOutput,
|
11242 12475 | <
|
11243 12476 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11244 12477 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11245 12478 | RestJson<L>,
|
11246 - | crate::operation_shape::MediaTypeHeader,
|
12479 + | crate::operation_shape::NoInputAndOutput,
|
11247 12480 | ModelPl::Output
|
11248 12481 | >
|
11249 12482 | >::Output
|
11250 12483 | >,
|
11251 12484 |
|
11252 12485 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11253 12486 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11254 12487 |
|
11255 12488 | {
|
11256 12489 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11257 12490 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11258 - | let svc = crate::operation_shape::MediaTypeHeader::from_service(service);
|
12491 + | let svc = crate::operation_shape::NoInputAndOutput::from_service(service);
|
11259 12492 | let svc = self.model_plugin.apply(svc);
|
11260 12493 | let svc =
|
11261 12494 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11262 12495 | .apply(svc);
|
11263 12496 | let svc = self.http_plugin.apply(svc);
|
11264 - | self.media_type_header_custom(svc)
|
12497 + | self.no_input_and_output_custom(svc)
|
11265 12498 | }
|
11266 12499 |
|
11267 - | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) to a custom [`Service`](tower::Service).
|
12500 + | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) to a custom [`Service`](tower::Service).
|
11268 12501 | /// not constrained by the Smithy contract.
|
11269 - | fn media_type_header_custom<S>(mut self, svc: S) -> Self
|
12502 + | fn no_input_and_output_custom<S>(mut self, svc: S) -> Self
|
11270 12503 | where
|
11271 12504 | S: ::tower::Service<
|
11272 12505 | ::http::Request<Body>,
|
11273 12506 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11274 12507 | Error = ::std::convert::Infallible,
|
11275 12508 | > + Clone
|
11276 12509 | + Send
|
11277 12510 | + 'static,
|
11278 12511 | S::Future: Send + 'static,
|
11279 12512 | {
|
11280 - | self.media_type_header = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12513 + | self.no_input_and_output = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11281 12514 | self
|
11282 12515 | }
|
11283 12516 |
|
11284 - | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
12517 + | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
11285 12518 | ///
|
11286 12519 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11287 12520 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11288 12521 | ///
|
11289 12522 | /// # Example
|
11290 12523 | ///
|
11291 12524 | /// ```no_run
|
11292 12525 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11293 12526 | ///
|
11294 12527 | /// use rest_json_http0x::{input, output, error};
|
11295 12528 | ///
|
11296 - | /// async fn handler(input: input::NoInputAndNoOutputInput) -> output::NoInputAndNoOutputOutput {
|
12529 + | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> output::NullAndEmptyHeadersClientOutput {
|
11297 12530 | /// todo!()
|
11298 12531 | /// }
|
11299 12532 | ///
|
11300 12533 | /// let config = RestJsonConfig::builder().build();
|
11301 12534 | /// let app = RestJson::builder(config)
|
11302 - | /// .no_input_and_no_output(handler)
|
12535 + | /// .null_and_empty_headers_client(handler)
|
11303 12536 | /// /* Set other handlers */
|
11304 12537 | /// .build()
|
11305 12538 | /// .unwrap();
|
11306 12539 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11307 12540 | /// ```
|
11308 12541 | ///
|
11309 - | pub fn no_input_and_no_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12542 + | pub fn null_and_empty_headers_client<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11310 12543 | where
|
11311 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndNoOutput, HandlerExtractors>,
|
12544 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersClient, HandlerExtractors>,
|
11312 12545 |
|
11313 12546 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11314 12547 | RestJson<L>,
|
11315 - | crate::operation_shape::NoInputAndNoOutput,
|
11316 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndNoOutput, HandlerType>
|
12548 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
12549 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersClient, HandlerType>
|
11317 12550 | >,
|
11318 12551 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11319 12552 | RestJson<L>,
|
11320 - | crate::operation_shape::NoInputAndNoOutput,
|
12553 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11321 12554 | ModelPl::Output
|
11322 12555 | >,
|
11323 12556 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11324 12557 | RestJson<L>,
|
11325 - | crate::operation_shape::NoInputAndNoOutput,
|
12558 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11326 12559 | <
|
11327 12560 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11328 12561 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11329 12562 | RestJson<L>,
|
11330 - | crate::operation_shape::NoInputAndNoOutput,
|
12563 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11331 12564 | ModelPl::Output
|
11332 12565 | >
|
11333 12566 | >::Output
|
11334 12567 | >,
|
11335 12568 |
|
11336 12569 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11337 12570 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11338 12571 |
|
11339 12572 | {
|
11340 12573 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11341 12574 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11342 - | let svc = crate::operation_shape::NoInputAndNoOutput::from_handler(handler);
|
12575 + | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_handler(handler);
|
11343 12576 | let svc = self.model_plugin.apply(svc);
|
11344 12577 | let svc =
|
11345 12578 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11346 12579 | .apply(svc);
|
11347 12580 | let svc = self.http_plugin.apply(svc);
|
11348 - | self.no_input_and_no_output_custom(svc)
|
12581 + | self.null_and_empty_headers_client_custom(svc)
|
11349 12582 | }
|
11350 12583 |
|
11351 - | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
12584 + | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
11352 12585 | ///
|
11353 12586 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11354 12587 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11355 12588 | ///
|
11356 12589 | /// # Example
|
11357 12590 | ///
|
11358 12591 | /// ```no_run
|
11359 12592 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11360 12593 | ///
|
11361 12594 | /// use rest_json_http0x::{input, output, error};
|
11362 12595 | ///
|
11363 - | /// async fn handler(input: input::NoInputAndNoOutputInput) -> Result<output::NoInputAndNoOutputOutput, std::convert::Infallible> {
|
12596 + | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> Result<output::NullAndEmptyHeadersClientOutput, std::convert::Infallible> {
|
11364 12597 | /// todo!()
|
11365 12598 | /// }
|
11366 12599 | ///
|
11367 12600 | /// let config = RestJsonConfig::builder().build();
|
11368 12601 | /// let svc = ::tower::util::service_fn(handler);
|
11369 12602 | /// let app = RestJson::builder(config)
|
11370 - | /// .no_input_and_no_output_service(svc)
|
12603 + | /// .null_and_empty_headers_client_service(svc)
|
11371 12604 | /// /* Set other handlers */
|
11372 12605 | /// .build()
|
11373 12606 | /// .unwrap();
|
11374 12607 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11375 12608 | /// ```
|
11376 12609 | ///
|
11377 - | pub fn no_input_and_no_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12610 + | pub fn null_and_empty_headers_client_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11378 12611 | where
|
11379 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndNoOutput, ServiceExtractors>,
|
12612 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersClient, ServiceExtractors>,
|
11380 12613 |
|
11381 12614 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11382 12615 | RestJson<L>,
|
11383 - | crate::operation_shape::NoInputAndNoOutput,
|
11384 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndNoOutput, S>
|
12616 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
12617 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersClient, S>
|
11385 12618 | >,
|
11386 12619 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11387 12620 | RestJson<L>,
|
11388 - | crate::operation_shape::NoInputAndNoOutput,
|
12621 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11389 12622 | ModelPl::Output
|
11390 12623 | >,
|
11391 12624 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11392 12625 | RestJson<L>,
|
11393 - | crate::operation_shape::NoInputAndNoOutput,
|
12626 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11394 12627 | <
|
11395 12628 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11396 12629 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11397 12630 | RestJson<L>,
|
11398 - | crate::operation_shape::NoInputAndNoOutput,
|
12631 + | crate::operation_shape::NullAndEmptyHeadersClient,
|
11399 12632 | ModelPl::Output
|
11400 12633 | >
|
11401 12634 | >::Output
|
11402 12635 | >,
|
11403 12636 |
|
11404 12637 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11405 12638 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11406 12639 |
|
11407 12640 | {
|
11408 12641 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11409 12642 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11410 - | let svc = crate::operation_shape::NoInputAndNoOutput::from_service(service);
|
12643 + | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_service(service);
|
11411 12644 | let svc = self.model_plugin.apply(svc);
|
11412 12645 | let svc =
|
11413 12646 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11414 12647 | .apply(svc);
|
11415 12648 | let svc = self.http_plugin.apply(svc);
|
11416 - | self.no_input_and_no_output_custom(svc)
|
12649 + | self.null_and_empty_headers_client_custom(svc)
|
11417 12650 | }
|
11418 12651 |
|
11419 - | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) to a custom [`Service`](tower::Service).
|
12652 + | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) to a custom [`Service`](tower::Service).
|
11420 12653 | /// not constrained by the Smithy contract.
|
11421 - | fn no_input_and_no_output_custom<S>(mut self, svc: S) -> Self
|
12654 + | fn null_and_empty_headers_client_custom<S>(mut self, svc: S) -> Self
|
11422 12655 | where
|
11423 12656 | S: ::tower::Service<
|
11424 12657 | ::http::Request<Body>,
|
11425 12658 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11426 12659 | Error = ::std::convert::Infallible,
|
11427 12660 | > + Clone
|
11428 12661 | + Send
|
11429 12662 | + 'static,
|
11430 12663 | S::Future: Send + 'static,
|
11431 12664 | {
|
11432 - | self.no_input_and_no_output =
|
12665 + | self.null_and_empty_headers_client =
|
11433 12666 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11434 12667 | self
|
11435 12668 | }
|
11436 12669 |
|
11437 - | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
12670 + | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
11438 12671 | ///
|
11439 12672 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11440 12673 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11441 12674 | ///
|
11442 12675 | /// # Example
|
11443 12676 | ///
|
11444 12677 | /// ```no_run
|
11445 12678 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11446 12679 | ///
|
11447 12680 | /// use rest_json_http0x::{input, output, error};
|
11448 12681 | ///
|
11449 - | /// async fn handler(input: input::NoInputAndOutputInput) -> output::NoInputAndOutputOutput {
|
12682 + | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> output::NullAndEmptyHeadersServerOutput {
|
11450 12683 | /// todo!()
|
11451 12684 | /// }
|
11452 12685 | ///
|
11453 12686 | /// let config = RestJsonConfig::builder().build();
|
11454 12687 | /// let app = RestJson::builder(config)
|
11455 - | /// .no_input_and_output(handler)
|
12688 + | /// .null_and_empty_headers_server(handler)
|
11456 12689 | /// /* Set other handlers */
|
11457 12690 | /// .build()
|
11458 12691 | /// .unwrap();
|
11459 12692 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11460 12693 | /// ```
|
11461 12694 | ///
|
11462 - | pub fn no_input_and_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12695 + | pub fn null_and_empty_headers_server<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11463 12696 | where
|
11464 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndOutput, HandlerExtractors>,
|
12697 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersServer, HandlerExtractors>,
|
11465 12698 |
|
11466 12699 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11467 12700 | RestJson<L>,
|
11468 - | crate::operation_shape::NoInputAndOutput,
|
11469 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndOutput, HandlerType>
|
12701 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
12702 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersServer, HandlerType>
|
11470 12703 | >,
|
11471 12704 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11472 12705 | RestJson<L>,
|
11473 - | crate::operation_shape::NoInputAndOutput,
|
12706 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11474 12707 | ModelPl::Output
|
11475 12708 | >,
|
11476 12709 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11477 12710 | RestJson<L>,
|
11478 - | crate::operation_shape::NoInputAndOutput,
|
12711 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11479 12712 | <
|
11480 12713 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11481 12714 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11482 12715 | RestJson<L>,
|
11483 - | crate::operation_shape::NoInputAndOutput,
|
12716 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11484 12717 | ModelPl::Output
|
11485 12718 | >
|
11486 12719 | >::Output
|
11487 12720 | >,
|
11488 12721 |
|
11489 12722 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11490 12723 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11491 12724 |
|
11492 12725 | {
|
11493 12726 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11494 12727 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11495 - | let svc = crate::operation_shape::NoInputAndOutput::from_handler(handler);
|
12728 + | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_handler(handler);
|
11496 12729 | let svc = self.model_plugin.apply(svc);
|
11497 12730 | let svc =
|
11498 12731 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11499 12732 | .apply(svc);
|
11500 12733 | let svc = self.http_plugin.apply(svc);
|
11501 - | self.no_input_and_output_custom(svc)
|
12734 + | self.null_and_empty_headers_server_custom(svc)
|
11502 12735 | }
|
11503 12736 |
|
11504 - | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
12737 + | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
11505 12738 | ///
|
11506 12739 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11507 12740 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11508 12741 | ///
|
11509 12742 | /// # Example
|
11510 12743 | ///
|
11511 12744 | /// ```no_run
|
11512 12745 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11513 12746 | ///
|
11514 12747 | /// use rest_json_http0x::{input, output, error};
|
11515 12748 | ///
|
11516 - | /// async fn handler(input: input::NoInputAndOutputInput) -> Result<output::NoInputAndOutputOutput, std::convert::Infallible> {
|
12749 + | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> Result<output::NullAndEmptyHeadersServerOutput, std::convert::Infallible> {
|
11517 12750 | /// todo!()
|
11518 12751 | /// }
|
11519 12752 | ///
|
11520 12753 | /// let config = RestJsonConfig::builder().build();
|
11521 12754 | /// let svc = ::tower::util::service_fn(handler);
|
11522 12755 | /// let app = RestJson::builder(config)
|
11523 - | /// .no_input_and_output_service(svc)
|
12756 + | /// .null_and_empty_headers_server_service(svc)
|
11524 12757 | /// /* Set other handlers */
|
11525 12758 | /// .build()
|
11526 12759 | /// .unwrap();
|
11527 12760 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11528 12761 | /// ```
|
11529 12762 | ///
|
11530 - | pub fn no_input_and_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12763 + | pub fn null_and_empty_headers_server_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11531 12764 | where
|
11532 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndOutput, ServiceExtractors>,
|
12765 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersServer, ServiceExtractors>,
|
11533 12766 |
|
11534 12767 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11535 12768 | RestJson<L>,
|
11536 - | crate::operation_shape::NoInputAndOutput,
|
11537 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndOutput, S>
|
12769 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
12770 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersServer, S>
|
11538 12771 | >,
|
11539 12772 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11540 12773 | RestJson<L>,
|
11541 - | crate::operation_shape::NoInputAndOutput,
|
12774 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11542 12775 | ModelPl::Output
|
11543 12776 | >,
|
11544 12777 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11545 12778 | RestJson<L>,
|
11546 - | crate::operation_shape::NoInputAndOutput,
|
12779 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11547 12780 | <
|
11548 12781 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11549 12782 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11550 12783 | RestJson<L>,
|
11551 - | crate::operation_shape::NoInputAndOutput,
|
12784 + | crate::operation_shape::NullAndEmptyHeadersServer,
|
11552 12785 | ModelPl::Output
|
11553 12786 | >
|
11554 12787 | >::Output
|
11555 12788 | >,
|
11556 12789 |
|
11557 12790 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11558 12791 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11559 12792 |
|
11560 12793 | {
|
11561 12794 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11562 12795 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11563 - | let svc = crate::operation_shape::NoInputAndOutput::from_service(service);
|
12796 + | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_service(service);
|
11564 12797 | let svc = self.model_plugin.apply(svc);
|
11565 12798 | let svc =
|
11566 12799 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11567 12800 | .apply(svc);
|
11568 12801 | let svc = self.http_plugin.apply(svc);
|
11569 - | self.no_input_and_output_custom(svc)
|
12802 + | self.null_and_empty_headers_server_custom(svc)
|
11570 12803 | }
|
11571 12804 |
|
11572 - | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) to a custom [`Service`](tower::Service).
|
12805 + | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) to a custom [`Service`](tower::Service).
|
11573 12806 | /// not constrained by the Smithy contract.
|
11574 - | fn no_input_and_output_custom<S>(mut self, svc: S) -> Self
|
12807 + | fn null_and_empty_headers_server_custom<S>(mut self, svc: S) -> Self
|
11575 12808 | where
|
11576 12809 | S: ::tower::Service<
|
11577 12810 | ::http::Request<Body>,
|
11578 12811 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11579 12812 | Error = ::std::convert::Infallible,
|
11580 12813 | > + Clone
|
11581 12814 | + Send
|
11582 12815 | + 'static,
|
11583 12816 | S::Future: Send + 'static,
|
11584 12817 | {
|
11585 - | self.no_input_and_output = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12818 + | self.null_and_empty_headers_server =
|
12819 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11586 12820 | self
|
11587 12821 | }
|
11588 12822 |
|
11589 - | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
12823 + | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
11590 12824 | ///
|
11591 12825 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11592 12826 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11593 12827 | ///
|
11594 12828 | /// # Example
|
11595 12829 | ///
|
11596 12830 | /// ```no_run
|
11597 12831 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11598 12832 | ///
|
11599 12833 | /// use rest_json_http0x::{input, output, error};
|
11600 12834 | ///
|
11601 - | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> output::NullAndEmptyHeadersClientOutput {
|
12835 + | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> output::OmitsNullSerializesEmptyStringOutput {
|
11602 12836 | /// todo!()
|
11603 12837 | /// }
|
11604 12838 | ///
|
11605 12839 | /// let config = RestJsonConfig::builder().build();
|
11606 12840 | /// let app = RestJson::builder(config)
|
11607 - | /// .null_and_empty_headers_client(handler)
|
12841 + | /// .omits_null_serializes_empty_string(handler)
|
11608 12842 | /// /* Set other handlers */
|
11609 12843 | /// .build()
|
11610 12844 | /// .unwrap();
|
11611 12845 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11612 12846 | /// ```
|
11613 12847 | ///
|
11614 - | pub fn null_and_empty_headers_client<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12848 + | pub fn omits_null_serializes_empty_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11615 12849 | where
|
11616 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersClient, HandlerExtractors>,
|
12850 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerExtractors>,
|
11617 12851 |
|
11618 12852 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11619 12853 | RestJson<L>,
|
11620 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
11621 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersClient, HandlerType>
|
12854 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
12855 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerType>
|
11622 12856 | >,
|
11623 12857 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11624 12858 | RestJson<L>,
|
11625 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12859 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11626 12860 | ModelPl::Output
|
11627 12861 | >,
|
11628 12862 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11629 12863 | RestJson<L>,
|
11630 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12864 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11631 12865 | <
|
11632 12866 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11633 12867 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11634 12868 | RestJson<L>,
|
11635 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12869 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11636 12870 | ModelPl::Output
|
11637 12871 | >
|
11638 12872 | >::Output
|
11639 12873 | >,
|
11640 12874 |
|
11641 12875 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11642 12876 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11643 12877 |
|
11644 12878 | {
|
11645 12879 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11646 12880 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11647 - | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_handler(handler);
|
12881 + | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_handler(handler);
|
11648 12882 | let svc = self.model_plugin.apply(svc);
|
11649 12883 | let svc =
|
11650 12884 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11651 12885 | .apply(svc);
|
11652 12886 | let svc = self.http_plugin.apply(svc);
|
11653 - | self.null_and_empty_headers_client_custom(svc)
|
12887 + | self.omits_null_serializes_empty_string_custom(svc)
|
11654 12888 | }
|
11655 12889 |
|
11656 - | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
12890 + | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
11657 12891 | ///
|
11658 12892 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11659 12893 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11660 12894 | ///
|
11661 12895 | /// # Example
|
11662 12896 | ///
|
11663 12897 | /// ```no_run
|
11664 12898 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11665 12899 | ///
|
11666 12900 | /// use rest_json_http0x::{input, output, error};
|
11667 12901 | ///
|
11668 - | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> Result<output::NullAndEmptyHeadersClientOutput, std::convert::Infallible> {
|
12902 + | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> Result<output::OmitsNullSerializesEmptyStringOutput, std::convert::Infallible> {
|
11669 12903 | /// todo!()
|
11670 12904 | /// }
|
11671 12905 | ///
|
11672 12906 | /// let config = RestJsonConfig::builder().build();
|
11673 12907 | /// let svc = ::tower::util::service_fn(handler);
|
11674 12908 | /// let app = RestJson::builder(config)
|
11675 - | /// .null_and_empty_headers_client_service(svc)
|
12909 + | /// .omits_null_serializes_empty_string_service(svc)
|
11676 12910 | /// /* Set other handlers */
|
11677 12911 | /// .build()
|
11678 12912 | /// .unwrap();
|
11679 12913 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11680 12914 | /// ```
|
11681 12915 | ///
|
11682 - | pub fn null_and_empty_headers_client_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12916 + | pub fn omits_null_serializes_empty_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11683 12917 | where
|
11684 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersClient, ServiceExtractors>,
|
12918 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsNullSerializesEmptyString, ServiceExtractors>,
|
11685 12919 |
|
11686 12920 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11687 12921 | RestJson<L>,
|
11688 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
11689 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersClient, S>
|
12922 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
12923 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsNullSerializesEmptyString, S>
|
11690 12924 | >,
|
11691 12925 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11692 12926 | RestJson<L>,
|
11693 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12927 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11694 12928 | ModelPl::Output
|
11695 12929 | >,
|
11696 12930 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11697 12931 | RestJson<L>,
|
11698 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12932 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11699 12933 | <
|
11700 12934 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11701 12935 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11702 12936 | RestJson<L>,
|
11703 - | crate::operation_shape::NullAndEmptyHeadersClient,
|
12937 + | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11704 12938 | ModelPl::Output
|
11705 12939 | >
|
11706 12940 | >::Output
|
11707 12941 | >,
|
11708 12942 |
|
11709 12943 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11710 12944 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11711 12945 |
|
11712 12946 | {
|
11713 12947 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11714 12948 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11715 - | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_service(service);
|
12949 + | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_service(service);
|
11716 12950 | let svc = self.model_plugin.apply(svc);
|
11717 12951 | let svc =
|
11718 12952 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11719 12953 | .apply(svc);
|
11720 12954 | let svc = self.http_plugin.apply(svc);
|
11721 - | self.null_and_empty_headers_client_custom(svc)
|
12955 + | self.omits_null_serializes_empty_string_custom(svc)
|
11722 12956 | }
|
11723 12957 |
|
11724 - | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) to a custom [`Service`](tower::Service).
|
12958 + | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) to a custom [`Service`](tower::Service).
|
11725 12959 | /// not constrained by the Smithy contract.
|
11726 - | fn null_and_empty_headers_client_custom<S>(mut self, svc: S) -> Self
|
12960 + | fn omits_null_serializes_empty_string_custom<S>(mut self, svc: S) -> Self
|
11727 12961 | where
|
11728 12962 | S: ::tower::Service<
|
11729 12963 | ::http::Request<Body>,
|
11730 12964 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11731 12965 | Error = ::std::convert::Infallible,
|
11732 12966 | > + Clone
|
11733 12967 | + Send
|
11734 12968 | + 'static,
|
11735 12969 | S::Future: Send + 'static,
|
11736 12970 | {
|
11737 - | self.null_and_empty_headers_client =
|
12971 + | self.omits_null_serializes_empty_string =
|
11738 12972 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11739 12973 | self
|
11740 12974 | }
|
11741 12975 |
|
11742 - | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
12976 + | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
11743 12977 | ///
|
11744 12978 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11745 12979 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11746 12980 | ///
|
11747 12981 | /// # Example
|
11748 12982 | ///
|
11749 12983 | /// ```no_run
|
11750 12984 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11751 12985 | ///
|
11752 12986 | /// use rest_json_http0x::{input, output, error};
|
11753 12987 | ///
|
11754 - | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> output::NullAndEmptyHeadersServerOutput {
|
12988 + | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
11755 12989 | /// todo!()
|
11756 12990 | /// }
|
11757 12991 | ///
|
11758 12992 | /// let config = RestJsonConfig::builder().build();
|
11759 12993 | /// let app = RestJson::builder(config)
|
11760 - | /// .null_and_empty_headers_server(handler)
|
12994 + | /// .omits_serializing_empty_lists(handler)
|
11761 12995 | /// /* Set other handlers */
|
11762 12996 | /// .build()
|
11763 12997 | /// .unwrap();
|
11764 12998 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11765 12999 | /// ```
|
11766 13000 | ///
|
11767 - | pub fn null_and_empty_headers_server<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13001 + | pub fn omits_serializing_empty_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11768 13002 | where
|
11769 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersServer, HandlerExtractors>,
|
13003 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsSerializingEmptyLists, HandlerExtractors>,
|
11770 13004 |
|
11771 13005 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11772 13006 | RestJson<L>,
|
11773 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
11774 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersServer, HandlerType>
|
13007 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
13008 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsSerializingEmptyLists, HandlerType>
|
11775 13009 | >,
|
11776 13010 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11777 13011 | RestJson<L>,
|
11778 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13012 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11779 13013 | ModelPl::Output
|
11780 13014 | >,
|
11781 13015 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11782 13016 | RestJson<L>,
|
11783 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13017 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11784 13018 | <
|
11785 13019 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11786 13020 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11787 13021 | RestJson<L>,
|
11788 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13022 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11789 13023 | ModelPl::Output
|
11790 13024 | >
|
11791 13025 | >::Output
|
11792 13026 | >,
|
11793 13027 |
|
11794 13028 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11795 13029 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11796 13030 |
|
11797 13031 | {
|
11798 13032 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11799 13033 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11800 - | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_handler(handler);
|
13034 + | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_handler(handler);
|
11801 13035 | let svc = self.model_plugin.apply(svc);
|
11802 13036 | let svc =
|
11803 13037 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11804 13038 | .apply(svc);
|
11805 13039 | let svc = self.http_plugin.apply(svc);
|
11806 - | self.null_and_empty_headers_server_custom(svc)
|
13040 + | self.omits_serializing_empty_lists_custom(svc)
|
11807 13041 | }
|
11808 13042 |
|
11809 - | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
13043 + | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
11810 13044 | ///
|
11811 13045 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11812 13046 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11813 13047 | ///
|
11814 13048 | /// # Example
|
11815 13049 | ///
|
11816 13050 | /// ```no_run
|
11817 13051 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11818 13052 | ///
|
11819 13053 | /// use rest_json_http0x::{input, output, error};
|
11820 13054 | ///
|
11821 - | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> Result<output::NullAndEmptyHeadersServerOutput, std::convert::Infallible> {
|
13055 + | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
11822 13056 | /// todo!()
|
11823 13057 | /// }
|
11824 13058 | ///
|
11825 13059 | /// let config = RestJsonConfig::builder().build();
|
11826 13060 | /// let svc = ::tower::util::service_fn(handler);
|
11827 13061 | /// let app = RestJson::builder(config)
|
11828 - | /// .null_and_empty_headers_server_service(svc)
|
13062 + | /// .omits_serializing_empty_lists_service(svc)
|
11829 13063 | /// /* Set other handlers */
|
11830 13064 | /// .build()
|
11831 13065 | /// .unwrap();
|
11832 13066 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11833 13067 | /// ```
|
11834 13068 | ///
|
11835 - | pub fn null_and_empty_headers_server_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13069 + | pub fn omits_serializing_empty_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11836 13070 | where
|
11837 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersServer, ServiceExtractors>,
|
13071 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsSerializingEmptyLists, ServiceExtractors>,
|
11838 13072 |
|
11839 13073 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11840 13074 | RestJson<L>,
|
11841 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
11842 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersServer, S>
|
13075 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
13076 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsSerializingEmptyLists, S>
|
11843 13077 | >,
|
11844 13078 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11845 13079 | RestJson<L>,
|
11846 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13080 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11847 13081 | ModelPl::Output
|
11848 13082 | >,
|
11849 13083 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11850 13084 | RestJson<L>,
|
11851 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13085 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11852 13086 | <
|
11853 13087 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11854 13088 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11855 13089 | RestJson<L>,
|
11856 - | crate::operation_shape::NullAndEmptyHeadersServer,
|
13090 + | crate::operation_shape::OmitsSerializingEmptyLists,
|
11857 13091 | ModelPl::Output
|
11858 13092 | >
|
11859 13093 | >::Output
|
11860 13094 | >,
|
11861 13095 |
|
11862 13096 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11863 13097 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11864 13098 |
|
11865 13099 | {
|
11866 13100 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11867 13101 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11868 - | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_service(service);
|
13102 + | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_service(service);
|
11869 13103 | let svc = self.model_plugin.apply(svc);
|
11870 13104 | let svc =
|
11871 13105 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11872 13106 | .apply(svc);
|
11873 13107 | let svc = self.http_plugin.apply(svc);
|
11874 - | self.null_and_empty_headers_server_custom(svc)
|
13108 + | self.omits_serializing_empty_lists_custom(svc)
|
11875 13109 | }
|
11876 13110 |
|
11877 - | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) to a custom [`Service`](tower::Service).
|
13111 + | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) to a custom [`Service`](tower::Service).
|
11878 13112 | /// not constrained by the Smithy contract.
|
11879 - | fn null_and_empty_headers_server_custom<S>(mut self, svc: S) -> Self
|
13113 + | fn omits_serializing_empty_lists_custom<S>(mut self, svc: S) -> Self
|
11880 13114 | where
|
11881 13115 | S: ::tower::Service<
|
11882 13116 | ::http::Request<Body>,
|
11883 13117 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11884 13118 | Error = ::std::convert::Infallible,
|
11885 13119 | > + Clone
|
11886 13120 | + Send
|
11887 13121 | + 'static,
|
11888 13122 | S::Future: Send + 'static,
|
11889 13123 | {
|
11890 - | self.null_and_empty_headers_server =
|
13124 + | self.omits_serializing_empty_lists =
|
11891 13125 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11892 13126 | self
|
11893 13127 | }
|
11894 13128 |
|
11895 - | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
13129 + | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
11896 13130 | ///
|
11897 13131 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11898 13132 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11899 13133 | ///
|
11900 13134 | /// # Example
|
11901 13135 | ///
|
11902 13136 | /// ```no_run
|
11903 13137 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11904 13138 | ///
|
11905 13139 | /// use rest_json_http0x::{input, output, error};
|
11906 13140 | ///
|
11907 - | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> output::OmitsNullSerializesEmptyStringOutput {
|
13141 + | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
11908 13142 | /// todo!()
|
11909 13143 | /// }
|
11910 13144 | ///
|
11911 13145 | /// let config = RestJsonConfig::builder().build();
|
11912 13146 | /// let app = RestJson::builder(config)
|
11913 - | /// .omits_null_serializes_empty_string(handler)
|
13147 + | /// .operation_with_defaults(handler)
|
11914 13148 | /// /* Set other handlers */
|
11915 13149 | /// .build()
|
11916 13150 | /// .unwrap();
|
11917 13151 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11918 13152 | /// ```
|
11919 13153 | ///
|
11920 - | pub fn omits_null_serializes_empty_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13154 + | pub fn operation_with_defaults<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11921 13155 | where
|
11922 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerExtractors>,
|
13156 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithDefaults, HandlerExtractors>,
|
11923 13157 |
|
11924 13158 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11925 13159 | RestJson<L>,
|
11926 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11927 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerType>
|
13160 + | crate::operation_shape::OperationWithDefaults,
|
13161 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithDefaults, HandlerType>
|
11928 13162 | >,
|
11929 13163 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11930 13164 | RestJson<L>,
|
11931 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13165 + | crate::operation_shape::OperationWithDefaults,
|
11932 13166 | ModelPl::Output
|
11933 13167 | >,
|
11934 13168 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11935 13169 | RestJson<L>,
|
11936 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13170 + | crate::operation_shape::OperationWithDefaults,
|
11937 13171 | <
|
11938 13172 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11939 13173 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11940 13174 | RestJson<L>,
|
11941 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13175 + | crate::operation_shape::OperationWithDefaults,
|
11942 13176 | ModelPl::Output
|
11943 13177 | >
|
11944 13178 | >::Output
|
11945 13179 | >,
|
11946 13180 |
|
11947 13181 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11948 13182 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11949 13183 |
|
11950 13184 | {
|
11951 13185 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11952 13186 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11953 - | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_handler(handler);
|
13187 + | let svc = crate::operation_shape::OperationWithDefaults::from_handler(handler);
|
11954 13188 | let svc = self.model_plugin.apply(svc);
|
11955 13189 | let svc =
|
11956 13190 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11957 13191 | .apply(svc);
|
11958 13192 | let svc = self.http_plugin.apply(svc);
|
11959 - | self.omits_null_serializes_empty_string_custom(svc)
|
13193 + | self.operation_with_defaults_custom(svc)
|
11960 13194 | }
|
11961 13195 |
|
11962 - | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
13196 + | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
11963 13197 | ///
|
11964 13198 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11965 13199 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11966 13200 | ///
|
11967 13201 | /// # Example
|
11968 13202 | ///
|
11969 13203 | /// ```no_run
|
11970 13204 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
11971 13205 | ///
|
11972 13206 | /// use rest_json_http0x::{input, output, error};
|
11973 13207 | ///
|
11974 - | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> Result<output::OmitsNullSerializesEmptyStringOutput, std::convert::Infallible> {
|
13208 + | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
11975 13209 | /// todo!()
|
11976 13210 | /// }
|
11977 13211 | ///
|
11978 13212 | /// let config = RestJsonConfig::builder().build();
|
11979 13213 | /// let svc = ::tower::util::service_fn(handler);
|
11980 13214 | /// let app = RestJson::builder(config)
|
11981 - | /// .omits_null_serializes_empty_string_service(svc)
|
13215 + | /// .operation_with_defaults_service(svc)
|
11982 13216 | /// /* Set other handlers */
|
11983 13217 | /// .build()
|
11984 13218 | /// .unwrap();
|
11985 13219 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11986 13220 | /// ```
|
11987 13221 | ///
|
11988 - | pub fn omits_null_serializes_empty_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13222 + | pub fn operation_with_defaults_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11989 13223 | where
|
11990 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsNullSerializesEmptyString, ServiceExtractors>,
|
13224 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithDefaults, ServiceExtractors>,
|
11991 13225 |
|
11992 13226 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11993 13227 | RestJson<L>,
|
11994 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11995 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsNullSerializesEmptyString, S>
|
13228 + | crate::operation_shape::OperationWithDefaults,
|
13229 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithDefaults, S>
|
11996 13230 | >,
|
11997 13231 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11998 13232 | RestJson<L>,
|
11999 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13233 + | crate::operation_shape::OperationWithDefaults,
|
12000 13234 | ModelPl::Output
|
12001 13235 | >,
|
12002 13236 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12003 13237 | RestJson<L>,
|
12004 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13238 + | crate::operation_shape::OperationWithDefaults,
|
12005 13239 | <
|
12006 13240 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12007 13241 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12008 13242 | RestJson<L>,
|
12009 - | crate::operation_shape::OmitsNullSerializesEmptyString,
|
13243 + | crate::operation_shape::OperationWithDefaults,
|
12010 13244 | ModelPl::Output
|
12011 13245 | >
|
12012 13246 | >::Output
|
12013 13247 | >,
|
12014 13248 |
|
12015 13249 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12016 13250 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12017 13251 |
|
12018 13252 | {
|
12019 13253 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12020 13254 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12021 - | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_service(service);
|
13255 + | let svc = crate::operation_shape::OperationWithDefaults::from_service(service);
|
12022 13256 | let svc = self.model_plugin.apply(svc);
|
12023 13257 | let svc =
|
12024 13258 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12025 13259 | .apply(svc);
|
12026 13260 | let svc = self.http_plugin.apply(svc);
|
12027 - | self.omits_null_serializes_empty_string_custom(svc)
|
13261 + | self.operation_with_defaults_custom(svc)
|
12028 13262 | }
|
12029 13263 |
|
12030 - | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) to a custom [`Service`](tower::Service).
|
13264 + | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) to a custom [`Service`](tower::Service).
|
12031 13265 | /// not constrained by the Smithy contract.
|
12032 - | fn omits_null_serializes_empty_string_custom<S>(mut self, svc: S) -> Self
|
13266 + | fn operation_with_defaults_custom<S>(mut self, svc: S) -> Self
|
12033 13267 | where
|
12034 13268 | S: ::tower::Service<
|
12035 13269 | ::http::Request<Body>,
|
12036 13270 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12037 13271 | Error = ::std::convert::Infallible,
|
12038 13272 | > + Clone
|
12039 13273 | + Send
|
12040 13274 | + 'static,
|
12041 13275 | S::Future: Send + 'static,
|
12042 13276 | {
|
12043 - | self.omits_null_serializes_empty_string =
|
13277 + | self.operation_with_defaults =
|
12044 13278 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12045 13279 | self
|
12046 13280 | }
|
12047 13281 |
|
12048 - | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
13282 + | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
12049 13283 | ///
|
12050 13284 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12051 13285 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12052 13286 | ///
|
12053 13287 | /// # Example
|
12054 13288 | ///
|
12055 13289 | /// ```no_run
|
12056 13290 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12057 13291 | ///
|
12058 13292 | /// use rest_json_http0x::{input, output, error};
|
12059 13293 | ///
|
12060 - | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
13294 + | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
12061 13295 | /// todo!()
|
12062 13296 | /// }
|
12063 13297 | ///
|
12064 13298 | /// let config = RestJsonConfig::builder().build();
|
12065 13299 | /// let app = RestJson::builder(config)
|
12066 - | /// .omits_serializing_empty_lists(handler)
|
13300 + | /// .operation_with_nested_structure(handler)
|
12067 13301 | /// /* Set other handlers */
|
12068 13302 | /// .build()
|
12069 13303 | /// .unwrap();
|
12070 13304 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12071 13305 | /// ```
|
12072 13306 | ///
|
12073 - | pub fn omits_serializing_empty_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13307 + | pub fn operation_with_nested_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12074 13308 | where
|
12075 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsSerializingEmptyLists, HandlerExtractors>,
|
13309 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithNestedStructure, HandlerExtractors>,
|
12076 13310 |
|
12077 13311 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12078 13312 | RestJson<L>,
|
12079 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
12080 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsSerializingEmptyLists, HandlerType>
|
13313 + | crate::operation_shape::OperationWithNestedStructure,
|
13314 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithNestedStructure, HandlerType>
|
12081 13315 | >,
|
12082 13316 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12083 13317 | RestJson<L>,
|
12084 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13318 + | crate::operation_shape::OperationWithNestedStructure,
|
12085 13319 | ModelPl::Output
|
12086 13320 | >,
|
12087 13321 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12088 13322 | RestJson<L>,
|
12089 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13323 + | crate::operation_shape::OperationWithNestedStructure,
|
12090 13324 | <
|
12091 13325 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12092 13326 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12093 13327 | RestJson<L>,
|
12094 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13328 + | crate::operation_shape::OperationWithNestedStructure,
|
12095 13329 | ModelPl::Output
|
12096 13330 | >
|
12097 13331 | >::Output
|
12098 13332 | >,
|
12099 13333 |
|
12100 13334 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12101 13335 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12102 13336 |
|
12103 13337 | {
|
12104 13338 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12105 13339 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12106 - | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_handler(handler);
|
13340 + | let svc = crate::operation_shape::OperationWithNestedStructure::from_handler(handler);
|
12107 13341 | let svc = self.model_plugin.apply(svc);
|
12108 13342 | let svc =
|
12109 13343 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12110 13344 | .apply(svc);
|
12111 13345 | let svc = self.http_plugin.apply(svc);
|
12112 - | self.omits_serializing_empty_lists_custom(svc)
|
13346 + | self.operation_with_nested_structure_custom(svc)
|
12113 13347 | }
|
12114 13348 |
|
12115 - | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
13349 + | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
12116 13350 | ///
|
12117 13351 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12118 13352 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12119 13353 | ///
|
12120 13354 | /// # Example
|
12121 13355 | ///
|
12122 13356 | /// ```no_run
|
12123 13357 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12124 13358 | ///
|
12125 13359 | /// use rest_json_http0x::{input, output, error};
|
12126 13360 | ///
|
12127 - | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
13361 + | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
12128 13362 | /// todo!()
|
12129 13363 | /// }
|
12130 13364 | ///
|
12131 13365 | /// let config = RestJsonConfig::builder().build();
|
12132 13366 | /// let svc = ::tower::util::service_fn(handler);
|
12133 13367 | /// let app = RestJson::builder(config)
|
12134 - | /// .omits_serializing_empty_lists_service(svc)
|
13368 + | /// .operation_with_nested_structure_service(svc)
|
12135 13369 | /// /* Set other handlers */
|
12136 13370 | /// .build()
|
12137 13371 | /// .unwrap();
|
12138 13372 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12139 13373 | /// ```
|
12140 13374 | ///
|
12141 - | pub fn omits_serializing_empty_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13375 + | pub fn operation_with_nested_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12142 13376 | where
|
12143 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsSerializingEmptyLists, ServiceExtractors>,
|
13377 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithNestedStructure, ServiceExtractors>,
|
12144 13378 |
|
12145 13379 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12146 13380 | RestJson<L>,
|
12147 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
12148 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsSerializingEmptyLists, S>
|
13381 + | crate::operation_shape::OperationWithNestedStructure,
|
13382 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithNestedStructure, S>
|
12149 13383 | >,
|
12150 13384 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12151 13385 | RestJson<L>,
|
12152 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13386 + | crate::operation_shape::OperationWithNestedStructure,
|
12153 13387 | ModelPl::Output
|
12154 13388 | >,
|
12155 13389 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12156 13390 | RestJson<L>,
|
12157 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13391 + | crate::operation_shape::OperationWithNestedStructure,
|
12158 13392 | <
|
12159 13393 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12160 13394 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12161 13395 | RestJson<L>,
|
12162 - | crate::operation_shape::OmitsSerializingEmptyLists,
|
13396 + | crate::operation_shape::OperationWithNestedStructure,
|
12163 13397 | ModelPl::Output
|
12164 13398 | >
|
12165 13399 | >::Output
|
12166 13400 | >,
|
12167 13401 |
|
12168 13402 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12169 13403 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12170 13404 |
|
12171 13405 | {
|
12172 13406 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12173 13407 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12174 - | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_service(service);
|
13408 + | let svc = crate::operation_shape::OperationWithNestedStructure::from_service(service);
|
12175 13409 | let svc = self.model_plugin.apply(svc);
|
12176 13410 | let svc =
|
12177 13411 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12178 13412 | .apply(svc);
|
12179 13413 | let svc = self.http_plugin.apply(svc);
|
12180 - | self.omits_serializing_empty_lists_custom(svc)
|
13414 + | self.operation_with_nested_structure_custom(svc)
|
12181 13415 | }
|
12182 13416 |
|
12183 - | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) to a custom [`Service`](tower::Service).
|
13417 + | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) to a custom [`Service`](tower::Service).
|
12184 13418 | /// not constrained by the Smithy contract.
|
12185 - | fn omits_serializing_empty_lists_custom<S>(mut self, svc: S) -> Self
|
13419 + | fn operation_with_nested_structure_custom<S>(mut self, svc: S) -> Self
|
12186 13420 | where
|
12187 13421 | S: ::tower::Service<
|
12188 13422 | ::http::Request<Body>,
|
12189 13423 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12190 13424 | Error = ::std::convert::Infallible,
|
12191 13425 | > + Clone
|
12192 13426 | + Send
|
12193 13427 | + 'static,
|
12194 13428 | S::Future: Send + 'static,
|
12195 13429 | {
|
12196 - | self.omits_serializing_empty_lists =
|
13430 + | self.operation_with_nested_structure =
|
12197 13431 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12198 13432 | self
|
12199 13433 | }
|
12200 13434 |
|
12201 - | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
13435 + | /// Sets the [`OutputStream`](crate::operation_shape::OutputStream) operation.
|
12202 13436 | ///
|
12203 13437 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12204 13438 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12205 13439 | ///
|
12206 13440 | /// # Example
|
12207 13441 | ///
|
12208 13442 | /// ```no_run
|
12209 13443 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12210 13444 | ///
|
12211 13445 | /// use rest_json_http0x::{input, output, error};
|
12212 13446 | ///
|
12213 - | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
13447 + | /// async fn handler(input: input::OutputStreamInput) -> Result<output::OutputStreamOutput, error::OutputStreamError> {
|
12214 13448 | /// todo!()
|
12215 13449 | /// }
|
12216 13450 | ///
|
12217 13451 | /// let config = RestJsonConfig::builder().build();
|
12218 13452 | /// let app = RestJson::builder(config)
|
12219 - | /// .operation_with_defaults(handler)
|
13453 + | /// .output_stream(handler)
|
12220 13454 | /// /* Set other handlers */
|
12221 13455 | /// .build()
|
12222 13456 | /// .unwrap();
|
12223 13457 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12224 13458 | /// ```
|
12225 13459 | ///
|
12226 - | pub fn operation_with_defaults<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13460 + | pub fn output_stream<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12227 13461 | where
|
12228 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithDefaults, HandlerExtractors>,
|
13462 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OutputStream, HandlerExtractors>,
|
12229 13463 |
|
12230 13464 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12231 13465 | RestJson<L>,
|
12232 - | crate::operation_shape::OperationWithDefaults,
|
12233 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithDefaults, HandlerType>
|
13466 + | crate::operation_shape::OutputStream,
|
13467 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OutputStream, HandlerType>
|
12234 13468 | >,
|
12235 13469 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12236 13470 | RestJson<L>,
|
12237 - | crate::operation_shape::OperationWithDefaults,
|
13471 + | crate::operation_shape::OutputStream,
|
12238 13472 | ModelPl::Output
|
12239 13473 | >,
|
12240 13474 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12241 13475 | RestJson<L>,
|
12242 - | crate::operation_shape::OperationWithDefaults,
|
13476 + | crate::operation_shape::OutputStream,
|
12243 13477 | <
|
12244 13478 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12245 13479 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12246 13480 | RestJson<L>,
|
12247 - | crate::operation_shape::OperationWithDefaults,
|
13481 + | crate::operation_shape::OutputStream,
|
12248 13482 | ModelPl::Output
|
12249 13483 | >
|
12250 13484 | >::Output
|
12251 13485 | >,
|
12252 13486 |
|
12253 13487 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12254 13488 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12255 13489 |
|
12256 13490 | {
|
12257 13491 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12258 13492 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12259 - | let svc = crate::operation_shape::OperationWithDefaults::from_handler(handler);
|
13493 + | let svc = crate::operation_shape::OutputStream::from_handler(handler);
|
12260 13494 | let svc = self.model_plugin.apply(svc);
|
12261 13495 | let svc =
|
12262 13496 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12263 13497 | .apply(svc);
|
12264 13498 | let svc = self.http_plugin.apply(svc);
|
12265 - | self.operation_with_defaults_custom(svc)
|
13499 + | self.output_stream_custom(svc)
|
12266 13500 | }
|
12267 13501 |
|
12268 - | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
13502 + | /// Sets the [`OutputStream`](crate::operation_shape::OutputStream) operation.
|
12269 13503 | ///
|
12270 13504 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12271 13505 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12272 13506 | ///
|
12273 13507 | /// # Example
|
12274 13508 | ///
|
12275 13509 | /// ```no_run
|
12276 13510 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12277 13511 | ///
|
12278 13512 | /// use rest_json_http0x::{input, output, error};
|
12279 13513 | ///
|
12280 - | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
13514 + | /// async fn handler(input: input::OutputStreamInput) -> Result<output::OutputStreamOutput, error::OutputStreamError> {
|
12281 13515 | /// todo!()
|
12282 13516 | /// }
|
12283 13517 | ///
|
12284 13518 | /// let config = RestJsonConfig::builder().build();
|
12285 13519 | /// let svc = ::tower::util::service_fn(handler);
|
12286 13520 | /// let app = RestJson::builder(config)
|
12287 - | /// .operation_with_defaults_service(svc)
|
13521 + | /// .output_stream_service(svc)
|
12288 13522 | /// /* Set other handlers */
|
12289 13523 | /// .build()
|
12290 13524 | /// .unwrap();
|
12291 13525 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12292 13526 | /// ```
|
12293 13527 | ///
|
12294 - | pub fn operation_with_defaults_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13528 + | pub fn output_stream_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12295 13529 | where
|
12296 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithDefaults, ServiceExtractors>,
|
13530 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OutputStream, ServiceExtractors>,
|
12297 13531 |
|
12298 13532 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12299 13533 | RestJson<L>,
|
12300 - | crate::operation_shape::OperationWithDefaults,
|
12301 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithDefaults, S>
|
13534 + | crate::operation_shape::OutputStream,
|
13535 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OutputStream, S>
|
12302 13536 | >,
|
12303 13537 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12304 13538 | RestJson<L>,
|
12305 - | crate::operation_shape::OperationWithDefaults,
|
13539 + | crate::operation_shape::OutputStream,
|
12306 13540 | ModelPl::Output
|
12307 13541 | >,
|
12308 13542 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12309 13543 | RestJson<L>,
|
12310 - | crate::operation_shape::OperationWithDefaults,
|
13544 + | crate::operation_shape::OutputStream,
|
12311 13545 | <
|
12312 13546 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12313 13547 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12314 13548 | RestJson<L>,
|
12315 - | crate::operation_shape::OperationWithDefaults,
|
13549 + | crate::operation_shape::OutputStream,
|
12316 13550 | ModelPl::Output
|
12317 13551 | >
|
12318 13552 | >::Output
|
12319 13553 | >,
|
12320 13554 |
|
12321 13555 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12322 13556 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12323 13557 |
|
12324 13558 | {
|
12325 13559 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12326 13560 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12327 - | let svc = crate::operation_shape::OperationWithDefaults::from_service(service);
|
13561 + | let svc = crate::operation_shape::OutputStream::from_service(service);
|
12328 13562 | let svc = self.model_plugin.apply(svc);
|
12329 13563 | let svc =
|
12330 13564 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12331 13565 | .apply(svc);
|
12332 13566 | let svc = self.http_plugin.apply(svc);
|
12333 - | self.operation_with_defaults_custom(svc)
|
13567 + | self.output_stream_custom(svc)
|
12334 13568 | }
|
12335 13569 |
|
12336 - | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) to a custom [`Service`](tower::Service).
|
13570 + | /// Sets the [`OutputStream`](crate::operation_shape::OutputStream) to a custom [`Service`](tower::Service).
|
12337 13571 | /// not constrained by the Smithy contract.
|
12338 - | fn operation_with_defaults_custom<S>(mut self, svc: S) -> Self
|
13572 + | fn output_stream_custom<S>(mut self, svc: S) -> Self
|
12339 13573 | where
|
12340 13574 | S: ::tower::Service<
|
12341 13575 | ::http::Request<Body>,
|
12342 13576 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12343 13577 | Error = ::std::convert::Infallible,
|
12344 13578 | > + Clone
|
12345 13579 | + Send
|
12346 13580 | + 'static,
|
12347 13581 | S::Future: Send + 'static,
|
12348 13582 | {
|
12349 - | self.operation_with_defaults =
|
12350 - | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13583 + | self.output_stream = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12351 13584 | self
|
12352 13585 | }
|
12353 13586 |
|
12354 - | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
13587 + | /// Sets the [`OutputStreamWithInitialResponse`](crate::operation_shape::OutputStreamWithInitialResponse) operation.
|
12355 13588 | ///
|
12356 13589 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12357 13590 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12358 13591 | ///
|
12359 13592 | /// # Example
|
12360 13593 | ///
|
12361 13594 | /// ```no_run
|
12362 13595 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12363 13596 | ///
|
12364 13597 | /// use rest_json_http0x::{input, output, error};
|
12365 13598 | ///
|
12366 - | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
13599 + | /// async fn handler(input: input::OutputStreamWithInitialResponseInput) -> Result<output::OutputStreamWithInitialResponseOutput, error::OutputStreamWithInitialResponseError> {
|
12367 13600 | /// todo!()
|
12368 13601 | /// }
|
12369 13602 | ///
|
12370 13603 | /// let config = RestJsonConfig::builder().build();
|
12371 13604 | /// let app = RestJson::builder(config)
|
12372 - | /// .operation_with_nested_structure(handler)
|
13605 + | /// .output_stream_with_initial_response(handler)
|
12373 13606 | /// /* Set other handlers */
|
12374 13607 | /// .build()
|
12375 13608 | /// .unwrap();
|
12376 13609 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12377 13610 | /// ```
|
12378 13611 | ///
|
12379 - | pub fn operation_with_nested_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13612 + | pub fn output_stream_with_initial_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12380 13613 | where
|
12381 - | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithNestedStructure, HandlerExtractors>,
|
13614 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OutputStreamWithInitialResponse, HandlerExtractors>,
|
12382 13615 |
|
12383 13616 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12384 13617 | RestJson<L>,
|
12385 - | crate::operation_shape::OperationWithNestedStructure,
|
12386 - | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithNestedStructure, HandlerType>
|
13618 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
13619 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OutputStreamWithInitialResponse, HandlerType>
|
12387 13620 | >,
|
12388 13621 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12389 13622 | RestJson<L>,
|
12390 - | crate::operation_shape::OperationWithNestedStructure,
|
13623 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12391 13624 | ModelPl::Output
|
12392 13625 | >,
|
12393 13626 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12394 13627 | RestJson<L>,
|
12395 - | crate::operation_shape::OperationWithNestedStructure,
|
13628 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12396 13629 | <
|
12397 13630 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12398 13631 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12399 13632 | RestJson<L>,
|
12400 - | crate::operation_shape::OperationWithNestedStructure,
|
13633 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12401 13634 | ModelPl::Output
|
12402 13635 | >
|
12403 13636 | >::Output
|
12404 13637 | >,
|
12405 13638 |
|
12406 13639 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12407 13640 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12408 13641 |
|
12409 13642 | {
|
12410 13643 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12411 13644 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12412 - | let svc = crate::operation_shape::OperationWithNestedStructure::from_handler(handler);
|
13645 + | let svc = crate::operation_shape::OutputStreamWithInitialResponse::from_handler(handler);
|
12413 13646 | let svc = self.model_plugin.apply(svc);
|
12414 13647 | let svc =
|
12415 13648 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12416 13649 | .apply(svc);
|
12417 13650 | let svc = self.http_plugin.apply(svc);
|
12418 - | self.operation_with_nested_structure_custom(svc)
|
13651 + | self.output_stream_with_initial_response_custom(svc)
|
12419 13652 | }
|
12420 13653 |
|
12421 - | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
13654 + | /// Sets the [`OutputStreamWithInitialResponse`](crate::operation_shape::OutputStreamWithInitialResponse) operation.
|
12422 13655 | ///
|
12423 13656 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12424 13657 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12425 13658 | ///
|
12426 13659 | /// # Example
|
12427 13660 | ///
|
12428 13661 | /// ```no_run
|
12429 13662 | /// use rest_json_http0x::{RestJson, RestJsonConfig};
|
12430 13663 | ///
|
12431 13664 | /// use rest_json_http0x::{input, output, error};
|
12432 13665 | ///
|
12433 - | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
13666 + | /// async fn handler(input: input::OutputStreamWithInitialResponseInput) -> Result<output::OutputStreamWithInitialResponseOutput, error::OutputStreamWithInitialResponseError> {
|
12434 13667 | /// todo!()
|
12435 13668 | /// }
|
12436 13669 | ///
|
12437 13670 | /// let config = RestJsonConfig::builder().build();
|
12438 13671 | /// let svc = ::tower::util::service_fn(handler);
|
12439 13672 | /// let app = RestJson::builder(config)
|
12440 - | /// .operation_with_nested_structure_service(svc)
|
13673 + | /// .output_stream_with_initial_response_service(svc)
|
12441 13674 | /// /* Set other handlers */
|
12442 13675 | /// .build()
|
12443 13676 | /// .unwrap();
|
12444 13677 | /// # let app: RestJson<::aws_smithy_legacy_http_server::routing::RoutingService<::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<::aws_smithy_legacy_http_server::routing::Route>, ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12445 13678 | /// ```
|
12446 13679 | ///
|
12447 - | pub fn operation_with_nested_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13680 + | pub fn output_stream_with_initial_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12448 13681 | where
|
12449 - | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithNestedStructure, ServiceExtractors>,
|
13682 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OutputStreamWithInitialResponse, ServiceExtractors>,
|
12450 13683 |
|
12451 13684 | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12452 13685 | RestJson<L>,
|
12453 - | crate::operation_shape::OperationWithNestedStructure,
|
12454 - | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithNestedStructure, S>
|
13686 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
13687 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OutputStreamWithInitialResponse, S>
|
12455 13688 | >,
|
12456 13689 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12457 13690 | RestJson<L>,
|
12458 - | crate::operation_shape::OperationWithNestedStructure,
|
13691 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12459 13692 | ModelPl::Output
|
12460 13693 | >,
|
12461 13694 | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12462 13695 | RestJson<L>,
|
12463 - | crate::operation_shape::OperationWithNestedStructure,
|
13696 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12464 13697 | <
|
12465 13698 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12466 13699 | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12467 13700 | RestJson<L>,
|
12468 - | crate::operation_shape::OperationWithNestedStructure,
|
13701 + | crate::operation_shape::OutputStreamWithInitialResponse,
|
12469 13702 | ModelPl::Output
|
12470 13703 | >
|
12471 13704 | >::Output
|
12472 13705 | >,
|
12473 13706 |
|
12474 13707 | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12475 13708 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12476 13709 |
|
12477 13710 | {
|
12478 13711 | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12479 13712 | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12480 - | let svc = crate::operation_shape::OperationWithNestedStructure::from_service(service);
|
13713 + | let svc = crate::operation_shape::OutputStreamWithInitialResponse::from_service(service);
|
12481 13714 | let svc = self.model_plugin.apply(svc);
|
12482 13715 | let svc =
|
12483 13716 | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12484 13717 | .apply(svc);
|
12485 13718 | let svc = self.http_plugin.apply(svc);
|
12486 - | self.operation_with_nested_structure_custom(svc)
|
13719 + | self.output_stream_with_initial_response_custom(svc)
|
12487 13720 | }
|
12488 13721 |
|
12489 - | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) to a custom [`Service`](tower::Service).
|
13722 + | /// Sets the [`OutputStreamWithInitialResponse`](crate::operation_shape::OutputStreamWithInitialResponse) to a custom [`Service`](tower::Service).
|
12490 13723 | /// not constrained by the Smithy contract.
|
12491 - | fn operation_with_nested_structure_custom<S>(mut self, svc: S) -> Self
|
13724 + | fn output_stream_with_initial_response_custom<S>(mut self, svc: S) -> Self
|
12492 13725 | where
|
12493 13726 | S: ::tower::Service<
|
12494 13727 | ::http::Request<Body>,
|
12495 13728 | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12496 13729 | Error = ::std::convert::Infallible,
|
12497 13730 | > + Clone
|
12498 13731 | + Send
|
12499 13732 | + 'static,
|
12500 13733 | S::Future: Send + 'static,
|
12501 13734 | {
|
12502 - | self.operation_with_nested_structure =
|
13735 + | self.output_stream_with_initial_response =
|
12503 13736 | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12504 13737 | self
|
12505 13738 | }
|
12506 13739 |
|
12507 13740 | /// Sets the [`PostPlayerAction`](crate::operation_shape::PostPlayerAction) operation.
|
12508 13741 | ///
|
12509 13742 | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12510 13743 | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12511 13744 | ///
|
12512 13745 | /// # Example
|