1 1 | // Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
|
2 2 | /// The service builder for [`RestJson`].
|
3 3 | ///
|
4 4 | /// Constructed via [`RestJson::builder`].
|
5 5 | pub struct RestJsonBuilder<Body, L, HttpPl, ModelPl> {
|
6 - | all_query_string_types: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
7 - | constant_and_variable_query_string: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
8 - | constant_query_string: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
9 - | content_type_parameters: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
10 - | datetime_offsets: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
11 - | document_type: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
12 - | document_type_as_map_value: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
13 - | document_type_as_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
14 - | empty_input_and_empty_output: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
15 - | endpoint_operation: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
16 - | endpoint_with_host_label_operation: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
17 - | fractional_seconds: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
18 - | greeting_with_errors: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
19 - | host_with_path_operation: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
20 - | http_checksum_required: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
21 - | http_empty_prefix_headers: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
22 - | http_enum_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
23 - | http_payload_traits: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
24 - | http_payload_traits_with_media_type: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
25 - | http_payload_with_structure: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
26 - | http_payload_with_union: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
27 - | http_prefix_headers: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
28 - | http_prefix_headers_in_response: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
29 - | http_request_with_float_labels: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
30 - | http_request_with_greedy_label_in_path: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
31 - | http_request_with_labels: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
6 + | all_query_string_types: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
7 + | constant_and_variable_query_string:
|
8 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
9 + | constant_query_string: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
10 + | content_type_parameters: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
11 + | datetime_offsets: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
12 + | document_type: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
13 + | document_type_as_map_value: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
14 + | document_type_as_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
15 + | empty_input_and_empty_output: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
16 + | endpoint_operation: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
17 + | endpoint_with_host_label_operation:
|
18 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
19 + | fractional_seconds: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
20 + | greeting_with_errors: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
21 + | host_with_path_operation: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
22 + | http_checksum_required: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
23 + | http_empty_prefix_headers: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
24 + | http_enum_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
25 + | http_payload_traits: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
26 + | http_payload_traits_with_media_type:
|
27 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
28 + | http_payload_with_structure: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
29 + | http_payload_with_union: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
30 + | http_prefix_headers: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
31 + | http_prefix_headers_in_response: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
32 + | http_request_with_float_labels: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
33 + | http_request_with_greedy_label_in_path:
|
34 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
35 + | http_request_with_labels: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
32 36 | http_request_with_labels_and_timestamp_format:
|
33 - | Option<::aws_smithy_http_server::routing::Route<Body>>,
|
34 - | http_request_with_regex_literal: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
35 - | http_response_code: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
36 - | http_string_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
37 - | ignore_query_params_in_response: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
38 - | input_and_output_with_headers: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
39 - | json_blobs: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
40 - | json_enums: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
41 - | json_int_enums: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
42 - | json_lists: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
43 - | json_maps: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
44 - | json_timestamps: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
45 - | json_unions: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
46 - | malformed_accept_with_body: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
47 - | malformed_accept_with_generic_string: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
48 - | malformed_accept_with_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
49 - | malformed_blob: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
50 - | malformed_boolean: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
51 - | malformed_byte: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
52 - | malformed_content_type_with_body: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
37 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
38 + | http_request_with_regex_literal: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
39 + | http_response_code: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
40 + | http_string_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
41 + | ignore_query_params_in_response: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
42 + | input_and_output_with_headers: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
43 + | json_blobs: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
44 + | json_enums: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
45 + | json_int_enums: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
46 + | json_lists: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
47 + | json_maps: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
48 + | json_timestamps: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
49 + | json_unions: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
50 + | malformed_accept_with_body: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
51 + | malformed_accept_with_generic_string:
|
52 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
53 + | malformed_accept_with_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
54 + | malformed_blob: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
55 + | malformed_boolean: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
56 + | malformed_byte: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
57 + | malformed_content_type_with_body: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
53 58 | malformed_content_type_with_generic_string:
|
54 - | Option<::aws_smithy_http_server::routing::Route<Body>>,
|
55 - | malformed_content_type_without_body: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
59 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
60 + | malformed_content_type_without_body:
|
61 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
56 62 | malformed_content_type_without_body_empty_input:
|
57 - | Option<::aws_smithy_http_server::routing::Route<Body>>,
|
58 - | malformed_content_type_with_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
59 - | malformed_double: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
60 - | malformed_float: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
61 - | malformed_integer: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
62 - | malformed_list: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
63 - | malformed_long: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
64 - | malformed_map: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
65 - | malformed_request_body: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
66 - | malformed_short: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
67 - | malformed_string: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
68 - | malformed_timestamp_body_date_time: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
69 - | malformed_timestamp_body_default: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
70 - | malformed_timestamp_body_http_date: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
71 - | malformed_timestamp_header_date_time: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
72 - | malformed_timestamp_header_default: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
73 - | malformed_timestamp_header_epoch: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
74 - | malformed_timestamp_path_default: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
75 - | malformed_timestamp_path_epoch: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
76 - | malformed_timestamp_path_http_date: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
77 - | malformed_timestamp_query_default: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
78 - | malformed_timestamp_query_epoch: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
79 - | malformed_timestamp_query_http_date: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
80 - | malformed_union: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
81 - | media_type_header: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
82 - | no_input_and_no_output: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
83 - | no_input_and_output: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
84 - | null_and_empty_headers_client: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
85 - | null_and_empty_headers_server: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
86 - | omits_null_serializes_empty_string: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
87 - | omits_serializing_empty_lists: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
88 - | operation_with_defaults: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
89 - | operation_with_nested_structure: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
90 - | post_player_action: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
91 - | post_union_with_json_name: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
92 - | put_with_content_encoding: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
93 - | query_idempotency_token_auto_fill: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
94 - | query_params_as_string_list_map: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
95 - | query_precedence: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
96 - | recursive_shapes: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
97 - | response_code_http_fallback: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
98 - | response_code_required: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
99 - | simple_scalar_properties: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
100 - | sparse_json_lists: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
101 - | sparse_json_maps: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
102 - | streaming_traits: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
103 - | streaming_traits_require_length: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
104 - | streaming_traits_with_media_type: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
105 - | test_body_structure: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
106 - | test_get_no_input_no_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
107 - | test_get_no_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
108 - | test_payload_blob: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
109 - | test_payload_structure: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
110 - | test_post_no_input_no_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
111 - | test_post_no_payload: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
112 - | timestamp_format_headers: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
113 - | unit_input_and_output: Option<::aws_smithy_http_server::routing::Route<Body>>,
|
63 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
64 + | malformed_content_type_with_payload:
|
65 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
66 + | malformed_double: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
67 + | malformed_float: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
68 + | malformed_integer: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
69 + | malformed_list: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
70 + | malformed_long: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
71 + | malformed_map: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
72 + | malformed_request_body: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
73 + | malformed_short: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
74 + | malformed_string: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
75 + | malformed_timestamp_body_date_time:
|
76 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
77 + | malformed_timestamp_body_default: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
78 + | malformed_timestamp_body_http_date:
|
79 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
80 + | malformed_timestamp_header_date_time:
|
81 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
82 + | malformed_timestamp_header_default:
|
83 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
84 + | malformed_timestamp_header_epoch: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
85 + | malformed_timestamp_path_default: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
86 + | malformed_timestamp_path_epoch: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
87 + | malformed_timestamp_path_http_date:
|
88 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
89 + | malformed_timestamp_query_default:
|
90 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
91 + | malformed_timestamp_query_epoch: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
92 + | malformed_timestamp_query_http_date:
|
93 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
94 + | malformed_union: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
95 + | media_type_header: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
96 + | no_input_and_no_output: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
97 + | no_input_and_output: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
98 + | null_and_empty_headers_client: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
99 + | null_and_empty_headers_server: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
100 + | omits_null_serializes_empty_string:
|
101 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
102 + | omits_serializing_empty_lists: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
103 + | operation_with_defaults: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
104 + | operation_with_nested_structure: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
105 + | post_player_action: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
106 + | post_union_with_json_name: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
107 + | put_with_content_encoding: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
108 + | query_idempotency_token_auto_fill:
|
109 + | Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
110 + | query_params_as_string_list_map: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
111 + | query_precedence: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
112 + | recursive_shapes: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
113 + | response_code_http_fallback: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
114 + | response_code_required: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
115 + | simple_scalar_properties: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
116 + | sparse_json_lists: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
117 + | sparse_json_maps: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
118 + | streaming_traits: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
119 + | streaming_traits_require_length: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
120 + | streaming_traits_with_media_type: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
121 + | test_body_structure: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
122 + | test_get_no_input_no_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
123 + | test_get_no_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
124 + | test_payload_blob: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
125 + | test_payload_structure: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
126 + | test_post_no_input_no_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
127 + | test_post_no_payload: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
128 + | timestamp_format_headers: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
129 + | unit_input_and_output: Option<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
114 130 | layer: L,
|
115 131 | http_plugin: HttpPl,
|
116 132 | model_plugin: ModelPl,
|
117 133 | }
|
118 134 |
|
119 135 | impl<Body, L, HttpPl, ModelPl> RestJsonBuilder<Body, L, HttpPl, ModelPl> {
|
120 136 | /// Sets the [`AllQueryStringTypes`](crate::operation_shape::AllQueryStringTypes) operation.
|
121 137 | ///
|
122 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
123 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
138 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
139 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
124 140 | ///
|
125 141 | /// # Example
|
126 142 | ///
|
127 143 | /// ```no_run
|
128 144 | /// use rest_json::{RestJson, RestJsonConfig};
|
129 145 | ///
|
130 146 | /// use rest_json::{input, output, error};
|
131 147 | ///
|
132 148 | /// async fn handler(input: input::AllQueryStringTypesInput) -> Result<output::AllQueryStringTypesOutput, error::AllQueryStringTypesError> {
|
133 149 | /// todo!()
|
134 150 | /// }
|
135 151 | ///
|
136 152 | /// let config = RestJsonConfig::builder().build();
|
137 153 | /// let app = RestJson::builder(config)
|
138 154 | /// .all_query_string_types(handler)
|
139 155 | /// /* Set other handlers */
|
140 156 | /// .build()
|
141 157 | /// .unwrap();
|
142 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
158 + | /// # 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;
|
143 159 | /// ```
|
144 160 | ///
|
145 161 | pub fn all_query_string_types<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
146 162 | where
|
147 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::AllQueryStringTypes, HandlerExtractors>,
|
163 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::AllQueryStringTypes, HandlerExtractors>,
|
148 164 |
|
149 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
165 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
150 166 | RestJson<L>,
|
151 167 | crate::operation_shape::AllQueryStringTypes,
|
152 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::AllQueryStringTypes, HandlerType>
|
168 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::AllQueryStringTypes, HandlerType>
|
153 169 | >,
|
154 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
170 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
155 171 | RestJson<L>,
|
156 172 | crate::operation_shape::AllQueryStringTypes,
|
157 173 | ModelPl::Output
|
158 174 | >,
|
159 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
175 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
160 176 | RestJson<L>,
|
161 177 | crate::operation_shape::AllQueryStringTypes,
|
162 178 | <
|
163 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
164 - | as ::aws_smithy_http_server::plugin::Plugin<
|
179 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
180 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
165 181 | RestJson<L>,
|
166 182 | crate::operation_shape::AllQueryStringTypes,
|
167 183 | ModelPl::Output
|
168 184 | >
|
169 185 | >::Output
|
170 186 | >,
|
171 187 |
|
172 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
188 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
173 189 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
174 190 |
|
175 191 | {
|
176 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
177 - | use ::aws_smithy_http_server::plugin::Plugin;
|
192 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
193 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
178 194 | let svc = crate::operation_shape::AllQueryStringTypes::from_handler(handler);
|
179 195 | let svc = self.model_plugin.apply(svc);
|
180 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
196 + | let svc =
|
197 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
181 198 | .apply(svc);
|
182 199 | let svc = self.http_plugin.apply(svc);
|
183 200 | self.all_query_string_types_custom(svc)
|
184 201 | }
|
185 202 |
|
186 203 | /// Sets the [`AllQueryStringTypes`](crate::operation_shape::AllQueryStringTypes) operation.
|
187 204 | ///
|
188 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
189 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
205 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
206 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
190 207 | ///
|
191 208 | /// # Example
|
192 209 | ///
|
193 210 | /// ```no_run
|
194 211 | /// use rest_json::{RestJson, RestJsonConfig};
|
195 212 | ///
|
196 213 | /// use rest_json::{input, output, error};
|
197 214 | ///
|
198 215 | /// async fn handler(input: input::AllQueryStringTypesInput) -> Result<output::AllQueryStringTypesOutput, error::AllQueryStringTypesError> {
|
199 216 | /// todo!()
|
200 217 | /// }
|
201 218 | ///
|
202 219 | /// let config = RestJsonConfig::builder().build();
|
203 220 | /// let svc = ::tower::util::service_fn(handler);
|
204 221 | /// let app = RestJson::builder(config)
|
205 222 | /// .all_query_string_types_service(svc)
|
206 223 | /// /* Set other handlers */
|
207 224 | /// .build()
|
208 225 | /// .unwrap();
|
209 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
226 + | /// # 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;
|
210 227 | /// ```
|
211 228 | ///
|
212 229 | pub fn all_query_string_types_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
213 230 | where
|
214 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::AllQueryStringTypes, ServiceExtractors>,
|
231 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::AllQueryStringTypes, ServiceExtractors>,
|
215 232 |
|
216 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
233 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
217 234 | RestJson<L>,
|
218 235 | crate::operation_shape::AllQueryStringTypes,
|
219 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::AllQueryStringTypes, S>
|
236 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::AllQueryStringTypes, S>
|
220 237 | >,
|
221 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
238 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
222 239 | RestJson<L>,
|
223 240 | crate::operation_shape::AllQueryStringTypes,
|
224 241 | ModelPl::Output
|
225 242 | >,
|
226 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
243 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
227 244 | RestJson<L>,
|
228 245 | crate::operation_shape::AllQueryStringTypes,
|
229 246 | <
|
230 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
231 - | as ::aws_smithy_http_server::plugin::Plugin<
|
247 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
248 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
232 249 | RestJson<L>,
|
233 250 | crate::operation_shape::AllQueryStringTypes,
|
234 251 | ModelPl::Output
|
235 252 | >
|
236 253 | >::Output
|
237 254 | >,
|
238 255 |
|
239 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
256 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
240 257 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
241 258 |
|
242 259 | {
|
243 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
244 - | use ::aws_smithy_http_server::plugin::Plugin;
|
260 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
261 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
245 262 | let svc = crate::operation_shape::AllQueryStringTypes::from_service(service);
|
246 263 | let svc = self.model_plugin.apply(svc);
|
247 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
264 + | let svc =
|
265 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
248 266 | .apply(svc);
|
249 267 | let svc = self.http_plugin.apply(svc);
|
250 268 | self.all_query_string_types_custom(svc)
|
251 269 | }
|
252 270 |
|
253 271 | /// Sets the [`AllQueryStringTypes`](crate::operation_shape::AllQueryStringTypes) to a custom [`Service`](tower::Service).
|
254 272 | /// not constrained by the Smithy contract.
|
255 273 | fn all_query_string_types_custom<S>(mut self, svc: S) -> Self
|
256 274 | where
|
257 275 | S: ::tower::Service<
|
258 276 | ::http::Request<Body>,
|
259 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
277 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
260 278 | Error = ::std::convert::Infallible,
|
261 279 | > + Clone
|
262 280 | + Send
|
263 281 | + 'static,
|
264 282 | S::Future: Send + 'static,
|
265 283 | {
|
266 - | self.all_query_string_types = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
284 + | self.all_query_string_types =
|
285 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
267 286 | self
|
268 287 | }
|
269 288 |
|
270 289 | /// Sets the [`ConstantAndVariableQueryString`](crate::operation_shape::ConstantAndVariableQueryString) operation.
|
271 290 | ///
|
272 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
273 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
291 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
292 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
274 293 | ///
|
275 294 | /// # Example
|
276 295 | ///
|
277 296 | /// ```no_run
|
278 297 | /// use rest_json::{RestJson, RestJsonConfig};
|
279 298 | ///
|
280 299 | /// use rest_json::{input, output, error};
|
281 300 | ///
|
282 301 | /// async fn handler(input: input::ConstantAndVariableQueryStringInput) -> Result<output::ConstantAndVariableQueryStringOutput, error::ConstantAndVariableQueryStringError> {
|
283 302 | /// todo!()
|
284 303 | /// }
|
285 304 | ///
|
286 305 | /// let config = RestJsonConfig::builder().build();
|
287 306 | /// let app = RestJson::builder(config)
|
288 307 | /// .constant_and_variable_query_string(handler)
|
289 308 | /// /* Set other handlers */
|
290 309 | /// .build()
|
291 310 | /// .unwrap();
|
292 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
311 + | /// # 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;
|
293 312 | /// ```
|
294 313 | ///
|
295 314 | pub fn constant_and_variable_query_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
296 315 | where
|
297 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ConstantAndVariableQueryString, HandlerExtractors>,
|
316 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ConstantAndVariableQueryString, HandlerExtractors>,
|
298 317 |
|
299 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
318 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
300 319 | RestJson<L>,
|
301 320 | crate::operation_shape::ConstantAndVariableQueryString,
|
302 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ConstantAndVariableQueryString, HandlerType>
|
321 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ConstantAndVariableQueryString, HandlerType>
|
303 322 | >,
|
304 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
323 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
305 324 | RestJson<L>,
|
306 325 | crate::operation_shape::ConstantAndVariableQueryString,
|
307 326 | ModelPl::Output
|
308 327 | >,
|
309 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
328 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
310 329 | RestJson<L>,
|
311 330 | crate::operation_shape::ConstantAndVariableQueryString,
|
312 331 | <
|
313 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
314 - | as ::aws_smithy_http_server::plugin::Plugin<
|
332 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
333 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
315 334 | RestJson<L>,
|
316 335 | crate::operation_shape::ConstantAndVariableQueryString,
|
317 336 | ModelPl::Output
|
318 337 | >
|
319 338 | >::Output
|
320 339 | >,
|
321 340 |
|
322 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
341 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
323 342 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
324 343 |
|
325 344 | {
|
326 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
327 - | use ::aws_smithy_http_server::plugin::Plugin;
|
345 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
346 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
328 347 | let svc = crate::operation_shape::ConstantAndVariableQueryString::from_handler(handler);
|
329 348 | let svc = self.model_plugin.apply(svc);
|
330 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
349 + | let svc =
|
350 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
331 351 | .apply(svc);
|
332 352 | let svc = self.http_plugin.apply(svc);
|
333 353 | self.constant_and_variable_query_string_custom(svc)
|
334 354 | }
|
335 355 |
|
336 356 | /// Sets the [`ConstantAndVariableQueryString`](crate::operation_shape::ConstantAndVariableQueryString) operation.
|
337 357 | ///
|
338 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
339 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
358 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
359 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
340 360 | ///
|
341 361 | /// # Example
|
342 362 | ///
|
343 363 | /// ```no_run
|
344 364 | /// use rest_json::{RestJson, RestJsonConfig};
|
345 365 | ///
|
346 366 | /// use rest_json::{input, output, error};
|
347 367 | ///
|
348 368 | /// async fn handler(input: input::ConstantAndVariableQueryStringInput) -> Result<output::ConstantAndVariableQueryStringOutput, error::ConstantAndVariableQueryStringError> {
|
349 369 | /// todo!()
|
350 370 | /// }
|
351 371 | ///
|
352 372 | /// let config = RestJsonConfig::builder().build();
|
353 373 | /// let svc = ::tower::util::service_fn(handler);
|
354 374 | /// let app = RestJson::builder(config)
|
355 375 | /// .constant_and_variable_query_string_service(svc)
|
356 376 | /// /* Set other handlers */
|
357 377 | /// .build()
|
358 378 | /// .unwrap();
|
359 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
379 + | /// # 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;
|
360 380 | /// ```
|
361 381 | ///
|
362 382 | pub fn constant_and_variable_query_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
363 383 | where
|
364 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ConstantAndVariableQueryString, ServiceExtractors>,
|
384 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ConstantAndVariableQueryString, ServiceExtractors>,
|
365 385 |
|
366 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
386 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
367 387 | RestJson<L>,
|
368 388 | crate::operation_shape::ConstantAndVariableQueryString,
|
369 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ConstantAndVariableQueryString, S>
|
389 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ConstantAndVariableQueryString, S>
|
370 390 | >,
|
371 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
391 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
372 392 | RestJson<L>,
|
373 393 | crate::operation_shape::ConstantAndVariableQueryString,
|
374 394 | ModelPl::Output
|
375 395 | >,
|
376 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
396 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
377 397 | RestJson<L>,
|
378 398 | crate::operation_shape::ConstantAndVariableQueryString,
|
379 399 | <
|
380 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
381 - | as ::aws_smithy_http_server::plugin::Plugin<
|
400 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
401 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
382 402 | RestJson<L>,
|
383 403 | crate::operation_shape::ConstantAndVariableQueryString,
|
384 404 | ModelPl::Output
|
385 405 | >
|
386 406 | >::Output
|
387 407 | >,
|
388 408 |
|
389 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
409 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
390 410 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
391 411 |
|
392 412 | {
|
393 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
394 - | use ::aws_smithy_http_server::plugin::Plugin;
|
413 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
414 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
395 415 | let svc = crate::operation_shape::ConstantAndVariableQueryString::from_service(service);
|
396 416 | let svc = self.model_plugin.apply(svc);
|
397 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
417 + | let svc =
|
418 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
398 419 | .apply(svc);
|
399 420 | let svc = self.http_plugin.apply(svc);
|
400 421 | self.constant_and_variable_query_string_custom(svc)
|
401 422 | }
|
402 423 |
|
403 424 | /// Sets the [`ConstantAndVariableQueryString`](crate::operation_shape::ConstantAndVariableQueryString) to a custom [`Service`](tower::Service).
|
404 425 | /// not constrained by the Smithy contract.
|
405 426 | fn constant_and_variable_query_string_custom<S>(mut self, svc: S) -> Self
|
406 427 | where
|
407 428 | S: ::tower::Service<
|
408 429 | ::http::Request<Body>,
|
409 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
430 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
410 431 | Error = ::std::convert::Infallible,
|
411 432 | > + Clone
|
412 433 | + Send
|
413 434 | + 'static,
|
414 435 | S::Future: Send + 'static,
|
415 436 | {
|
416 437 | self.constant_and_variable_query_string =
|
417 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
438 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
418 439 | self
|
419 440 | }
|
420 441 |
|
421 442 | /// Sets the [`ConstantQueryString`](crate::operation_shape::ConstantQueryString) operation.
|
422 443 | ///
|
423 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
424 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
444 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
445 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
425 446 | ///
|
426 447 | /// # Example
|
427 448 | ///
|
428 449 | /// ```no_run
|
429 450 | /// use rest_json::{RestJson, RestJsonConfig};
|
430 451 | ///
|
431 452 | /// use rest_json::{input, output, error};
|
432 453 | ///
|
433 454 | /// async fn handler(input: input::ConstantQueryStringInput) -> Result<output::ConstantQueryStringOutput, error::ConstantQueryStringError> {
|
434 455 | /// todo!()
|
435 456 | /// }
|
436 457 | ///
|
437 458 | /// let config = RestJsonConfig::builder().build();
|
438 459 | /// let app = RestJson::builder(config)
|
439 460 | /// .constant_query_string(handler)
|
440 461 | /// /* Set other handlers */
|
441 462 | /// .build()
|
442 463 | /// .unwrap();
|
443 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
464 + | /// # 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;
|
444 465 | /// ```
|
445 466 | ///
|
446 467 | pub fn constant_query_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
447 468 | where
|
448 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ConstantQueryString, HandlerExtractors>,
|
469 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ConstantQueryString, HandlerExtractors>,
|
449 470 |
|
450 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
471 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
451 472 | RestJson<L>,
|
452 473 | crate::operation_shape::ConstantQueryString,
|
453 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ConstantQueryString, HandlerType>
|
474 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ConstantQueryString, HandlerType>
|
454 475 | >,
|
455 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
476 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
456 477 | RestJson<L>,
|
457 478 | crate::operation_shape::ConstantQueryString,
|
458 479 | ModelPl::Output
|
459 480 | >,
|
460 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
481 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
461 482 | RestJson<L>,
|
462 483 | crate::operation_shape::ConstantQueryString,
|
463 484 | <
|
464 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
465 - | as ::aws_smithy_http_server::plugin::Plugin<
|
485 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
486 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
466 487 | RestJson<L>,
|
467 488 | crate::operation_shape::ConstantQueryString,
|
468 489 | ModelPl::Output
|
469 490 | >
|
470 491 | >::Output
|
471 492 | >,
|
472 493 |
|
473 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
494 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
474 495 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
475 496 |
|
476 497 | {
|
477 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
478 - | use ::aws_smithy_http_server::plugin::Plugin;
|
498 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
499 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
479 500 | let svc = crate::operation_shape::ConstantQueryString::from_handler(handler);
|
480 501 | let svc = self.model_plugin.apply(svc);
|
481 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
502 + | let svc =
|
503 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
482 504 | .apply(svc);
|
483 505 | let svc = self.http_plugin.apply(svc);
|
484 506 | self.constant_query_string_custom(svc)
|
485 507 | }
|
486 508 |
|
487 509 | /// Sets the [`ConstantQueryString`](crate::operation_shape::ConstantQueryString) operation.
|
488 510 | ///
|
489 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
490 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
511 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
512 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
491 513 | ///
|
492 514 | /// # Example
|
493 515 | ///
|
494 516 | /// ```no_run
|
495 517 | /// use rest_json::{RestJson, RestJsonConfig};
|
496 518 | ///
|
497 519 | /// use rest_json::{input, output, error};
|
498 520 | ///
|
499 521 | /// async fn handler(input: input::ConstantQueryStringInput) -> Result<output::ConstantQueryStringOutput, error::ConstantQueryStringError> {
|
500 522 | /// todo!()
|
501 523 | /// }
|
502 524 | ///
|
503 525 | /// let config = RestJsonConfig::builder().build();
|
504 526 | /// let svc = ::tower::util::service_fn(handler);
|
505 527 | /// let app = RestJson::builder(config)
|
506 528 | /// .constant_query_string_service(svc)
|
507 529 | /// /* Set other handlers */
|
508 530 | /// .build()
|
509 531 | /// .unwrap();
|
510 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
532 + | /// # 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;
|
511 533 | /// ```
|
512 534 | ///
|
513 535 | pub fn constant_query_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
514 536 | where
|
515 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ConstantQueryString, ServiceExtractors>,
|
537 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ConstantQueryString, ServiceExtractors>,
|
516 538 |
|
517 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
539 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
518 540 | RestJson<L>,
|
519 541 | crate::operation_shape::ConstantQueryString,
|
520 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ConstantQueryString, S>
|
542 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ConstantQueryString, S>
|
521 543 | >,
|
522 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
544 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
523 545 | RestJson<L>,
|
524 546 | crate::operation_shape::ConstantQueryString,
|
525 547 | ModelPl::Output
|
526 548 | >,
|
527 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
549 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
528 550 | RestJson<L>,
|
529 551 | crate::operation_shape::ConstantQueryString,
|
530 552 | <
|
531 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
532 - | as ::aws_smithy_http_server::plugin::Plugin<
|
553 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
554 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
533 555 | RestJson<L>,
|
534 556 | crate::operation_shape::ConstantQueryString,
|
535 557 | ModelPl::Output
|
536 558 | >
|
537 559 | >::Output
|
538 560 | >,
|
539 561 |
|
540 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
562 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
541 563 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
542 564 |
|
543 565 | {
|
544 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
545 - | use ::aws_smithy_http_server::plugin::Plugin;
|
566 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
567 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
546 568 | let svc = crate::operation_shape::ConstantQueryString::from_service(service);
|
547 569 | let svc = self.model_plugin.apply(svc);
|
548 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
570 + | let svc =
|
571 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
549 572 | .apply(svc);
|
550 573 | let svc = self.http_plugin.apply(svc);
|
551 574 | self.constant_query_string_custom(svc)
|
552 575 | }
|
553 576 |
|
554 577 | /// Sets the [`ConstantQueryString`](crate::operation_shape::ConstantQueryString) to a custom [`Service`](tower::Service).
|
555 578 | /// not constrained by the Smithy contract.
|
556 579 | fn constant_query_string_custom<S>(mut self, svc: S) -> Self
|
557 580 | where
|
558 581 | S: ::tower::Service<
|
559 582 | ::http::Request<Body>,
|
560 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
583 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
561 584 | Error = ::std::convert::Infallible,
|
562 585 | > + Clone
|
563 586 | + Send
|
564 587 | + 'static,
|
565 588 | S::Future: Send + 'static,
|
566 589 | {
|
567 - | self.constant_query_string = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
590 + | self.constant_query_string =
|
591 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
568 592 | self
|
569 593 | }
|
570 594 |
|
571 595 | /// Sets the [`ContentTypeParameters`](crate::operation_shape::ContentTypeParameters) operation.
|
572 596 | ///
|
573 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
574 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
597 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
598 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
575 599 | ///
|
576 600 | /// # Example
|
577 601 | ///
|
578 602 | /// ```no_run
|
579 603 | /// use rest_json::{RestJson, RestJsonConfig};
|
580 604 | ///
|
581 605 | /// use rest_json::{input, output, error};
|
582 606 | ///
|
583 607 | /// async fn handler(input: input::ContentTypeParametersInput) -> Result<output::ContentTypeParametersOutput, error::ContentTypeParametersError> {
|
584 608 | /// todo!()
|
585 609 | /// }
|
586 610 | ///
|
587 611 | /// let config = RestJsonConfig::builder().build();
|
588 612 | /// let app = RestJson::builder(config)
|
589 613 | /// .content_type_parameters(handler)
|
590 614 | /// /* Set other handlers */
|
591 615 | /// .build()
|
592 616 | /// .unwrap();
|
593 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
617 + | /// # 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;
|
594 618 | /// ```
|
595 619 | ///
|
596 620 | pub fn content_type_parameters<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
597 621 | where
|
598 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ContentTypeParameters, HandlerExtractors>,
|
622 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ContentTypeParameters, HandlerExtractors>,
|
599 623 |
|
600 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
624 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
601 625 | RestJson<L>,
|
602 626 | crate::operation_shape::ContentTypeParameters,
|
603 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ContentTypeParameters, HandlerType>
|
627 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ContentTypeParameters, HandlerType>
|
604 628 | >,
|
605 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
629 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
606 630 | RestJson<L>,
|
607 631 | crate::operation_shape::ContentTypeParameters,
|
608 632 | ModelPl::Output
|
609 633 | >,
|
610 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
634 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
611 635 | RestJson<L>,
|
612 636 | crate::operation_shape::ContentTypeParameters,
|
613 637 | <
|
614 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
615 - | as ::aws_smithy_http_server::plugin::Plugin<
|
638 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
639 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
616 640 | RestJson<L>,
|
617 641 | crate::operation_shape::ContentTypeParameters,
|
618 642 | ModelPl::Output
|
619 643 | >
|
620 644 | >::Output
|
621 645 | >,
|
622 646 |
|
623 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
647 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
624 648 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
625 649 |
|
626 650 | {
|
627 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
628 - | use ::aws_smithy_http_server::plugin::Plugin;
|
651 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
652 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
629 653 | let svc = crate::operation_shape::ContentTypeParameters::from_handler(handler);
|
630 654 | let svc = self.model_plugin.apply(svc);
|
631 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
655 + | let svc =
|
656 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
632 657 | .apply(svc);
|
633 658 | let svc = self.http_plugin.apply(svc);
|
634 659 | self.content_type_parameters_custom(svc)
|
635 660 | }
|
636 661 |
|
637 662 | /// Sets the [`ContentTypeParameters`](crate::operation_shape::ContentTypeParameters) operation.
|
638 663 | ///
|
639 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
640 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
664 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
665 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
641 666 | ///
|
642 667 | /// # Example
|
643 668 | ///
|
644 669 | /// ```no_run
|
645 670 | /// use rest_json::{RestJson, RestJsonConfig};
|
646 671 | ///
|
647 672 | /// use rest_json::{input, output, error};
|
648 673 | ///
|
649 674 | /// async fn handler(input: input::ContentTypeParametersInput) -> Result<output::ContentTypeParametersOutput, error::ContentTypeParametersError> {
|
650 675 | /// todo!()
|
651 676 | /// }
|
652 677 | ///
|
653 678 | /// let config = RestJsonConfig::builder().build();
|
654 679 | /// let svc = ::tower::util::service_fn(handler);
|
655 680 | /// let app = RestJson::builder(config)
|
656 681 | /// .content_type_parameters_service(svc)
|
657 682 | /// /* Set other handlers */
|
658 683 | /// .build()
|
659 684 | /// .unwrap();
|
660 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
685 + | /// # 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;
|
661 686 | /// ```
|
662 687 | ///
|
663 688 | pub fn content_type_parameters_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
664 689 | where
|
665 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ContentTypeParameters, ServiceExtractors>,
|
690 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ContentTypeParameters, ServiceExtractors>,
|
666 691 |
|
667 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
692 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
668 693 | RestJson<L>,
|
669 694 | crate::operation_shape::ContentTypeParameters,
|
670 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ContentTypeParameters, S>
|
695 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ContentTypeParameters, S>
|
671 696 | >,
|
672 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
697 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
673 698 | RestJson<L>,
|
674 699 | crate::operation_shape::ContentTypeParameters,
|
675 700 | ModelPl::Output
|
676 701 | >,
|
677 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
702 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
678 703 | RestJson<L>,
|
679 704 | crate::operation_shape::ContentTypeParameters,
|
680 705 | <
|
681 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
682 - | as ::aws_smithy_http_server::plugin::Plugin<
|
706 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
707 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
683 708 | RestJson<L>,
|
684 709 | crate::operation_shape::ContentTypeParameters,
|
685 710 | ModelPl::Output
|
686 711 | >
|
687 712 | >::Output
|
688 713 | >,
|
689 714 |
|
690 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
715 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
691 716 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
692 717 |
|
693 718 | {
|
694 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
695 - | use ::aws_smithy_http_server::plugin::Plugin;
|
719 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
720 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
696 721 | let svc = crate::operation_shape::ContentTypeParameters::from_service(service);
|
697 722 | let svc = self.model_plugin.apply(svc);
|
698 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
723 + | let svc =
|
724 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
699 725 | .apply(svc);
|
700 726 | let svc = self.http_plugin.apply(svc);
|
701 727 | self.content_type_parameters_custom(svc)
|
702 728 | }
|
703 729 |
|
704 730 | /// Sets the [`ContentTypeParameters`](crate::operation_shape::ContentTypeParameters) to a custom [`Service`](tower::Service).
|
705 731 | /// not constrained by the Smithy contract.
|
706 732 | fn content_type_parameters_custom<S>(mut self, svc: S) -> Self
|
707 733 | where
|
708 734 | S: ::tower::Service<
|
709 735 | ::http::Request<Body>,
|
710 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
736 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
711 737 | Error = ::std::convert::Infallible,
|
712 738 | > + Clone
|
713 739 | + Send
|
714 740 | + 'static,
|
715 741 | S::Future: Send + 'static,
|
716 742 | {
|
717 - | self.content_type_parameters = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
743 + | self.content_type_parameters =
|
744 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
718 745 | self
|
719 746 | }
|
720 747 |
|
721 748 | /// Sets the [`DatetimeOffsets`](crate::operation_shape::DatetimeOffsets) operation.
|
722 749 | ///
|
723 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
724 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
750 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
751 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
725 752 | ///
|
726 753 | /// # Example
|
727 754 | ///
|
728 755 | /// ```no_run
|
729 756 | /// use rest_json::{RestJson, RestJsonConfig};
|
730 757 | ///
|
731 758 | /// use rest_json::{input, output, error};
|
732 759 | ///
|
733 760 | /// async fn handler(input: input::DatetimeOffsetsInput) -> Result<output::DatetimeOffsetsOutput, error::DatetimeOffsetsError> {
|
734 761 | /// todo!()
|
735 762 | /// }
|
736 763 | ///
|
737 764 | /// let config = RestJsonConfig::builder().build();
|
738 765 | /// let app = RestJson::builder(config)
|
739 766 | /// .datetime_offsets(handler)
|
740 767 | /// /* Set other handlers */
|
741 768 | /// .build()
|
742 769 | /// .unwrap();
|
743 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
770 + | /// # 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;
|
744 771 | /// ```
|
745 772 | ///
|
746 773 | pub fn datetime_offsets<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
747 774 | where
|
748 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::DatetimeOffsets, HandlerExtractors>,
|
775 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DatetimeOffsets, HandlerExtractors>,
|
749 776 |
|
750 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
777 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
751 778 | RestJson<L>,
|
752 779 | crate::operation_shape::DatetimeOffsets,
|
753 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::DatetimeOffsets, HandlerType>
|
780 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DatetimeOffsets, HandlerType>
|
754 781 | >,
|
755 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
782 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
756 783 | RestJson<L>,
|
757 784 | crate::operation_shape::DatetimeOffsets,
|
758 785 | ModelPl::Output
|
759 786 | >,
|
760 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
787 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
761 788 | RestJson<L>,
|
762 789 | crate::operation_shape::DatetimeOffsets,
|
763 790 | <
|
764 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
765 - | as ::aws_smithy_http_server::plugin::Plugin<
|
791 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
792 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
766 793 | RestJson<L>,
|
767 794 | crate::operation_shape::DatetimeOffsets,
|
768 795 | ModelPl::Output
|
769 796 | >
|
770 797 | >::Output
|
771 798 | >,
|
772 799 |
|
773 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
800 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
774 801 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
775 802 |
|
776 803 | {
|
777 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
778 - | use ::aws_smithy_http_server::plugin::Plugin;
|
804 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
805 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
779 806 | let svc = crate::operation_shape::DatetimeOffsets::from_handler(handler);
|
780 807 | let svc = self.model_plugin.apply(svc);
|
781 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
808 + | let svc =
|
809 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
782 810 | .apply(svc);
|
783 811 | let svc = self.http_plugin.apply(svc);
|
784 812 | self.datetime_offsets_custom(svc)
|
785 813 | }
|
786 814 |
|
787 815 | /// Sets the [`DatetimeOffsets`](crate::operation_shape::DatetimeOffsets) operation.
|
788 816 | ///
|
789 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
790 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
817 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
818 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
791 819 | ///
|
792 820 | /// # Example
|
793 821 | ///
|
794 822 | /// ```no_run
|
795 823 | /// use rest_json::{RestJson, RestJsonConfig};
|
796 824 | ///
|
797 825 | /// use rest_json::{input, output, error};
|
798 826 | ///
|
799 827 | /// async fn handler(input: input::DatetimeOffsetsInput) -> Result<output::DatetimeOffsetsOutput, error::DatetimeOffsetsError> {
|
800 828 | /// todo!()
|
801 829 | /// }
|
802 830 | ///
|
803 831 | /// let config = RestJsonConfig::builder().build();
|
804 832 | /// let svc = ::tower::util::service_fn(handler);
|
805 833 | /// let app = RestJson::builder(config)
|
806 834 | /// .datetime_offsets_service(svc)
|
807 835 | /// /* Set other handlers */
|
808 836 | /// .build()
|
809 837 | /// .unwrap();
|
810 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
838 + | /// # 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;
|
811 839 | /// ```
|
812 840 | ///
|
813 841 | pub fn datetime_offsets_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
814 842 | where
|
815 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::DatetimeOffsets, ServiceExtractors>,
|
843 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DatetimeOffsets, ServiceExtractors>,
|
816 844 |
|
817 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
845 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
818 846 | RestJson<L>,
|
819 847 | crate::operation_shape::DatetimeOffsets,
|
820 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::DatetimeOffsets, S>
|
848 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DatetimeOffsets, S>
|
821 849 | >,
|
822 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
850 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
823 851 | RestJson<L>,
|
824 852 | crate::operation_shape::DatetimeOffsets,
|
825 853 | ModelPl::Output
|
826 854 | >,
|
827 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
855 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
828 856 | RestJson<L>,
|
829 857 | crate::operation_shape::DatetimeOffsets,
|
830 858 | <
|
831 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
832 - | as ::aws_smithy_http_server::plugin::Plugin<
|
859 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
860 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
833 861 | RestJson<L>,
|
834 862 | crate::operation_shape::DatetimeOffsets,
|
835 863 | ModelPl::Output
|
836 864 | >
|
837 865 | >::Output
|
838 866 | >,
|
839 867 |
|
840 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
868 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
841 869 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
842 870 |
|
843 871 | {
|
844 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
845 - | use ::aws_smithy_http_server::plugin::Plugin;
|
872 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
873 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
846 874 | let svc = crate::operation_shape::DatetimeOffsets::from_service(service);
|
847 875 | let svc = self.model_plugin.apply(svc);
|
848 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
876 + | let svc =
|
877 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
849 878 | .apply(svc);
|
850 879 | let svc = self.http_plugin.apply(svc);
|
851 880 | self.datetime_offsets_custom(svc)
|
852 881 | }
|
853 882 |
|
854 883 | /// Sets the [`DatetimeOffsets`](crate::operation_shape::DatetimeOffsets) to a custom [`Service`](tower::Service).
|
855 884 | /// not constrained by the Smithy contract.
|
856 885 | fn datetime_offsets_custom<S>(mut self, svc: S) -> Self
|
857 886 | where
|
858 887 | S: ::tower::Service<
|
859 888 | ::http::Request<Body>,
|
860 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
889 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
861 890 | Error = ::std::convert::Infallible,
|
862 891 | > + Clone
|
863 892 | + Send
|
864 893 | + 'static,
|
865 894 | S::Future: Send + 'static,
|
866 895 | {
|
867 - | self.datetime_offsets = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
896 + | self.datetime_offsets = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
868 897 | self
|
869 898 | }
|
870 899 |
|
871 900 | /// Sets the [`DocumentType`](crate::operation_shape::DocumentType) operation.
|
872 901 | ///
|
873 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
874 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
902 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
903 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
875 904 | ///
|
876 905 | /// # Example
|
877 906 | ///
|
878 907 | /// ```no_run
|
879 908 | /// use rest_json::{RestJson, RestJsonConfig};
|
880 909 | ///
|
881 910 | /// use rest_json::{input, output, error};
|
882 911 | ///
|
883 912 | /// async fn handler(input: input::DocumentTypeInput) -> Result<output::DocumentTypeOutput, error::DocumentTypeError> {
|
884 913 | /// todo!()
|
885 914 | /// }
|
886 915 | ///
|
887 916 | /// let config = RestJsonConfig::builder().build();
|
888 917 | /// let app = RestJson::builder(config)
|
889 918 | /// .document_type(handler)
|
890 919 | /// /* Set other handlers */
|
891 920 | /// .build()
|
892 921 | /// .unwrap();
|
893 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
922 + | /// # 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;
|
894 923 | /// ```
|
895 924 | ///
|
896 925 | pub fn document_type<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
897 926 | where
|
898 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::DocumentType, HandlerExtractors>,
|
927 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DocumentType, HandlerExtractors>,
|
899 928 |
|
900 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
929 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
901 930 | RestJson<L>,
|
902 931 | crate::operation_shape::DocumentType,
|
903 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::DocumentType, HandlerType>
|
932 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DocumentType, HandlerType>
|
904 933 | >,
|
905 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
934 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
906 935 | RestJson<L>,
|
907 936 | crate::operation_shape::DocumentType,
|
908 937 | ModelPl::Output
|
909 938 | >,
|
910 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
939 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
911 940 | RestJson<L>,
|
912 941 | crate::operation_shape::DocumentType,
|
913 942 | <
|
914 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
915 - | as ::aws_smithy_http_server::plugin::Plugin<
|
943 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
944 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
916 945 | RestJson<L>,
|
917 946 | crate::operation_shape::DocumentType,
|
918 947 | ModelPl::Output
|
919 948 | >
|
920 949 | >::Output
|
921 950 | >,
|
922 951 |
|
923 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
952 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
924 953 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
925 954 |
|
926 955 | {
|
927 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
928 - | use ::aws_smithy_http_server::plugin::Plugin;
|
956 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
957 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
929 958 | let svc = crate::operation_shape::DocumentType::from_handler(handler);
|
930 959 | let svc = self.model_plugin.apply(svc);
|
931 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
960 + | let svc =
|
961 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
932 962 | .apply(svc);
|
933 963 | let svc = self.http_plugin.apply(svc);
|
934 964 | self.document_type_custom(svc)
|
935 965 | }
|
936 966 |
|
937 967 | /// Sets the [`DocumentType`](crate::operation_shape::DocumentType) operation.
|
938 968 | ///
|
939 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
940 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
969 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
970 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
941 971 | ///
|
942 972 | /// # Example
|
943 973 | ///
|
944 974 | /// ```no_run
|
945 975 | /// use rest_json::{RestJson, RestJsonConfig};
|
946 976 | ///
|
947 977 | /// use rest_json::{input, output, error};
|
948 978 | ///
|
949 979 | /// async fn handler(input: input::DocumentTypeInput) -> Result<output::DocumentTypeOutput, error::DocumentTypeError> {
|
950 980 | /// todo!()
|
951 981 | /// }
|
952 982 | ///
|
953 983 | /// let config = RestJsonConfig::builder().build();
|
954 984 | /// let svc = ::tower::util::service_fn(handler);
|
955 985 | /// let app = RestJson::builder(config)
|
956 986 | /// .document_type_service(svc)
|
957 987 | /// /* Set other handlers */
|
958 988 | /// .build()
|
959 989 | /// .unwrap();
|
960 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
990 + | /// # 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;
|
961 991 | /// ```
|
962 992 | ///
|
963 993 | pub fn document_type_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
964 994 | where
|
965 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::DocumentType, ServiceExtractors>,
|
995 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DocumentType, ServiceExtractors>,
|
966 996 |
|
967 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
997 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
968 998 | RestJson<L>,
|
969 999 | crate::operation_shape::DocumentType,
|
970 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::DocumentType, S>
|
1000 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DocumentType, S>
|
971 1001 | >,
|
972 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1002 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
973 1003 | RestJson<L>,
|
974 1004 | crate::operation_shape::DocumentType,
|
975 1005 | ModelPl::Output
|
976 1006 | >,
|
977 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1007 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
978 1008 | RestJson<L>,
|
979 1009 | crate::operation_shape::DocumentType,
|
980 1010 | <
|
981 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
982 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1011 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1012 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
983 1013 | RestJson<L>,
|
984 1014 | crate::operation_shape::DocumentType,
|
985 1015 | ModelPl::Output
|
986 1016 | >
|
987 1017 | >::Output
|
988 1018 | >,
|
989 1019 |
|
990 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1020 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
991 1021 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
992 1022 |
|
993 1023 | {
|
994 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
995 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1024 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1025 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
996 1026 | let svc = crate::operation_shape::DocumentType::from_service(service);
|
997 1027 | let svc = self.model_plugin.apply(svc);
|
998 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1028 + | let svc =
|
1029 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
999 1030 | .apply(svc);
|
1000 1031 | let svc = self.http_plugin.apply(svc);
|
1001 1032 | self.document_type_custom(svc)
|
1002 1033 | }
|
1003 1034 |
|
1004 1035 | /// Sets the [`DocumentType`](crate::operation_shape::DocumentType) to a custom [`Service`](tower::Service).
|
1005 1036 | /// not constrained by the Smithy contract.
|
1006 1037 | fn document_type_custom<S>(mut self, svc: S) -> Self
|
1007 1038 | where
|
1008 1039 | S: ::tower::Service<
|
1009 1040 | ::http::Request<Body>,
|
1010 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1041 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1011 1042 | Error = ::std::convert::Infallible,
|
1012 1043 | > + Clone
|
1013 1044 | + Send
|
1014 1045 | + 'static,
|
1015 1046 | S::Future: Send + 'static,
|
1016 1047 | {
|
1017 - | self.document_type = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1048 + | self.document_type = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1018 1049 | self
|
1019 1050 | }
|
1020 1051 |
|
1021 1052 | /// Sets the [`DocumentTypeAsMapValue`](crate::operation_shape::DocumentTypeAsMapValue) operation.
|
1022 1053 | ///
|
1023 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1024 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1054 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1055 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1025 1056 | ///
|
1026 1057 | /// # Example
|
1027 1058 | ///
|
1028 1059 | /// ```no_run
|
1029 1060 | /// use rest_json::{RestJson, RestJsonConfig};
|
1030 1061 | ///
|
1031 1062 | /// use rest_json::{input, output, error};
|
1032 1063 | ///
|
1033 1064 | /// async fn handler(input: input::DocumentTypeAsMapValueInput) -> Result<output::DocumentTypeAsMapValueOutput, error::DocumentTypeAsMapValueError> {
|
1034 1065 | /// todo!()
|
1035 1066 | /// }
|
1036 1067 | ///
|
1037 1068 | /// let config = RestJsonConfig::builder().build();
|
1038 1069 | /// let app = RestJson::builder(config)
|
1039 1070 | /// .document_type_as_map_value(handler)
|
1040 1071 | /// /* Set other handlers */
|
1041 1072 | /// .build()
|
1042 1073 | /// .unwrap();
|
1043 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1074 + | /// # 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;
|
1044 1075 | /// ```
|
1045 1076 | ///
|
1046 1077 | pub fn document_type_as_map_value<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1047 1078 | where
|
1048 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::DocumentTypeAsMapValue, HandlerExtractors>,
|
1079 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DocumentTypeAsMapValue, HandlerExtractors>,
|
1049 1080 |
|
1050 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1081 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1051 1082 | RestJson<L>,
|
1052 1083 | crate::operation_shape::DocumentTypeAsMapValue,
|
1053 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::DocumentTypeAsMapValue, HandlerType>
|
1084 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DocumentTypeAsMapValue, HandlerType>
|
1054 1085 | >,
|
1055 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1086 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1056 1087 | RestJson<L>,
|
1057 1088 | crate::operation_shape::DocumentTypeAsMapValue,
|
1058 1089 | ModelPl::Output
|
1059 1090 | >,
|
1060 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1091 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1061 1092 | RestJson<L>,
|
1062 1093 | crate::operation_shape::DocumentTypeAsMapValue,
|
1063 1094 | <
|
1064 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1065 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1095 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1096 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1066 1097 | RestJson<L>,
|
1067 1098 | crate::operation_shape::DocumentTypeAsMapValue,
|
1068 1099 | ModelPl::Output
|
1069 1100 | >
|
1070 1101 | >::Output
|
1071 1102 | >,
|
1072 1103 |
|
1073 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1104 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1074 1105 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1075 1106 |
|
1076 1107 | {
|
1077 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1078 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1108 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1109 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1079 1110 | let svc = crate::operation_shape::DocumentTypeAsMapValue::from_handler(handler);
|
1080 1111 | let svc = self.model_plugin.apply(svc);
|
1081 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1112 + | let svc =
|
1113 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1082 1114 | .apply(svc);
|
1083 1115 | let svc = self.http_plugin.apply(svc);
|
1084 1116 | self.document_type_as_map_value_custom(svc)
|
1085 1117 | }
|
1086 1118 |
|
1087 1119 | /// Sets the [`DocumentTypeAsMapValue`](crate::operation_shape::DocumentTypeAsMapValue) operation.
|
1088 1120 | ///
|
1089 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1090 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1121 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1122 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1091 1123 | ///
|
1092 1124 | /// # Example
|
1093 1125 | ///
|
1094 1126 | /// ```no_run
|
1095 1127 | /// use rest_json::{RestJson, RestJsonConfig};
|
1096 1128 | ///
|
1097 1129 | /// use rest_json::{input, output, error};
|
1098 1130 | ///
|
1099 1131 | /// async fn handler(input: input::DocumentTypeAsMapValueInput) -> Result<output::DocumentTypeAsMapValueOutput, error::DocumentTypeAsMapValueError> {
|
1100 1132 | /// todo!()
|
1101 1133 | /// }
|
1102 1134 | ///
|
1103 1135 | /// let config = RestJsonConfig::builder().build();
|
1104 1136 | /// let svc = ::tower::util::service_fn(handler);
|
1105 1137 | /// let app = RestJson::builder(config)
|
1106 1138 | /// .document_type_as_map_value_service(svc)
|
1107 1139 | /// /* Set other handlers */
|
1108 1140 | /// .build()
|
1109 1141 | /// .unwrap();
|
1110 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1142 + | /// # 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;
|
1111 1143 | /// ```
|
1112 1144 | ///
|
1113 1145 | pub fn document_type_as_map_value_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1114 1146 | where
|
1115 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::DocumentTypeAsMapValue, ServiceExtractors>,
|
1147 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DocumentTypeAsMapValue, ServiceExtractors>,
|
1116 1148 |
|
1117 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1149 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1118 1150 | RestJson<L>,
|
1119 1151 | crate::operation_shape::DocumentTypeAsMapValue,
|
1120 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::DocumentTypeAsMapValue, S>
|
1152 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DocumentTypeAsMapValue, S>
|
1121 1153 | >,
|
1122 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1154 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1123 1155 | RestJson<L>,
|
1124 1156 | crate::operation_shape::DocumentTypeAsMapValue,
|
1125 1157 | ModelPl::Output
|
1126 1158 | >,
|
1127 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1159 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1128 1160 | RestJson<L>,
|
1129 1161 | crate::operation_shape::DocumentTypeAsMapValue,
|
1130 1162 | <
|
1131 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1132 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1163 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1164 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1133 1165 | RestJson<L>,
|
1134 1166 | crate::operation_shape::DocumentTypeAsMapValue,
|
1135 1167 | ModelPl::Output
|
1136 1168 | >
|
1137 1169 | >::Output
|
1138 1170 | >,
|
1139 1171 |
|
1140 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1172 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1141 1173 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1142 1174 |
|
1143 1175 | {
|
1144 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1145 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1176 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1177 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1146 1178 | let svc = crate::operation_shape::DocumentTypeAsMapValue::from_service(service);
|
1147 1179 | let svc = self.model_plugin.apply(svc);
|
1148 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1180 + | let svc =
|
1181 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1149 1182 | .apply(svc);
|
1150 1183 | let svc = self.http_plugin.apply(svc);
|
1151 1184 | self.document_type_as_map_value_custom(svc)
|
1152 1185 | }
|
1153 1186 |
|
1154 1187 | /// Sets the [`DocumentTypeAsMapValue`](crate::operation_shape::DocumentTypeAsMapValue) to a custom [`Service`](tower::Service).
|
1155 1188 | /// not constrained by the Smithy contract.
|
1156 1189 | fn document_type_as_map_value_custom<S>(mut self, svc: S) -> Self
|
1157 1190 | where
|
1158 1191 | S: ::tower::Service<
|
1159 1192 | ::http::Request<Body>,
|
1160 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1193 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1161 1194 | Error = ::std::convert::Infallible,
|
1162 1195 | > + Clone
|
1163 1196 | + Send
|
1164 1197 | + 'static,
|
1165 1198 | S::Future: Send + 'static,
|
1166 1199 | {
|
1167 - | self.document_type_as_map_value = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1200 + | self.document_type_as_map_value =
|
1201 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1168 1202 | self
|
1169 1203 | }
|
1170 1204 |
|
1171 1205 | /// Sets the [`DocumentTypeAsPayload`](crate::operation_shape::DocumentTypeAsPayload) operation.
|
1172 1206 | ///
|
1173 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1174 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1207 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1208 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1175 1209 | ///
|
1176 1210 | /// # Example
|
1177 1211 | ///
|
1178 1212 | /// ```no_run
|
1179 1213 | /// use rest_json::{RestJson, RestJsonConfig};
|
1180 1214 | ///
|
1181 1215 | /// use rest_json::{input, output, error};
|
1182 1216 | ///
|
1183 1217 | /// async fn handler(input: input::DocumentTypeAsPayloadInput) -> Result<output::DocumentTypeAsPayloadOutput, error::DocumentTypeAsPayloadError> {
|
1184 1218 | /// todo!()
|
1185 1219 | /// }
|
1186 1220 | ///
|
1187 1221 | /// let config = RestJsonConfig::builder().build();
|
1188 1222 | /// let app = RestJson::builder(config)
|
1189 1223 | /// .document_type_as_payload(handler)
|
1190 1224 | /// /* Set other handlers */
|
1191 1225 | /// .build()
|
1192 1226 | /// .unwrap();
|
1193 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1227 + | /// # 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;
|
1194 1228 | /// ```
|
1195 1229 | ///
|
1196 1230 | pub fn document_type_as_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1197 1231 | where
|
1198 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::DocumentTypeAsPayload, HandlerExtractors>,
|
1232 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::DocumentTypeAsPayload, HandlerExtractors>,
|
1199 1233 |
|
1200 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1234 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1201 1235 | RestJson<L>,
|
1202 1236 | crate::operation_shape::DocumentTypeAsPayload,
|
1203 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::DocumentTypeAsPayload, HandlerType>
|
1237 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::DocumentTypeAsPayload, HandlerType>
|
1204 1238 | >,
|
1205 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1239 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1206 1240 | RestJson<L>,
|
1207 1241 | crate::operation_shape::DocumentTypeAsPayload,
|
1208 1242 | ModelPl::Output
|
1209 1243 | >,
|
1210 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1244 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1211 1245 | RestJson<L>,
|
1212 1246 | crate::operation_shape::DocumentTypeAsPayload,
|
1213 1247 | <
|
1214 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1215 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1248 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1249 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1216 1250 | RestJson<L>,
|
1217 1251 | crate::operation_shape::DocumentTypeAsPayload,
|
1218 1252 | ModelPl::Output
|
1219 1253 | >
|
1220 1254 | >::Output
|
1221 1255 | >,
|
1222 1256 |
|
1223 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1257 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1224 1258 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1225 1259 |
|
1226 1260 | {
|
1227 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1228 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1261 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1262 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1229 1263 | let svc = crate::operation_shape::DocumentTypeAsPayload::from_handler(handler);
|
1230 1264 | let svc = self.model_plugin.apply(svc);
|
1231 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1265 + | let svc =
|
1266 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1232 1267 | .apply(svc);
|
1233 1268 | let svc = self.http_plugin.apply(svc);
|
1234 1269 | self.document_type_as_payload_custom(svc)
|
1235 1270 | }
|
1236 1271 |
|
1237 1272 | /// Sets the [`DocumentTypeAsPayload`](crate::operation_shape::DocumentTypeAsPayload) operation.
|
1238 1273 | ///
|
1239 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1240 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1274 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1275 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1241 1276 | ///
|
1242 1277 | /// # Example
|
1243 1278 | ///
|
1244 1279 | /// ```no_run
|
1245 1280 | /// use rest_json::{RestJson, RestJsonConfig};
|
1246 1281 | ///
|
1247 1282 | /// use rest_json::{input, output, error};
|
1248 1283 | ///
|
1249 1284 | /// async fn handler(input: input::DocumentTypeAsPayloadInput) -> Result<output::DocumentTypeAsPayloadOutput, error::DocumentTypeAsPayloadError> {
|
1250 1285 | /// todo!()
|
1251 1286 | /// }
|
1252 1287 | ///
|
1253 1288 | /// let config = RestJsonConfig::builder().build();
|
1254 1289 | /// let svc = ::tower::util::service_fn(handler);
|
1255 1290 | /// let app = RestJson::builder(config)
|
1256 1291 | /// .document_type_as_payload_service(svc)
|
1257 1292 | /// /* Set other handlers */
|
1258 1293 | /// .build()
|
1259 1294 | /// .unwrap();
|
1260 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1295 + | /// # 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;
|
1261 1296 | /// ```
|
1262 1297 | ///
|
1263 1298 | pub fn document_type_as_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1264 1299 | where
|
1265 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::DocumentTypeAsPayload, ServiceExtractors>,
|
1300 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::DocumentTypeAsPayload, ServiceExtractors>,
|
1266 1301 |
|
1267 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1302 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1268 1303 | RestJson<L>,
|
1269 1304 | crate::operation_shape::DocumentTypeAsPayload,
|
1270 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::DocumentTypeAsPayload, S>
|
1305 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::DocumentTypeAsPayload, S>
|
1271 1306 | >,
|
1272 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1307 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1273 1308 | RestJson<L>,
|
1274 1309 | crate::operation_shape::DocumentTypeAsPayload,
|
1275 1310 | ModelPl::Output
|
1276 1311 | >,
|
1277 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1312 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1278 1313 | RestJson<L>,
|
1279 1314 | crate::operation_shape::DocumentTypeAsPayload,
|
1280 1315 | <
|
1281 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1282 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1316 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1317 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1283 1318 | RestJson<L>,
|
1284 1319 | crate::operation_shape::DocumentTypeAsPayload,
|
1285 1320 | ModelPl::Output
|
1286 1321 | >
|
1287 1322 | >::Output
|
1288 1323 | >,
|
1289 1324 |
|
1290 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1325 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1291 1326 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1292 1327 |
|
1293 1328 | {
|
1294 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1295 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1329 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1330 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1296 1331 | let svc = crate::operation_shape::DocumentTypeAsPayload::from_service(service);
|
1297 1332 | let svc = self.model_plugin.apply(svc);
|
1298 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1333 + | let svc =
|
1334 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1299 1335 | .apply(svc);
|
1300 1336 | let svc = self.http_plugin.apply(svc);
|
1301 1337 | self.document_type_as_payload_custom(svc)
|
1302 1338 | }
|
1303 1339 |
|
1304 1340 | /// Sets the [`DocumentTypeAsPayload`](crate::operation_shape::DocumentTypeAsPayload) to a custom [`Service`](tower::Service).
|
1305 1341 | /// not constrained by the Smithy contract.
|
1306 1342 | fn document_type_as_payload_custom<S>(mut self, svc: S) -> Self
|
1307 1343 | where
|
1308 1344 | S: ::tower::Service<
|
1309 1345 | ::http::Request<Body>,
|
1310 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1346 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1311 1347 | Error = ::std::convert::Infallible,
|
1312 1348 | > + Clone
|
1313 1349 | + Send
|
1314 1350 | + 'static,
|
1315 1351 | S::Future: Send + 'static,
|
1316 1352 | {
|
1317 - | self.document_type_as_payload = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1353 + | self.document_type_as_payload =
|
1354 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1318 1355 | self
|
1319 1356 | }
|
1320 1357 |
|
1321 1358 | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1322 1359 | ///
|
1323 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1324 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1360 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1361 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1325 1362 | ///
|
1326 1363 | /// # Example
|
1327 1364 | ///
|
1328 1365 | /// ```no_run
|
1329 1366 | /// use rest_json::{RestJson, RestJsonConfig};
|
1330 1367 | ///
|
1331 1368 | /// use rest_json::{input, output, error};
|
1332 1369 | ///
|
1333 1370 | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> Result<output::EmptyInputAndEmptyOutputOutput, error::EmptyInputAndEmptyOutputError> {
|
1334 1371 | /// todo!()
|
1335 1372 | /// }
|
1336 1373 | ///
|
1337 1374 | /// let config = RestJsonConfig::builder().build();
|
1338 1375 | /// let app = RestJson::builder(config)
|
1339 1376 | /// .empty_input_and_empty_output(handler)
|
1340 1377 | /// /* Set other handlers */
|
1341 1378 | /// .build()
|
1342 1379 | /// .unwrap();
|
1343 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1380 + | /// # 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;
|
1344 1381 | /// ```
|
1345 1382 | ///
|
1346 1383 | pub fn empty_input_and_empty_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1347 1384 | where
|
1348 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerExtractors>,
|
1385 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerExtractors>,
|
1349 1386 |
|
1350 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1387 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1351 1388 | RestJson<L>,
|
1352 1389 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1353 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerType>
|
1390 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EmptyInputAndEmptyOutput, HandlerType>
|
1354 1391 | >,
|
1355 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1392 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1356 1393 | RestJson<L>,
|
1357 1394 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1358 1395 | ModelPl::Output
|
1359 1396 | >,
|
1360 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1397 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1361 1398 | RestJson<L>,
|
1362 1399 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1363 1400 | <
|
1364 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1365 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1401 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1402 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1366 1403 | RestJson<L>,
|
1367 1404 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1368 1405 | ModelPl::Output
|
1369 1406 | >
|
1370 1407 | >::Output
|
1371 1408 | >,
|
1372 1409 |
|
1373 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1410 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1374 1411 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1375 1412 |
|
1376 1413 | {
|
1377 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1378 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1414 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1415 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1379 1416 | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_handler(handler);
|
1380 1417 | let svc = self.model_plugin.apply(svc);
|
1381 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1418 + | let svc =
|
1419 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1382 1420 | .apply(svc);
|
1383 1421 | let svc = self.http_plugin.apply(svc);
|
1384 1422 | self.empty_input_and_empty_output_custom(svc)
|
1385 1423 | }
|
1386 1424 |
|
1387 1425 | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) operation.
|
1388 1426 | ///
|
1389 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1390 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1427 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1428 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1391 1429 | ///
|
1392 1430 | /// # Example
|
1393 1431 | ///
|
1394 1432 | /// ```no_run
|
1395 1433 | /// use rest_json::{RestJson, RestJsonConfig};
|
1396 1434 | ///
|
1397 1435 | /// use rest_json::{input, output, error};
|
1398 1436 | ///
|
1399 1437 | /// async fn handler(input: input::EmptyInputAndEmptyOutputInput) -> Result<output::EmptyInputAndEmptyOutputOutput, error::EmptyInputAndEmptyOutputError> {
|
1400 1438 | /// todo!()
|
1401 1439 | /// }
|
1402 1440 | ///
|
1403 1441 | /// let config = RestJsonConfig::builder().build();
|
1404 1442 | /// let svc = ::tower::util::service_fn(handler);
|
1405 1443 | /// let app = RestJson::builder(config)
|
1406 1444 | /// .empty_input_and_empty_output_service(svc)
|
1407 1445 | /// /* Set other handlers */
|
1408 1446 | /// .build()
|
1409 1447 | /// .unwrap();
|
1410 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1448 + | /// # 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;
|
1411 1449 | /// ```
|
1412 1450 | ///
|
1413 1451 | pub fn empty_input_and_empty_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1414 1452 | where
|
1415 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::EmptyInputAndEmptyOutput, ServiceExtractors>,
|
1453 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EmptyInputAndEmptyOutput, ServiceExtractors>,
|
1416 1454 |
|
1417 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1455 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1418 1456 | RestJson<L>,
|
1419 1457 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1420 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::EmptyInputAndEmptyOutput, S>
|
1458 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EmptyInputAndEmptyOutput, S>
|
1421 1459 | >,
|
1422 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1460 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1423 1461 | RestJson<L>,
|
1424 1462 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1425 1463 | ModelPl::Output
|
1426 1464 | >,
|
1427 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1465 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1428 1466 | RestJson<L>,
|
1429 1467 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1430 1468 | <
|
1431 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1432 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1469 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1470 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1433 1471 | RestJson<L>,
|
1434 1472 | crate::operation_shape::EmptyInputAndEmptyOutput,
|
1435 1473 | ModelPl::Output
|
1436 1474 | >
|
1437 1475 | >::Output
|
1438 1476 | >,
|
1439 1477 |
|
1440 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1478 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1441 1479 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1442 1480 |
|
1443 1481 | {
|
1444 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1445 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1482 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1483 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1446 1484 | let svc = crate::operation_shape::EmptyInputAndEmptyOutput::from_service(service);
|
1447 1485 | let svc = self.model_plugin.apply(svc);
|
1448 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1486 + | let svc =
|
1487 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1449 1488 | .apply(svc);
|
1450 1489 | let svc = self.http_plugin.apply(svc);
|
1451 1490 | self.empty_input_and_empty_output_custom(svc)
|
1452 1491 | }
|
1453 1492 |
|
1454 1493 | /// Sets the [`EmptyInputAndEmptyOutput`](crate::operation_shape::EmptyInputAndEmptyOutput) to a custom [`Service`](tower::Service).
|
1455 1494 | /// not constrained by the Smithy contract.
|
1456 1495 | fn empty_input_and_empty_output_custom<S>(mut self, svc: S) -> Self
|
1457 1496 | where
|
1458 1497 | S: ::tower::Service<
|
1459 1498 | ::http::Request<Body>,
|
1460 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1499 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1461 1500 | Error = ::std::convert::Infallible,
|
1462 1501 | > + Clone
|
1463 1502 | + Send
|
1464 1503 | + 'static,
|
1465 1504 | S::Future: Send + 'static,
|
1466 1505 | {
|
1467 1506 | self.empty_input_and_empty_output =
|
1468 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1507 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1469 1508 | self
|
1470 1509 | }
|
1471 1510 |
|
1472 1511 | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
1473 1512 | ///
|
1474 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1475 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1513 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1514 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1476 1515 | ///
|
1477 1516 | /// # Example
|
1478 1517 | ///
|
1479 1518 | /// ```no_run
|
1480 1519 | /// use rest_json::{RestJson, RestJsonConfig};
|
1481 1520 | ///
|
1482 1521 | /// use rest_json::{input, output, error};
|
1483 1522 | ///
|
1484 1523 | /// async fn handler(input: input::EndpointOperationInput) -> Result<output::EndpointOperationOutput, error::EndpointOperationError> {
|
1485 1524 | /// todo!()
|
1486 1525 | /// }
|
1487 1526 | ///
|
1488 1527 | /// let config = RestJsonConfig::builder().build();
|
1489 1528 | /// let app = RestJson::builder(config)
|
1490 1529 | /// .endpoint_operation(handler)
|
1491 1530 | /// /* Set other handlers */
|
1492 1531 | /// .build()
|
1493 1532 | /// .unwrap();
|
1494 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1533 + | /// # 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;
|
1495 1534 | /// ```
|
1496 1535 | ///
|
1497 1536 | pub fn endpoint_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1498 1537 | where
|
1499 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::EndpointOperation, HandlerExtractors>,
|
1538 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointOperation, HandlerExtractors>,
|
1500 1539 |
|
1501 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1540 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1502 1541 | RestJson<L>,
|
1503 1542 | crate::operation_shape::EndpointOperation,
|
1504 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::EndpointOperation, HandlerType>
|
1543 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointOperation, HandlerType>
|
1505 1544 | >,
|
1506 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1545 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1507 1546 | RestJson<L>,
|
1508 1547 | crate::operation_shape::EndpointOperation,
|
1509 1548 | ModelPl::Output
|
1510 1549 | >,
|
1511 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1550 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1512 1551 | RestJson<L>,
|
1513 1552 | crate::operation_shape::EndpointOperation,
|
1514 1553 | <
|
1515 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1516 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1554 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1555 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1517 1556 | RestJson<L>,
|
1518 1557 | crate::operation_shape::EndpointOperation,
|
1519 1558 | ModelPl::Output
|
1520 1559 | >
|
1521 1560 | >::Output
|
1522 1561 | >,
|
1523 1562 |
|
1524 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1563 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1525 1564 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1526 1565 |
|
1527 1566 | {
|
1528 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1529 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1567 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1568 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1530 1569 | let svc = crate::operation_shape::EndpointOperation::from_handler(handler);
|
1531 1570 | let svc = self.model_plugin.apply(svc);
|
1532 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1571 + | let svc =
|
1572 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1533 1573 | .apply(svc);
|
1534 1574 | let svc = self.http_plugin.apply(svc);
|
1535 1575 | self.endpoint_operation_custom(svc)
|
1536 1576 | }
|
1537 1577 |
|
1538 1578 | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) operation.
|
1539 1579 | ///
|
1540 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1541 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1580 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1581 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1542 1582 | ///
|
1543 1583 | /// # Example
|
1544 1584 | ///
|
1545 1585 | /// ```no_run
|
1546 1586 | /// use rest_json::{RestJson, RestJsonConfig};
|
1547 1587 | ///
|
1548 1588 | /// use rest_json::{input, output, error};
|
1549 1589 | ///
|
1550 1590 | /// async fn handler(input: input::EndpointOperationInput) -> Result<output::EndpointOperationOutput, error::EndpointOperationError> {
|
1551 1591 | /// todo!()
|
1552 1592 | /// }
|
1553 1593 | ///
|
1554 1594 | /// let config = RestJsonConfig::builder().build();
|
1555 1595 | /// let svc = ::tower::util::service_fn(handler);
|
1556 1596 | /// let app = RestJson::builder(config)
|
1557 1597 | /// .endpoint_operation_service(svc)
|
1558 1598 | /// /* Set other handlers */
|
1559 1599 | /// .build()
|
1560 1600 | /// .unwrap();
|
1561 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1601 + | /// # 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;
|
1562 1602 | /// ```
|
1563 1603 | ///
|
1564 1604 | pub fn endpoint_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1565 1605 | where
|
1566 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::EndpointOperation, ServiceExtractors>,
|
1606 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointOperation, ServiceExtractors>,
|
1567 1607 |
|
1568 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1608 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1569 1609 | RestJson<L>,
|
1570 1610 | crate::operation_shape::EndpointOperation,
|
1571 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::EndpointOperation, S>
|
1611 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointOperation, S>
|
1572 1612 | >,
|
1573 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1613 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1574 1614 | RestJson<L>,
|
1575 1615 | crate::operation_shape::EndpointOperation,
|
1576 1616 | ModelPl::Output
|
1577 1617 | >,
|
1578 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1618 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1579 1619 | RestJson<L>,
|
1580 1620 | crate::operation_shape::EndpointOperation,
|
1581 1621 | <
|
1582 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1583 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1622 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1623 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1584 1624 | RestJson<L>,
|
1585 1625 | crate::operation_shape::EndpointOperation,
|
1586 1626 | ModelPl::Output
|
1587 1627 | >
|
1588 1628 | >::Output
|
1589 1629 | >,
|
1590 1630 |
|
1591 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1631 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1592 1632 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1593 1633 |
|
1594 1634 | {
|
1595 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1596 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1635 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1636 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1597 1637 | let svc = crate::operation_shape::EndpointOperation::from_service(service);
|
1598 1638 | let svc = self.model_plugin.apply(svc);
|
1599 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1639 + | let svc =
|
1640 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1600 1641 | .apply(svc);
|
1601 1642 | let svc = self.http_plugin.apply(svc);
|
1602 1643 | self.endpoint_operation_custom(svc)
|
1603 1644 | }
|
1604 1645 |
|
1605 1646 | /// Sets the [`EndpointOperation`](crate::operation_shape::EndpointOperation) to a custom [`Service`](tower::Service).
|
1606 1647 | /// not constrained by the Smithy contract.
|
1607 1648 | fn endpoint_operation_custom<S>(mut self, svc: S) -> Self
|
1608 1649 | where
|
1609 1650 | S: ::tower::Service<
|
1610 1651 | ::http::Request<Body>,
|
1611 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1652 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1612 1653 | Error = ::std::convert::Infallible,
|
1613 1654 | > + Clone
|
1614 1655 | + Send
|
1615 1656 | + 'static,
|
1616 1657 | S::Future: Send + 'static,
|
1617 1658 | {
|
1618 - | self.endpoint_operation = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1659 + | self.endpoint_operation = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1619 1660 | self
|
1620 1661 | }
|
1621 1662 |
|
1622 1663 | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
1623 1664 | ///
|
1624 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1625 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1665 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1666 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1626 1667 | ///
|
1627 1668 | /// # Example
|
1628 1669 | ///
|
1629 1670 | /// ```no_run
|
1630 1671 | /// use rest_json::{RestJson, RestJsonConfig};
|
1631 1672 | ///
|
1632 1673 | /// use rest_json::{input, output, error};
|
1633 1674 | ///
|
1634 1675 | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
1635 1676 | /// todo!()
|
1636 1677 | /// }
|
1637 1678 | ///
|
1638 1679 | /// let config = RestJsonConfig::builder().build();
|
1639 1680 | /// let app = RestJson::builder(config)
|
1640 1681 | /// .endpoint_with_host_label_operation(handler)
|
1641 1682 | /// /* Set other handlers */
|
1642 1683 | /// .build()
|
1643 1684 | /// .unwrap();
|
1644 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1685 + | /// # 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;
|
1645 1686 | /// ```
|
1646 1687 | ///
|
1647 1688 | pub fn endpoint_with_host_label_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1648 1689 | where
|
1649 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::EndpointWithHostLabelOperation, HandlerExtractors>,
|
1690 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::EndpointWithHostLabelOperation, HandlerExtractors>,
|
1650 1691 |
|
1651 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1692 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1652 1693 | RestJson<L>,
|
1653 1694 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1654 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::EndpointWithHostLabelOperation, HandlerType>
|
1695 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::EndpointWithHostLabelOperation, HandlerType>
|
1655 1696 | >,
|
1656 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1697 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1657 1698 | RestJson<L>,
|
1658 1699 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1659 1700 | ModelPl::Output
|
1660 1701 | >,
|
1661 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1702 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1662 1703 | RestJson<L>,
|
1663 1704 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1664 1705 | <
|
1665 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1666 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1706 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1707 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1667 1708 | RestJson<L>,
|
1668 1709 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1669 1710 | ModelPl::Output
|
1670 1711 | >
|
1671 1712 | >::Output
|
1672 1713 | >,
|
1673 1714 |
|
1674 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1715 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1675 1716 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1676 1717 |
|
1677 1718 | {
|
1678 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1679 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1719 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1720 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1680 1721 | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_handler(handler);
|
1681 1722 | let svc = self.model_plugin.apply(svc);
|
1682 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1723 + | let svc =
|
1724 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1683 1725 | .apply(svc);
|
1684 1726 | let svc = self.http_plugin.apply(svc);
|
1685 1727 | self.endpoint_with_host_label_operation_custom(svc)
|
1686 1728 | }
|
1687 1729 |
|
1688 1730 | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) operation.
|
1689 1731 | ///
|
1690 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1691 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1732 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1733 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1692 1734 | ///
|
1693 1735 | /// # Example
|
1694 1736 | ///
|
1695 1737 | /// ```no_run
|
1696 1738 | /// use rest_json::{RestJson, RestJsonConfig};
|
1697 1739 | ///
|
1698 1740 | /// use rest_json::{input, output, error};
|
1699 1741 | ///
|
1700 1742 | /// async fn handler(input: input::EndpointWithHostLabelOperationInput) -> Result<output::EndpointWithHostLabelOperationOutput, error::EndpointWithHostLabelOperationError> {
|
1701 1743 | /// todo!()
|
1702 1744 | /// }
|
1703 1745 | ///
|
1704 1746 | /// let config = RestJsonConfig::builder().build();
|
1705 1747 | /// let svc = ::tower::util::service_fn(handler);
|
1706 1748 | /// let app = RestJson::builder(config)
|
1707 1749 | /// .endpoint_with_host_label_operation_service(svc)
|
1708 1750 | /// /* Set other handlers */
|
1709 1751 | /// .build()
|
1710 1752 | /// .unwrap();
|
1711 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1753 + | /// # 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;
|
1712 1754 | /// ```
|
1713 1755 | ///
|
1714 1756 | pub fn endpoint_with_host_label_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1715 1757 | where
|
1716 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::EndpointWithHostLabelOperation, ServiceExtractors>,
|
1758 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::EndpointWithHostLabelOperation, ServiceExtractors>,
|
1717 1759 |
|
1718 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1760 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1719 1761 | RestJson<L>,
|
1720 1762 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1721 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::EndpointWithHostLabelOperation, S>
|
1763 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::EndpointWithHostLabelOperation, S>
|
1722 1764 | >,
|
1723 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1765 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1724 1766 | RestJson<L>,
|
1725 1767 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1726 1768 | ModelPl::Output
|
1727 1769 | >,
|
1728 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1770 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1729 1771 | RestJson<L>,
|
1730 1772 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1731 1773 | <
|
1732 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1733 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1774 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1775 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1734 1776 | RestJson<L>,
|
1735 1777 | crate::operation_shape::EndpointWithHostLabelOperation,
|
1736 1778 | ModelPl::Output
|
1737 1779 | >
|
1738 1780 | >::Output
|
1739 1781 | >,
|
1740 1782 |
|
1741 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1783 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1742 1784 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1743 1785 |
|
1744 1786 | {
|
1745 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1746 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1787 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1788 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1747 1789 | let svc = crate::operation_shape::EndpointWithHostLabelOperation::from_service(service);
|
1748 1790 | let svc = self.model_plugin.apply(svc);
|
1749 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1791 + | let svc =
|
1792 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1750 1793 | .apply(svc);
|
1751 1794 | let svc = self.http_plugin.apply(svc);
|
1752 1795 | self.endpoint_with_host_label_operation_custom(svc)
|
1753 1796 | }
|
1754 1797 |
|
1755 1798 | /// Sets the [`EndpointWithHostLabelOperation`](crate::operation_shape::EndpointWithHostLabelOperation) to a custom [`Service`](tower::Service).
|
1756 1799 | /// not constrained by the Smithy contract.
|
1757 1800 | fn endpoint_with_host_label_operation_custom<S>(mut self, svc: S) -> Self
|
1758 1801 | where
|
1759 1802 | S: ::tower::Service<
|
1760 1803 | ::http::Request<Body>,
|
1761 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1804 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1762 1805 | Error = ::std::convert::Infallible,
|
1763 1806 | > + Clone
|
1764 1807 | + Send
|
1765 1808 | + 'static,
|
1766 1809 | S::Future: Send + 'static,
|
1767 1810 | {
|
1768 1811 | self.endpoint_with_host_label_operation =
|
1769 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1812 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1770 1813 | self
|
1771 1814 | }
|
1772 1815 |
|
1773 1816 | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
1774 1817 | ///
|
1775 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1776 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1818 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1819 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1777 1820 | ///
|
1778 1821 | /// # Example
|
1779 1822 | ///
|
1780 1823 | /// ```no_run
|
1781 1824 | /// use rest_json::{RestJson, RestJsonConfig};
|
1782 1825 | ///
|
1783 1826 | /// use rest_json::{input, output, error};
|
1784 1827 | ///
|
1785 1828 | /// async fn handler(input: input::FractionalSecondsInput) -> Result<output::FractionalSecondsOutput, error::FractionalSecondsError> {
|
1786 1829 | /// todo!()
|
1787 1830 | /// }
|
1788 1831 | ///
|
1789 1832 | /// let config = RestJsonConfig::builder().build();
|
1790 1833 | /// let app = RestJson::builder(config)
|
1791 1834 | /// .fractional_seconds(handler)
|
1792 1835 | /// /* Set other handlers */
|
1793 1836 | /// .build()
|
1794 1837 | /// .unwrap();
|
1795 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1838 + | /// # 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;
|
1796 1839 | /// ```
|
1797 1840 | ///
|
1798 1841 | pub fn fractional_seconds<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1799 1842 | where
|
1800 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::FractionalSeconds, HandlerExtractors>,
|
1843 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::FractionalSeconds, HandlerExtractors>,
|
1801 1844 |
|
1802 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1845 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1803 1846 | RestJson<L>,
|
1804 1847 | crate::operation_shape::FractionalSeconds,
|
1805 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::FractionalSeconds, HandlerType>
|
1848 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::FractionalSeconds, HandlerType>
|
1806 1849 | >,
|
1807 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1850 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1808 1851 | RestJson<L>,
|
1809 1852 | crate::operation_shape::FractionalSeconds,
|
1810 1853 | ModelPl::Output
|
1811 1854 | >,
|
1812 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1855 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1813 1856 | RestJson<L>,
|
1814 1857 | crate::operation_shape::FractionalSeconds,
|
1815 1858 | <
|
1816 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1817 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1859 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1860 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1818 1861 | RestJson<L>,
|
1819 1862 | crate::operation_shape::FractionalSeconds,
|
1820 1863 | ModelPl::Output
|
1821 1864 | >
|
1822 1865 | >::Output
|
1823 1866 | >,
|
1824 1867 |
|
1825 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1868 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1826 1869 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1827 1870 |
|
1828 1871 | {
|
1829 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1830 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1872 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1873 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1831 1874 | let svc = crate::operation_shape::FractionalSeconds::from_handler(handler);
|
1832 1875 | let svc = self.model_plugin.apply(svc);
|
1833 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1876 + | let svc =
|
1877 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1834 1878 | .apply(svc);
|
1835 1879 | let svc = self.http_plugin.apply(svc);
|
1836 1880 | self.fractional_seconds_custom(svc)
|
1837 1881 | }
|
1838 1882 |
|
1839 1883 | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) operation.
|
1840 1884 | ///
|
1841 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1842 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1885 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1886 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1843 1887 | ///
|
1844 1888 | /// # Example
|
1845 1889 | ///
|
1846 1890 | /// ```no_run
|
1847 1891 | /// use rest_json::{RestJson, RestJsonConfig};
|
1848 1892 | ///
|
1849 1893 | /// use rest_json::{input, output, error};
|
1850 1894 | ///
|
1851 1895 | /// async fn handler(input: input::FractionalSecondsInput) -> Result<output::FractionalSecondsOutput, error::FractionalSecondsError> {
|
1852 1896 | /// todo!()
|
1853 1897 | /// }
|
1854 1898 | ///
|
1855 1899 | /// let config = RestJsonConfig::builder().build();
|
1856 1900 | /// let svc = ::tower::util::service_fn(handler);
|
1857 1901 | /// let app = RestJson::builder(config)
|
1858 1902 | /// .fractional_seconds_service(svc)
|
1859 1903 | /// /* Set other handlers */
|
1860 1904 | /// .build()
|
1861 1905 | /// .unwrap();
|
1862 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1906 + | /// # 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;
|
1863 1907 | /// ```
|
1864 1908 | ///
|
1865 1909 | pub fn fractional_seconds_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
1866 1910 | where
|
1867 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::FractionalSeconds, ServiceExtractors>,
|
1911 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::FractionalSeconds, ServiceExtractors>,
|
1868 1912 |
|
1869 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1913 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1870 1914 | RestJson<L>,
|
1871 1915 | crate::operation_shape::FractionalSeconds,
|
1872 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::FractionalSeconds, S>
|
1916 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::FractionalSeconds, S>
|
1873 1917 | >,
|
1874 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
1918 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1875 1919 | RestJson<L>,
|
1876 1920 | crate::operation_shape::FractionalSeconds,
|
1877 1921 | ModelPl::Output
|
1878 1922 | >,
|
1879 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
1923 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1880 1924 | RestJson<L>,
|
1881 1925 | crate::operation_shape::FractionalSeconds,
|
1882 1926 | <
|
1883 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1884 - | as ::aws_smithy_http_server::plugin::Plugin<
|
1927 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1928 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1885 1929 | RestJson<L>,
|
1886 1930 | crate::operation_shape::FractionalSeconds,
|
1887 1931 | ModelPl::Output
|
1888 1932 | >
|
1889 1933 | >::Output
|
1890 1934 | >,
|
1891 1935 |
|
1892 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1936 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1893 1937 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1894 1938 |
|
1895 1939 | {
|
1896 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1897 - | use ::aws_smithy_http_server::plugin::Plugin;
|
1940 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
1941 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1898 1942 | let svc = crate::operation_shape::FractionalSeconds::from_service(service);
|
1899 1943 | let svc = self.model_plugin.apply(svc);
|
1900 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1944 + | let svc =
|
1945 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1901 1946 | .apply(svc);
|
1902 1947 | let svc = self.http_plugin.apply(svc);
|
1903 1948 | self.fractional_seconds_custom(svc)
|
1904 1949 | }
|
1905 1950 |
|
1906 1951 | /// Sets the [`FractionalSeconds`](crate::operation_shape::FractionalSeconds) to a custom [`Service`](tower::Service).
|
1907 1952 | /// not constrained by the Smithy contract.
|
1908 1953 | fn fractional_seconds_custom<S>(mut self, svc: S) -> Self
|
1909 1954 | where
|
1910 1955 | S: ::tower::Service<
|
1911 1956 | ::http::Request<Body>,
|
1912 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
1957 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
1913 1958 | Error = ::std::convert::Infallible,
|
1914 1959 | > + Clone
|
1915 1960 | + Send
|
1916 1961 | + 'static,
|
1917 1962 | S::Future: Send + 'static,
|
1918 1963 | {
|
1919 - | self.fractional_seconds = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
1964 + | self.fractional_seconds = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
1920 1965 | self
|
1921 1966 | }
|
1922 1967 |
|
1923 1968 | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
1924 1969 | ///
|
1925 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1926 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
1970 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
1971 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1927 1972 | ///
|
1928 1973 | /// # Example
|
1929 1974 | ///
|
1930 1975 | /// ```no_run
|
1931 1976 | /// use rest_json::{RestJson, RestJsonConfig};
|
1932 1977 | ///
|
1933 1978 | /// use rest_json::{input, output, error};
|
1934 1979 | ///
|
1935 1980 | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
1936 1981 | /// todo!()
|
1937 1982 | /// }
|
1938 1983 | ///
|
1939 1984 | /// let config = RestJsonConfig::builder().build();
|
1940 1985 | /// let app = RestJson::builder(config)
|
1941 1986 | /// .greeting_with_errors(handler)
|
1942 1987 | /// /* Set other handlers */
|
1943 1988 | /// .build()
|
1944 1989 | /// .unwrap();
|
1945 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
1990 + | /// # 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;
|
1946 1991 | /// ```
|
1947 1992 | ///
|
1948 1993 | pub fn greeting_with_errors<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
1949 1994 | where
|
1950 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::GreetingWithErrors, HandlerExtractors>,
|
1995 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::GreetingWithErrors, HandlerExtractors>,
|
1951 1996 |
|
1952 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
1997 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1953 1998 | RestJson<L>,
|
1954 1999 | crate::operation_shape::GreetingWithErrors,
|
1955 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::GreetingWithErrors, HandlerType>
|
2000 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::GreetingWithErrors, HandlerType>
|
1956 2001 | >,
|
1957 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2002 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1958 2003 | RestJson<L>,
|
1959 2004 | crate::operation_shape::GreetingWithErrors,
|
1960 2005 | ModelPl::Output
|
1961 2006 | >,
|
1962 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2007 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1963 2008 | RestJson<L>,
|
1964 2009 | crate::operation_shape::GreetingWithErrors,
|
1965 2010 | <
|
1966 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
1967 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2011 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2012 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
1968 2013 | RestJson<L>,
|
1969 2014 | crate::operation_shape::GreetingWithErrors,
|
1970 2015 | ModelPl::Output
|
1971 2016 | >
|
1972 2017 | >::Output
|
1973 2018 | >,
|
1974 2019 |
|
1975 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2020 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
1976 2021 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
1977 2022 |
|
1978 2023 | {
|
1979 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
1980 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2024 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2025 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
1981 2026 | let svc = crate::operation_shape::GreetingWithErrors::from_handler(handler);
|
1982 2027 | let svc = self.model_plugin.apply(svc);
|
1983 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2028 + | let svc =
|
2029 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
1984 2030 | .apply(svc);
|
1985 2031 | let svc = self.http_plugin.apply(svc);
|
1986 2032 | self.greeting_with_errors_custom(svc)
|
1987 2033 | }
|
1988 2034 |
|
1989 2035 | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) operation.
|
1990 2036 | ///
|
1991 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
1992 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2037 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2038 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
1993 2039 | ///
|
1994 2040 | /// # Example
|
1995 2041 | ///
|
1996 2042 | /// ```no_run
|
1997 2043 | /// use rest_json::{RestJson, RestJsonConfig};
|
1998 2044 | ///
|
1999 2045 | /// use rest_json::{input, output, error};
|
2000 2046 | ///
|
2001 2047 | /// async fn handler(input: input::GreetingWithErrorsInput) -> Result<output::GreetingWithErrorsOutput, error::GreetingWithErrorsError> {
|
2002 2048 | /// todo!()
|
2003 2049 | /// }
|
2004 2050 | ///
|
2005 2051 | /// let config = RestJsonConfig::builder().build();
|
2006 2052 | /// let svc = ::tower::util::service_fn(handler);
|
2007 2053 | /// let app = RestJson::builder(config)
|
2008 2054 | /// .greeting_with_errors_service(svc)
|
2009 2055 | /// /* Set other handlers */
|
2010 2056 | /// .build()
|
2011 2057 | /// .unwrap();
|
2012 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2058 + | /// # 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;
|
2013 2059 | /// ```
|
2014 2060 | ///
|
2015 2061 | pub fn greeting_with_errors_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2016 2062 | where
|
2017 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::GreetingWithErrors, ServiceExtractors>,
|
2063 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::GreetingWithErrors, ServiceExtractors>,
|
2018 2064 |
|
2019 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2065 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2020 2066 | RestJson<L>,
|
2021 2067 | crate::operation_shape::GreetingWithErrors,
|
2022 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::GreetingWithErrors, S>
|
2068 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::GreetingWithErrors, S>
|
2023 2069 | >,
|
2024 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2070 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2025 2071 | RestJson<L>,
|
2026 2072 | crate::operation_shape::GreetingWithErrors,
|
2027 2073 | ModelPl::Output
|
2028 2074 | >,
|
2029 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2075 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2030 2076 | RestJson<L>,
|
2031 2077 | crate::operation_shape::GreetingWithErrors,
|
2032 2078 | <
|
2033 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2034 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2079 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2080 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2035 2081 | RestJson<L>,
|
2036 2082 | crate::operation_shape::GreetingWithErrors,
|
2037 2083 | ModelPl::Output
|
2038 2084 | >
|
2039 2085 | >::Output
|
2040 2086 | >,
|
2041 2087 |
|
2042 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2088 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2043 2089 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2044 2090 |
|
2045 2091 | {
|
2046 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2047 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2092 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2093 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2048 2094 | let svc = crate::operation_shape::GreetingWithErrors::from_service(service);
|
2049 2095 | let svc = self.model_plugin.apply(svc);
|
2050 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2096 + | let svc =
|
2097 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2051 2098 | .apply(svc);
|
2052 2099 | let svc = self.http_plugin.apply(svc);
|
2053 2100 | self.greeting_with_errors_custom(svc)
|
2054 2101 | }
|
2055 2102 |
|
2056 2103 | /// Sets the [`GreetingWithErrors`](crate::operation_shape::GreetingWithErrors) to a custom [`Service`](tower::Service).
|
2057 2104 | /// not constrained by the Smithy contract.
|
2058 2105 | fn greeting_with_errors_custom<S>(mut self, svc: S) -> Self
|
2059 2106 | where
|
2060 2107 | S: ::tower::Service<
|
2061 2108 | ::http::Request<Body>,
|
2062 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2109 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2063 2110 | Error = ::std::convert::Infallible,
|
2064 2111 | > + Clone
|
2065 2112 | + Send
|
2066 2113 | + 'static,
|
2067 2114 | S::Future: Send + 'static,
|
2068 2115 | {
|
2069 - | self.greeting_with_errors = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2116 + | self.greeting_with_errors = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2070 2117 | self
|
2071 2118 | }
|
2072 2119 |
|
2073 2120 | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2074 2121 | ///
|
2075 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2076 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2122 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2123 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2077 2124 | ///
|
2078 2125 | /// # Example
|
2079 2126 | ///
|
2080 2127 | /// ```no_run
|
2081 2128 | /// use rest_json::{RestJson, RestJsonConfig};
|
2082 2129 | ///
|
2083 2130 | /// use rest_json::{input, output, error};
|
2084 2131 | ///
|
2085 2132 | /// async fn handler(input: input::HostWithPathOperationInput) -> Result<output::HostWithPathOperationOutput, error::HostWithPathOperationError> {
|
2086 2133 | /// todo!()
|
2087 2134 | /// }
|
2088 2135 | ///
|
2089 2136 | /// let config = RestJsonConfig::builder().build();
|
2090 2137 | /// let app = RestJson::builder(config)
|
2091 2138 | /// .host_with_path_operation(handler)
|
2092 2139 | /// /* Set other handlers */
|
2093 2140 | /// .build()
|
2094 2141 | /// .unwrap();
|
2095 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2142 + | /// # 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;
|
2096 2143 | /// ```
|
2097 2144 | ///
|
2098 2145 | pub fn host_with_path_operation<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2099 2146 | where
|
2100 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HostWithPathOperation, HandlerExtractors>,
|
2147 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HostWithPathOperation, HandlerExtractors>,
|
2101 2148 |
|
2102 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2149 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2103 2150 | RestJson<L>,
|
2104 2151 | crate::operation_shape::HostWithPathOperation,
|
2105 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HostWithPathOperation, HandlerType>
|
2152 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HostWithPathOperation, HandlerType>
|
2106 2153 | >,
|
2107 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2154 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2108 2155 | RestJson<L>,
|
2109 2156 | crate::operation_shape::HostWithPathOperation,
|
2110 2157 | ModelPl::Output
|
2111 2158 | >,
|
2112 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2159 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2113 2160 | RestJson<L>,
|
2114 2161 | crate::operation_shape::HostWithPathOperation,
|
2115 2162 | <
|
2116 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2117 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2163 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2164 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2118 2165 | RestJson<L>,
|
2119 2166 | crate::operation_shape::HostWithPathOperation,
|
2120 2167 | ModelPl::Output
|
2121 2168 | >
|
2122 2169 | >::Output
|
2123 2170 | >,
|
2124 2171 |
|
2125 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2172 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2126 2173 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2127 2174 |
|
2128 2175 | {
|
2129 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2130 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2176 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2177 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2131 2178 | let svc = crate::operation_shape::HostWithPathOperation::from_handler(handler);
|
2132 2179 | let svc = self.model_plugin.apply(svc);
|
2133 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2180 + | let svc =
|
2181 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2134 2182 | .apply(svc);
|
2135 2183 | let svc = self.http_plugin.apply(svc);
|
2136 2184 | self.host_with_path_operation_custom(svc)
|
2137 2185 | }
|
2138 2186 |
|
2139 2187 | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) operation.
|
2140 2188 | ///
|
2141 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2142 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2189 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2190 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2143 2191 | ///
|
2144 2192 | /// # Example
|
2145 2193 | ///
|
2146 2194 | /// ```no_run
|
2147 2195 | /// use rest_json::{RestJson, RestJsonConfig};
|
2148 2196 | ///
|
2149 2197 | /// use rest_json::{input, output, error};
|
2150 2198 | ///
|
2151 2199 | /// async fn handler(input: input::HostWithPathOperationInput) -> Result<output::HostWithPathOperationOutput, error::HostWithPathOperationError> {
|
2152 2200 | /// todo!()
|
2153 2201 | /// }
|
2154 2202 | ///
|
2155 2203 | /// let config = RestJsonConfig::builder().build();
|
2156 2204 | /// let svc = ::tower::util::service_fn(handler);
|
2157 2205 | /// let app = RestJson::builder(config)
|
2158 2206 | /// .host_with_path_operation_service(svc)
|
2159 2207 | /// /* Set other handlers */
|
2160 2208 | /// .build()
|
2161 2209 | /// .unwrap();
|
2162 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2210 + | /// # 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;
|
2163 2211 | /// ```
|
2164 2212 | ///
|
2165 2213 | pub fn host_with_path_operation_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2166 2214 | where
|
2167 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HostWithPathOperation, ServiceExtractors>,
|
2215 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HostWithPathOperation, ServiceExtractors>,
|
2168 2216 |
|
2169 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2217 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2170 2218 | RestJson<L>,
|
2171 2219 | crate::operation_shape::HostWithPathOperation,
|
2172 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HostWithPathOperation, S>
|
2220 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HostWithPathOperation, S>
|
2173 2221 | >,
|
2174 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2222 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2175 2223 | RestJson<L>,
|
2176 2224 | crate::operation_shape::HostWithPathOperation,
|
2177 2225 | ModelPl::Output
|
2178 2226 | >,
|
2179 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2227 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2180 2228 | RestJson<L>,
|
2181 2229 | crate::operation_shape::HostWithPathOperation,
|
2182 2230 | <
|
2183 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2184 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2231 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2232 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2185 2233 | RestJson<L>,
|
2186 2234 | crate::operation_shape::HostWithPathOperation,
|
2187 2235 | ModelPl::Output
|
2188 2236 | >
|
2189 2237 | >::Output
|
2190 2238 | >,
|
2191 2239 |
|
2192 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2240 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2193 2241 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2194 2242 |
|
2195 2243 | {
|
2196 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2197 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2244 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2245 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2198 2246 | let svc = crate::operation_shape::HostWithPathOperation::from_service(service);
|
2199 2247 | let svc = self.model_plugin.apply(svc);
|
2200 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2248 + | let svc =
|
2249 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2201 2250 | .apply(svc);
|
2202 2251 | let svc = self.http_plugin.apply(svc);
|
2203 2252 | self.host_with_path_operation_custom(svc)
|
2204 2253 | }
|
2205 2254 |
|
2206 2255 | /// Sets the [`HostWithPathOperation`](crate::operation_shape::HostWithPathOperation) to a custom [`Service`](tower::Service).
|
2207 2256 | /// not constrained by the Smithy contract.
|
2208 2257 | fn host_with_path_operation_custom<S>(mut self, svc: S) -> Self
|
2209 2258 | where
|
2210 2259 | S: ::tower::Service<
|
2211 2260 | ::http::Request<Body>,
|
2212 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2261 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2213 2262 | Error = ::std::convert::Infallible,
|
2214 2263 | > + Clone
|
2215 2264 | + Send
|
2216 2265 | + 'static,
|
2217 2266 | S::Future: Send + 'static,
|
2218 2267 | {
|
2219 - | self.host_with_path_operation = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2268 + | self.host_with_path_operation =
|
2269 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2220 2270 | self
|
2221 2271 | }
|
2222 2272 |
|
2223 2273 | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
2224 2274 | ///
|
2225 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2226 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2275 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2276 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2227 2277 | ///
|
2228 2278 | /// # Example
|
2229 2279 | ///
|
2230 2280 | /// ```no_run
|
2231 2281 | /// use rest_json::{RestJson, RestJsonConfig};
|
2232 2282 | ///
|
2233 2283 | /// use rest_json::{input, output, error};
|
2234 2284 | ///
|
2235 2285 | /// async fn handler(input: input::HttpChecksumRequiredInput) -> Result<output::HttpChecksumRequiredOutput, error::HttpChecksumRequiredError> {
|
2236 2286 | /// todo!()
|
2237 2287 | /// }
|
2238 2288 | ///
|
2239 2289 | /// let config = RestJsonConfig::builder().build();
|
2240 2290 | /// let app = RestJson::builder(config)
|
2241 2291 | /// .http_checksum_required(handler)
|
2242 2292 | /// /* Set other handlers */
|
2243 2293 | /// .build()
|
2244 2294 | /// .unwrap();
|
2245 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2295 + | /// # 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;
|
2246 2296 | /// ```
|
2247 2297 | ///
|
2248 2298 | pub fn http_checksum_required<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2249 2299 | where
|
2250 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpChecksumRequired, HandlerExtractors>,
|
2300 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpChecksumRequired, HandlerExtractors>,
|
2251 2301 |
|
2252 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2302 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2253 2303 | RestJson<L>,
|
2254 2304 | crate::operation_shape::HttpChecksumRequired,
|
2255 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpChecksumRequired, HandlerType>
|
2305 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpChecksumRequired, HandlerType>
|
2256 2306 | >,
|
2257 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2307 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2258 2308 | RestJson<L>,
|
2259 2309 | crate::operation_shape::HttpChecksumRequired,
|
2260 2310 | ModelPl::Output
|
2261 2311 | >,
|
2262 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2312 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2263 2313 | RestJson<L>,
|
2264 2314 | crate::operation_shape::HttpChecksumRequired,
|
2265 2315 | <
|
2266 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2267 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2316 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2317 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2268 2318 | RestJson<L>,
|
2269 2319 | crate::operation_shape::HttpChecksumRequired,
|
2270 2320 | ModelPl::Output
|
2271 2321 | >
|
2272 2322 | >::Output
|
2273 2323 | >,
|
2274 2324 |
|
2275 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2325 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2276 2326 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2277 2327 |
|
2278 2328 | {
|
2279 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2280 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2329 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2330 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2281 2331 | let svc = crate::operation_shape::HttpChecksumRequired::from_handler(handler);
|
2282 2332 | let svc = self.model_plugin.apply(svc);
|
2283 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2333 + | let svc =
|
2334 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2284 2335 | .apply(svc);
|
2285 2336 | let svc = self.http_plugin.apply(svc);
|
2286 2337 | self.http_checksum_required_custom(svc)
|
2287 2338 | }
|
2288 2339 |
|
2289 2340 | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) operation.
|
2290 2341 | ///
|
2291 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2292 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2342 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2343 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2293 2344 | ///
|
2294 2345 | /// # Example
|
2295 2346 | ///
|
2296 2347 | /// ```no_run
|
2297 2348 | /// use rest_json::{RestJson, RestJsonConfig};
|
2298 2349 | ///
|
2299 2350 | /// use rest_json::{input, output, error};
|
2300 2351 | ///
|
2301 2352 | /// async fn handler(input: input::HttpChecksumRequiredInput) -> Result<output::HttpChecksumRequiredOutput, error::HttpChecksumRequiredError> {
|
2302 2353 | /// todo!()
|
2303 2354 | /// }
|
2304 2355 | ///
|
2305 2356 | /// let config = RestJsonConfig::builder().build();
|
2306 2357 | /// let svc = ::tower::util::service_fn(handler);
|
2307 2358 | /// let app = RestJson::builder(config)
|
2308 2359 | /// .http_checksum_required_service(svc)
|
2309 2360 | /// /* Set other handlers */
|
2310 2361 | /// .build()
|
2311 2362 | /// .unwrap();
|
2312 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2363 + | /// # 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;
|
2313 2364 | /// ```
|
2314 2365 | ///
|
2315 2366 | pub fn http_checksum_required_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2316 2367 | where
|
2317 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpChecksumRequired, ServiceExtractors>,
|
2368 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpChecksumRequired, ServiceExtractors>,
|
2318 2369 |
|
2319 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2370 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2320 2371 | RestJson<L>,
|
2321 2372 | crate::operation_shape::HttpChecksumRequired,
|
2322 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpChecksumRequired, S>
|
2373 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpChecksumRequired, S>
|
2323 2374 | >,
|
2324 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2375 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2325 2376 | RestJson<L>,
|
2326 2377 | crate::operation_shape::HttpChecksumRequired,
|
2327 2378 | ModelPl::Output
|
2328 2379 | >,
|
2329 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2380 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2330 2381 | RestJson<L>,
|
2331 2382 | crate::operation_shape::HttpChecksumRequired,
|
2332 2383 | <
|
2333 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2334 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2384 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2385 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2335 2386 | RestJson<L>,
|
2336 2387 | crate::operation_shape::HttpChecksumRequired,
|
2337 2388 | ModelPl::Output
|
2338 2389 | >
|
2339 2390 | >::Output
|
2340 2391 | >,
|
2341 2392 |
|
2342 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2393 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2343 2394 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2344 2395 |
|
2345 2396 | {
|
2346 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2347 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2397 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2398 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2348 2399 | let svc = crate::operation_shape::HttpChecksumRequired::from_service(service);
|
2349 2400 | let svc = self.model_plugin.apply(svc);
|
2350 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2401 + | let svc =
|
2402 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2351 2403 | .apply(svc);
|
2352 2404 | let svc = self.http_plugin.apply(svc);
|
2353 2405 | self.http_checksum_required_custom(svc)
|
2354 2406 | }
|
2355 2407 |
|
2356 2408 | /// Sets the [`HttpChecksumRequired`](crate::operation_shape::HttpChecksumRequired) to a custom [`Service`](tower::Service).
|
2357 2409 | /// not constrained by the Smithy contract.
|
2358 2410 | fn http_checksum_required_custom<S>(mut self, svc: S) -> Self
|
2359 2411 | where
|
2360 2412 | S: ::tower::Service<
|
2361 2413 | ::http::Request<Body>,
|
2362 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2414 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2363 2415 | Error = ::std::convert::Infallible,
|
2364 2416 | > + Clone
|
2365 2417 | + Send
|
2366 2418 | + 'static,
|
2367 2419 | S::Future: Send + 'static,
|
2368 2420 | {
|
2369 - | self.http_checksum_required = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2421 + | self.http_checksum_required =
|
2422 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2370 2423 | self
|
2371 2424 | }
|
2372 2425 |
|
2373 2426 | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
2374 2427 | ///
|
2375 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2376 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2428 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2429 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2377 2430 | ///
|
2378 2431 | /// # Example
|
2379 2432 | ///
|
2380 2433 | /// ```no_run
|
2381 2434 | /// use rest_json::{RestJson, RestJsonConfig};
|
2382 2435 | ///
|
2383 2436 | /// use rest_json::{input, output, error};
|
2384 2437 | ///
|
2385 2438 | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> Result<output::HttpEmptyPrefixHeadersOutput, error::HttpEmptyPrefixHeadersError> {
|
2386 2439 | /// todo!()
|
2387 2440 | /// }
|
2388 2441 | ///
|
2389 2442 | /// let config = RestJsonConfig::builder().build();
|
2390 2443 | /// let app = RestJson::builder(config)
|
2391 2444 | /// .http_empty_prefix_headers(handler)
|
2392 2445 | /// /* Set other handlers */
|
2393 2446 | /// .build()
|
2394 2447 | /// .unwrap();
|
2395 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2448 + | /// # 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;
|
2396 2449 | /// ```
|
2397 2450 | ///
|
2398 2451 | pub fn http_empty_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2399 2452 | where
|
2400 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerExtractors>,
|
2453 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerExtractors>,
|
2401 2454 |
|
2402 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2455 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2403 2456 | RestJson<L>,
|
2404 2457 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2405 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerType>
|
2458 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEmptyPrefixHeaders, HandlerType>
|
2406 2459 | >,
|
2407 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2460 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2408 2461 | RestJson<L>,
|
2409 2462 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2410 2463 | ModelPl::Output
|
2411 2464 | >,
|
2412 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2465 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2413 2466 | RestJson<L>,
|
2414 2467 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2415 2468 | <
|
2416 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2417 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2469 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2470 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2418 2471 | RestJson<L>,
|
2419 2472 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2420 2473 | ModelPl::Output
|
2421 2474 | >
|
2422 2475 | >::Output
|
2423 2476 | >,
|
2424 2477 |
|
2425 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2478 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2426 2479 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2427 2480 |
|
2428 2481 | {
|
2429 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2430 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2482 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2483 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2431 2484 | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_handler(handler);
|
2432 2485 | let svc = self.model_plugin.apply(svc);
|
2433 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2486 + | let svc =
|
2487 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2434 2488 | .apply(svc);
|
2435 2489 | let svc = self.http_plugin.apply(svc);
|
2436 2490 | self.http_empty_prefix_headers_custom(svc)
|
2437 2491 | }
|
2438 2492 |
|
2439 2493 | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) operation.
|
2440 2494 | ///
|
2441 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2442 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2495 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2496 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2443 2497 | ///
|
2444 2498 | /// # Example
|
2445 2499 | ///
|
2446 2500 | /// ```no_run
|
2447 2501 | /// use rest_json::{RestJson, RestJsonConfig};
|
2448 2502 | ///
|
2449 2503 | /// use rest_json::{input, output, error};
|
2450 2504 | ///
|
2451 2505 | /// async fn handler(input: input::HttpEmptyPrefixHeadersInput) -> Result<output::HttpEmptyPrefixHeadersOutput, error::HttpEmptyPrefixHeadersError> {
|
2452 2506 | /// todo!()
|
2453 2507 | /// }
|
2454 2508 | ///
|
2455 2509 | /// let config = RestJsonConfig::builder().build();
|
2456 2510 | /// let svc = ::tower::util::service_fn(handler);
|
2457 2511 | /// let app = RestJson::builder(config)
|
2458 2512 | /// .http_empty_prefix_headers_service(svc)
|
2459 2513 | /// /* Set other handlers */
|
2460 2514 | /// .build()
|
2461 2515 | /// .unwrap();
|
2462 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2516 + | /// # 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;
|
2463 2517 | /// ```
|
2464 2518 | ///
|
2465 2519 | pub fn http_empty_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2466 2520 | where
|
2467 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpEmptyPrefixHeaders, ServiceExtractors>,
|
2521 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEmptyPrefixHeaders, ServiceExtractors>,
|
2468 2522 |
|
2469 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2523 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2470 2524 | RestJson<L>,
|
2471 2525 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2472 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpEmptyPrefixHeaders, S>
|
2526 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEmptyPrefixHeaders, S>
|
2473 2527 | >,
|
2474 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2528 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2475 2529 | RestJson<L>,
|
2476 2530 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2477 2531 | ModelPl::Output
|
2478 2532 | >,
|
2479 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2533 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2480 2534 | RestJson<L>,
|
2481 2535 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2482 2536 | <
|
2483 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2484 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2537 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2538 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2485 2539 | RestJson<L>,
|
2486 2540 | crate::operation_shape::HttpEmptyPrefixHeaders,
|
2487 2541 | ModelPl::Output
|
2488 2542 | >
|
2489 2543 | >::Output
|
2490 2544 | >,
|
2491 2545 |
|
2492 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2546 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2493 2547 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2494 2548 |
|
2495 2549 | {
|
2496 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2497 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2550 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2551 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2498 2552 | let svc = crate::operation_shape::HttpEmptyPrefixHeaders::from_service(service);
|
2499 2553 | let svc = self.model_plugin.apply(svc);
|
2500 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2554 + | let svc =
|
2555 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2501 2556 | .apply(svc);
|
2502 2557 | let svc = self.http_plugin.apply(svc);
|
2503 2558 | self.http_empty_prefix_headers_custom(svc)
|
2504 2559 | }
|
2505 2560 |
|
2506 2561 | /// Sets the [`HttpEmptyPrefixHeaders`](crate::operation_shape::HttpEmptyPrefixHeaders) to a custom [`Service`](tower::Service).
|
2507 2562 | /// not constrained by the Smithy contract.
|
2508 2563 | fn http_empty_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
2509 2564 | where
|
2510 2565 | S: ::tower::Service<
|
2511 2566 | ::http::Request<Body>,
|
2512 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2567 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2513 2568 | Error = ::std::convert::Infallible,
|
2514 2569 | > + Clone
|
2515 2570 | + Send
|
2516 2571 | + 'static,
|
2517 2572 | S::Future: Send + 'static,
|
2518 2573 | {
|
2519 - | self.http_empty_prefix_headers = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2574 + | self.http_empty_prefix_headers =
|
2575 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2520 2576 | self
|
2521 2577 | }
|
2522 2578 |
|
2523 2579 | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
2524 2580 | ///
|
2525 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2526 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2581 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2582 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2527 2583 | ///
|
2528 2584 | /// # Example
|
2529 2585 | ///
|
2530 2586 | /// ```no_run
|
2531 2587 | /// use rest_json::{RestJson, RestJsonConfig};
|
2532 2588 | ///
|
2533 2589 | /// use rest_json::{input, output, error};
|
2534 2590 | ///
|
2535 2591 | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
2536 2592 | /// todo!()
|
2537 2593 | /// }
|
2538 2594 | ///
|
2539 2595 | /// let config = RestJsonConfig::builder().build();
|
2540 2596 | /// let app = RestJson::builder(config)
|
2541 2597 | /// .http_enum_payload(handler)
|
2542 2598 | /// /* Set other handlers */
|
2543 2599 | /// .build()
|
2544 2600 | /// .unwrap();
|
2545 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2601 + | /// # 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;
|
2546 2602 | /// ```
|
2547 2603 | ///
|
2548 2604 | pub fn http_enum_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2549 2605 | where
|
2550 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpEnumPayload, HandlerExtractors>,
|
2606 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpEnumPayload, HandlerExtractors>,
|
2551 2607 |
|
2552 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2608 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2553 2609 | RestJson<L>,
|
2554 2610 | crate::operation_shape::HttpEnumPayload,
|
2555 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpEnumPayload, HandlerType>
|
2611 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpEnumPayload, HandlerType>
|
2556 2612 | >,
|
2557 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2613 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2558 2614 | RestJson<L>,
|
2559 2615 | crate::operation_shape::HttpEnumPayload,
|
2560 2616 | ModelPl::Output
|
2561 2617 | >,
|
2562 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2618 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2563 2619 | RestJson<L>,
|
2564 2620 | crate::operation_shape::HttpEnumPayload,
|
2565 2621 | <
|
2566 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2567 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2622 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2623 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2568 2624 | RestJson<L>,
|
2569 2625 | crate::operation_shape::HttpEnumPayload,
|
2570 2626 | ModelPl::Output
|
2571 2627 | >
|
2572 2628 | >::Output
|
2573 2629 | >,
|
2574 2630 |
|
2575 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2631 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2576 2632 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2577 2633 |
|
2578 2634 | {
|
2579 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2580 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2635 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2636 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2581 2637 | let svc = crate::operation_shape::HttpEnumPayload::from_handler(handler);
|
2582 2638 | let svc = self.model_plugin.apply(svc);
|
2583 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2639 + | let svc =
|
2640 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2584 2641 | .apply(svc);
|
2585 2642 | let svc = self.http_plugin.apply(svc);
|
2586 2643 | self.http_enum_payload_custom(svc)
|
2587 2644 | }
|
2588 2645 |
|
2589 2646 | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) operation.
|
2590 2647 | ///
|
2591 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2592 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2648 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2649 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2593 2650 | ///
|
2594 2651 | /// # Example
|
2595 2652 | ///
|
2596 2653 | /// ```no_run
|
2597 2654 | /// use rest_json::{RestJson, RestJsonConfig};
|
2598 2655 | ///
|
2599 2656 | /// use rest_json::{input, output, error};
|
2600 2657 | ///
|
2601 2658 | /// async fn handler(input: input::HttpEnumPayloadInput) -> Result<output::HttpEnumPayloadOutput, error::HttpEnumPayloadError> {
|
2602 2659 | /// todo!()
|
2603 2660 | /// }
|
2604 2661 | ///
|
2605 2662 | /// let config = RestJsonConfig::builder().build();
|
2606 2663 | /// let svc = ::tower::util::service_fn(handler);
|
2607 2664 | /// let app = RestJson::builder(config)
|
2608 2665 | /// .http_enum_payload_service(svc)
|
2609 2666 | /// /* Set other handlers */
|
2610 2667 | /// .build()
|
2611 2668 | /// .unwrap();
|
2612 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2669 + | /// # 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;
|
2613 2670 | /// ```
|
2614 2671 | ///
|
2615 2672 | pub fn http_enum_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2616 2673 | where
|
2617 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpEnumPayload, ServiceExtractors>,
|
2674 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpEnumPayload, ServiceExtractors>,
|
2618 2675 |
|
2619 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2676 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2620 2677 | RestJson<L>,
|
2621 2678 | crate::operation_shape::HttpEnumPayload,
|
2622 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpEnumPayload, S>
|
2679 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpEnumPayload, S>
|
2623 2680 | >,
|
2624 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2681 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2625 2682 | RestJson<L>,
|
2626 2683 | crate::operation_shape::HttpEnumPayload,
|
2627 2684 | ModelPl::Output
|
2628 2685 | >,
|
2629 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2686 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2630 2687 | RestJson<L>,
|
2631 2688 | crate::operation_shape::HttpEnumPayload,
|
2632 2689 | <
|
2633 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2634 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2690 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2691 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2635 2692 | RestJson<L>,
|
2636 2693 | crate::operation_shape::HttpEnumPayload,
|
2637 2694 | ModelPl::Output
|
2638 2695 | >
|
2639 2696 | >::Output
|
2640 2697 | >,
|
2641 2698 |
|
2642 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2699 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2643 2700 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2644 2701 |
|
2645 2702 | {
|
2646 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2647 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2703 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2704 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2648 2705 | let svc = crate::operation_shape::HttpEnumPayload::from_service(service);
|
2649 2706 | let svc = self.model_plugin.apply(svc);
|
2650 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2707 + | let svc =
|
2708 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2651 2709 | .apply(svc);
|
2652 2710 | let svc = self.http_plugin.apply(svc);
|
2653 2711 | self.http_enum_payload_custom(svc)
|
2654 2712 | }
|
2655 2713 |
|
2656 2714 | /// Sets the [`HttpEnumPayload`](crate::operation_shape::HttpEnumPayload) to a custom [`Service`](tower::Service).
|
2657 2715 | /// not constrained by the Smithy contract.
|
2658 2716 | fn http_enum_payload_custom<S>(mut self, svc: S) -> Self
|
2659 2717 | where
|
2660 2718 | S: ::tower::Service<
|
2661 2719 | ::http::Request<Body>,
|
2662 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2720 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2663 2721 | Error = ::std::convert::Infallible,
|
2664 2722 | > + Clone
|
2665 2723 | + Send
|
2666 2724 | + 'static,
|
2667 2725 | S::Future: Send + 'static,
|
2668 2726 | {
|
2669 - | self.http_enum_payload = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2727 + | self.http_enum_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2670 2728 | self
|
2671 2729 | }
|
2672 2730 |
|
2673 2731 | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
2674 2732 | ///
|
2675 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2676 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2733 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2734 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2677 2735 | ///
|
2678 2736 | /// # Example
|
2679 2737 | ///
|
2680 2738 | /// ```no_run
|
2681 2739 | /// use rest_json::{RestJson, RestJsonConfig};
|
2682 2740 | ///
|
2683 2741 | /// use rest_json::{input, output, error};
|
2684 2742 | ///
|
2685 2743 | /// async fn handler(input: input::HttpPayloadTraitsInput) -> Result<output::HttpPayloadTraitsOutput, error::HttpPayloadTraitsError> {
|
2686 2744 | /// todo!()
|
2687 2745 | /// }
|
2688 2746 | ///
|
2689 2747 | /// let config = RestJsonConfig::builder().build();
|
2690 2748 | /// let app = RestJson::builder(config)
|
2691 2749 | /// .http_payload_traits(handler)
|
2692 2750 | /// /* Set other handlers */
|
2693 2751 | /// .build()
|
2694 2752 | /// .unwrap();
|
2695 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2753 + | /// # 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;
|
2696 2754 | /// ```
|
2697 2755 | ///
|
2698 2756 | pub fn http_payload_traits<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2699 2757 | where
|
2700 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraits, HandlerExtractors>,
|
2758 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraits, HandlerExtractors>,
|
2701 2759 |
|
2702 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2760 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2703 2761 | RestJson<L>,
|
2704 2762 | crate::operation_shape::HttpPayloadTraits,
|
2705 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraits, HandlerType>
|
2763 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraits, HandlerType>
|
2706 2764 | >,
|
2707 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2765 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2708 2766 | RestJson<L>,
|
2709 2767 | crate::operation_shape::HttpPayloadTraits,
|
2710 2768 | ModelPl::Output
|
2711 2769 | >,
|
2712 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2770 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2713 2771 | RestJson<L>,
|
2714 2772 | crate::operation_shape::HttpPayloadTraits,
|
2715 2773 | <
|
2716 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2717 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2774 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2775 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2718 2776 | RestJson<L>,
|
2719 2777 | crate::operation_shape::HttpPayloadTraits,
|
2720 2778 | ModelPl::Output
|
2721 2779 | >
|
2722 2780 | >::Output
|
2723 2781 | >,
|
2724 2782 |
|
2725 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2783 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2726 2784 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2727 2785 |
|
2728 2786 | {
|
2729 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2730 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2787 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2788 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2731 2789 | let svc = crate::operation_shape::HttpPayloadTraits::from_handler(handler);
|
2732 2790 | let svc = self.model_plugin.apply(svc);
|
2733 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2791 + | let svc =
|
2792 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2734 2793 | .apply(svc);
|
2735 2794 | let svc = self.http_plugin.apply(svc);
|
2736 2795 | self.http_payload_traits_custom(svc)
|
2737 2796 | }
|
2738 2797 |
|
2739 2798 | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) operation.
|
2740 2799 | ///
|
2741 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2742 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2800 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2801 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2743 2802 | ///
|
2744 2803 | /// # Example
|
2745 2804 | ///
|
2746 2805 | /// ```no_run
|
2747 2806 | /// use rest_json::{RestJson, RestJsonConfig};
|
2748 2807 | ///
|
2749 2808 | /// use rest_json::{input, output, error};
|
2750 2809 | ///
|
2751 2810 | /// async fn handler(input: input::HttpPayloadTraitsInput) -> Result<output::HttpPayloadTraitsOutput, error::HttpPayloadTraitsError> {
|
2752 2811 | /// todo!()
|
2753 2812 | /// }
|
2754 2813 | ///
|
2755 2814 | /// let config = RestJsonConfig::builder().build();
|
2756 2815 | /// let svc = ::tower::util::service_fn(handler);
|
2757 2816 | /// let app = RestJson::builder(config)
|
2758 2817 | /// .http_payload_traits_service(svc)
|
2759 2818 | /// /* Set other handlers */
|
2760 2819 | /// .build()
|
2761 2820 | /// .unwrap();
|
2762 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2821 + | /// # 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;
|
2763 2822 | /// ```
|
2764 2823 | ///
|
2765 2824 | pub fn http_payload_traits_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2766 2825 | where
|
2767 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraits, ServiceExtractors>,
|
2826 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraits, ServiceExtractors>,
|
2768 2827 |
|
2769 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2828 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2770 2829 | RestJson<L>,
|
2771 2830 | crate::operation_shape::HttpPayloadTraits,
|
2772 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraits, S>
|
2831 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraits, S>
|
2773 2832 | >,
|
2774 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2833 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2775 2834 | RestJson<L>,
|
2776 2835 | crate::operation_shape::HttpPayloadTraits,
|
2777 2836 | ModelPl::Output
|
2778 2837 | >,
|
2779 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2838 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2780 2839 | RestJson<L>,
|
2781 2840 | crate::operation_shape::HttpPayloadTraits,
|
2782 2841 | <
|
2783 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2784 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2842 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2843 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2785 2844 | RestJson<L>,
|
2786 2845 | crate::operation_shape::HttpPayloadTraits,
|
2787 2846 | ModelPl::Output
|
2788 2847 | >
|
2789 2848 | >::Output
|
2790 2849 | >,
|
2791 2850 |
|
2792 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2851 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2793 2852 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2794 2853 |
|
2795 2854 | {
|
2796 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2797 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2855 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2856 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2798 2857 | let svc = crate::operation_shape::HttpPayloadTraits::from_service(service);
|
2799 2858 | let svc = self.model_plugin.apply(svc);
|
2800 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2859 + | let svc =
|
2860 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2801 2861 | .apply(svc);
|
2802 2862 | let svc = self.http_plugin.apply(svc);
|
2803 2863 | self.http_payload_traits_custom(svc)
|
2804 2864 | }
|
2805 2865 |
|
2806 2866 | /// Sets the [`HttpPayloadTraits`](crate::operation_shape::HttpPayloadTraits) to a custom [`Service`](tower::Service).
|
2807 2867 | /// not constrained by the Smithy contract.
|
2808 2868 | fn http_payload_traits_custom<S>(mut self, svc: S) -> Self
|
2809 2869 | where
|
2810 2870 | S: ::tower::Service<
|
2811 2871 | ::http::Request<Body>,
|
2812 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
2872 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2813 2873 | Error = ::std::convert::Infallible,
|
2814 2874 | > + Clone
|
2815 2875 | + Send
|
2816 2876 | + 'static,
|
2817 2877 | S::Future: Send + 'static,
|
2818 2878 | {
|
2819 - | self.http_payload_traits = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
2879 + | self.http_payload_traits = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2820 2880 | self
|
2821 2881 | }
|
2822 2882 |
|
2823 2883 | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
2824 2884 | ///
|
2825 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2826 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2885 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2886 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2827 2887 | ///
|
2828 2888 | /// # Example
|
2829 2889 | ///
|
2830 2890 | /// ```no_run
|
2831 2891 | /// use rest_json::{RestJson, RestJsonConfig};
|
2832 2892 | ///
|
2833 2893 | /// use rest_json::{input, output, error};
|
2834 2894 | ///
|
2835 2895 | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> Result<output::HttpPayloadTraitsWithMediaTypeOutput, error::HttpPayloadTraitsWithMediaTypeError> {
|
2836 2896 | /// todo!()
|
2837 2897 | /// }
|
2838 2898 | ///
|
2839 2899 | /// let config = RestJsonConfig::builder().build();
|
2840 2900 | /// let app = RestJson::builder(config)
|
2841 2901 | /// .http_payload_traits_with_media_type(handler)
|
2842 2902 | /// /* Set other handlers */
|
2843 2903 | /// .build()
|
2844 2904 | /// .unwrap();
|
2845 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2905 + | /// # 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;
|
2846 2906 | /// ```
|
2847 2907 | ///
|
2848 2908 | pub fn http_payload_traits_with_media_type<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
2849 2909 | where
|
2850 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerExtractors>,
|
2910 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerExtractors>,
|
2851 2911 |
|
2852 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2912 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2853 2913 | RestJson<L>,
|
2854 2914 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2855 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerType>
|
2915 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadTraitsWithMediaType, HandlerType>
|
2856 2916 | >,
|
2857 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2917 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2858 2918 | RestJson<L>,
|
2859 2919 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2860 2920 | ModelPl::Output
|
2861 2921 | >,
|
2862 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2922 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2863 2923 | RestJson<L>,
|
2864 2924 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2865 2925 | <
|
2866 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2867 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2926 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2927 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2868 2928 | RestJson<L>,
|
2869 2929 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2870 2930 | ModelPl::Output
|
2871 2931 | >
|
2872 2932 | >::Output
|
2873 2933 | >,
|
2874 2934 |
|
2875 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2935 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2876 2936 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2877 2937 |
|
2878 2938 | {
|
2879 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2880 - | use ::aws_smithy_http_server::plugin::Plugin;
|
2939 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
2940 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2881 2941 | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_handler(handler);
|
2882 2942 | let svc = self.model_plugin.apply(svc);
|
2883 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2943 + | let svc =
|
2944 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2884 2945 | .apply(svc);
|
2885 2946 | let svc = self.http_plugin.apply(svc);
|
2886 2947 | self.http_payload_traits_with_media_type_custom(svc)
|
2887 2948 | }
|
2888 2949 |
|
2889 2950 | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) operation.
|
2890 2951 | ///
|
2891 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2892 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
2952 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
2953 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2893 2954 | ///
|
2894 2955 | /// # Example
|
2895 2956 | ///
|
2896 2957 | /// ```no_run
|
2897 2958 | /// use rest_json::{RestJson, RestJsonConfig};
|
2898 2959 | ///
|
2899 2960 | /// use rest_json::{input, output, error};
|
2900 2961 | ///
|
2901 2962 | /// async fn handler(input: input::HttpPayloadTraitsWithMediaTypeInput) -> Result<output::HttpPayloadTraitsWithMediaTypeOutput, error::HttpPayloadTraitsWithMediaTypeError> {
|
2902 2963 | /// todo!()
|
2903 2964 | /// }
|
2904 2965 | ///
|
2905 2966 | /// let config = RestJsonConfig::builder().build();
|
2906 2967 | /// let svc = ::tower::util::service_fn(handler);
|
2907 2968 | /// let app = RestJson::builder(config)
|
2908 2969 | /// .http_payload_traits_with_media_type_service(svc)
|
2909 2970 | /// /* Set other handlers */
|
2910 2971 | /// .build()
|
2911 2972 | /// .unwrap();
|
2912 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
2973 + | /// # 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;
|
2913 2974 | /// ```
|
2914 2975 | ///
|
2915 2976 | pub fn http_payload_traits_with_media_type_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
2916 2977 | where
|
2917 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraitsWithMediaType, ServiceExtractors>,
|
2978 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadTraitsWithMediaType, ServiceExtractors>,
|
2918 2979 |
|
2919 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
2980 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2920 2981 | RestJson<L>,
|
2921 2982 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2922 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraitsWithMediaType, S>
|
2983 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadTraitsWithMediaType, S>
|
2923 2984 | >,
|
2924 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
2985 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2925 2986 | RestJson<L>,
|
2926 2987 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2927 2988 | ModelPl::Output
|
2928 2989 | >,
|
2929 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
2990 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2930 2991 | RestJson<L>,
|
2931 2992 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2932 2993 | <
|
2933 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2934 - | as ::aws_smithy_http_server::plugin::Plugin<
|
2994 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
2995 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
2935 2996 | RestJson<L>,
|
2936 2997 | crate::operation_shape::HttpPayloadTraitsWithMediaType,
|
2937 2998 | ModelPl::Output
|
2938 2999 | >
|
2939 3000 | >::Output
|
2940 3001 | >,
|
2941 3002 |
|
2942 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3003 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
2943 3004 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
2944 3005 |
|
2945 3006 | {
|
2946 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
2947 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3007 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3008 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
2948 3009 | let svc = crate::operation_shape::HttpPayloadTraitsWithMediaType::from_service(service);
|
2949 3010 | let svc = self.model_plugin.apply(svc);
|
2950 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3011 + | let svc =
|
3012 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
2951 3013 | .apply(svc);
|
2952 3014 | let svc = self.http_plugin.apply(svc);
|
2953 3015 | self.http_payload_traits_with_media_type_custom(svc)
|
2954 3016 | }
|
2955 3017 |
|
2956 3018 | /// Sets the [`HttpPayloadTraitsWithMediaType`](crate::operation_shape::HttpPayloadTraitsWithMediaType) to a custom [`Service`](tower::Service).
|
2957 3019 | /// not constrained by the Smithy contract.
|
2958 3020 | fn http_payload_traits_with_media_type_custom<S>(mut self, svc: S) -> Self
|
2959 3021 | where
|
2960 3022 | S: ::tower::Service<
|
2961 3023 | ::http::Request<Body>,
|
2962 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3024 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
2963 3025 | Error = ::std::convert::Infallible,
|
2964 3026 | > + Clone
|
2965 3027 | + Send
|
2966 3028 | + 'static,
|
2967 3029 | S::Future: Send + 'static,
|
2968 3030 | {
|
2969 3031 | self.http_payload_traits_with_media_type =
|
2970 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3032 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
2971 3033 | self
|
2972 3034 | }
|
2973 3035 |
|
2974 3036 | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
2975 3037 | ///
|
2976 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
2977 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3038 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3039 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
2978 3040 | ///
|
2979 3041 | /// # Example
|
2980 3042 | ///
|
2981 3043 | /// ```no_run
|
2982 3044 | /// use rest_json::{RestJson, RestJsonConfig};
|
2983 3045 | ///
|
2984 3046 | /// use rest_json::{input, output, error};
|
2985 3047 | ///
|
2986 3048 | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> Result<output::HttpPayloadWithStructureOutput, error::HttpPayloadWithStructureError> {
|
2987 3049 | /// todo!()
|
2988 3050 | /// }
|
2989 3051 | ///
|
2990 3052 | /// let config = RestJsonConfig::builder().build();
|
2991 3053 | /// let app = RestJson::builder(config)
|
2992 3054 | /// .http_payload_with_structure(handler)
|
2993 3055 | /// /* Set other handlers */
|
2994 3056 | /// .build()
|
2995 3057 | /// .unwrap();
|
2996 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3058 + | /// # 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;
|
2997 3059 | /// ```
|
2998 3060 | ///
|
2999 3061 | pub fn http_payload_with_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3000 3062 | where
|
3001 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithStructure, HandlerExtractors>,
|
3063 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithStructure, HandlerExtractors>,
|
3002 3064 |
|
3003 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3065 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3004 3066 | RestJson<L>,
|
3005 3067 | crate::operation_shape::HttpPayloadWithStructure,
|
3006 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithStructure, HandlerType>
|
3068 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithStructure, HandlerType>
|
3007 3069 | >,
|
3008 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3070 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3009 3071 | RestJson<L>,
|
3010 3072 | crate::operation_shape::HttpPayloadWithStructure,
|
3011 3073 | ModelPl::Output
|
3012 3074 | >,
|
3013 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3075 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3014 3076 | RestJson<L>,
|
3015 3077 | crate::operation_shape::HttpPayloadWithStructure,
|
3016 3078 | <
|
3017 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3018 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3079 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3080 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3019 3081 | RestJson<L>,
|
3020 3082 | crate::operation_shape::HttpPayloadWithStructure,
|
3021 3083 | ModelPl::Output
|
3022 3084 | >
|
3023 3085 | >::Output
|
3024 3086 | >,
|
3025 3087 |
|
3026 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3088 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3027 3089 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3028 3090 |
|
3029 3091 | {
|
3030 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3031 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3092 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3093 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3032 3094 | let svc = crate::operation_shape::HttpPayloadWithStructure::from_handler(handler);
|
3033 3095 | let svc = self.model_plugin.apply(svc);
|
3034 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3096 + | let svc =
|
3097 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3035 3098 | .apply(svc);
|
3036 3099 | let svc = self.http_plugin.apply(svc);
|
3037 3100 | self.http_payload_with_structure_custom(svc)
|
3038 3101 | }
|
3039 3102 |
|
3040 3103 | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) operation.
|
3041 3104 | ///
|
3042 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3043 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3105 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3106 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3044 3107 | ///
|
3045 3108 | /// # Example
|
3046 3109 | ///
|
3047 3110 | /// ```no_run
|
3048 3111 | /// use rest_json::{RestJson, RestJsonConfig};
|
3049 3112 | ///
|
3050 3113 | /// use rest_json::{input, output, error};
|
3051 3114 | ///
|
3052 3115 | /// async fn handler(input: input::HttpPayloadWithStructureInput) -> Result<output::HttpPayloadWithStructureOutput, error::HttpPayloadWithStructureError> {
|
3053 3116 | /// todo!()
|
3054 3117 | /// }
|
3055 3118 | ///
|
3056 3119 | /// let config = RestJsonConfig::builder().build();
|
3057 3120 | /// let svc = ::tower::util::service_fn(handler);
|
3058 3121 | /// let app = RestJson::builder(config)
|
3059 3122 | /// .http_payload_with_structure_service(svc)
|
3060 3123 | /// /* Set other handlers */
|
3061 3124 | /// .build()
|
3062 3125 | /// .unwrap();
|
3063 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3126 + | /// # 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;
|
3064 3127 | /// ```
|
3065 3128 | ///
|
3066 3129 | pub fn http_payload_with_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3067 3130 | where
|
3068 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithStructure, ServiceExtractors>,
|
3131 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithStructure, ServiceExtractors>,
|
3069 3132 |
|
3070 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3133 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3071 3134 | RestJson<L>,
|
3072 3135 | crate::operation_shape::HttpPayloadWithStructure,
|
3073 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithStructure, S>
|
3136 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithStructure, S>
|
3074 3137 | >,
|
3075 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3138 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3076 3139 | RestJson<L>,
|
3077 3140 | crate::operation_shape::HttpPayloadWithStructure,
|
3078 3141 | ModelPl::Output
|
3079 3142 | >,
|
3080 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3143 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3081 3144 | RestJson<L>,
|
3082 3145 | crate::operation_shape::HttpPayloadWithStructure,
|
3083 3146 | <
|
3084 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3085 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3147 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3148 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3086 3149 | RestJson<L>,
|
3087 3150 | crate::operation_shape::HttpPayloadWithStructure,
|
3088 3151 | ModelPl::Output
|
3089 3152 | >
|
3090 3153 | >::Output
|
3091 3154 | >,
|
3092 3155 |
|
3093 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3156 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3094 3157 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3095 3158 |
|
3096 3159 | {
|
3097 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3098 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3160 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3161 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3099 3162 | let svc = crate::operation_shape::HttpPayloadWithStructure::from_service(service);
|
3100 3163 | let svc = self.model_plugin.apply(svc);
|
3101 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3164 + | let svc =
|
3165 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3102 3166 | .apply(svc);
|
3103 3167 | let svc = self.http_plugin.apply(svc);
|
3104 3168 | self.http_payload_with_structure_custom(svc)
|
3105 3169 | }
|
3106 3170 |
|
3107 3171 | /// Sets the [`HttpPayloadWithStructure`](crate::operation_shape::HttpPayloadWithStructure) to a custom [`Service`](tower::Service).
|
3108 3172 | /// not constrained by the Smithy contract.
|
3109 3173 | fn http_payload_with_structure_custom<S>(mut self, svc: S) -> Self
|
3110 3174 | where
|
3111 3175 | S: ::tower::Service<
|
3112 3176 | ::http::Request<Body>,
|
3113 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3177 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3114 3178 | Error = ::std::convert::Infallible,
|
3115 3179 | > + Clone
|
3116 3180 | + Send
|
3117 3181 | + 'static,
|
3118 3182 | S::Future: Send + 'static,
|
3119 3183 | {
|
3120 - | self.http_payload_with_structure = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3184 + | self.http_payload_with_structure =
|
3185 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3121 3186 | self
|
3122 3187 | }
|
3123 3188 |
|
3124 3189 | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
3125 3190 | ///
|
3126 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3127 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3191 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3192 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3128 3193 | ///
|
3129 3194 | /// # Example
|
3130 3195 | ///
|
3131 3196 | /// ```no_run
|
3132 3197 | /// use rest_json::{RestJson, RestJsonConfig};
|
3133 3198 | ///
|
3134 3199 | /// use rest_json::{input, output, error};
|
3135 3200 | ///
|
3136 3201 | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> Result<output::HttpPayloadWithUnionOutput, error::HttpPayloadWithUnionError> {
|
3137 3202 | /// todo!()
|
3138 3203 | /// }
|
3139 3204 | ///
|
3140 3205 | /// let config = RestJsonConfig::builder().build();
|
3141 3206 | /// let app = RestJson::builder(config)
|
3142 3207 | /// .http_payload_with_union(handler)
|
3143 3208 | /// /* Set other handlers */
|
3144 3209 | /// .build()
|
3145 3210 | /// .unwrap();
|
3146 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3211 + | /// # 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;
|
3147 3212 | /// ```
|
3148 3213 | ///
|
3149 3214 | pub fn http_payload_with_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3150 3215 | where
|
3151 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithUnion, HandlerExtractors>,
|
3216 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPayloadWithUnion, HandlerExtractors>,
|
3152 3217 |
|
3153 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3218 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3154 3219 | RestJson<L>,
|
3155 3220 | crate::operation_shape::HttpPayloadWithUnion,
|
3156 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithUnion, HandlerType>
|
3221 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPayloadWithUnion, HandlerType>
|
3157 3222 | >,
|
3158 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3223 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3159 3224 | RestJson<L>,
|
3160 3225 | crate::operation_shape::HttpPayloadWithUnion,
|
3161 3226 | ModelPl::Output
|
3162 3227 | >,
|
3163 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3228 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3164 3229 | RestJson<L>,
|
3165 3230 | crate::operation_shape::HttpPayloadWithUnion,
|
3166 3231 | <
|
3167 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3168 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3232 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3233 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3169 3234 | RestJson<L>,
|
3170 3235 | crate::operation_shape::HttpPayloadWithUnion,
|
3171 3236 | ModelPl::Output
|
3172 3237 | >
|
3173 3238 | >::Output
|
3174 3239 | >,
|
3175 3240 |
|
3176 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3241 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3177 3242 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3178 3243 |
|
3179 3244 | {
|
3180 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3181 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3245 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3246 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3182 3247 | let svc = crate::operation_shape::HttpPayloadWithUnion::from_handler(handler);
|
3183 3248 | let svc = self.model_plugin.apply(svc);
|
3184 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3249 + | let svc =
|
3250 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3185 3251 | .apply(svc);
|
3186 3252 | let svc = self.http_plugin.apply(svc);
|
3187 3253 | self.http_payload_with_union_custom(svc)
|
3188 3254 | }
|
3189 3255 |
|
3190 3256 | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) operation.
|
3191 3257 | ///
|
3192 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3193 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3258 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3259 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3194 3260 | ///
|
3195 3261 | /// # Example
|
3196 3262 | ///
|
3197 3263 | /// ```no_run
|
3198 3264 | /// use rest_json::{RestJson, RestJsonConfig};
|
3199 3265 | ///
|
3200 3266 | /// use rest_json::{input, output, error};
|
3201 3267 | ///
|
3202 3268 | /// async fn handler(input: input::HttpPayloadWithUnionInput) -> Result<output::HttpPayloadWithUnionOutput, error::HttpPayloadWithUnionError> {
|
3203 3269 | /// todo!()
|
3204 3270 | /// }
|
3205 3271 | ///
|
3206 3272 | /// let config = RestJsonConfig::builder().build();
|
3207 3273 | /// let svc = ::tower::util::service_fn(handler);
|
3208 3274 | /// let app = RestJson::builder(config)
|
3209 3275 | /// .http_payload_with_union_service(svc)
|
3210 3276 | /// /* Set other handlers */
|
3211 3277 | /// .build()
|
3212 3278 | /// .unwrap();
|
3213 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3279 + | /// # 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;
|
3214 3280 | /// ```
|
3215 3281 | ///
|
3216 3282 | pub fn http_payload_with_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3217 3283 | where
|
3218 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithUnion, ServiceExtractors>,
|
3284 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPayloadWithUnion, ServiceExtractors>,
|
3219 3285 |
|
3220 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3286 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3221 3287 | RestJson<L>,
|
3222 3288 | crate::operation_shape::HttpPayloadWithUnion,
|
3223 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithUnion, S>
|
3289 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPayloadWithUnion, S>
|
3224 3290 | >,
|
3225 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3291 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3226 3292 | RestJson<L>,
|
3227 3293 | crate::operation_shape::HttpPayloadWithUnion,
|
3228 3294 | ModelPl::Output
|
3229 3295 | >,
|
3230 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3296 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3231 3297 | RestJson<L>,
|
3232 3298 | crate::operation_shape::HttpPayloadWithUnion,
|
3233 3299 | <
|
3234 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3235 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3300 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3301 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3236 3302 | RestJson<L>,
|
3237 3303 | crate::operation_shape::HttpPayloadWithUnion,
|
3238 3304 | ModelPl::Output
|
3239 3305 | >
|
3240 3306 | >::Output
|
3241 3307 | >,
|
3242 3308 |
|
3243 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3309 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3244 3310 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3245 3311 |
|
3246 3312 | {
|
3247 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3248 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3313 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3314 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3249 3315 | let svc = crate::operation_shape::HttpPayloadWithUnion::from_service(service);
|
3250 3316 | let svc = self.model_plugin.apply(svc);
|
3251 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3317 + | let svc =
|
3318 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3252 3319 | .apply(svc);
|
3253 3320 | let svc = self.http_plugin.apply(svc);
|
3254 3321 | self.http_payload_with_union_custom(svc)
|
3255 3322 | }
|
3256 3323 |
|
3257 3324 | /// Sets the [`HttpPayloadWithUnion`](crate::operation_shape::HttpPayloadWithUnion) to a custom [`Service`](tower::Service).
|
3258 3325 | /// not constrained by the Smithy contract.
|
3259 3326 | fn http_payload_with_union_custom<S>(mut self, svc: S) -> Self
|
3260 3327 | where
|
3261 3328 | S: ::tower::Service<
|
3262 3329 | ::http::Request<Body>,
|
3263 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3330 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3264 3331 | Error = ::std::convert::Infallible,
|
3265 3332 | > + Clone
|
3266 3333 | + Send
|
3267 3334 | + 'static,
|
3268 3335 | S::Future: Send + 'static,
|
3269 3336 | {
|
3270 - | self.http_payload_with_union = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3337 + | self.http_payload_with_union =
|
3338 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3271 3339 | self
|
3272 3340 | }
|
3273 3341 |
|
3274 3342 | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
3275 3343 | ///
|
3276 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3277 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3344 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3345 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3278 3346 | ///
|
3279 3347 | /// # Example
|
3280 3348 | ///
|
3281 3349 | /// ```no_run
|
3282 3350 | /// use rest_json::{RestJson, RestJsonConfig};
|
3283 3351 | ///
|
3284 3352 | /// use rest_json::{input, output, error};
|
3285 3353 | ///
|
3286 3354 | /// async fn handler(input: input::HttpPrefixHeadersInput) -> Result<output::HttpPrefixHeadersOutput, error::HttpPrefixHeadersError> {
|
3287 3355 | /// todo!()
|
3288 3356 | /// }
|
3289 3357 | ///
|
3290 3358 | /// let config = RestJsonConfig::builder().build();
|
3291 3359 | /// let app = RestJson::builder(config)
|
3292 3360 | /// .http_prefix_headers(handler)
|
3293 3361 | /// /* Set other handlers */
|
3294 3362 | /// .build()
|
3295 3363 | /// .unwrap();
|
3296 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3364 + | /// # 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;
|
3297 3365 | /// ```
|
3298 3366 | ///
|
3299 3367 | pub fn http_prefix_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3300 3368 | where
|
3301 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeaders, HandlerExtractors>,
|
3369 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeaders, HandlerExtractors>,
|
3302 3370 |
|
3303 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3371 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3304 3372 | RestJson<L>,
|
3305 3373 | crate::operation_shape::HttpPrefixHeaders,
|
3306 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeaders, HandlerType>
|
3374 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeaders, HandlerType>
|
3307 3375 | >,
|
3308 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3376 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3309 3377 | RestJson<L>,
|
3310 3378 | crate::operation_shape::HttpPrefixHeaders,
|
3311 3379 | ModelPl::Output
|
3312 3380 | >,
|
3313 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3381 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3314 3382 | RestJson<L>,
|
3315 3383 | crate::operation_shape::HttpPrefixHeaders,
|
3316 3384 | <
|
3317 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3318 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3385 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3386 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3319 3387 | RestJson<L>,
|
3320 3388 | crate::operation_shape::HttpPrefixHeaders,
|
3321 3389 | ModelPl::Output
|
3322 3390 | >
|
3323 3391 | >::Output
|
3324 3392 | >,
|
3325 3393 |
|
3326 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3394 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3327 3395 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3328 3396 |
|
3329 3397 | {
|
3330 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3331 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3398 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3399 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3332 3400 | let svc = crate::operation_shape::HttpPrefixHeaders::from_handler(handler);
|
3333 3401 | let svc = self.model_plugin.apply(svc);
|
3334 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3402 + | let svc =
|
3403 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3335 3404 | .apply(svc);
|
3336 3405 | let svc = self.http_plugin.apply(svc);
|
3337 3406 | self.http_prefix_headers_custom(svc)
|
3338 3407 | }
|
3339 3408 |
|
3340 3409 | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) operation.
|
3341 3410 | ///
|
3342 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3343 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3411 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3412 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3344 3413 | ///
|
3345 3414 | /// # Example
|
3346 3415 | ///
|
3347 3416 | /// ```no_run
|
3348 3417 | /// use rest_json::{RestJson, RestJsonConfig};
|
3349 3418 | ///
|
3350 3419 | /// use rest_json::{input, output, error};
|
3351 3420 | ///
|
3352 3421 | /// async fn handler(input: input::HttpPrefixHeadersInput) -> Result<output::HttpPrefixHeadersOutput, error::HttpPrefixHeadersError> {
|
3353 3422 | /// todo!()
|
3354 3423 | /// }
|
3355 3424 | ///
|
3356 3425 | /// let config = RestJsonConfig::builder().build();
|
3357 3426 | /// let svc = ::tower::util::service_fn(handler);
|
3358 3427 | /// let app = RestJson::builder(config)
|
3359 3428 | /// .http_prefix_headers_service(svc)
|
3360 3429 | /// /* Set other handlers */
|
3361 3430 | /// .build()
|
3362 3431 | /// .unwrap();
|
3363 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3432 + | /// # 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;
|
3364 3433 | /// ```
|
3365 3434 | ///
|
3366 3435 | pub fn http_prefix_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3367 3436 | where
|
3368 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeaders, ServiceExtractors>,
|
3437 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeaders, ServiceExtractors>,
|
3369 3438 |
|
3370 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3439 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3371 3440 | RestJson<L>,
|
3372 3441 | crate::operation_shape::HttpPrefixHeaders,
|
3373 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeaders, S>
|
3442 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeaders, S>
|
3374 3443 | >,
|
3375 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3444 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3376 3445 | RestJson<L>,
|
3377 3446 | crate::operation_shape::HttpPrefixHeaders,
|
3378 3447 | ModelPl::Output
|
3379 3448 | >,
|
3380 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3449 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3381 3450 | RestJson<L>,
|
3382 3451 | crate::operation_shape::HttpPrefixHeaders,
|
3383 3452 | <
|
3384 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3385 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3453 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3454 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3386 3455 | RestJson<L>,
|
3387 3456 | crate::operation_shape::HttpPrefixHeaders,
|
3388 3457 | ModelPl::Output
|
3389 3458 | >
|
3390 3459 | >::Output
|
3391 3460 | >,
|
3392 3461 |
|
3393 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3462 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3394 3463 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3395 3464 |
|
3396 3465 | {
|
3397 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3398 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3466 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3467 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3399 3468 | let svc = crate::operation_shape::HttpPrefixHeaders::from_service(service);
|
3400 3469 | let svc = self.model_plugin.apply(svc);
|
3401 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3470 + | let svc =
|
3471 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3402 3472 | .apply(svc);
|
3403 3473 | let svc = self.http_plugin.apply(svc);
|
3404 3474 | self.http_prefix_headers_custom(svc)
|
3405 3475 | }
|
3406 3476 |
|
3407 3477 | /// Sets the [`HttpPrefixHeaders`](crate::operation_shape::HttpPrefixHeaders) to a custom [`Service`](tower::Service).
|
3408 3478 | /// not constrained by the Smithy contract.
|
3409 3479 | fn http_prefix_headers_custom<S>(mut self, svc: S) -> Self
|
3410 3480 | where
|
3411 3481 | S: ::tower::Service<
|
3412 3482 | ::http::Request<Body>,
|
3413 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3483 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3414 3484 | Error = ::std::convert::Infallible,
|
3415 3485 | > + Clone
|
3416 3486 | + Send
|
3417 3487 | + 'static,
|
3418 3488 | S::Future: Send + 'static,
|
3419 3489 | {
|
3420 - | self.http_prefix_headers = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3490 + | self.http_prefix_headers = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3421 3491 | self
|
3422 3492 | }
|
3423 3493 |
|
3424 3494 | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
3425 3495 | ///
|
3426 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3427 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3496 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3497 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3428 3498 | ///
|
3429 3499 | /// # Example
|
3430 3500 | ///
|
3431 3501 | /// ```no_run
|
3432 3502 | /// use rest_json::{RestJson, RestJsonConfig};
|
3433 3503 | ///
|
3434 3504 | /// use rest_json::{input, output, error};
|
3435 3505 | ///
|
3436 3506 | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> Result<output::HttpPrefixHeadersInResponseOutput, error::HttpPrefixHeadersInResponseError> {
|
3437 3507 | /// todo!()
|
3438 3508 | /// }
|
3439 3509 | ///
|
3440 3510 | /// let config = RestJsonConfig::builder().build();
|
3441 3511 | /// let app = RestJson::builder(config)
|
3442 3512 | /// .http_prefix_headers_in_response(handler)
|
3443 3513 | /// /* Set other handlers */
|
3444 3514 | /// .build()
|
3445 3515 | /// .unwrap();
|
3446 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3516 + | /// # 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;
|
3447 3517 | /// ```
|
3448 3518 | ///
|
3449 3519 | pub fn http_prefix_headers_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3450 3520 | where
|
3451 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerExtractors>,
|
3521 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerExtractors>,
|
3452 3522 |
|
3453 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3523 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3454 3524 | RestJson<L>,
|
3455 3525 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3456 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerType>
|
3526 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpPrefixHeadersInResponse, HandlerType>
|
3457 3527 | >,
|
3458 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3528 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3459 3529 | RestJson<L>,
|
3460 3530 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3461 3531 | ModelPl::Output
|
3462 3532 | >,
|
3463 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3533 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3464 3534 | RestJson<L>,
|
3465 3535 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3466 3536 | <
|
3467 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3468 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3537 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3538 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3469 3539 | RestJson<L>,
|
3470 3540 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3471 3541 | ModelPl::Output
|
3472 3542 | >
|
3473 3543 | >::Output
|
3474 3544 | >,
|
3475 3545 |
|
3476 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3546 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3477 3547 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3478 3548 |
|
3479 3549 | {
|
3480 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3481 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3550 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3551 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3482 3552 | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_handler(handler);
|
3483 3553 | let svc = self.model_plugin.apply(svc);
|
3484 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3554 + | let svc =
|
3555 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3485 3556 | .apply(svc);
|
3486 3557 | let svc = self.http_plugin.apply(svc);
|
3487 3558 | self.http_prefix_headers_in_response_custom(svc)
|
3488 3559 | }
|
3489 3560 |
|
3490 3561 | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) operation.
|
3491 3562 | ///
|
3492 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3493 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3563 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3564 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3494 3565 | ///
|
3495 3566 | /// # Example
|
3496 3567 | ///
|
3497 3568 | /// ```no_run
|
3498 3569 | /// use rest_json::{RestJson, RestJsonConfig};
|
3499 3570 | ///
|
3500 3571 | /// use rest_json::{input, output, error};
|
3501 3572 | ///
|
3502 3573 | /// async fn handler(input: input::HttpPrefixHeadersInResponseInput) -> Result<output::HttpPrefixHeadersInResponseOutput, error::HttpPrefixHeadersInResponseError> {
|
3503 3574 | /// todo!()
|
3504 3575 | /// }
|
3505 3576 | ///
|
3506 3577 | /// let config = RestJsonConfig::builder().build();
|
3507 3578 | /// let svc = ::tower::util::service_fn(handler);
|
3508 3579 | /// let app = RestJson::builder(config)
|
3509 3580 | /// .http_prefix_headers_in_response_service(svc)
|
3510 3581 | /// /* Set other handlers */
|
3511 3582 | /// .build()
|
3512 3583 | /// .unwrap();
|
3513 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3584 + | /// # 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;
|
3514 3585 | /// ```
|
3515 3586 | ///
|
3516 3587 | pub fn http_prefix_headers_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3517 3588 | where
|
3518 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeadersInResponse, ServiceExtractors>,
|
3589 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpPrefixHeadersInResponse, ServiceExtractors>,
|
3519 3590 |
|
3520 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3591 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3521 3592 | RestJson<L>,
|
3522 3593 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3523 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeadersInResponse, S>
|
3594 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpPrefixHeadersInResponse, S>
|
3524 3595 | >,
|
3525 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3596 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3526 3597 | RestJson<L>,
|
3527 3598 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3528 3599 | ModelPl::Output
|
3529 3600 | >,
|
3530 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3601 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3531 3602 | RestJson<L>,
|
3532 3603 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3533 3604 | <
|
3534 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3535 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3605 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3606 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3536 3607 | RestJson<L>,
|
3537 3608 | crate::operation_shape::HttpPrefixHeadersInResponse,
|
3538 3609 | ModelPl::Output
|
3539 3610 | >
|
3540 3611 | >::Output
|
3541 3612 | >,
|
3542 3613 |
|
3543 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3614 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3544 3615 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3545 3616 |
|
3546 3617 | {
|
3547 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3548 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3618 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3619 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3549 3620 | let svc = crate::operation_shape::HttpPrefixHeadersInResponse::from_service(service);
|
3550 3621 | let svc = self.model_plugin.apply(svc);
|
3551 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3622 + | let svc =
|
3623 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3552 3624 | .apply(svc);
|
3553 3625 | let svc = self.http_plugin.apply(svc);
|
3554 3626 | self.http_prefix_headers_in_response_custom(svc)
|
3555 3627 | }
|
3556 3628 |
|
3557 3629 | /// Sets the [`HttpPrefixHeadersInResponse`](crate::operation_shape::HttpPrefixHeadersInResponse) to a custom [`Service`](tower::Service).
|
3558 3630 | /// not constrained by the Smithy contract.
|
3559 3631 | fn http_prefix_headers_in_response_custom<S>(mut self, svc: S) -> Self
|
3560 3632 | where
|
3561 3633 | S: ::tower::Service<
|
3562 3634 | ::http::Request<Body>,
|
3563 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3635 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3564 3636 | Error = ::std::convert::Infallible,
|
3565 3637 | > + Clone
|
3566 3638 | + Send
|
3567 3639 | + 'static,
|
3568 3640 | S::Future: Send + 'static,
|
3569 3641 | {
|
3570 3642 | self.http_prefix_headers_in_response =
|
3571 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3643 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3572 3644 | self
|
3573 3645 | }
|
3574 3646 |
|
3575 3647 | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
3576 3648 | ///
|
3577 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3578 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3649 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3650 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3579 3651 | ///
|
3580 3652 | /// # Example
|
3581 3653 | ///
|
3582 3654 | /// ```no_run
|
3583 3655 | /// use rest_json::{RestJson, RestJsonConfig};
|
3584 3656 | ///
|
3585 3657 | /// use rest_json::{input, output, error};
|
3586 3658 | ///
|
3587 3659 | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
3588 3660 | /// todo!()
|
3589 3661 | /// }
|
3590 3662 | ///
|
3591 3663 | /// let config = RestJsonConfig::builder().build();
|
3592 3664 | /// let app = RestJson::builder(config)
|
3593 3665 | /// .http_request_with_float_labels(handler)
|
3594 3666 | /// /* Set other handlers */
|
3595 3667 | /// .build()
|
3596 3668 | /// .unwrap();
|
3597 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3669 + | /// # 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;
|
3598 3670 | /// ```
|
3599 3671 | ///
|
3600 3672 | pub fn http_request_with_float_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3601 3673 | where
|
3602 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithFloatLabels, HandlerExtractors>,
|
3674 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithFloatLabels, HandlerExtractors>,
|
3603 3675 |
|
3604 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3676 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3605 3677 | RestJson<L>,
|
3606 3678 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3607 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithFloatLabels, HandlerType>
|
3679 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithFloatLabels, HandlerType>
|
3608 3680 | >,
|
3609 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3681 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3610 3682 | RestJson<L>,
|
3611 3683 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3612 3684 | ModelPl::Output
|
3613 3685 | >,
|
3614 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3686 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3615 3687 | RestJson<L>,
|
3616 3688 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3617 3689 | <
|
3618 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3619 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3690 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3691 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3620 3692 | RestJson<L>,
|
3621 3693 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3622 3694 | ModelPl::Output
|
3623 3695 | >
|
3624 3696 | >::Output
|
3625 3697 | >,
|
3626 3698 |
|
3627 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3699 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3628 3700 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3629 3701 |
|
3630 3702 | {
|
3631 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3632 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3703 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3704 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3633 3705 | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_handler(handler);
|
3634 3706 | let svc = self.model_plugin.apply(svc);
|
3635 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3707 + | let svc =
|
3708 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3636 3709 | .apply(svc);
|
3637 3710 | let svc = self.http_plugin.apply(svc);
|
3638 3711 | self.http_request_with_float_labels_custom(svc)
|
3639 3712 | }
|
3640 3713 |
|
3641 3714 | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) operation.
|
3642 3715 | ///
|
3643 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3644 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3716 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3717 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3645 3718 | ///
|
3646 3719 | /// # Example
|
3647 3720 | ///
|
3648 3721 | /// ```no_run
|
3649 3722 | /// use rest_json::{RestJson, RestJsonConfig};
|
3650 3723 | ///
|
3651 3724 | /// use rest_json::{input, output, error};
|
3652 3725 | ///
|
3653 3726 | /// async fn handler(input: input::HttpRequestWithFloatLabelsInput) -> Result<output::HttpRequestWithFloatLabelsOutput, error::HttpRequestWithFloatLabelsError> {
|
3654 3727 | /// todo!()
|
3655 3728 | /// }
|
3656 3729 | ///
|
3657 3730 | /// let config = RestJsonConfig::builder().build();
|
3658 3731 | /// let svc = ::tower::util::service_fn(handler);
|
3659 3732 | /// let app = RestJson::builder(config)
|
3660 3733 | /// .http_request_with_float_labels_service(svc)
|
3661 3734 | /// /* Set other handlers */
|
3662 3735 | /// .build()
|
3663 3736 | /// .unwrap();
|
3664 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3737 + | /// # 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;
|
3665 3738 | /// ```
|
3666 3739 | ///
|
3667 3740 | pub fn http_request_with_float_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3668 3741 | where
|
3669 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithFloatLabels, ServiceExtractors>,
|
3742 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithFloatLabels, ServiceExtractors>,
|
3670 3743 |
|
3671 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3744 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3672 3745 | RestJson<L>,
|
3673 3746 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3674 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithFloatLabels, S>
|
3747 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithFloatLabels, S>
|
3675 3748 | >,
|
3676 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3749 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3677 3750 | RestJson<L>,
|
3678 3751 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3679 3752 | ModelPl::Output
|
3680 3753 | >,
|
3681 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3754 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3682 3755 | RestJson<L>,
|
3683 3756 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3684 3757 | <
|
3685 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3686 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3758 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3759 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3687 3760 | RestJson<L>,
|
3688 3761 | crate::operation_shape::HttpRequestWithFloatLabels,
|
3689 3762 | ModelPl::Output
|
3690 3763 | >
|
3691 3764 | >::Output
|
3692 3765 | >,
|
3693 3766 |
|
3694 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3767 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3695 3768 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3696 3769 |
|
3697 3770 | {
|
3698 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3699 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3771 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3772 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3700 3773 | let svc = crate::operation_shape::HttpRequestWithFloatLabels::from_service(service);
|
3701 3774 | let svc = self.model_plugin.apply(svc);
|
3702 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3775 + | let svc =
|
3776 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3703 3777 | .apply(svc);
|
3704 3778 | let svc = self.http_plugin.apply(svc);
|
3705 3779 | self.http_request_with_float_labels_custom(svc)
|
3706 3780 | }
|
3707 3781 |
|
3708 3782 | /// Sets the [`HttpRequestWithFloatLabels`](crate::operation_shape::HttpRequestWithFloatLabels) to a custom [`Service`](tower::Service).
|
3709 3783 | /// not constrained by the Smithy contract.
|
3710 3784 | fn http_request_with_float_labels_custom<S>(mut self, svc: S) -> Self
|
3711 3785 | where
|
3712 3786 | S: ::tower::Service<
|
3713 3787 | ::http::Request<Body>,
|
3714 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3788 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3715 3789 | Error = ::std::convert::Infallible,
|
3716 3790 | > + Clone
|
3717 3791 | + Send
|
3718 3792 | + 'static,
|
3719 3793 | S::Future: Send + 'static,
|
3720 3794 | {
|
3721 3795 | self.http_request_with_float_labels =
|
3722 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3796 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3723 3797 | self
|
3724 3798 | }
|
3725 3799 |
|
3726 3800 | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
3727 3801 | ///
|
3728 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3729 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3802 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3803 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3730 3804 | ///
|
3731 3805 | /// # Example
|
3732 3806 | ///
|
3733 3807 | /// ```no_run
|
3734 3808 | /// use rest_json::{RestJson, RestJsonConfig};
|
3735 3809 | ///
|
3736 3810 | /// use rest_json::{input, output, error};
|
3737 3811 | ///
|
3738 3812 | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
3739 3813 | /// todo!()
|
3740 3814 | /// }
|
3741 3815 | ///
|
3742 3816 | /// let config = RestJsonConfig::builder().build();
|
3743 3817 | /// let app = RestJson::builder(config)
|
3744 3818 | /// .http_request_with_greedy_label_in_path(handler)
|
3745 3819 | /// /* Set other handlers */
|
3746 3820 | /// .build()
|
3747 3821 | /// .unwrap();
|
3748 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3822 + | /// # 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;
|
3749 3823 | /// ```
|
3750 3824 | ///
|
3751 3825 | pub fn http_request_with_greedy_label_in_path<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3752 3826 | where
|
3753 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerExtractors>,
|
3827 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerExtractors>,
|
3754 3828 |
|
3755 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3829 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3756 3830 | RestJson<L>,
|
3757 3831 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3758 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerType>
|
3832 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, HandlerType>
|
3759 3833 | >,
|
3760 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3834 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3761 3835 | RestJson<L>,
|
3762 3836 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3763 3837 | ModelPl::Output
|
3764 3838 | >,
|
3765 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3839 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3766 3840 | RestJson<L>,
|
3767 3841 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3768 3842 | <
|
3769 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3770 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3843 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3844 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3771 3845 | RestJson<L>,
|
3772 3846 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3773 3847 | ModelPl::Output
|
3774 3848 | >
|
3775 3849 | >::Output
|
3776 3850 | >,
|
3777 3851 |
|
3778 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3852 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3779 3853 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3780 3854 |
|
3781 3855 | {
|
3782 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3783 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3856 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3857 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3784 3858 | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_handler(handler);
|
3785 3859 | let svc = self.model_plugin.apply(svc);
|
3786 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3860 + | let svc =
|
3861 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3787 3862 | .apply(svc);
|
3788 3863 | let svc = self.http_plugin.apply(svc);
|
3789 3864 | self.http_request_with_greedy_label_in_path_custom(svc)
|
3790 3865 | }
|
3791 3866 |
|
3792 3867 | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) operation.
|
3793 3868 | ///
|
3794 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3795 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3869 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3870 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3796 3871 | ///
|
3797 3872 | /// # Example
|
3798 3873 | ///
|
3799 3874 | /// ```no_run
|
3800 3875 | /// use rest_json::{RestJson, RestJsonConfig};
|
3801 3876 | ///
|
3802 3877 | /// use rest_json::{input, output, error};
|
3803 3878 | ///
|
3804 3879 | /// async fn handler(input: input::HttpRequestWithGreedyLabelInPathInput) -> Result<output::HttpRequestWithGreedyLabelInPathOutput, error::HttpRequestWithGreedyLabelInPathError> {
|
3805 3880 | /// todo!()
|
3806 3881 | /// }
|
3807 3882 | ///
|
3808 3883 | /// let config = RestJsonConfig::builder().build();
|
3809 3884 | /// let svc = ::tower::util::service_fn(handler);
|
3810 3885 | /// let app = RestJson::builder(config)
|
3811 3886 | /// .http_request_with_greedy_label_in_path_service(svc)
|
3812 3887 | /// /* Set other handlers */
|
3813 3888 | /// .build()
|
3814 3889 | /// .unwrap();
|
3815 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3890 + | /// # 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;
|
3816 3891 | /// ```
|
3817 3892 | ///
|
3818 3893 | pub fn http_request_with_greedy_label_in_path_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3819 3894 | where
|
3820 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, ServiceExtractors>,
|
3895 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithGreedyLabelInPath, ServiceExtractors>,
|
3821 3896 |
|
3822 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3897 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3823 3898 | RestJson<L>,
|
3824 3899 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3825 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithGreedyLabelInPath, S>
|
3900 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithGreedyLabelInPath, S>
|
3826 3901 | >,
|
3827 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3902 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3828 3903 | RestJson<L>,
|
3829 3904 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3830 3905 | ModelPl::Output
|
3831 3906 | >,
|
3832 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3907 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3833 3908 | RestJson<L>,
|
3834 3909 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3835 3910 | <
|
3836 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3837 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3911 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3912 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3838 3913 | RestJson<L>,
|
3839 3914 | crate::operation_shape::HttpRequestWithGreedyLabelInPath,
|
3840 3915 | ModelPl::Output
|
3841 3916 | >
|
3842 3917 | >::Output
|
3843 3918 | >,
|
3844 3919 |
|
3845 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3920 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3846 3921 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3847 3922 |
|
3848 3923 | {
|
3849 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3850 - | use ::aws_smithy_http_server::plugin::Plugin;
|
3924 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
3925 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3851 3926 | let svc = crate::operation_shape::HttpRequestWithGreedyLabelInPath::from_service(service);
|
3852 3927 | let svc = self.model_plugin.apply(svc);
|
3853 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3928 + | let svc =
|
3929 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3854 3930 | .apply(svc);
|
3855 3931 | let svc = self.http_plugin.apply(svc);
|
3856 3932 | self.http_request_with_greedy_label_in_path_custom(svc)
|
3857 3933 | }
|
3858 3934 |
|
3859 3935 | /// Sets the [`HttpRequestWithGreedyLabelInPath`](crate::operation_shape::HttpRequestWithGreedyLabelInPath) to a custom [`Service`](tower::Service).
|
3860 3936 | /// not constrained by the Smithy contract.
|
3861 3937 | fn http_request_with_greedy_label_in_path_custom<S>(mut self, svc: S) -> Self
|
3862 3938 | where
|
3863 3939 | S: ::tower::Service<
|
3864 3940 | ::http::Request<Body>,
|
3865 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
3941 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
3866 3942 | Error = ::std::convert::Infallible,
|
3867 3943 | > + Clone
|
3868 3944 | + Send
|
3869 3945 | + 'static,
|
3870 3946 | S::Future: Send + 'static,
|
3871 3947 | {
|
3872 3948 | self.http_request_with_greedy_label_in_path =
|
3873 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
3949 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
3874 3950 | self
|
3875 3951 | }
|
3876 3952 |
|
3877 3953 | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
3878 3954 | ///
|
3879 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3880 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
3955 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
3956 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3881 3957 | ///
|
3882 3958 | /// # Example
|
3883 3959 | ///
|
3884 3960 | /// ```no_run
|
3885 3961 | /// use rest_json::{RestJson, RestJsonConfig};
|
3886 3962 | ///
|
3887 3963 | /// use rest_json::{input, output, error};
|
3888 3964 | ///
|
3889 3965 | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
3890 3966 | /// todo!()
|
3891 3967 | /// }
|
3892 3968 | ///
|
3893 3969 | /// let config = RestJsonConfig::builder().build();
|
3894 3970 | /// let app = RestJson::builder(config)
|
3895 3971 | /// .http_request_with_labels(handler)
|
3896 3972 | /// /* Set other handlers */
|
3897 3973 | /// .build()
|
3898 3974 | /// .unwrap();
|
3899 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
3975 + | /// # 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;
|
3900 3976 | /// ```
|
3901 3977 | ///
|
3902 3978 | pub fn http_request_with_labels<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
3903 3979 | where
|
3904 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabels, HandlerExtractors>,
|
3980 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabels, HandlerExtractors>,
|
3905 3981 |
|
3906 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
3982 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3907 3983 | RestJson<L>,
|
3908 3984 | crate::operation_shape::HttpRequestWithLabels,
|
3909 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabels, HandlerType>
|
3985 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabels, HandlerType>
|
3910 3986 | >,
|
3911 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
3987 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3912 3988 | RestJson<L>,
|
3913 3989 | crate::operation_shape::HttpRequestWithLabels,
|
3914 3990 | ModelPl::Output
|
3915 3991 | >,
|
3916 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
3992 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3917 3993 | RestJson<L>,
|
3918 3994 | crate::operation_shape::HttpRequestWithLabels,
|
3919 3995 | <
|
3920 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3921 - | as ::aws_smithy_http_server::plugin::Plugin<
|
3996 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3997 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3922 3998 | RestJson<L>,
|
3923 3999 | crate::operation_shape::HttpRequestWithLabels,
|
3924 4000 | ModelPl::Output
|
3925 4001 | >
|
3926 4002 | >::Output
|
3927 4003 | >,
|
3928 4004 |
|
3929 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4005 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3930 4006 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3931 4007 |
|
3932 4008 | {
|
3933 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
3934 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4009 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4010 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
3935 4011 | let svc = crate::operation_shape::HttpRequestWithLabels::from_handler(handler);
|
3936 4012 | let svc = self.model_plugin.apply(svc);
|
3937 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4013 + | let svc =
|
4014 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
3938 4015 | .apply(svc);
|
3939 4016 | let svc = self.http_plugin.apply(svc);
|
3940 4017 | self.http_request_with_labels_custom(svc)
|
3941 4018 | }
|
3942 4019 |
|
3943 4020 | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) operation.
|
3944 4021 | ///
|
3945 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
3946 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4022 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4023 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
3947 4024 | ///
|
3948 4025 | /// # Example
|
3949 4026 | ///
|
3950 4027 | /// ```no_run
|
3951 4028 | /// use rest_json::{RestJson, RestJsonConfig};
|
3952 4029 | ///
|
3953 4030 | /// use rest_json::{input, output, error};
|
3954 4031 | ///
|
3955 4032 | /// async fn handler(input: input::HttpRequestWithLabelsInput) -> Result<output::HttpRequestWithLabelsOutput, error::HttpRequestWithLabelsError> {
|
3956 4033 | /// todo!()
|
3957 4034 | /// }
|
3958 4035 | ///
|
3959 4036 | /// let config = RestJsonConfig::builder().build();
|
3960 4037 | /// let svc = ::tower::util::service_fn(handler);
|
3961 4038 | /// let app = RestJson::builder(config)
|
3962 4039 | /// .http_request_with_labels_service(svc)
|
3963 4040 | /// /* Set other handlers */
|
3964 4041 | /// .build()
|
3965 4042 | /// .unwrap();
|
3966 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4043 + | /// # 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;
|
3967 4044 | /// ```
|
3968 4045 | ///
|
3969 4046 | pub fn http_request_with_labels_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
3970 4047 | where
|
3971 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabels, ServiceExtractors>,
|
4048 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabels, ServiceExtractors>,
|
3972 4049 |
|
3973 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4050 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3974 4051 | RestJson<L>,
|
3975 4052 | crate::operation_shape::HttpRequestWithLabels,
|
3976 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabels, S>
|
4053 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabels, S>
|
3977 4054 | >,
|
3978 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4055 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3979 4056 | RestJson<L>,
|
3980 4057 | crate::operation_shape::HttpRequestWithLabels,
|
3981 4058 | ModelPl::Output
|
3982 4059 | >,
|
3983 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4060 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3984 4061 | RestJson<L>,
|
3985 4062 | crate::operation_shape::HttpRequestWithLabels,
|
3986 4063 | <
|
3987 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
3988 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4064 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4065 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
3989 4066 | RestJson<L>,
|
3990 4067 | crate::operation_shape::HttpRequestWithLabels,
|
3991 4068 | ModelPl::Output
|
3992 4069 | >
|
3993 4070 | >::Output
|
3994 4071 | >,
|
3995 4072 |
|
3996 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4073 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
3997 4074 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
3998 4075 |
|
3999 4076 | {
|
4000 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4001 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4077 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4078 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4002 4079 | let svc = crate::operation_shape::HttpRequestWithLabels::from_service(service);
|
4003 4080 | let svc = self.model_plugin.apply(svc);
|
4004 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4081 + | let svc =
|
4082 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4005 4083 | .apply(svc);
|
4006 4084 | let svc = self.http_plugin.apply(svc);
|
4007 4085 | self.http_request_with_labels_custom(svc)
|
4008 4086 | }
|
4009 4087 |
|
4010 4088 | /// Sets the [`HttpRequestWithLabels`](crate::operation_shape::HttpRequestWithLabels) to a custom [`Service`](tower::Service).
|
4011 4089 | /// not constrained by the Smithy contract.
|
4012 4090 | fn http_request_with_labels_custom<S>(mut self, svc: S) -> Self
|
4013 4091 | where
|
4014 4092 | S: ::tower::Service<
|
4015 4093 | ::http::Request<Body>,
|
4016 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4094 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4017 4095 | Error = ::std::convert::Infallible,
|
4018 4096 | > + Clone
|
4019 4097 | + Send
|
4020 4098 | + 'static,
|
4021 4099 | S::Future: Send + 'static,
|
4022 4100 | {
|
4023 - | self.http_request_with_labels = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4101 + | self.http_request_with_labels =
|
4102 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4024 4103 | self
|
4025 4104 | }
|
4026 4105 |
|
4027 4106 | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
4028 4107 | ///
|
4029 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4030 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4108 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4109 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4031 4110 | ///
|
4032 4111 | /// # Example
|
4033 4112 | ///
|
4034 4113 | /// ```no_run
|
4035 4114 | /// use rest_json::{RestJson, RestJsonConfig};
|
4036 4115 | ///
|
4037 4116 | /// use rest_json::{input, output, error};
|
4038 4117 | ///
|
4039 4118 | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
4040 4119 | /// todo!()
|
4041 4120 | /// }
|
4042 4121 | ///
|
4043 4122 | /// let config = RestJsonConfig::builder().build();
|
4044 4123 | /// let app = RestJson::builder(config)
|
4045 4124 | /// .http_request_with_labels_and_timestamp_format(handler)
|
4046 4125 | /// /* Set other handlers */
|
4047 4126 | /// .build()
|
4048 4127 | /// .unwrap();
|
4049 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4128 + | /// # 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;
|
4050 4129 | /// ```
|
4051 4130 | ///
|
4052 4131 | pub fn http_request_with_labels_and_timestamp_format<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4053 4132 | where
|
4054 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerExtractors>,
|
4133 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerExtractors>,
|
4055 4134 |
|
4056 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4135 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4057 4136 | RestJson<L>,
|
4058 4137 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4059 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerType>
|
4138 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, HandlerType>
|
4060 4139 | >,
|
4061 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4140 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4062 4141 | RestJson<L>,
|
4063 4142 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4064 4143 | ModelPl::Output
|
4065 4144 | >,
|
4066 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4145 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4067 4146 | RestJson<L>,
|
4068 4147 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4069 4148 | <
|
4070 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4071 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4149 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4150 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4072 4151 | RestJson<L>,
|
4073 4152 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4074 4153 | ModelPl::Output
|
4075 4154 | >
|
4076 4155 | >::Output
|
4077 4156 | >,
|
4078 4157 |
|
4079 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4158 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4080 4159 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4081 4160 |
|
4082 4161 | {
|
4083 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4084 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4162 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4163 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4085 4164 | let svc =
|
4086 4165 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_handler(handler);
|
4087 4166 | let svc = self.model_plugin.apply(svc);
|
4088 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4167 + | let svc =
|
4168 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4089 4169 | .apply(svc);
|
4090 4170 | let svc = self.http_plugin.apply(svc);
|
4091 4171 | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
4092 4172 | }
|
4093 4173 |
|
4094 4174 | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) operation.
|
4095 4175 | ///
|
4096 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4097 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4176 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4177 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4098 4178 | ///
|
4099 4179 | /// # Example
|
4100 4180 | ///
|
4101 4181 | /// ```no_run
|
4102 4182 | /// use rest_json::{RestJson, RestJsonConfig};
|
4103 4183 | ///
|
4104 4184 | /// use rest_json::{input, output, error};
|
4105 4185 | ///
|
4106 4186 | /// async fn handler(input: input::HttpRequestWithLabelsAndTimestampFormatInput) -> Result<output::HttpRequestWithLabelsAndTimestampFormatOutput, error::HttpRequestWithLabelsAndTimestampFormatError> {
|
4107 4187 | /// todo!()
|
4108 4188 | /// }
|
4109 4189 | ///
|
4110 4190 | /// let config = RestJsonConfig::builder().build();
|
4111 4191 | /// let svc = ::tower::util::service_fn(handler);
|
4112 4192 | /// let app = RestJson::builder(config)
|
4113 4193 | /// .http_request_with_labels_and_timestamp_format_service(svc)
|
4114 4194 | /// /* Set other handlers */
|
4115 4195 | /// .build()
|
4116 4196 | /// .unwrap();
|
4117 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4197 + | /// # 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;
|
4118 4198 | /// ```
|
4119 4199 | ///
|
4120 4200 | pub fn http_request_with_labels_and_timestamp_format_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4121 4201 | where
|
4122 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, ServiceExtractors>,
|
4202 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, ServiceExtractors>,
|
4123 4203 |
|
4124 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4204 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4125 4205 | RestJson<L>,
|
4126 4206 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4127 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, S>
|
4207 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat, S>
|
4128 4208 | >,
|
4129 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4209 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4130 4210 | RestJson<L>,
|
4131 4211 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4132 4212 | ModelPl::Output
|
4133 4213 | >,
|
4134 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4214 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4135 4215 | RestJson<L>,
|
4136 4216 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4137 4217 | <
|
4138 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4139 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4218 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4219 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4140 4220 | RestJson<L>,
|
4141 4221 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat,
|
4142 4222 | ModelPl::Output
|
4143 4223 | >
|
4144 4224 | >::Output
|
4145 4225 | >,
|
4146 4226 |
|
4147 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4227 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4148 4228 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4149 4229 |
|
4150 4230 | {
|
4151 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4152 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4231 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4232 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4153 4233 | let svc =
|
4154 4234 | crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat::from_service(service);
|
4155 4235 | let svc = self.model_plugin.apply(svc);
|
4156 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4236 + | let svc =
|
4237 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4157 4238 | .apply(svc);
|
4158 4239 | let svc = self.http_plugin.apply(svc);
|
4159 4240 | self.http_request_with_labels_and_timestamp_format_custom(svc)
|
4160 4241 | }
|
4161 4242 |
|
4162 4243 | /// Sets the [`HttpRequestWithLabelsAndTimestampFormat`](crate::operation_shape::HttpRequestWithLabelsAndTimestampFormat) to a custom [`Service`](tower::Service).
|
4163 4244 | /// not constrained by the Smithy contract.
|
4164 4245 | fn http_request_with_labels_and_timestamp_format_custom<S>(mut self, svc: S) -> Self
|
4165 4246 | where
|
4166 4247 | S: ::tower::Service<
|
4167 4248 | ::http::Request<Body>,
|
4168 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4249 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4169 4250 | Error = ::std::convert::Infallible,
|
4170 4251 | > + Clone
|
4171 4252 | + Send
|
4172 4253 | + 'static,
|
4173 4254 | S::Future: Send + 'static,
|
4174 4255 | {
|
4175 4256 | self.http_request_with_labels_and_timestamp_format =
|
4176 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4257 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4177 4258 | self
|
4178 4259 | }
|
4179 4260 |
|
4180 4261 | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
4181 4262 | ///
|
4182 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4183 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4263 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4264 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4184 4265 | ///
|
4185 4266 | /// # Example
|
4186 4267 | ///
|
4187 4268 | /// ```no_run
|
4188 4269 | /// use rest_json::{RestJson, RestJsonConfig};
|
4189 4270 | ///
|
4190 4271 | /// use rest_json::{input, output, error};
|
4191 4272 | ///
|
4192 4273 | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
4193 4274 | /// todo!()
|
4194 4275 | /// }
|
4195 4276 | ///
|
4196 4277 | /// let config = RestJsonConfig::builder().build();
|
4197 4278 | /// let app = RestJson::builder(config)
|
4198 4279 | /// .http_request_with_regex_literal(handler)
|
4199 4280 | /// /* Set other handlers */
|
4200 4281 | /// .build()
|
4201 4282 | /// .unwrap();
|
4202 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4283 + | /// # 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;
|
4203 4284 | /// ```
|
4204 4285 | ///
|
4205 4286 | pub fn http_request_with_regex_literal<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4206 4287 | where
|
4207 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerExtractors>,
|
4288 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerExtractors>,
|
4208 4289 |
|
4209 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4290 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4210 4291 | RestJson<L>,
|
4211 4292 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4212 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerType>
|
4293 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpRequestWithRegexLiteral, HandlerType>
|
4213 4294 | >,
|
4214 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4295 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4215 4296 | RestJson<L>,
|
4216 4297 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4217 4298 | ModelPl::Output
|
4218 4299 | >,
|
4219 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4300 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4220 4301 | RestJson<L>,
|
4221 4302 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4222 4303 | <
|
4223 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4224 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4304 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4305 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4225 4306 | RestJson<L>,
|
4226 4307 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4227 4308 | ModelPl::Output
|
4228 4309 | >
|
4229 4310 | >::Output
|
4230 4311 | >,
|
4231 4312 |
|
4232 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4313 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4233 4314 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4234 4315 |
|
4235 4316 | {
|
4236 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4237 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4317 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4318 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4238 4319 | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_handler(handler);
|
4239 4320 | let svc = self.model_plugin.apply(svc);
|
4240 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4321 + | let svc =
|
4322 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4241 4323 | .apply(svc);
|
4242 4324 | let svc = self.http_plugin.apply(svc);
|
4243 4325 | self.http_request_with_regex_literal_custom(svc)
|
4244 4326 | }
|
4245 4327 |
|
4246 4328 | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) operation.
|
4247 4329 | ///
|
4248 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4249 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4330 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4331 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4250 4332 | ///
|
4251 4333 | /// # Example
|
4252 4334 | ///
|
4253 4335 | /// ```no_run
|
4254 4336 | /// use rest_json::{RestJson, RestJsonConfig};
|
4255 4337 | ///
|
4256 4338 | /// use rest_json::{input, output, error};
|
4257 4339 | ///
|
4258 4340 | /// async fn handler(input: input::HttpRequestWithRegexLiteralInput) -> Result<output::HttpRequestWithRegexLiteralOutput, error::HttpRequestWithRegexLiteralError> {
|
4259 4341 | /// todo!()
|
4260 4342 | /// }
|
4261 4343 | ///
|
4262 4344 | /// let config = RestJsonConfig::builder().build();
|
4263 4345 | /// let svc = ::tower::util::service_fn(handler);
|
4264 4346 | /// let app = RestJson::builder(config)
|
4265 4347 | /// .http_request_with_regex_literal_service(svc)
|
4266 4348 | /// /* Set other handlers */
|
4267 4349 | /// .build()
|
4268 4350 | /// .unwrap();
|
4269 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4351 + | /// # 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;
|
4270 4352 | /// ```
|
4271 4353 | ///
|
4272 4354 | pub fn http_request_with_regex_literal_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4273 4355 | where
|
4274 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithRegexLiteral, ServiceExtractors>,
|
4356 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpRequestWithRegexLiteral, ServiceExtractors>,
|
4275 4357 |
|
4276 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4358 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4277 4359 | RestJson<L>,
|
4278 4360 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4279 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithRegexLiteral, S>
|
4361 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpRequestWithRegexLiteral, S>
|
4280 4362 | >,
|
4281 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4363 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4282 4364 | RestJson<L>,
|
4283 4365 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4284 4366 | ModelPl::Output
|
4285 4367 | >,
|
4286 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4368 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4287 4369 | RestJson<L>,
|
4288 4370 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4289 4371 | <
|
4290 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4291 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4372 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4373 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4292 4374 | RestJson<L>,
|
4293 4375 | crate::operation_shape::HttpRequestWithRegexLiteral,
|
4294 4376 | ModelPl::Output
|
4295 4377 | >
|
4296 4378 | >::Output
|
4297 4379 | >,
|
4298 4380 |
|
4299 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4381 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4300 4382 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4301 4383 |
|
4302 4384 | {
|
4303 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4304 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4385 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4386 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4305 4387 | let svc = crate::operation_shape::HttpRequestWithRegexLiteral::from_service(service);
|
4306 4388 | let svc = self.model_plugin.apply(svc);
|
4307 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4389 + | let svc =
|
4390 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4308 4391 | .apply(svc);
|
4309 4392 | let svc = self.http_plugin.apply(svc);
|
4310 4393 | self.http_request_with_regex_literal_custom(svc)
|
4311 4394 | }
|
4312 4395 |
|
4313 4396 | /// Sets the [`HttpRequestWithRegexLiteral`](crate::operation_shape::HttpRequestWithRegexLiteral) to a custom [`Service`](tower::Service).
|
4314 4397 | /// not constrained by the Smithy contract.
|
4315 4398 | fn http_request_with_regex_literal_custom<S>(mut self, svc: S) -> Self
|
4316 4399 | where
|
4317 4400 | S: ::tower::Service<
|
4318 4401 | ::http::Request<Body>,
|
4319 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4402 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4320 4403 | Error = ::std::convert::Infallible,
|
4321 4404 | > + Clone
|
4322 4405 | + Send
|
4323 4406 | + 'static,
|
4324 4407 | S::Future: Send + 'static,
|
4325 4408 | {
|
4326 4409 | self.http_request_with_regex_literal =
|
4327 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4410 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4328 4411 | self
|
4329 4412 | }
|
4330 4413 |
|
4331 4414 | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
4332 4415 | ///
|
4333 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4334 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4416 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4417 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4335 4418 | ///
|
4336 4419 | /// # Example
|
4337 4420 | ///
|
4338 4421 | /// ```no_run
|
4339 4422 | /// use rest_json::{RestJson, RestJsonConfig};
|
4340 4423 | ///
|
4341 4424 | /// use rest_json::{input, output, error};
|
4342 4425 | ///
|
4343 4426 | /// async fn handler(input: input::HttpResponseCodeInput) -> Result<output::HttpResponseCodeOutput, error::HttpResponseCodeError> {
|
4344 4427 | /// todo!()
|
4345 4428 | /// }
|
4346 4429 | ///
|
4347 4430 | /// let config = RestJsonConfig::builder().build();
|
4348 4431 | /// let app = RestJson::builder(config)
|
4349 4432 | /// .http_response_code(handler)
|
4350 4433 | /// /* Set other handlers */
|
4351 4434 | /// .build()
|
4352 4435 | /// .unwrap();
|
4353 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4436 + | /// # 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;
|
4354 4437 | /// ```
|
4355 4438 | ///
|
4356 4439 | pub fn http_response_code<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4357 4440 | where
|
4358 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpResponseCode, HandlerExtractors>,
|
4441 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpResponseCode, HandlerExtractors>,
|
4359 4442 |
|
4360 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4443 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4361 4444 | RestJson<L>,
|
4362 4445 | crate::operation_shape::HttpResponseCode,
|
4363 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpResponseCode, HandlerType>
|
4446 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpResponseCode, HandlerType>
|
4364 4447 | >,
|
4365 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4448 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4366 4449 | RestJson<L>,
|
4367 4450 | crate::operation_shape::HttpResponseCode,
|
4368 4451 | ModelPl::Output
|
4369 4452 | >,
|
4370 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4453 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4371 4454 | RestJson<L>,
|
4372 4455 | crate::operation_shape::HttpResponseCode,
|
4373 4456 | <
|
4374 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4375 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4457 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4458 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4376 4459 | RestJson<L>,
|
4377 4460 | crate::operation_shape::HttpResponseCode,
|
4378 4461 | ModelPl::Output
|
4379 4462 | >
|
4380 4463 | >::Output
|
4381 4464 | >,
|
4382 4465 |
|
4383 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4466 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4384 4467 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4385 4468 |
|
4386 4469 | {
|
4387 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4388 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4470 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4471 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4389 4472 | let svc = crate::operation_shape::HttpResponseCode::from_handler(handler);
|
4390 4473 | let svc = self.model_plugin.apply(svc);
|
4391 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4474 + | let svc =
|
4475 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4392 4476 | .apply(svc);
|
4393 4477 | let svc = self.http_plugin.apply(svc);
|
4394 4478 | self.http_response_code_custom(svc)
|
4395 4479 | }
|
4396 4480 |
|
4397 4481 | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) operation.
|
4398 4482 | ///
|
4399 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4400 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4483 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4484 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4401 4485 | ///
|
4402 4486 | /// # Example
|
4403 4487 | ///
|
4404 4488 | /// ```no_run
|
4405 4489 | /// use rest_json::{RestJson, RestJsonConfig};
|
4406 4490 | ///
|
4407 4491 | /// use rest_json::{input, output, error};
|
4408 4492 | ///
|
4409 4493 | /// async fn handler(input: input::HttpResponseCodeInput) -> Result<output::HttpResponseCodeOutput, error::HttpResponseCodeError> {
|
4410 4494 | /// todo!()
|
4411 4495 | /// }
|
4412 4496 | ///
|
4413 4497 | /// let config = RestJsonConfig::builder().build();
|
4414 4498 | /// let svc = ::tower::util::service_fn(handler);
|
4415 4499 | /// let app = RestJson::builder(config)
|
4416 4500 | /// .http_response_code_service(svc)
|
4417 4501 | /// /* Set other handlers */
|
4418 4502 | /// .build()
|
4419 4503 | /// .unwrap();
|
4420 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4504 + | /// # 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;
|
4421 4505 | /// ```
|
4422 4506 | ///
|
4423 4507 | pub fn http_response_code_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4424 4508 | where
|
4425 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpResponseCode, ServiceExtractors>,
|
4509 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpResponseCode, ServiceExtractors>,
|
4426 4510 |
|
4427 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4511 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4428 4512 | RestJson<L>,
|
4429 4513 | crate::operation_shape::HttpResponseCode,
|
4430 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpResponseCode, S>
|
4514 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpResponseCode, S>
|
4431 4515 | >,
|
4432 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4516 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4433 4517 | RestJson<L>,
|
4434 4518 | crate::operation_shape::HttpResponseCode,
|
4435 4519 | ModelPl::Output
|
4436 4520 | >,
|
4437 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4521 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4438 4522 | RestJson<L>,
|
4439 4523 | crate::operation_shape::HttpResponseCode,
|
4440 4524 | <
|
4441 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4442 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4525 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4526 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4443 4527 | RestJson<L>,
|
4444 4528 | crate::operation_shape::HttpResponseCode,
|
4445 4529 | ModelPl::Output
|
4446 4530 | >
|
4447 4531 | >::Output
|
4448 4532 | >,
|
4449 4533 |
|
4450 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4534 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4451 4535 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4452 4536 |
|
4453 4537 | {
|
4454 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4455 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4538 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4539 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4456 4540 | let svc = crate::operation_shape::HttpResponseCode::from_service(service);
|
4457 4541 | let svc = self.model_plugin.apply(svc);
|
4458 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4542 + | let svc =
|
4543 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4459 4544 | .apply(svc);
|
4460 4545 | let svc = self.http_plugin.apply(svc);
|
4461 4546 | self.http_response_code_custom(svc)
|
4462 4547 | }
|
4463 4548 |
|
4464 4549 | /// Sets the [`HttpResponseCode`](crate::operation_shape::HttpResponseCode) to a custom [`Service`](tower::Service).
|
4465 4550 | /// not constrained by the Smithy contract.
|
4466 4551 | fn http_response_code_custom<S>(mut self, svc: S) -> Self
|
4467 4552 | where
|
4468 4553 | S: ::tower::Service<
|
4469 4554 | ::http::Request<Body>,
|
4470 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4555 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4471 4556 | Error = ::std::convert::Infallible,
|
4472 4557 | > + Clone
|
4473 4558 | + Send
|
4474 4559 | + 'static,
|
4475 4560 | S::Future: Send + 'static,
|
4476 4561 | {
|
4477 - | self.http_response_code = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4562 + | self.http_response_code = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4478 4563 | self
|
4479 4564 | }
|
4480 4565 |
|
4481 4566 | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
4482 4567 | ///
|
4483 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4484 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4568 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4569 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4485 4570 | ///
|
4486 4571 | /// # Example
|
4487 4572 | ///
|
4488 4573 | /// ```no_run
|
4489 4574 | /// use rest_json::{RestJson, RestJsonConfig};
|
4490 4575 | ///
|
4491 4576 | /// use rest_json::{input, output, error};
|
4492 4577 | ///
|
4493 4578 | /// async fn handler(input: input::HttpStringPayloadInput) -> Result<output::HttpStringPayloadOutput, error::HttpStringPayloadError> {
|
4494 4579 | /// todo!()
|
4495 4580 | /// }
|
4496 4581 | ///
|
4497 4582 | /// let config = RestJsonConfig::builder().build();
|
4498 4583 | /// let app = RestJson::builder(config)
|
4499 4584 | /// .http_string_payload(handler)
|
4500 4585 | /// /* Set other handlers */
|
4501 4586 | /// .build()
|
4502 4587 | /// .unwrap();
|
4503 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4588 + | /// # 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;
|
4504 4589 | /// ```
|
4505 4590 | ///
|
4506 4591 | pub fn http_string_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4507 4592 | where
|
4508 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::HttpStringPayload, HandlerExtractors>,
|
4593 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::HttpStringPayload, HandlerExtractors>,
|
4509 4594 |
|
4510 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4595 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4511 4596 | RestJson<L>,
|
4512 4597 | crate::operation_shape::HttpStringPayload,
|
4513 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::HttpStringPayload, HandlerType>
|
4598 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::HttpStringPayload, HandlerType>
|
4514 4599 | >,
|
4515 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4600 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4516 4601 | RestJson<L>,
|
4517 4602 | crate::operation_shape::HttpStringPayload,
|
4518 4603 | ModelPl::Output
|
4519 4604 | >,
|
4520 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4605 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4521 4606 | RestJson<L>,
|
4522 4607 | crate::operation_shape::HttpStringPayload,
|
4523 4608 | <
|
4524 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4525 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4609 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4610 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4526 4611 | RestJson<L>,
|
4527 4612 | crate::operation_shape::HttpStringPayload,
|
4528 4613 | ModelPl::Output
|
4529 4614 | >
|
4530 4615 | >::Output
|
4531 4616 | >,
|
4532 4617 |
|
4533 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4618 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4534 4619 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4535 4620 |
|
4536 4621 | {
|
4537 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4538 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4622 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4623 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4539 4624 | let svc = crate::operation_shape::HttpStringPayload::from_handler(handler);
|
4540 4625 | let svc = self.model_plugin.apply(svc);
|
4541 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4626 + | let svc =
|
4627 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4542 4628 | .apply(svc);
|
4543 4629 | let svc = self.http_plugin.apply(svc);
|
4544 4630 | self.http_string_payload_custom(svc)
|
4545 4631 | }
|
4546 4632 |
|
4547 4633 | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) operation.
|
4548 4634 | ///
|
4549 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4550 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4635 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4636 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4551 4637 | ///
|
4552 4638 | /// # Example
|
4553 4639 | ///
|
4554 4640 | /// ```no_run
|
4555 4641 | /// use rest_json::{RestJson, RestJsonConfig};
|
4556 4642 | ///
|
4557 4643 | /// use rest_json::{input, output, error};
|
4558 4644 | ///
|
4559 4645 | /// async fn handler(input: input::HttpStringPayloadInput) -> Result<output::HttpStringPayloadOutput, error::HttpStringPayloadError> {
|
4560 4646 | /// todo!()
|
4561 4647 | /// }
|
4562 4648 | ///
|
4563 4649 | /// let config = RestJsonConfig::builder().build();
|
4564 4650 | /// let svc = ::tower::util::service_fn(handler);
|
4565 4651 | /// let app = RestJson::builder(config)
|
4566 4652 | /// .http_string_payload_service(svc)
|
4567 4653 | /// /* Set other handlers */
|
4568 4654 | /// .build()
|
4569 4655 | /// .unwrap();
|
4570 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4656 + | /// # 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;
|
4571 4657 | /// ```
|
4572 4658 | ///
|
4573 4659 | pub fn http_string_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4574 4660 | where
|
4575 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::HttpStringPayload, ServiceExtractors>,
|
4661 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::HttpStringPayload, ServiceExtractors>,
|
4576 4662 |
|
4577 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4663 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4578 4664 | RestJson<L>,
|
4579 4665 | crate::operation_shape::HttpStringPayload,
|
4580 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::HttpStringPayload, S>
|
4666 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::HttpStringPayload, S>
|
4581 4667 | >,
|
4582 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4668 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4583 4669 | RestJson<L>,
|
4584 4670 | crate::operation_shape::HttpStringPayload,
|
4585 4671 | ModelPl::Output
|
4586 4672 | >,
|
4587 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4673 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4588 4674 | RestJson<L>,
|
4589 4675 | crate::operation_shape::HttpStringPayload,
|
4590 4676 | <
|
4591 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4592 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4677 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4678 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4593 4679 | RestJson<L>,
|
4594 4680 | crate::operation_shape::HttpStringPayload,
|
4595 4681 | ModelPl::Output
|
4596 4682 | >
|
4597 4683 | >::Output
|
4598 4684 | >,
|
4599 4685 |
|
4600 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4686 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4601 4687 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4602 4688 |
|
4603 4689 | {
|
4604 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4605 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4690 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4691 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4606 4692 | let svc = crate::operation_shape::HttpStringPayload::from_service(service);
|
4607 4693 | let svc = self.model_plugin.apply(svc);
|
4608 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4694 + | let svc =
|
4695 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4609 4696 | .apply(svc);
|
4610 4697 | let svc = self.http_plugin.apply(svc);
|
4611 4698 | self.http_string_payload_custom(svc)
|
4612 4699 | }
|
4613 4700 |
|
4614 4701 | /// Sets the [`HttpStringPayload`](crate::operation_shape::HttpStringPayload) to a custom [`Service`](tower::Service).
|
4615 4702 | /// not constrained by the Smithy contract.
|
4616 4703 | fn http_string_payload_custom<S>(mut self, svc: S) -> Self
|
4617 4704 | where
|
4618 4705 | S: ::tower::Service<
|
4619 4706 | ::http::Request<Body>,
|
4620 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4707 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4621 4708 | Error = ::std::convert::Infallible,
|
4622 4709 | > + Clone
|
4623 4710 | + Send
|
4624 4711 | + 'static,
|
4625 4712 | S::Future: Send + 'static,
|
4626 4713 | {
|
4627 - | self.http_string_payload = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4714 + | self.http_string_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4628 4715 | self
|
4629 4716 | }
|
4630 4717 |
|
4631 4718 | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
4632 4719 | ///
|
4633 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4634 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4720 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4721 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4635 4722 | ///
|
4636 4723 | /// # Example
|
4637 4724 | ///
|
4638 4725 | /// ```no_run
|
4639 4726 | /// use rest_json::{RestJson, RestJsonConfig};
|
4640 4727 | ///
|
4641 4728 | /// use rest_json::{input, output, error};
|
4642 4729 | ///
|
4643 4730 | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> Result<output::IgnoreQueryParamsInResponseOutput, error::IgnoreQueryParamsInResponseError> {
|
4644 4731 | /// todo!()
|
4645 4732 | /// }
|
4646 4733 | ///
|
4647 4734 | /// let config = RestJsonConfig::builder().build();
|
4648 4735 | /// let app = RestJson::builder(config)
|
4649 4736 | /// .ignore_query_params_in_response(handler)
|
4650 4737 | /// /* Set other handlers */
|
4651 4738 | /// .build()
|
4652 4739 | /// .unwrap();
|
4653 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4740 + | /// # 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;
|
4654 4741 | /// ```
|
4655 4742 | ///
|
4656 4743 | pub fn ignore_query_params_in_response<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4657 4744 | where
|
4658 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerExtractors>,
|
4745 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerExtractors>,
|
4659 4746 |
|
4660 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4747 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4661 4748 | RestJson<L>,
|
4662 4749 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4663 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerType>
|
4750 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::IgnoreQueryParamsInResponse, HandlerType>
|
4664 4751 | >,
|
4665 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4752 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4666 4753 | RestJson<L>,
|
4667 4754 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4668 4755 | ModelPl::Output
|
4669 4756 | >,
|
4670 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4757 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4671 4758 | RestJson<L>,
|
4672 4759 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4673 4760 | <
|
4674 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4675 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4761 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4762 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4676 4763 | RestJson<L>,
|
4677 4764 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4678 4765 | ModelPl::Output
|
4679 4766 | >
|
4680 4767 | >::Output
|
4681 4768 | >,
|
4682 4769 |
|
4683 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4770 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4684 4771 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4685 4772 |
|
4686 4773 | {
|
4687 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4688 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4774 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4775 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4689 4776 | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_handler(handler);
|
4690 4777 | let svc = self.model_plugin.apply(svc);
|
4691 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4778 + | let svc =
|
4779 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4692 4780 | .apply(svc);
|
4693 4781 | let svc = self.http_plugin.apply(svc);
|
4694 4782 | self.ignore_query_params_in_response_custom(svc)
|
4695 4783 | }
|
4696 4784 |
|
4697 4785 | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) operation.
|
4698 4786 | ///
|
4699 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4700 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4787 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4788 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4701 4789 | ///
|
4702 4790 | /// # Example
|
4703 4791 | ///
|
4704 4792 | /// ```no_run
|
4705 4793 | /// use rest_json::{RestJson, RestJsonConfig};
|
4706 4794 | ///
|
4707 4795 | /// use rest_json::{input, output, error};
|
4708 4796 | ///
|
4709 4797 | /// async fn handler(input: input::IgnoreQueryParamsInResponseInput) -> Result<output::IgnoreQueryParamsInResponseOutput, error::IgnoreQueryParamsInResponseError> {
|
4710 4798 | /// todo!()
|
4711 4799 | /// }
|
4712 4800 | ///
|
4713 4801 | /// let config = RestJsonConfig::builder().build();
|
4714 4802 | /// let svc = ::tower::util::service_fn(handler);
|
4715 4803 | /// let app = RestJson::builder(config)
|
4716 4804 | /// .ignore_query_params_in_response_service(svc)
|
4717 4805 | /// /* Set other handlers */
|
4718 4806 | /// .build()
|
4719 4807 | /// .unwrap();
|
4720 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4808 + | /// # 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;
|
4721 4809 | /// ```
|
4722 4810 | ///
|
4723 4811 | pub fn ignore_query_params_in_response_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4724 4812 | where
|
4725 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::IgnoreQueryParamsInResponse, ServiceExtractors>,
|
4813 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::IgnoreQueryParamsInResponse, ServiceExtractors>,
|
4726 4814 |
|
4727 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4815 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4728 4816 | RestJson<L>,
|
4729 4817 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4730 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::IgnoreQueryParamsInResponse, S>
|
4818 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::IgnoreQueryParamsInResponse, S>
|
4731 4819 | >,
|
4732 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4820 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4733 4821 | RestJson<L>,
|
4734 4822 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4735 4823 | ModelPl::Output
|
4736 4824 | >,
|
4737 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4825 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4738 4826 | RestJson<L>,
|
4739 4827 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4740 4828 | <
|
4741 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4742 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4829 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4830 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4743 4831 | RestJson<L>,
|
4744 4832 | crate::operation_shape::IgnoreQueryParamsInResponse,
|
4745 4833 | ModelPl::Output
|
4746 4834 | >
|
4747 4835 | >::Output
|
4748 4836 | >,
|
4749 4837 |
|
4750 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4838 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4751 4839 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4752 4840 |
|
4753 4841 | {
|
4754 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4755 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4842 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4843 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4756 4844 | let svc = crate::operation_shape::IgnoreQueryParamsInResponse::from_service(service);
|
4757 4845 | let svc = self.model_plugin.apply(svc);
|
4758 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4846 + | let svc =
|
4847 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4759 4848 | .apply(svc);
|
4760 4849 | let svc = self.http_plugin.apply(svc);
|
4761 4850 | self.ignore_query_params_in_response_custom(svc)
|
4762 4851 | }
|
4763 4852 |
|
4764 4853 | /// Sets the [`IgnoreQueryParamsInResponse`](crate::operation_shape::IgnoreQueryParamsInResponse) to a custom [`Service`](tower::Service).
|
4765 4854 | /// not constrained by the Smithy contract.
|
4766 4855 | fn ignore_query_params_in_response_custom<S>(mut self, svc: S) -> Self
|
4767 4856 | where
|
4768 4857 | S: ::tower::Service<
|
4769 4858 | ::http::Request<Body>,
|
4770 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
4859 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4771 4860 | Error = ::std::convert::Infallible,
|
4772 4861 | > + Clone
|
4773 4862 | + Send
|
4774 4863 | + 'static,
|
4775 4864 | S::Future: Send + 'static,
|
4776 4865 | {
|
4777 4866 | self.ignore_query_params_in_response =
|
4778 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
4867 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4779 4868 | self
|
4780 4869 | }
|
4781 4870 |
|
4782 4871 | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
4783 4872 | ///
|
4784 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4785 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4873 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4874 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4786 4875 | ///
|
4787 4876 | /// # Example
|
4788 4877 | ///
|
4789 4878 | /// ```no_run
|
4790 4879 | /// use rest_json::{RestJson, RestJsonConfig};
|
4791 4880 | ///
|
4792 4881 | /// use rest_json::{input, output, error};
|
4793 4882 | ///
|
4794 4883 | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
4795 4884 | /// todo!()
|
4796 4885 | /// }
|
4797 4886 | ///
|
4798 4887 | /// let config = RestJsonConfig::builder().build();
|
4799 4888 | /// let app = RestJson::builder(config)
|
4800 4889 | /// .input_and_output_with_headers(handler)
|
4801 4890 | /// /* Set other handlers */
|
4802 4891 | /// .build()
|
4803 4892 | /// .unwrap();
|
4804 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4893 + | /// # 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;
|
4805 4894 | /// ```
|
4806 4895 | ///
|
4807 4896 | pub fn input_and_output_with_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4808 4897 | where
|
4809 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::InputAndOutputWithHeaders, HandlerExtractors>,
|
4898 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::InputAndOutputWithHeaders, HandlerExtractors>,
|
4810 4899 |
|
4811 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4900 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4812 4901 | RestJson<L>,
|
4813 4902 | crate::operation_shape::InputAndOutputWithHeaders,
|
4814 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::InputAndOutputWithHeaders, HandlerType>
|
4903 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::InputAndOutputWithHeaders, HandlerType>
|
4815 4904 | >,
|
4816 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4905 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4817 4906 | RestJson<L>,
|
4818 4907 | crate::operation_shape::InputAndOutputWithHeaders,
|
4819 4908 | ModelPl::Output
|
4820 4909 | >,
|
4821 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4910 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4822 4911 | RestJson<L>,
|
4823 4912 | crate::operation_shape::InputAndOutputWithHeaders,
|
4824 4913 | <
|
4825 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4826 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4914 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4915 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4827 4916 | RestJson<L>,
|
4828 4917 | crate::operation_shape::InputAndOutputWithHeaders,
|
4829 4918 | ModelPl::Output
|
4830 4919 | >
|
4831 4920 | >::Output
|
4832 4921 | >,
|
4833 4922 |
|
4834 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4923 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4835 4924 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4836 4925 |
|
4837 4926 | {
|
4838 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4839 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4927 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4928 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4840 4929 | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_handler(handler);
|
4841 4930 | let svc = self.model_plugin.apply(svc);
|
4842 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4931 + | let svc =
|
4932 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4843 4933 | .apply(svc);
|
4844 4934 | let svc = self.http_plugin.apply(svc);
|
4845 4935 | self.input_and_output_with_headers_custom(svc)
|
4846 4936 | }
|
4847 4937 |
|
4848 4938 | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) operation.
|
4849 4939 | ///
|
4850 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4851 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
4940 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
4941 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4852 4942 | ///
|
4853 4943 | /// # Example
|
4854 4944 | ///
|
4855 4945 | /// ```no_run
|
4856 4946 | /// use rest_json::{RestJson, RestJsonConfig};
|
4857 4947 | ///
|
4858 4948 | /// use rest_json::{input, output, error};
|
4859 4949 | ///
|
4860 4950 | /// async fn handler(input: input::InputAndOutputWithHeadersInput) -> Result<output::InputAndOutputWithHeadersOutput, error::InputAndOutputWithHeadersError> {
|
4861 4951 | /// todo!()
|
4862 4952 | /// }
|
4863 4953 | ///
|
4864 4954 | /// let config = RestJsonConfig::builder().build();
|
4865 4955 | /// let svc = ::tower::util::service_fn(handler);
|
4866 4956 | /// let app = RestJson::builder(config)
|
4867 4957 | /// .input_and_output_with_headers_service(svc)
|
4868 4958 | /// /* Set other handlers */
|
4869 4959 | /// .build()
|
4870 4960 | /// .unwrap();
|
4871 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
4961 + | /// # 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;
|
4872 4962 | /// ```
|
4873 4963 | ///
|
4874 4964 | pub fn input_and_output_with_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
4875 4965 | where
|
4876 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::InputAndOutputWithHeaders, ServiceExtractors>,
|
4966 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::InputAndOutputWithHeaders, ServiceExtractors>,
|
4877 4967 |
|
4878 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
4968 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4879 4969 | RestJson<L>,
|
4880 4970 | crate::operation_shape::InputAndOutputWithHeaders,
|
4881 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::InputAndOutputWithHeaders, S>
|
4971 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::InputAndOutputWithHeaders, S>
|
4882 4972 | >,
|
4883 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
4973 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4884 4974 | RestJson<L>,
|
4885 4975 | crate::operation_shape::InputAndOutputWithHeaders,
|
4886 4976 | ModelPl::Output
|
4887 4977 | >,
|
4888 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
4978 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4889 4979 | RestJson<L>,
|
4890 4980 | crate::operation_shape::InputAndOutputWithHeaders,
|
4891 4981 | <
|
4892 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4893 - | as ::aws_smithy_http_server::plugin::Plugin<
|
4982 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4983 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4894 4984 | RestJson<L>,
|
4895 4985 | crate::operation_shape::InputAndOutputWithHeaders,
|
4896 4986 | ModelPl::Output
|
4897 4987 | >
|
4898 4988 | >::Output
|
4899 4989 | >,
|
4900 4990 |
|
4901 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4991 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4902 4992 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4903 4993 |
|
4904 4994 | {
|
4905 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4906 - | use ::aws_smithy_http_server::plugin::Plugin;
|
4995 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
4996 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4907 4997 | let svc = crate::operation_shape::InputAndOutputWithHeaders::from_service(service);
|
4908 4998 | let svc = self.model_plugin.apply(svc);
|
4909 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4999 + | let svc =
|
5000 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4910 5001 | .apply(svc);
|
4911 5002 | let svc = self.http_plugin.apply(svc);
|
4912 5003 | self.input_and_output_with_headers_custom(svc)
|
4913 5004 | }
|
4914 5005 |
|
4915 5006 | /// Sets the [`InputAndOutputWithHeaders`](crate::operation_shape::InputAndOutputWithHeaders) to a custom [`Service`](tower::Service).
|
4916 5007 | /// not constrained by the Smithy contract.
|
4917 5008 | fn input_and_output_with_headers_custom<S>(mut self, svc: S) -> Self
|
4918 5009 | where
|
4919 5010 | S: ::tower::Service<
|
4920 5011 | ::http::Request<Body>,
|
4921 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5012 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
4922 5013 | Error = ::std::convert::Infallible,
|
4923 5014 | > + Clone
|
4924 5015 | + Send
|
4925 5016 | + 'static,
|
4926 5017 | S::Future: Send + 'static,
|
4927 5018 | {
|
4928 5019 | self.input_and_output_with_headers =
|
4929 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5020 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
4930 5021 | self
|
4931 5022 | }
|
4932 5023 |
|
4933 5024 | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
4934 5025 | ///
|
4935 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
4936 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5026 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5027 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
4937 5028 | ///
|
4938 5029 | /// # Example
|
4939 5030 | ///
|
4940 5031 | /// ```no_run
|
4941 5032 | /// use rest_json::{RestJson, RestJsonConfig};
|
4942 5033 | ///
|
4943 5034 | /// use rest_json::{input, output, error};
|
4944 5035 | ///
|
4945 5036 | /// async fn handler(input: input::JsonBlobsInput) -> Result<output::JsonBlobsOutput, error::JsonBlobsError> {
|
4946 5037 | /// todo!()
|
4947 5038 | /// }
|
4948 5039 | ///
|
4949 5040 | /// let config = RestJsonConfig::builder().build();
|
4950 5041 | /// let app = RestJson::builder(config)
|
4951 5042 | /// .json_blobs(handler)
|
4952 5043 | /// /* Set other handlers */
|
4953 5044 | /// .build()
|
4954 5045 | /// .unwrap();
|
4955 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5046 + | /// # 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;
|
4956 5047 | /// ```
|
4957 5048 | ///
|
4958 5049 | pub fn json_blobs<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
4959 5050 | where
|
4960 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonBlobs, HandlerExtractors>,
|
5051 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonBlobs, HandlerExtractors>,
|
4961 5052 |
|
4962 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5053 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4963 5054 | RestJson<L>,
|
4964 5055 | crate::operation_shape::JsonBlobs,
|
4965 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonBlobs, HandlerType>
|
5056 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonBlobs, HandlerType>
|
4966 5057 | >,
|
4967 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5058 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4968 5059 | RestJson<L>,
|
4969 5060 | crate::operation_shape::JsonBlobs,
|
4970 5061 | ModelPl::Output
|
4971 5062 | >,
|
4972 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5063 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4973 5064 | RestJson<L>,
|
4974 5065 | crate::operation_shape::JsonBlobs,
|
4975 5066 | <
|
4976 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
4977 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5067 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5068 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
4978 5069 | RestJson<L>,
|
4979 5070 | crate::operation_shape::JsonBlobs,
|
4980 5071 | ModelPl::Output
|
4981 5072 | >
|
4982 5073 | >::Output
|
4983 5074 | >,
|
4984 5075 |
|
4985 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5076 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
4986 5077 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
4987 5078 |
|
4988 5079 | {
|
4989 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
4990 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5080 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5081 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
4991 5082 | let svc = crate::operation_shape::JsonBlobs::from_handler(handler);
|
4992 5083 | let svc = self.model_plugin.apply(svc);
|
4993 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5084 + | let svc =
|
5085 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
4994 5086 | .apply(svc);
|
4995 5087 | let svc = self.http_plugin.apply(svc);
|
4996 5088 | self.json_blobs_custom(svc)
|
4997 5089 | }
|
4998 5090 |
|
4999 5091 | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) operation.
|
5000 5092 | ///
|
5001 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5002 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5093 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5094 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5003 5095 | ///
|
5004 5096 | /// # Example
|
5005 5097 | ///
|
5006 5098 | /// ```no_run
|
5007 5099 | /// use rest_json::{RestJson, RestJsonConfig};
|
5008 5100 | ///
|
5009 5101 | /// use rest_json::{input, output, error};
|
5010 5102 | ///
|
5011 5103 | /// async fn handler(input: input::JsonBlobsInput) -> Result<output::JsonBlobsOutput, error::JsonBlobsError> {
|
5012 5104 | /// todo!()
|
5013 5105 | /// }
|
5014 5106 | ///
|
5015 5107 | /// let config = RestJsonConfig::builder().build();
|
5016 5108 | /// let svc = ::tower::util::service_fn(handler);
|
5017 5109 | /// let app = RestJson::builder(config)
|
5018 5110 | /// .json_blobs_service(svc)
|
5019 5111 | /// /* Set other handlers */
|
5020 5112 | /// .build()
|
5021 5113 | /// .unwrap();
|
5022 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5114 + | /// # 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;
|
5023 5115 | /// ```
|
5024 5116 | ///
|
5025 5117 | pub fn json_blobs_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5026 5118 | where
|
5027 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonBlobs, ServiceExtractors>,
|
5119 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonBlobs, ServiceExtractors>,
|
5028 5120 |
|
5029 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5121 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5030 5122 | RestJson<L>,
|
5031 5123 | crate::operation_shape::JsonBlobs,
|
5032 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonBlobs, S>
|
5124 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonBlobs, S>
|
5033 5125 | >,
|
5034 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5126 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5035 5127 | RestJson<L>,
|
5036 5128 | crate::operation_shape::JsonBlobs,
|
5037 5129 | ModelPl::Output
|
5038 5130 | >,
|
5039 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5131 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5040 5132 | RestJson<L>,
|
5041 5133 | crate::operation_shape::JsonBlobs,
|
5042 5134 | <
|
5043 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5044 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5135 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5136 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5045 5137 | RestJson<L>,
|
5046 5138 | crate::operation_shape::JsonBlobs,
|
5047 5139 | ModelPl::Output
|
5048 5140 | >
|
5049 5141 | >::Output
|
5050 5142 | >,
|
5051 5143 |
|
5052 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5144 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5053 5145 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5054 5146 |
|
5055 5147 | {
|
5056 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5057 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5148 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5149 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5058 5150 | let svc = crate::operation_shape::JsonBlobs::from_service(service);
|
5059 5151 | let svc = self.model_plugin.apply(svc);
|
5060 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5152 + | let svc =
|
5153 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5061 5154 | .apply(svc);
|
5062 5155 | let svc = self.http_plugin.apply(svc);
|
5063 5156 | self.json_blobs_custom(svc)
|
5064 5157 | }
|
5065 5158 |
|
5066 5159 | /// Sets the [`JsonBlobs`](crate::operation_shape::JsonBlobs) to a custom [`Service`](tower::Service).
|
5067 5160 | /// not constrained by the Smithy contract.
|
5068 5161 | fn json_blobs_custom<S>(mut self, svc: S) -> Self
|
5069 5162 | where
|
5070 5163 | S: ::tower::Service<
|
5071 5164 | ::http::Request<Body>,
|
5072 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5165 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5073 5166 | Error = ::std::convert::Infallible,
|
5074 5167 | > + Clone
|
5075 5168 | + Send
|
5076 5169 | + 'static,
|
5077 5170 | S::Future: Send + 'static,
|
5078 5171 | {
|
5079 - | self.json_blobs = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5172 + | self.json_blobs = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5080 5173 | self
|
5081 5174 | }
|
5082 5175 |
|
5083 5176 | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
5084 5177 | ///
|
5085 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5086 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5178 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5179 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5087 5180 | ///
|
5088 5181 | /// # Example
|
5089 5182 | ///
|
5090 5183 | /// ```no_run
|
5091 5184 | /// use rest_json::{RestJson, RestJsonConfig};
|
5092 5185 | ///
|
5093 5186 | /// use rest_json::{input, output, error};
|
5094 5187 | ///
|
5095 5188 | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
5096 5189 | /// todo!()
|
5097 5190 | /// }
|
5098 5191 | ///
|
5099 5192 | /// let config = RestJsonConfig::builder().build();
|
5100 5193 | /// let app = RestJson::builder(config)
|
5101 5194 | /// .json_enums(handler)
|
5102 5195 | /// /* Set other handlers */
|
5103 5196 | /// .build()
|
5104 5197 | /// .unwrap();
|
5105 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5198 + | /// # 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;
|
5106 5199 | /// ```
|
5107 5200 | ///
|
5108 5201 | pub fn json_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5109 5202 | where
|
5110 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonEnums, HandlerExtractors>,
|
5203 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonEnums, HandlerExtractors>,
|
5111 5204 |
|
5112 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5205 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5113 5206 | RestJson<L>,
|
5114 5207 | crate::operation_shape::JsonEnums,
|
5115 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonEnums, HandlerType>
|
5208 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonEnums, HandlerType>
|
5116 5209 | >,
|
5117 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5210 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5118 5211 | RestJson<L>,
|
5119 5212 | crate::operation_shape::JsonEnums,
|
5120 5213 | ModelPl::Output
|
5121 5214 | >,
|
5122 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5215 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5123 5216 | RestJson<L>,
|
5124 5217 | crate::operation_shape::JsonEnums,
|
5125 5218 | <
|
5126 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5127 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5219 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5220 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5128 5221 | RestJson<L>,
|
5129 5222 | crate::operation_shape::JsonEnums,
|
5130 5223 | ModelPl::Output
|
5131 5224 | >
|
5132 5225 | >::Output
|
5133 5226 | >,
|
5134 5227 |
|
5135 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5228 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5136 5229 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5137 5230 |
|
5138 5231 | {
|
5139 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5140 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5232 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5233 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5141 5234 | let svc = crate::operation_shape::JsonEnums::from_handler(handler);
|
5142 5235 | let svc = self.model_plugin.apply(svc);
|
5143 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5236 + | let svc =
|
5237 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5144 5238 | .apply(svc);
|
5145 5239 | let svc = self.http_plugin.apply(svc);
|
5146 5240 | self.json_enums_custom(svc)
|
5147 5241 | }
|
5148 5242 |
|
5149 5243 | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) operation.
|
5150 5244 | ///
|
5151 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5152 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5245 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5246 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5153 5247 | ///
|
5154 5248 | /// # Example
|
5155 5249 | ///
|
5156 5250 | /// ```no_run
|
5157 5251 | /// use rest_json::{RestJson, RestJsonConfig};
|
5158 5252 | ///
|
5159 5253 | /// use rest_json::{input, output, error};
|
5160 5254 | ///
|
5161 5255 | /// async fn handler(input: input::JsonEnumsInput) -> Result<output::JsonEnumsOutput, error::JsonEnumsError> {
|
5162 5256 | /// todo!()
|
5163 5257 | /// }
|
5164 5258 | ///
|
5165 5259 | /// let config = RestJsonConfig::builder().build();
|
5166 5260 | /// let svc = ::tower::util::service_fn(handler);
|
5167 5261 | /// let app = RestJson::builder(config)
|
5168 5262 | /// .json_enums_service(svc)
|
5169 5263 | /// /* Set other handlers */
|
5170 5264 | /// .build()
|
5171 5265 | /// .unwrap();
|
5172 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5266 + | /// # 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;
|
5173 5267 | /// ```
|
5174 5268 | ///
|
5175 5269 | pub fn json_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5176 5270 | where
|
5177 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonEnums, ServiceExtractors>,
|
5271 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonEnums, ServiceExtractors>,
|
5178 5272 |
|
5179 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5273 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5180 5274 | RestJson<L>,
|
5181 5275 | crate::operation_shape::JsonEnums,
|
5182 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonEnums, S>
|
5276 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonEnums, S>
|
5183 5277 | >,
|
5184 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5278 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5185 5279 | RestJson<L>,
|
5186 5280 | crate::operation_shape::JsonEnums,
|
5187 5281 | ModelPl::Output
|
5188 5282 | >,
|
5189 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5283 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5190 5284 | RestJson<L>,
|
5191 5285 | crate::operation_shape::JsonEnums,
|
5192 5286 | <
|
5193 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5194 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5287 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5288 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5195 5289 | RestJson<L>,
|
5196 5290 | crate::operation_shape::JsonEnums,
|
5197 5291 | ModelPl::Output
|
5198 5292 | >
|
5199 5293 | >::Output
|
5200 5294 | >,
|
5201 5295 |
|
5202 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5296 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5203 5297 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5204 5298 |
|
5205 5299 | {
|
5206 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5207 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5300 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5301 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5208 5302 | let svc = crate::operation_shape::JsonEnums::from_service(service);
|
5209 5303 | let svc = self.model_plugin.apply(svc);
|
5210 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5304 + | let svc =
|
5305 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5211 5306 | .apply(svc);
|
5212 5307 | let svc = self.http_plugin.apply(svc);
|
5213 5308 | self.json_enums_custom(svc)
|
5214 5309 | }
|
5215 5310 |
|
5216 5311 | /// Sets the [`JsonEnums`](crate::operation_shape::JsonEnums) to a custom [`Service`](tower::Service).
|
5217 5312 | /// not constrained by the Smithy contract.
|
5218 5313 | fn json_enums_custom<S>(mut self, svc: S) -> Self
|
5219 5314 | where
|
5220 5315 | S: ::tower::Service<
|
5221 5316 | ::http::Request<Body>,
|
5222 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5317 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5223 5318 | Error = ::std::convert::Infallible,
|
5224 5319 | > + Clone
|
5225 5320 | + Send
|
5226 5321 | + 'static,
|
5227 5322 | S::Future: Send + 'static,
|
5228 5323 | {
|
5229 - | self.json_enums = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5324 + | self.json_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5230 5325 | self
|
5231 5326 | }
|
5232 5327 |
|
5233 5328 | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
5234 5329 | ///
|
5235 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5236 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5330 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5331 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5237 5332 | ///
|
5238 5333 | /// # Example
|
5239 5334 | ///
|
5240 5335 | /// ```no_run
|
5241 5336 | /// use rest_json::{RestJson, RestJsonConfig};
|
5242 5337 | ///
|
5243 5338 | /// use rest_json::{input, output, error};
|
5244 5339 | ///
|
5245 5340 | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
5246 5341 | /// todo!()
|
5247 5342 | /// }
|
5248 5343 | ///
|
5249 5344 | /// let config = RestJsonConfig::builder().build();
|
5250 5345 | /// let app = RestJson::builder(config)
|
5251 5346 | /// .json_int_enums(handler)
|
5252 5347 | /// /* Set other handlers */
|
5253 5348 | /// .build()
|
5254 5349 | /// .unwrap();
|
5255 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5350 + | /// # 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;
|
5256 5351 | /// ```
|
5257 5352 | ///
|
5258 5353 | pub fn json_int_enums<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5259 5354 | where
|
5260 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonIntEnums, HandlerExtractors>,
|
5355 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonIntEnums, HandlerExtractors>,
|
5261 5356 |
|
5262 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5357 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5263 5358 | RestJson<L>,
|
5264 5359 | crate::operation_shape::JsonIntEnums,
|
5265 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonIntEnums, HandlerType>
|
5360 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonIntEnums, HandlerType>
|
5266 5361 | >,
|
5267 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5362 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5268 5363 | RestJson<L>,
|
5269 5364 | crate::operation_shape::JsonIntEnums,
|
5270 5365 | ModelPl::Output
|
5271 5366 | >,
|
5272 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5367 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5273 5368 | RestJson<L>,
|
5274 5369 | crate::operation_shape::JsonIntEnums,
|
5275 5370 | <
|
5276 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5277 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5371 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5372 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5278 5373 | RestJson<L>,
|
5279 5374 | crate::operation_shape::JsonIntEnums,
|
5280 5375 | ModelPl::Output
|
5281 5376 | >
|
5282 5377 | >::Output
|
5283 5378 | >,
|
5284 5379 |
|
5285 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5380 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5286 5381 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5287 5382 |
|
5288 5383 | {
|
5289 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5290 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5384 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5385 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5291 5386 | let svc = crate::operation_shape::JsonIntEnums::from_handler(handler);
|
5292 5387 | let svc = self.model_plugin.apply(svc);
|
5293 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5388 + | let svc =
|
5389 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5294 5390 | .apply(svc);
|
5295 5391 | let svc = self.http_plugin.apply(svc);
|
5296 5392 | self.json_int_enums_custom(svc)
|
5297 5393 | }
|
5298 5394 |
|
5299 5395 | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) operation.
|
5300 5396 | ///
|
5301 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5302 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5397 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5398 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5303 5399 | ///
|
5304 5400 | /// # Example
|
5305 5401 | ///
|
5306 5402 | /// ```no_run
|
5307 5403 | /// use rest_json::{RestJson, RestJsonConfig};
|
5308 5404 | ///
|
5309 5405 | /// use rest_json::{input, output, error};
|
5310 5406 | ///
|
5311 5407 | /// async fn handler(input: input::JsonIntEnumsInput) -> Result<output::JsonIntEnumsOutput, error::JsonIntEnumsError> {
|
5312 5408 | /// todo!()
|
5313 5409 | /// }
|
5314 5410 | ///
|
5315 5411 | /// let config = RestJsonConfig::builder().build();
|
5316 5412 | /// let svc = ::tower::util::service_fn(handler);
|
5317 5413 | /// let app = RestJson::builder(config)
|
5318 5414 | /// .json_int_enums_service(svc)
|
5319 5415 | /// /* Set other handlers */
|
5320 5416 | /// .build()
|
5321 5417 | /// .unwrap();
|
5322 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5418 + | /// # 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;
|
5323 5419 | /// ```
|
5324 5420 | ///
|
5325 5421 | pub fn json_int_enums_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5326 5422 | where
|
5327 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonIntEnums, ServiceExtractors>,
|
5423 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonIntEnums, ServiceExtractors>,
|
5328 5424 |
|
5329 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5425 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5330 5426 | RestJson<L>,
|
5331 5427 | crate::operation_shape::JsonIntEnums,
|
5332 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonIntEnums, S>
|
5428 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonIntEnums, S>
|
5333 5429 | >,
|
5334 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5430 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5335 5431 | RestJson<L>,
|
5336 5432 | crate::operation_shape::JsonIntEnums,
|
5337 5433 | ModelPl::Output
|
5338 5434 | >,
|
5339 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5435 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5340 5436 | RestJson<L>,
|
5341 5437 | crate::operation_shape::JsonIntEnums,
|
5342 5438 | <
|
5343 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5344 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5439 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5440 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5345 5441 | RestJson<L>,
|
5346 5442 | crate::operation_shape::JsonIntEnums,
|
5347 5443 | ModelPl::Output
|
5348 5444 | >
|
5349 5445 | >::Output
|
5350 5446 | >,
|
5351 5447 |
|
5352 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5448 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5353 5449 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5354 5450 |
|
5355 5451 | {
|
5356 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5357 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5452 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5453 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5358 5454 | let svc = crate::operation_shape::JsonIntEnums::from_service(service);
|
5359 5455 | let svc = self.model_plugin.apply(svc);
|
5360 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5456 + | let svc =
|
5457 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5361 5458 | .apply(svc);
|
5362 5459 | let svc = self.http_plugin.apply(svc);
|
5363 5460 | self.json_int_enums_custom(svc)
|
5364 5461 | }
|
5365 5462 |
|
5366 5463 | /// Sets the [`JsonIntEnums`](crate::operation_shape::JsonIntEnums) to a custom [`Service`](tower::Service).
|
5367 5464 | /// not constrained by the Smithy contract.
|
5368 5465 | fn json_int_enums_custom<S>(mut self, svc: S) -> Self
|
5369 5466 | where
|
5370 5467 | S: ::tower::Service<
|
5371 5468 | ::http::Request<Body>,
|
5372 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5469 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5373 5470 | Error = ::std::convert::Infallible,
|
5374 5471 | > + Clone
|
5375 5472 | + Send
|
5376 5473 | + 'static,
|
5377 5474 | S::Future: Send + 'static,
|
5378 5475 | {
|
5379 - | self.json_int_enums = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5476 + | self.json_int_enums = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5380 5477 | self
|
5381 5478 | }
|
5382 5479 |
|
5383 5480 | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
5384 5481 | ///
|
5385 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5386 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5482 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5483 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5387 5484 | ///
|
5388 5485 | /// # Example
|
5389 5486 | ///
|
5390 5487 | /// ```no_run
|
5391 5488 | /// use rest_json::{RestJson, RestJsonConfig};
|
5392 5489 | ///
|
5393 5490 | /// use rest_json::{input, output, error};
|
5394 5491 | ///
|
5395 5492 | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
5396 5493 | /// todo!()
|
5397 5494 | /// }
|
5398 5495 | ///
|
5399 5496 | /// let config = RestJsonConfig::builder().build();
|
5400 5497 | /// let app = RestJson::builder(config)
|
5401 5498 | /// .json_lists(handler)
|
5402 5499 | /// /* Set other handlers */
|
5403 5500 | /// .build()
|
5404 5501 | /// .unwrap();
|
5405 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5502 + | /// # 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;
|
5406 5503 | /// ```
|
5407 5504 | ///
|
5408 5505 | pub fn json_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5409 5506 | where
|
5410 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonLists, HandlerExtractors>,
|
5507 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonLists, HandlerExtractors>,
|
5411 5508 |
|
5412 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5509 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5413 5510 | RestJson<L>,
|
5414 5511 | crate::operation_shape::JsonLists,
|
5415 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonLists, HandlerType>
|
5512 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonLists, HandlerType>
|
5416 5513 | >,
|
5417 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5514 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5418 5515 | RestJson<L>,
|
5419 5516 | crate::operation_shape::JsonLists,
|
5420 5517 | ModelPl::Output
|
5421 5518 | >,
|
5422 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5519 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5423 5520 | RestJson<L>,
|
5424 5521 | crate::operation_shape::JsonLists,
|
5425 5522 | <
|
5426 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5427 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5523 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5524 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5428 5525 | RestJson<L>,
|
5429 5526 | crate::operation_shape::JsonLists,
|
5430 5527 | ModelPl::Output
|
5431 5528 | >
|
5432 5529 | >::Output
|
5433 5530 | >,
|
5434 5531 |
|
5435 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5532 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5436 5533 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5437 5534 |
|
5438 5535 | {
|
5439 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5440 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5536 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5537 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5441 5538 | let svc = crate::operation_shape::JsonLists::from_handler(handler);
|
5442 5539 | let svc = self.model_plugin.apply(svc);
|
5443 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5540 + | let svc =
|
5541 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5444 5542 | .apply(svc);
|
5445 5543 | let svc = self.http_plugin.apply(svc);
|
5446 5544 | self.json_lists_custom(svc)
|
5447 5545 | }
|
5448 5546 |
|
5449 5547 | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) operation.
|
5450 5548 | ///
|
5451 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5452 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5549 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5550 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5453 5551 | ///
|
5454 5552 | /// # Example
|
5455 5553 | ///
|
5456 5554 | /// ```no_run
|
5457 5555 | /// use rest_json::{RestJson, RestJsonConfig};
|
5458 5556 | ///
|
5459 5557 | /// use rest_json::{input, output, error};
|
5460 5558 | ///
|
5461 5559 | /// async fn handler(input: input::JsonListsInput) -> Result<output::JsonListsOutput, error::JsonListsError> {
|
5462 5560 | /// todo!()
|
5463 5561 | /// }
|
5464 5562 | ///
|
5465 5563 | /// let config = RestJsonConfig::builder().build();
|
5466 5564 | /// let svc = ::tower::util::service_fn(handler);
|
5467 5565 | /// let app = RestJson::builder(config)
|
5468 5566 | /// .json_lists_service(svc)
|
5469 5567 | /// /* Set other handlers */
|
5470 5568 | /// .build()
|
5471 5569 | /// .unwrap();
|
5472 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5570 + | /// # 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;
|
5473 5571 | /// ```
|
5474 5572 | ///
|
5475 5573 | pub fn json_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5476 5574 | where
|
5477 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonLists, ServiceExtractors>,
|
5575 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonLists, ServiceExtractors>,
|
5478 5576 |
|
5479 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5577 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5480 5578 | RestJson<L>,
|
5481 5579 | crate::operation_shape::JsonLists,
|
5482 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonLists, S>
|
5580 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonLists, S>
|
5483 5581 | >,
|
5484 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5582 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5485 5583 | RestJson<L>,
|
5486 5584 | crate::operation_shape::JsonLists,
|
5487 5585 | ModelPl::Output
|
5488 5586 | >,
|
5489 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5587 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5490 5588 | RestJson<L>,
|
5491 5589 | crate::operation_shape::JsonLists,
|
5492 5590 | <
|
5493 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5494 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5591 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5592 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5495 5593 | RestJson<L>,
|
5496 5594 | crate::operation_shape::JsonLists,
|
5497 5595 | ModelPl::Output
|
5498 5596 | >
|
5499 5597 | >::Output
|
5500 5598 | >,
|
5501 5599 |
|
5502 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5600 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5503 5601 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5504 5602 |
|
5505 5603 | {
|
5506 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5507 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5604 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5605 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5508 5606 | let svc = crate::operation_shape::JsonLists::from_service(service);
|
5509 5607 | let svc = self.model_plugin.apply(svc);
|
5510 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5608 + | let svc =
|
5609 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5511 5610 | .apply(svc);
|
5512 5611 | let svc = self.http_plugin.apply(svc);
|
5513 5612 | self.json_lists_custom(svc)
|
5514 5613 | }
|
5515 5614 |
|
5516 5615 | /// Sets the [`JsonLists`](crate::operation_shape::JsonLists) to a custom [`Service`](tower::Service).
|
5517 5616 | /// not constrained by the Smithy contract.
|
5518 5617 | fn json_lists_custom<S>(mut self, svc: S) -> Self
|
5519 5618 | where
|
5520 5619 | S: ::tower::Service<
|
5521 5620 | ::http::Request<Body>,
|
5522 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5621 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5523 5622 | Error = ::std::convert::Infallible,
|
5524 5623 | > + Clone
|
5525 5624 | + Send
|
5526 5625 | + 'static,
|
5527 5626 | S::Future: Send + 'static,
|
5528 5627 | {
|
5529 - | self.json_lists = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5628 + | self.json_lists = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5530 5629 | self
|
5531 5630 | }
|
5532 5631 |
|
5533 5632 | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
5534 5633 | ///
|
5535 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5536 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5634 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5635 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5537 5636 | ///
|
5538 5637 | /// # Example
|
5539 5638 | ///
|
5540 5639 | /// ```no_run
|
5541 5640 | /// use rest_json::{RestJson, RestJsonConfig};
|
5542 5641 | ///
|
5543 5642 | /// use rest_json::{input, output, error};
|
5544 5643 | ///
|
5545 5644 | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
5546 5645 | /// todo!()
|
5547 5646 | /// }
|
5548 5647 | ///
|
5549 5648 | /// let config = RestJsonConfig::builder().build();
|
5550 5649 | /// let app = RestJson::builder(config)
|
5551 5650 | /// .json_maps(handler)
|
5552 5651 | /// /* Set other handlers */
|
5553 5652 | /// .build()
|
5554 5653 | /// .unwrap();
|
5555 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5654 + | /// # 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;
|
5556 5655 | /// ```
|
5557 5656 | ///
|
5558 5657 | pub fn json_maps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5559 5658 | where
|
5560 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonMaps, HandlerExtractors>,
|
5659 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonMaps, HandlerExtractors>,
|
5561 5660 |
|
5562 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5661 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5563 5662 | RestJson<L>,
|
5564 5663 | crate::operation_shape::JsonMaps,
|
5565 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonMaps, HandlerType>
|
5664 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonMaps, HandlerType>
|
5566 5665 | >,
|
5567 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5666 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5568 5667 | RestJson<L>,
|
5569 5668 | crate::operation_shape::JsonMaps,
|
5570 5669 | ModelPl::Output
|
5571 5670 | >,
|
5572 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5671 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5573 5672 | RestJson<L>,
|
5574 5673 | crate::operation_shape::JsonMaps,
|
5575 5674 | <
|
5576 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5577 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5675 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5676 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5578 5677 | RestJson<L>,
|
5579 5678 | crate::operation_shape::JsonMaps,
|
5580 5679 | ModelPl::Output
|
5581 5680 | >
|
5582 5681 | >::Output
|
5583 5682 | >,
|
5584 5683 |
|
5585 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5684 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5586 5685 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5587 5686 |
|
5588 5687 | {
|
5589 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5590 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5688 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5689 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5591 5690 | let svc = crate::operation_shape::JsonMaps::from_handler(handler);
|
5592 5691 | let svc = self.model_plugin.apply(svc);
|
5593 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5692 + | let svc =
|
5693 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5594 5694 | .apply(svc);
|
5595 5695 | let svc = self.http_plugin.apply(svc);
|
5596 5696 | self.json_maps_custom(svc)
|
5597 5697 | }
|
5598 5698 |
|
5599 5699 | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) operation.
|
5600 5700 | ///
|
5601 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5602 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5701 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5702 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5603 5703 | ///
|
5604 5704 | /// # Example
|
5605 5705 | ///
|
5606 5706 | /// ```no_run
|
5607 5707 | /// use rest_json::{RestJson, RestJsonConfig};
|
5608 5708 | ///
|
5609 5709 | /// use rest_json::{input, output, error};
|
5610 5710 | ///
|
5611 5711 | /// async fn handler(input: input::JsonMapsInput) -> Result<output::JsonMapsOutput, error::JsonMapsError> {
|
5612 5712 | /// todo!()
|
5613 5713 | /// }
|
5614 5714 | ///
|
5615 5715 | /// let config = RestJsonConfig::builder().build();
|
5616 5716 | /// let svc = ::tower::util::service_fn(handler);
|
5617 5717 | /// let app = RestJson::builder(config)
|
5618 5718 | /// .json_maps_service(svc)
|
5619 5719 | /// /* Set other handlers */
|
5620 5720 | /// .build()
|
5621 5721 | /// .unwrap();
|
5622 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5722 + | /// # 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;
|
5623 5723 | /// ```
|
5624 5724 | ///
|
5625 5725 | pub fn json_maps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5626 5726 | where
|
5627 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonMaps, ServiceExtractors>,
|
5727 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonMaps, ServiceExtractors>,
|
5628 5728 |
|
5629 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5729 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5630 5730 | RestJson<L>,
|
5631 5731 | crate::operation_shape::JsonMaps,
|
5632 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonMaps, S>
|
5732 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonMaps, S>
|
5633 5733 | >,
|
5634 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5734 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5635 5735 | RestJson<L>,
|
5636 5736 | crate::operation_shape::JsonMaps,
|
5637 5737 | ModelPl::Output
|
5638 5738 | >,
|
5639 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5739 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5640 5740 | RestJson<L>,
|
5641 5741 | crate::operation_shape::JsonMaps,
|
5642 5742 | <
|
5643 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5644 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5743 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5744 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5645 5745 | RestJson<L>,
|
5646 5746 | crate::operation_shape::JsonMaps,
|
5647 5747 | ModelPl::Output
|
5648 5748 | >
|
5649 5749 | >::Output
|
5650 5750 | >,
|
5651 5751 |
|
5652 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5752 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5653 5753 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5654 5754 |
|
5655 5755 | {
|
5656 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5657 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5756 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5757 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5658 5758 | let svc = crate::operation_shape::JsonMaps::from_service(service);
|
5659 5759 | let svc = self.model_plugin.apply(svc);
|
5660 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5760 + | let svc =
|
5761 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5661 5762 | .apply(svc);
|
5662 5763 | let svc = self.http_plugin.apply(svc);
|
5663 5764 | self.json_maps_custom(svc)
|
5664 5765 | }
|
5665 5766 |
|
5666 5767 | /// Sets the [`JsonMaps`](crate::operation_shape::JsonMaps) to a custom [`Service`](tower::Service).
|
5667 5768 | /// not constrained by the Smithy contract.
|
5668 5769 | fn json_maps_custom<S>(mut self, svc: S) -> Self
|
5669 5770 | where
|
5670 5771 | S: ::tower::Service<
|
5671 5772 | ::http::Request<Body>,
|
5672 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5773 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5673 5774 | Error = ::std::convert::Infallible,
|
5674 5775 | > + Clone
|
5675 5776 | + Send
|
5676 5777 | + 'static,
|
5677 5778 | S::Future: Send + 'static,
|
5678 5779 | {
|
5679 - | self.json_maps = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5780 + | self.json_maps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5680 5781 | self
|
5681 5782 | }
|
5682 5783 |
|
5683 5784 | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
5684 5785 | ///
|
5685 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5686 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5786 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5787 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5687 5788 | ///
|
5688 5789 | /// # Example
|
5689 5790 | ///
|
5690 5791 | /// ```no_run
|
5691 5792 | /// use rest_json::{RestJson, RestJsonConfig};
|
5692 5793 | ///
|
5693 5794 | /// use rest_json::{input, output, error};
|
5694 5795 | ///
|
5695 5796 | /// async fn handler(input: input::JsonTimestampsInput) -> Result<output::JsonTimestampsOutput, error::JsonTimestampsError> {
|
5696 5797 | /// todo!()
|
5697 5798 | /// }
|
5698 5799 | ///
|
5699 5800 | /// let config = RestJsonConfig::builder().build();
|
5700 5801 | /// let app = RestJson::builder(config)
|
5701 5802 | /// .json_timestamps(handler)
|
5702 5803 | /// /* Set other handlers */
|
5703 5804 | /// .build()
|
5704 5805 | /// .unwrap();
|
5705 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5806 + | /// # 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;
|
5706 5807 | /// ```
|
5707 5808 | ///
|
5708 5809 | pub fn json_timestamps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5709 5810 | where
|
5710 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonTimestamps, HandlerExtractors>,
|
5811 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonTimestamps, HandlerExtractors>,
|
5711 5812 |
|
5712 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5813 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5713 5814 | RestJson<L>,
|
5714 5815 | crate::operation_shape::JsonTimestamps,
|
5715 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonTimestamps, HandlerType>
|
5816 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonTimestamps, HandlerType>
|
5716 5817 | >,
|
5717 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5818 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5718 5819 | RestJson<L>,
|
5719 5820 | crate::operation_shape::JsonTimestamps,
|
5720 5821 | ModelPl::Output
|
5721 5822 | >,
|
5722 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5823 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5723 5824 | RestJson<L>,
|
5724 5825 | crate::operation_shape::JsonTimestamps,
|
5725 5826 | <
|
5726 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5727 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5827 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5828 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5728 5829 | RestJson<L>,
|
5729 5830 | crate::operation_shape::JsonTimestamps,
|
5730 5831 | ModelPl::Output
|
5731 5832 | >
|
5732 5833 | >::Output
|
5733 5834 | >,
|
5734 5835 |
|
5735 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5836 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5736 5837 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5737 5838 |
|
5738 5839 | {
|
5739 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5740 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5840 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5841 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5741 5842 | let svc = crate::operation_shape::JsonTimestamps::from_handler(handler);
|
5742 5843 | let svc = self.model_plugin.apply(svc);
|
5743 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5844 + | let svc =
|
5845 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5744 5846 | .apply(svc);
|
5745 5847 | let svc = self.http_plugin.apply(svc);
|
5746 5848 | self.json_timestamps_custom(svc)
|
5747 5849 | }
|
5748 5850 |
|
5749 5851 | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) operation.
|
5750 5852 | ///
|
5751 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5752 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5853 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5854 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5753 5855 | ///
|
5754 5856 | /// # Example
|
5755 5857 | ///
|
5756 5858 | /// ```no_run
|
5757 5859 | /// use rest_json::{RestJson, RestJsonConfig};
|
5758 5860 | ///
|
5759 5861 | /// use rest_json::{input, output, error};
|
5760 5862 | ///
|
5761 5863 | /// async fn handler(input: input::JsonTimestampsInput) -> Result<output::JsonTimestampsOutput, error::JsonTimestampsError> {
|
5762 5864 | /// todo!()
|
5763 5865 | /// }
|
5764 5866 | ///
|
5765 5867 | /// let config = RestJsonConfig::builder().build();
|
5766 5868 | /// let svc = ::tower::util::service_fn(handler);
|
5767 5869 | /// let app = RestJson::builder(config)
|
5768 5870 | /// .json_timestamps_service(svc)
|
5769 5871 | /// /* Set other handlers */
|
5770 5872 | /// .build()
|
5771 5873 | /// .unwrap();
|
5772 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5874 + | /// # 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;
|
5773 5875 | /// ```
|
5774 5876 | ///
|
5775 5877 | pub fn json_timestamps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5776 5878 | where
|
5777 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonTimestamps, ServiceExtractors>,
|
5879 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonTimestamps, ServiceExtractors>,
|
5778 5880 |
|
5779 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5881 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5780 5882 | RestJson<L>,
|
5781 5883 | crate::operation_shape::JsonTimestamps,
|
5782 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonTimestamps, S>
|
5884 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonTimestamps, S>
|
5783 5885 | >,
|
5784 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5886 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5785 5887 | RestJson<L>,
|
5786 5888 | crate::operation_shape::JsonTimestamps,
|
5787 5889 | ModelPl::Output
|
5788 5890 | >,
|
5789 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5891 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5790 5892 | RestJson<L>,
|
5791 5893 | crate::operation_shape::JsonTimestamps,
|
5792 5894 | <
|
5793 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5794 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5895 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5896 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5795 5897 | RestJson<L>,
|
5796 5898 | crate::operation_shape::JsonTimestamps,
|
5797 5899 | ModelPl::Output
|
5798 5900 | >
|
5799 5901 | >::Output
|
5800 5902 | >,
|
5801 5903 |
|
5802 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5904 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5803 5905 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5804 5906 |
|
5805 5907 | {
|
5806 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5807 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5908 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5909 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5808 5910 | let svc = crate::operation_shape::JsonTimestamps::from_service(service);
|
5809 5911 | let svc = self.model_plugin.apply(svc);
|
5810 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5912 + | let svc =
|
5913 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5811 5914 | .apply(svc);
|
5812 5915 | let svc = self.http_plugin.apply(svc);
|
5813 5916 | self.json_timestamps_custom(svc)
|
5814 5917 | }
|
5815 5918 |
|
5816 5919 | /// Sets the [`JsonTimestamps`](crate::operation_shape::JsonTimestamps) to a custom [`Service`](tower::Service).
|
5817 5920 | /// not constrained by the Smithy contract.
|
5818 5921 | fn json_timestamps_custom<S>(mut self, svc: S) -> Self
|
5819 5922 | where
|
5820 5923 | S: ::tower::Service<
|
5821 5924 | ::http::Request<Body>,
|
5822 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
5925 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5823 5926 | Error = ::std::convert::Infallible,
|
5824 5927 | > + Clone
|
5825 5928 | + Send
|
5826 5929 | + 'static,
|
5827 5930 | S::Future: Send + 'static,
|
5828 5931 | {
|
5829 - | self.json_timestamps = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
5932 + | self.json_timestamps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5830 5933 | self
|
5831 5934 | }
|
5832 5935 |
|
5833 5936 | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
5834 5937 | ///
|
5835 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5836 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
5938 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
5939 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5837 5940 | ///
|
5838 5941 | /// # Example
|
5839 5942 | ///
|
5840 5943 | /// ```no_run
|
5841 5944 | /// use rest_json::{RestJson, RestJsonConfig};
|
5842 5945 | ///
|
5843 5946 | /// use rest_json::{input, output, error};
|
5844 5947 | ///
|
5845 5948 | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
5846 5949 | /// todo!()
|
5847 5950 | /// }
|
5848 5951 | ///
|
5849 5952 | /// let config = RestJsonConfig::builder().build();
|
5850 5953 | /// let app = RestJson::builder(config)
|
5851 5954 | /// .json_unions(handler)
|
5852 5955 | /// /* Set other handlers */
|
5853 5956 | /// .build()
|
5854 5957 | /// .unwrap();
|
5855 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
5958 + | /// # 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;
|
5856 5959 | /// ```
|
5857 5960 | ///
|
5858 5961 | pub fn json_unions<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
5859 5962 | where
|
5860 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::JsonUnions, HandlerExtractors>,
|
5963 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::JsonUnions, HandlerExtractors>,
|
5861 5964 |
|
5862 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
5965 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5863 5966 | RestJson<L>,
|
5864 5967 | crate::operation_shape::JsonUnions,
|
5865 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::JsonUnions, HandlerType>
|
5968 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::JsonUnions, HandlerType>
|
5866 5969 | >,
|
5867 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
5970 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5868 5971 | RestJson<L>,
|
5869 5972 | crate::operation_shape::JsonUnions,
|
5870 5973 | ModelPl::Output
|
5871 5974 | >,
|
5872 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
5975 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5873 5976 | RestJson<L>,
|
5874 5977 | crate::operation_shape::JsonUnions,
|
5875 5978 | <
|
5876 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5877 - | as ::aws_smithy_http_server::plugin::Plugin<
|
5979 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5980 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5878 5981 | RestJson<L>,
|
5879 5982 | crate::operation_shape::JsonUnions,
|
5880 5983 | ModelPl::Output
|
5881 5984 | >
|
5882 5985 | >::Output
|
5883 5986 | >,
|
5884 5987 |
|
5885 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5988 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5886 5989 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5887 5990 |
|
5888 5991 | {
|
5889 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5890 - | use ::aws_smithy_http_server::plugin::Plugin;
|
5992 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
5993 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5891 5994 | let svc = crate::operation_shape::JsonUnions::from_handler(handler);
|
5892 5995 | let svc = self.model_plugin.apply(svc);
|
5893 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5996 + | let svc =
|
5997 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5894 5998 | .apply(svc);
|
5895 5999 | let svc = self.http_plugin.apply(svc);
|
5896 6000 | self.json_unions_custom(svc)
|
5897 6001 | }
|
5898 6002 |
|
5899 6003 | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) operation.
|
5900 6004 | ///
|
5901 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5902 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6005 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6006 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5903 6007 | ///
|
5904 6008 | /// # Example
|
5905 6009 | ///
|
5906 6010 | /// ```no_run
|
5907 6011 | /// use rest_json::{RestJson, RestJsonConfig};
|
5908 6012 | ///
|
5909 6013 | /// use rest_json::{input, output, error};
|
5910 6014 | ///
|
5911 6015 | /// async fn handler(input: input::JsonUnionsInput) -> Result<output::JsonUnionsOutput, error::JsonUnionsError> {
|
5912 6016 | /// todo!()
|
5913 6017 | /// }
|
5914 6018 | ///
|
5915 6019 | /// let config = RestJsonConfig::builder().build();
|
5916 6020 | /// let svc = ::tower::util::service_fn(handler);
|
5917 6021 | /// let app = RestJson::builder(config)
|
5918 6022 | /// .json_unions_service(svc)
|
5919 6023 | /// /* Set other handlers */
|
5920 6024 | /// .build()
|
5921 6025 | /// .unwrap();
|
5922 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6026 + | /// # 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;
|
5923 6027 | /// ```
|
5924 6028 | ///
|
5925 6029 | pub fn json_unions_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
5926 6030 | where
|
5927 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::JsonUnions, ServiceExtractors>,
|
6031 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::JsonUnions, ServiceExtractors>,
|
5928 6032 |
|
5929 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6033 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5930 6034 | RestJson<L>,
|
5931 6035 | crate::operation_shape::JsonUnions,
|
5932 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::JsonUnions, S>
|
6036 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::JsonUnions, S>
|
5933 6037 | >,
|
5934 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6038 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5935 6039 | RestJson<L>,
|
5936 6040 | crate::operation_shape::JsonUnions,
|
5937 6041 | ModelPl::Output
|
5938 6042 | >,
|
5939 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6043 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5940 6044 | RestJson<L>,
|
5941 6045 | crate::operation_shape::JsonUnions,
|
5942 6046 | <
|
5943 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
5944 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6047 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6048 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
5945 6049 | RestJson<L>,
|
5946 6050 | crate::operation_shape::JsonUnions,
|
5947 6051 | ModelPl::Output
|
5948 6052 | >
|
5949 6053 | >::Output
|
5950 6054 | >,
|
5951 6055 |
|
5952 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6056 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
5953 6057 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
5954 6058 |
|
5955 6059 | {
|
5956 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
5957 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6060 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6061 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
5958 6062 | let svc = crate::operation_shape::JsonUnions::from_service(service);
|
5959 6063 | let svc = self.model_plugin.apply(svc);
|
5960 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6064 + | let svc =
|
6065 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
5961 6066 | .apply(svc);
|
5962 6067 | let svc = self.http_plugin.apply(svc);
|
5963 6068 | self.json_unions_custom(svc)
|
5964 6069 | }
|
5965 6070 |
|
5966 6071 | /// Sets the [`JsonUnions`](crate::operation_shape::JsonUnions) to a custom [`Service`](tower::Service).
|
5967 6072 | /// not constrained by the Smithy contract.
|
5968 6073 | fn json_unions_custom<S>(mut self, svc: S) -> Self
|
5969 6074 | where
|
5970 6075 | S: ::tower::Service<
|
5971 6076 | ::http::Request<Body>,
|
5972 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6077 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
5973 6078 | Error = ::std::convert::Infallible,
|
5974 6079 | > + Clone
|
5975 6080 | + Send
|
5976 6081 | + 'static,
|
5977 6082 | S::Future: Send + 'static,
|
5978 6083 | {
|
5979 - | self.json_unions = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6084 + | self.json_unions = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
5980 6085 | self
|
5981 6086 | }
|
5982 6087 |
|
5983 6088 | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
5984 6089 | ///
|
5985 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
5986 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6090 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6091 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
5987 6092 | ///
|
5988 6093 | /// # Example
|
5989 6094 | ///
|
5990 6095 | /// ```no_run
|
5991 6096 | /// use rest_json::{RestJson, RestJsonConfig};
|
5992 6097 | ///
|
5993 6098 | /// use rest_json::{input, output, error};
|
5994 6099 | ///
|
5995 6100 | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> Result<output::MalformedAcceptWithBodyOutput, error::MalformedAcceptWithBodyError> {
|
5996 6101 | /// todo!()
|
5997 6102 | /// }
|
5998 6103 | ///
|
5999 6104 | /// let config = RestJsonConfig::builder().build();
|
6000 6105 | /// let app = RestJson::builder(config)
|
6001 6106 | /// .malformed_accept_with_body(handler)
|
6002 6107 | /// /* Set other handlers */
|
6003 6108 | /// .build()
|
6004 6109 | /// .unwrap();
|
6005 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6110 + | /// # 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;
|
6006 6111 | /// ```
|
6007 6112 | ///
|
6008 6113 | pub fn malformed_accept_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6009 6114 | where
|
6010 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithBody, HandlerExtractors>,
|
6115 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithBody, HandlerExtractors>,
|
6011 6116 |
|
6012 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6117 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6013 6118 | RestJson<L>,
|
6014 6119 | crate::operation_shape::MalformedAcceptWithBody,
|
6015 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithBody, HandlerType>
|
6120 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithBody, HandlerType>
|
6016 6121 | >,
|
6017 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6122 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6018 6123 | RestJson<L>,
|
6019 6124 | crate::operation_shape::MalformedAcceptWithBody,
|
6020 6125 | ModelPl::Output
|
6021 6126 | >,
|
6022 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6127 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6023 6128 | RestJson<L>,
|
6024 6129 | crate::operation_shape::MalformedAcceptWithBody,
|
6025 6130 | <
|
6026 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6027 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6131 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6132 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6028 6133 | RestJson<L>,
|
6029 6134 | crate::operation_shape::MalformedAcceptWithBody,
|
6030 6135 | ModelPl::Output
|
6031 6136 | >
|
6032 6137 | >::Output
|
6033 6138 | >,
|
6034 6139 |
|
6035 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6140 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6036 6141 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6037 6142 |
|
6038 6143 | {
|
6039 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6040 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6144 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6145 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6041 6146 | let svc = crate::operation_shape::MalformedAcceptWithBody::from_handler(handler);
|
6042 6147 | let svc = self.model_plugin.apply(svc);
|
6043 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6148 + | let svc =
|
6149 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6044 6150 | .apply(svc);
|
6045 6151 | let svc = self.http_plugin.apply(svc);
|
6046 6152 | self.malformed_accept_with_body_custom(svc)
|
6047 6153 | }
|
6048 6154 |
|
6049 6155 | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) operation.
|
6050 6156 | ///
|
6051 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6052 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6157 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6158 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6053 6159 | ///
|
6054 6160 | /// # Example
|
6055 6161 | ///
|
6056 6162 | /// ```no_run
|
6057 6163 | /// use rest_json::{RestJson, RestJsonConfig};
|
6058 6164 | ///
|
6059 6165 | /// use rest_json::{input, output, error};
|
6060 6166 | ///
|
6061 6167 | /// async fn handler(input: input::MalformedAcceptWithBodyInput) -> Result<output::MalformedAcceptWithBodyOutput, error::MalformedAcceptWithBodyError> {
|
6062 6168 | /// todo!()
|
6063 6169 | /// }
|
6064 6170 | ///
|
6065 6171 | /// let config = RestJsonConfig::builder().build();
|
6066 6172 | /// let svc = ::tower::util::service_fn(handler);
|
6067 6173 | /// let app = RestJson::builder(config)
|
6068 6174 | /// .malformed_accept_with_body_service(svc)
|
6069 6175 | /// /* Set other handlers */
|
6070 6176 | /// .build()
|
6071 6177 | /// .unwrap();
|
6072 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6178 + | /// # 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;
|
6073 6179 | /// ```
|
6074 6180 | ///
|
6075 6181 | pub fn malformed_accept_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6076 6182 | where
|
6077 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithBody, ServiceExtractors>,
|
6183 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithBody, ServiceExtractors>,
|
6078 6184 |
|
6079 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6185 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6080 6186 | RestJson<L>,
|
6081 6187 | crate::operation_shape::MalformedAcceptWithBody,
|
6082 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithBody, S>
|
6188 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithBody, S>
|
6083 6189 | >,
|
6084 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6190 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6085 6191 | RestJson<L>,
|
6086 6192 | crate::operation_shape::MalformedAcceptWithBody,
|
6087 6193 | ModelPl::Output
|
6088 6194 | >,
|
6089 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6195 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6090 6196 | RestJson<L>,
|
6091 6197 | crate::operation_shape::MalformedAcceptWithBody,
|
6092 6198 | <
|
6093 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6094 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6199 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6200 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6095 6201 | RestJson<L>,
|
6096 6202 | crate::operation_shape::MalformedAcceptWithBody,
|
6097 6203 | ModelPl::Output
|
6098 6204 | >
|
6099 6205 | >::Output
|
6100 6206 | >,
|
6101 6207 |
|
6102 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6208 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6103 6209 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6104 6210 |
|
6105 6211 | {
|
6106 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6107 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6212 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6213 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6108 6214 | let svc = crate::operation_shape::MalformedAcceptWithBody::from_service(service);
|
6109 6215 | let svc = self.model_plugin.apply(svc);
|
6110 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6216 + | let svc =
|
6217 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6111 6218 | .apply(svc);
|
6112 6219 | let svc = self.http_plugin.apply(svc);
|
6113 6220 | self.malformed_accept_with_body_custom(svc)
|
6114 6221 | }
|
6115 6222 |
|
6116 6223 | /// Sets the [`MalformedAcceptWithBody`](crate::operation_shape::MalformedAcceptWithBody) to a custom [`Service`](tower::Service).
|
6117 6224 | /// not constrained by the Smithy contract.
|
6118 6225 | fn malformed_accept_with_body_custom<S>(mut self, svc: S) -> Self
|
6119 6226 | where
|
6120 6227 | S: ::tower::Service<
|
6121 6228 | ::http::Request<Body>,
|
6122 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6229 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6123 6230 | Error = ::std::convert::Infallible,
|
6124 6231 | > + Clone
|
6125 6232 | + Send
|
6126 6233 | + 'static,
|
6127 6234 | S::Future: Send + 'static,
|
6128 6235 | {
|
6129 - | self.malformed_accept_with_body = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6236 + | self.malformed_accept_with_body =
|
6237 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6130 6238 | self
|
6131 6239 | }
|
6132 6240 |
|
6133 6241 | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
6134 6242 | ///
|
6135 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6136 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6243 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6244 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6137 6245 | ///
|
6138 6246 | /// # Example
|
6139 6247 | ///
|
6140 6248 | /// ```no_run
|
6141 6249 | /// use rest_json::{RestJson, RestJsonConfig};
|
6142 6250 | ///
|
6143 6251 | /// use rest_json::{input, output, error};
|
6144 6252 | ///
|
6145 6253 | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> Result<output::MalformedAcceptWithGenericStringOutput, error::MalformedAcceptWithGenericStringError> {
|
6146 6254 | /// todo!()
|
6147 6255 | /// }
|
6148 6256 | ///
|
6149 6257 | /// let config = RestJsonConfig::builder().build();
|
6150 6258 | /// let app = RestJson::builder(config)
|
6151 6259 | /// .malformed_accept_with_generic_string(handler)
|
6152 6260 | /// /* Set other handlers */
|
6153 6261 | /// .build()
|
6154 6262 | /// .unwrap();
|
6155 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6263 + | /// # 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;
|
6156 6264 | /// ```
|
6157 6265 | ///
|
6158 6266 | pub fn malformed_accept_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6159 6267 | where
|
6160 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithGenericString, HandlerExtractors>,
|
6268 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithGenericString, HandlerExtractors>,
|
6161 6269 |
|
6162 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6270 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6163 6271 | RestJson<L>,
|
6164 6272 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6165 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithGenericString, HandlerType>
|
6273 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithGenericString, HandlerType>
|
6166 6274 | >,
|
6167 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6275 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6168 6276 | RestJson<L>,
|
6169 6277 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6170 6278 | ModelPl::Output
|
6171 6279 | >,
|
6172 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6280 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6173 6281 | RestJson<L>,
|
6174 6282 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6175 6283 | <
|
6176 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6177 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6284 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6285 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6178 6286 | RestJson<L>,
|
6179 6287 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6180 6288 | ModelPl::Output
|
6181 6289 | >
|
6182 6290 | >::Output
|
6183 6291 | >,
|
6184 6292 |
|
6185 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6293 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6186 6294 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6187 6295 |
|
6188 6296 | {
|
6189 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6190 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6297 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6298 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6191 6299 | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_handler(handler);
|
6192 6300 | let svc = self.model_plugin.apply(svc);
|
6193 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6301 + | let svc =
|
6302 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6194 6303 | .apply(svc);
|
6195 6304 | let svc = self.http_plugin.apply(svc);
|
6196 6305 | self.malformed_accept_with_generic_string_custom(svc)
|
6197 6306 | }
|
6198 6307 |
|
6199 6308 | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) operation.
|
6200 6309 | ///
|
6201 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6202 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6310 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6311 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6203 6312 | ///
|
6204 6313 | /// # Example
|
6205 6314 | ///
|
6206 6315 | /// ```no_run
|
6207 6316 | /// use rest_json::{RestJson, RestJsonConfig};
|
6208 6317 | ///
|
6209 6318 | /// use rest_json::{input, output, error};
|
6210 6319 | ///
|
6211 6320 | /// async fn handler(input: input::MalformedAcceptWithGenericStringInput) -> Result<output::MalformedAcceptWithGenericStringOutput, error::MalformedAcceptWithGenericStringError> {
|
6212 6321 | /// todo!()
|
6213 6322 | /// }
|
6214 6323 | ///
|
6215 6324 | /// let config = RestJsonConfig::builder().build();
|
6216 6325 | /// let svc = ::tower::util::service_fn(handler);
|
6217 6326 | /// let app = RestJson::builder(config)
|
6218 6327 | /// .malformed_accept_with_generic_string_service(svc)
|
6219 6328 | /// /* Set other handlers */
|
6220 6329 | /// .build()
|
6221 6330 | /// .unwrap();
|
6222 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6331 + | /// # 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;
|
6223 6332 | /// ```
|
6224 6333 | ///
|
6225 6334 | pub fn malformed_accept_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6226 6335 | where
|
6227 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithGenericString, ServiceExtractors>,
|
6336 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithGenericString, ServiceExtractors>,
|
6228 6337 |
|
6229 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6338 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6230 6339 | RestJson<L>,
|
6231 6340 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6232 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithGenericString, S>
|
6341 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithGenericString, S>
|
6233 6342 | >,
|
6234 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6343 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6235 6344 | RestJson<L>,
|
6236 6345 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6237 6346 | ModelPl::Output
|
6238 6347 | >,
|
6239 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6348 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6240 6349 | RestJson<L>,
|
6241 6350 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6242 6351 | <
|
6243 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6244 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6352 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6353 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6245 6354 | RestJson<L>,
|
6246 6355 | crate::operation_shape::MalformedAcceptWithGenericString,
|
6247 6356 | ModelPl::Output
|
6248 6357 | >
|
6249 6358 | >::Output
|
6250 6359 | >,
|
6251 6360 |
|
6252 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6361 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6253 6362 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6254 6363 |
|
6255 6364 | {
|
6256 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6257 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6365 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6366 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6258 6367 | let svc = crate::operation_shape::MalformedAcceptWithGenericString::from_service(service);
|
6259 6368 | let svc = self.model_plugin.apply(svc);
|
6260 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6369 + | let svc =
|
6370 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6261 6371 | .apply(svc);
|
6262 6372 | let svc = self.http_plugin.apply(svc);
|
6263 6373 | self.malformed_accept_with_generic_string_custom(svc)
|
6264 6374 | }
|
6265 6375 |
|
6266 6376 | /// Sets the [`MalformedAcceptWithGenericString`](crate::operation_shape::MalformedAcceptWithGenericString) to a custom [`Service`](tower::Service).
|
6267 6377 | /// not constrained by the Smithy contract.
|
6268 6378 | fn malformed_accept_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
6269 6379 | where
|
6270 6380 | S: ::tower::Service<
|
6271 6381 | ::http::Request<Body>,
|
6272 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6382 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6273 6383 | Error = ::std::convert::Infallible,
|
6274 6384 | > + Clone
|
6275 6385 | + Send
|
6276 6386 | + 'static,
|
6277 6387 | S::Future: Send + 'static,
|
6278 6388 | {
|
6279 6389 | self.malformed_accept_with_generic_string =
|
6280 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6390 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6281 6391 | self
|
6282 6392 | }
|
6283 6393 |
|
6284 6394 | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
6285 6395 | ///
|
6286 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6287 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6396 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6397 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6288 6398 | ///
|
6289 6399 | /// # Example
|
6290 6400 | ///
|
6291 6401 | /// ```no_run
|
6292 6402 | /// use rest_json::{RestJson, RestJsonConfig};
|
6293 6403 | ///
|
6294 6404 | /// use rest_json::{input, output, error};
|
6295 6405 | ///
|
6296 6406 | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> Result<output::MalformedAcceptWithPayloadOutput, error::MalformedAcceptWithPayloadError> {
|
6297 6407 | /// todo!()
|
6298 6408 | /// }
|
6299 6409 | ///
|
6300 6410 | /// let config = RestJsonConfig::builder().build();
|
6301 6411 | /// let app = RestJson::builder(config)
|
6302 6412 | /// .malformed_accept_with_payload(handler)
|
6303 6413 | /// /* Set other handlers */
|
6304 6414 | /// .build()
|
6305 6415 | /// .unwrap();
|
6306 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6416 + | /// # 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;
|
6307 6417 | /// ```
|
6308 6418 | ///
|
6309 6419 | pub fn malformed_accept_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6310 6420 | where
|
6311 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithPayload, HandlerExtractors>,
|
6421 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedAcceptWithPayload, HandlerExtractors>,
|
6312 6422 |
|
6313 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6423 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6314 6424 | RestJson<L>,
|
6315 6425 | crate::operation_shape::MalformedAcceptWithPayload,
|
6316 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithPayload, HandlerType>
|
6426 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedAcceptWithPayload, HandlerType>
|
6317 6427 | >,
|
6318 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6428 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6319 6429 | RestJson<L>,
|
6320 6430 | crate::operation_shape::MalformedAcceptWithPayload,
|
6321 6431 | ModelPl::Output
|
6322 6432 | >,
|
6323 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6433 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6324 6434 | RestJson<L>,
|
6325 6435 | crate::operation_shape::MalformedAcceptWithPayload,
|
6326 6436 | <
|
6327 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6328 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6437 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6438 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6329 6439 | RestJson<L>,
|
6330 6440 | crate::operation_shape::MalformedAcceptWithPayload,
|
6331 6441 | ModelPl::Output
|
6332 6442 | >
|
6333 6443 | >::Output
|
6334 6444 | >,
|
6335 6445 |
|
6336 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6446 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6337 6447 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6338 6448 |
|
6339 6449 | {
|
6340 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6341 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6450 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6451 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6342 6452 | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_handler(handler);
|
6343 6453 | let svc = self.model_plugin.apply(svc);
|
6344 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6454 + | let svc =
|
6455 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6345 6456 | .apply(svc);
|
6346 6457 | let svc = self.http_plugin.apply(svc);
|
6347 6458 | self.malformed_accept_with_payload_custom(svc)
|
6348 6459 | }
|
6349 6460 |
|
6350 6461 | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) operation.
|
6351 6462 | ///
|
6352 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6353 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6463 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6464 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6354 6465 | ///
|
6355 6466 | /// # Example
|
6356 6467 | ///
|
6357 6468 | /// ```no_run
|
6358 6469 | /// use rest_json::{RestJson, RestJsonConfig};
|
6359 6470 | ///
|
6360 6471 | /// use rest_json::{input, output, error};
|
6361 6472 | ///
|
6362 6473 | /// async fn handler(input: input::MalformedAcceptWithPayloadInput) -> Result<output::MalformedAcceptWithPayloadOutput, error::MalformedAcceptWithPayloadError> {
|
6363 6474 | /// todo!()
|
6364 6475 | /// }
|
6365 6476 | ///
|
6366 6477 | /// let config = RestJsonConfig::builder().build();
|
6367 6478 | /// let svc = ::tower::util::service_fn(handler);
|
6368 6479 | /// let app = RestJson::builder(config)
|
6369 6480 | /// .malformed_accept_with_payload_service(svc)
|
6370 6481 | /// /* Set other handlers */
|
6371 6482 | /// .build()
|
6372 6483 | /// .unwrap();
|
6373 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6484 + | /// # 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;
|
6374 6485 | /// ```
|
6375 6486 | ///
|
6376 6487 | pub fn malformed_accept_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6377 6488 | where
|
6378 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithPayload, ServiceExtractors>,
|
6489 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedAcceptWithPayload, ServiceExtractors>,
|
6379 6490 |
|
6380 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6491 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6381 6492 | RestJson<L>,
|
6382 6493 | crate::operation_shape::MalformedAcceptWithPayload,
|
6383 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithPayload, S>
|
6494 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedAcceptWithPayload, S>
|
6384 6495 | >,
|
6385 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6496 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6386 6497 | RestJson<L>,
|
6387 6498 | crate::operation_shape::MalformedAcceptWithPayload,
|
6388 6499 | ModelPl::Output
|
6389 6500 | >,
|
6390 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6501 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6391 6502 | RestJson<L>,
|
6392 6503 | crate::operation_shape::MalformedAcceptWithPayload,
|
6393 6504 | <
|
6394 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6395 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6505 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6506 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6396 6507 | RestJson<L>,
|
6397 6508 | crate::operation_shape::MalformedAcceptWithPayload,
|
6398 6509 | ModelPl::Output
|
6399 6510 | >
|
6400 6511 | >::Output
|
6401 6512 | >,
|
6402 6513 |
|
6403 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6514 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6404 6515 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6405 6516 |
|
6406 6517 | {
|
6407 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6408 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6518 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6519 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6409 6520 | let svc = crate::operation_shape::MalformedAcceptWithPayload::from_service(service);
|
6410 6521 | let svc = self.model_plugin.apply(svc);
|
6411 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6522 + | let svc =
|
6523 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6412 6524 | .apply(svc);
|
6413 6525 | let svc = self.http_plugin.apply(svc);
|
6414 6526 | self.malformed_accept_with_payload_custom(svc)
|
6415 6527 | }
|
6416 6528 |
|
6417 6529 | /// Sets the [`MalformedAcceptWithPayload`](crate::operation_shape::MalformedAcceptWithPayload) to a custom [`Service`](tower::Service).
|
6418 6530 | /// not constrained by the Smithy contract.
|
6419 6531 | fn malformed_accept_with_payload_custom<S>(mut self, svc: S) -> Self
|
6420 6532 | where
|
6421 6533 | S: ::tower::Service<
|
6422 6534 | ::http::Request<Body>,
|
6423 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6535 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6424 6536 | Error = ::std::convert::Infallible,
|
6425 6537 | > + Clone
|
6426 6538 | + Send
|
6427 6539 | + 'static,
|
6428 6540 | S::Future: Send + 'static,
|
6429 6541 | {
|
6430 6542 | self.malformed_accept_with_payload =
|
6431 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6543 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6432 6544 | self
|
6433 6545 | }
|
6434 6546 |
|
6435 6547 | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
6436 6548 | ///
|
6437 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6438 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6549 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6550 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6439 6551 | ///
|
6440 6552 | /// # Example
|
6441 6553 | ///
|
6442 6554 | /// ```no_run
|
6443 6555 | /// use rest_json::{RestJson, RestJsonConfig};
|
6444 6556 | ///
|
6445 6557 | /// use rest_json::{input, output, error};
|
6446 6558 | ///
|
6447 6559 | /// async fn handler(input: input::MalformedBlobInput) -> Result<output::MalformedBlobOutput, error::MalformedBlobError> {
|
6448 6560 | /// todo!()
|
6449 6561 | /// }
|
6450 6562 | ///
|
6451 6563 | /// let config = RestJsonConfig::builder().build();
|
6452 6564 | /// let app = RestJson::builder(config)
|
6453 6565 | /// .malformed_blob(handler)
|
6454 6566 | /// /* Set other handlers */
|
6455 6567 | /// .build()
|
6456 6568 | /// .unwrap();
|
6457 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6569 + | /// # 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;
|
6458 6570 | /// ```
|
6459 6571 | ///
|
6460 6572 | pub fn malformed_blob<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6461 6573 | where
|
6462 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedBlob, HandlerExtractors>,
|
6574 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBlob, HandlerExtractors>,
|
6463 6575 |
|
6464 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6576 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6465 6577 | RestJson<L>,
|
6466 6578 | crate::operation_shape::MalformedBlob,
|
6467 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedBlob, HandlerType>
|
6579 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBlob, HandlerType>
|
6468 6580 | >,
|
6469 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6581 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6470 6582 | RestJson<L>,
|
6471 6583 | crate::operation_shape::MalformedBlob,
|
6472 6584 | ModelPl::Output
|
6473 6585 | >,
|
6474 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6586 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6475 6587 | RestJson<L>,
|
6476 6588 | crate::operation_shape::MalformedBlob,
|
6477 6589 | <
|
6478 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6479 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6590 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6591 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6480 6592 | RestJson<L>,
|
6481 6593 | crate::operation_shape::MalformedBlob,
|
6482 6594 | ModelPl::Output
|
6483 6595 | >
|
6484 6596 | >::Output
|
6485 6597 | >,
|
6486 6598 |
|
6487 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6599 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6488 6600 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6489 6601 |
|
6490 6602 | {
|
6491 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6492 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6603 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6604 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6493 6605 | let svc = crate::operation_shape::MalformedBlob::from_handler(handler);
|
6494 6606 | let svc = self.model_plugin.apply(svc);
|
6495 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6607 + | let svc =
|
6608 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6496 6609 | .apply(svc);
|
6497 6610 | let svc = self.http_plugin.apply(svc);
|
6498 6611 | self.malformed_blob_custom(svc)
|
6499 6612 | }
|
6500 6613 |
|
6501 6614 | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) operation.
|
6502 6615 | ///
|
6503 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6504 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6616 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6617 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6505 6618 | ///
|
6506 6619 | /// # Example
|
6507 6620 | ///
|
6508 6621 | /// ```no_run
|
6509 6622 | /// use rest_json::{RestJson, RestJsonConfig};
|
6510 6623 | ///
|
6511 6624 | /// use rest_json::{input, output, error};
|
6512 6625 | ///
|
6513 6626 | /// async fn handler(input: input::MalformedBlobInput) -> Result<output::MalformedBlobOutput, error::MalformedBlobError> {
|
6514 6627 | /// todo!()
|
6515 6628 | /// }
|
6516 6629 | ///
|
6517 6630 | /// let config = RestJsonConfig::builder().build();
|
6518 6631 | /// let svc = ::tower::util::service_fn(handler);
|
6519 6632 | /// let app = RestJson::builder(config)
|
6520 6633 | /// .malformed_blob_service(svc)
|
6521 6634 | /// /* Set other handlers */
|
6522 6635 | /// .build()
|
6523 6636 | /// .unwrap();
|
6524 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6637 + | /// # 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;
|
6525 6638 | /// ```
|
6526 6639 | ///
|
6527 6640 | pub fn malformed_blob_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6528 6641 | where
|
6529 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedBlob, ServiceExtractors>,
|
6642 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBlob, ServiceExtractors>,
|
6530 6643 |
|
6531 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6644 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6532 6645 | RestJson<L>,
|
6533 6646 | crate::operation_shape::MalformedBlob,
|
6534 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedBlob, S>
|
6647 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBlob, S>
|
6535 6648 | >,
|
6536 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6649 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6537 6650 | RestJson<L>,
|
6538 6651 | crate::operation_shape::MalformedBlob,
|
6539 6652 | ModelPl::Output
|
6540 6653 | >,
|
6541 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6654 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6542 6655 | RestJson<L>,
|
6543 6656 | crate::operation_shape::MalformedBlob,
|
6544 6657 | <
|
6545 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6546 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6658 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6659 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6547 6660 | RestJson<L>,
|
6548 6661 | crate::operation_shape::MalformedBlob,
|
6549 6662 | ModelPl::Output
|
6550 6663 | >
|
6551 6664 | >::Output
|
6552 6665 | >,
|
6553 6666 |
|
6554 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6667 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6555 6668 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6556 6669 |
|
6557 6670 | {
|
6558 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6559 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6671 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6672 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6560 6673 | let svc = crate::operation_shape::MalformedBlob::from_service(service);
|
6561 6674 | let svc = self.model_plugin.apply(svc);
|
6562 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6675 + | let svc =
|
6676 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6563 6677 | .apply(svc);
|
6564 6678 | let svc = self.http_plugin.apply(svc);
|
6565 6679 | self.malformed_blob_custom(svc)
|
6566 6680 | }
|
6567 6681 |
|
6568 6682 | /// Sets the [`MalformedBlob`](crate::operation_shape::MalformedBlob) to a custom [`Service`](tower::Service).
|
6569 6683 | /// not constrained by the Smithy contract.
|
6570 6684 | fn malformed_blob_custom<S>(mut self, svc: S) -> Self
|
6571 6685 | where
|
6572 6686 | S: ::tower::Service<
|
6573 6687 | ::http::Request<Body>,
|
6574 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6688 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6575 6689 | Error = ::std::convert::Infallible,
|
6576 6690 | > + Clone
|
6577 6691 | + Send
|
6578 6692 | + 'static,
|
6579 6693 | S::Future: Send + 'static,
|
6580 6694 | {
|
6581 - | self.malformed_blob = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6695 + | self.malformed_blob = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6582 6696 | self
|
6583 6697 | }
|
6584 6698 |
|
6585 6699 | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
6586 6700 | ///
|
6587 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6588 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6701 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6702 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6589 6703 | ///
|
6590 6704 | /// # Example
|
6591 6705 | ///
|
6592 6706 | /// ```no_run
|
6593 6707 | /// use rest_json::{RestJson, RestJsonConfig};
|
6594 6708 | ///
|
6595 6709 | /// use rest_json::{input, output, error};
|
6596 6710 | ///
|
6597 6711 | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
6598 6712 | /// todo!()
|
6599 6713 | /// }
|
6600 6714 | ///
|
6601 6715 | /// let config = RestJsonConfig::builder().build();
|
6602 6716 | /// let app = RestJson::builder(config)
|
6603 6717 | /// .malformed_boolean(handler)
|
6604 6718 | /// /* Set other handlers */
|
6605 6719 | /// .build()
|
6606 6720 | /// .unwrap();
|
6607 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6721 + | /// # 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;
|
6608 6722 | /// ```
|
6609 6723 | ///
|
6610 6724 | pub fn malformed_boolean<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6611 6725 | where
|
6612 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedBoolean, HandlerExtractors>,
|
6726 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedBoolean, HandlerExtractors>,
|
6613 6727 |
|
6614 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6728 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6615 6729 | RestJson<L>,
|
6616 6730 | crate::operation_shape::MalformedBoolean,
|
6617 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedBoolean, HandlerType>
|
6731 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedBoolean, HandlerType>
|
6618 6732 | >,
|
6619 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6733 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6620 6734 | RestJson<L>,
|
6621 6735 | crate::operation_shape::MalformedBoolean,
|
6622 6736 | ModelPl::Output
|
6623 6737 | >,
|
6624 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6738 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6625 6739 | RestJson<L>,
|
6626 6740 | crate::operation_shape::MalformedBoolean,
|
6627 6741 | <
|
6628 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6629 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6742 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6743 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6630 6744 | RestJson<L>,
|
6631 6745 | crate::operation_shape::MalformedBoolean,
|
6632 6746 | ModelPl::Output
|
6633 6747 | >
|
6634 6748 | >::Output
|
6635 6749 | >,
|
6636 6750 |
|
6637 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6751 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6638 6752 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6639 6753 |
|
6640 6754 | {
|
6641 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6642 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6755 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6756 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6643 6757 | let svc = crate::operation_shape::MalformedBoolean::from_handler(handler);
|
6644 6758 | let svc = self.model_plugin.apply(svc);
|
6645 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6759 + | let svc =
|
6760 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6646 6761 | .apply(svc);
|
6647 6762 | let svc = self.http_plugin.apply(svc);
|
6648 6763 | self.malformed_boolean_custom(svc)
|
6649 6764 | }
|
6650 6765 |
|
6651 6766 | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) operation.
|
6652 6767 | ///
|
6653 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6654 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6768 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6769 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6655 6770 | ///
|
6656 6771 | /// # Example
|
6657 6772 | ///
|
6658 6773 | /// ```no_run
|
6659 6774 | /// use rest_json::{RestJson, RestJsonConfig};
|
6660 6775 | ///
|
6661 6776 | /// use rest_json::{input, output, error};
|
6662 6777 | ///
|
6663 6778 | /// async fn handler(input: input::MalformedBooleanInput) -> Result<output::MalformedBooleanOutput, error::MalformedBooleanError> {
|
6664 6779 | /// todo!()
|
6665 6780 | /// }
|
6666 6781 | ///
|
6667 6782 | /// let config = RestJsonConfig::builder().build();
|
6668 6783 | /// let svc = ::tower::util::service_fn(handler);
|
6669 6784 | /// let app = RestJson::builder(config)
|
6670 6785 | /// .malformed_boolean_service(svc)
|
6671 6786 | /// /* Set other handlers */
|
6672 6787 | /// .build()
|
6673 6788 | /// .unwrap();
|
6674 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6789 + | /// # 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;
|
6675 6790 | /// ```
|
6676 6791 | ///
|
6677 6792 | pub fn malformed_boolean_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6678 6793 | where
|
6679 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedBoolean, ServiceExtractors>,
|
6794 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedBoolean, ServiceExtractors>,
|
6680 6795 |
|
6681 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6796 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6682 6797 | RestJson<L>,
|
6683 6798 | crate::operation_shape::MalformedBoolean,
|
6684 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedBoolean, S>
|
6799 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedBoolean, S>
|
6685 6800 | >,
|
6686 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6801 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6687 6802 | RestJson<L>,
|
6688 6803 | crate::operation_shape::MalformedBoolean,
|
6689 6804 | ModelPl::Output
|
6690 6805 | >,
|
6691 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6806 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6692 6807 | RestJson<L>,
|
6693 6808 | crate::operation_shape::MalformedBoolean,
|
6694 6809 | <
|
6695 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6696 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6810 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6811 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6697 6812 | RestJson<L>,
|
6698 6813 | crate::operation_shape::MalformedBoolean,
|
6699 6814 | ModelPl::Output
|
6700 6815 | >
|
6701 6816 | >::Output
|
6702 6817 | >,
|
6703 6818 |
|
6704 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6819 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6705 6820 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6706 6821 |
|
6707 6822 | {
|
6708 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6709 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6823 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6824 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6710 6825 | let svc = crate::operation_shape::MalformedBoolean::from_service(service);
|
6711 6826 | let svc = self.model_plugin.apply(svc);
|
6712 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6827 + | let svc =
|
6828 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6713 6829 | .apply(svc);
|
6714 6830 | let svc = self.http_plugin.apply(svc);
|
6715 6831 | self.malformed_boolean_custom(svc)
|
6716 6832 | }
|
6717 6833 |
|
6718 6834 | /// Sets the [`MalformedBoolean`](crate::operation_shape::MalformedBoolean) to a custom [`Service`](tower::Service).
|
6719 6835 | /// not constrained by the Smithy contract.
|
6720 6836 | fn malformed_boolean_custom<S>(mut self, svc: S) -> Self
|
6721 6837 | where
|
6722 6838 | S: ::tower::Service<
|
6723 6839 | ::http::Request<Body>,
|
6724 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6840 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6725 6841 | Error = ::std::convert::Infallible,
|
6726 6842 | > + Clone
|
6727 6843 | + Send
|
6728 6844 | + 'static,
|
6729 6845 | S::Future: Send + 'static,
|
6730 6846 | {
|
6731 - | self.malformed_boolean = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6847 + | self.malformed_boolean = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6732 6848 | self
|
6733 6849 | }
|
6734 6850 |
|
6735 6851 | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
6736 6852 | ///
|
6737 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6738 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6853 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6854 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6739 6855 | ///
|
6740 6856 | /// # Example
|
6741 6857 | ///
|
6742 6858 | /// ```no_run
|
6743 6859 | /// use rest_json::{RestJson, RestJsonConfig};
|
6744 6860 | ///
|
6745 6861 | /// use rest_json::{input, output, error};
|
6746 6862 | ///
|
6747 6863 | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
6748 6864 | /// todo!()
|
6749 6865 | /// }
|
6750 6866 | ///
|
6751 6867 | /// let config = RestJsonConfig::builder().build();
|
6752 6868 | /// let app = RestJson::builder(config)
|
6753 6869 | /// .malformed_byte(handler)
|
6754 6870 | /// /* Set other handlers */
|
6755 6871 | /// .build()
|
6756 6872 | /// .unwrap();
|
6757 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6873 + | /// # 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;
|
6758 6874 | /// ```
|
6759 6875 | ///
|
6760 6876 | pub fn malformed_byte<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6761 6877 | where
|
6762 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedByte, HandlerExtractors>,
|
6878 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedByte, HandlerExtractors>,
|
6763 6879 |
|
6764 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6880 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6765 6881 | RestJson<L>,
|
6766 6882 | crate::operation_shape::MalformedByte,
|
6767 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedByte, HandlerType>
|
6883 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedByte, HandlerType>
|
6768 6884 | >,
|
6769 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6885 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6770 6886 | RestJson<L>,
|
6771 6887 | crate::operation_shape::MalformedByte,
|
6772 6888 | ModelPl::Output
|
6773 6889 | >,
|
6774 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6890 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6775 6891 | RestJson<L>,
|
6776 6892 | crate::operation_shape::MalformedByte,
|
6777 6893 | <
|
6778 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6779 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6894 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6895 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6780 6896 | RestJson<L>,
|
6781 6897 | crate::operation_shape::MalformedByte,
|
6782 6898 | ModelPl::Output
|
6783 6899 | >
|
6784 6900 | >::Output
|
6785 6901 | >,
|
6786 6902 |
|
6787 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6903 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6788 6904 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6789 6905 |
|
6790 6906 | {
|
6791 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6792 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6907 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6908 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6793 6909 | let svc = crate::operation_shape::MalformedByte::from_handler(handler);
|
6794 6910 | let svc = self.model_plugin.apply(svc);
|
6795 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6911 + | let svc =
|
6912 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6796 6913 | .apply(svc);
|
6797 6914 | let svc = self.http_plugin.apply(svc);
|
6798 6915 | self.malformed_byte_custom(svc)
|
6799 6916 | }
|
6800 6917 |
|
6801 6918 | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) operation.
|
6802 6919 | ///
|
6803 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6804 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
6920 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
6921 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6805 6922 | ///
|
6806 6923 | /// # Example
|
6807 6924 | ///
|
6808 6925 | /// ```no_run
|
6809 6926 | /// use rest_json::{RestJson, RestJsonConfig};
|
6810 6927 | ///
|
6811 6928 | /// use rest_json::{input, output, error};
|
6812 6929 | ///
|
6813 6930 | /// async fn handler(input: input::MalformedByteInput) -> Result<output::MalformedByteOutput, error::MalformedByteError> {
|
6814 6931 | /// todo!()
|
6815 6932 | /// }
|
6816 6933 | ///
|
6817 6934 | /// let config = RestJsonConfig::builder().build();
|
6818 6935 | /// let svc = ::tower::util::service_fn(handler);
|
6819 6936 | /// let app = RestJson::builder(config)
|
6820 6937 | /// .malformed_byte_service(svc)
|
6821 6938 | /// /* Set other handlers */
|
6822 6939 | /// .build()
|
6823 6940 | /// .unwrap();
|
6824 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
6941 + | /// # 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;
|
6825 6942 | /// ```
|
6826 6943 | ///
|
6827 6944 | pub fn malformed_byte_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6828 6945 | where
|
6829 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedByte, ServiceExtractors>,
|
6946 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedByte, ServiceExtractors>,
|
6830 6947 |
|
6831 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
6948 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6832 6949 | RestJson<L>,
|
6833 6950 | crate::operation_shape::MalformedByte,
|
6834 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedByte, S>
|
6951 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedByte, S>
|
6835 6952 | >,
|
6836 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
6953 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6837 6954 | RestJson<L>,
|
6838 6955 | crate::operation_shape::MalformedByte,
|
6839 6956 | ModelPl::Output
|
6840 6957 | >,
|
6841 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
6958 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6842 6959 | RestJson<L>,
|
6843 6960 | crate::operation_shape::MalformedByte,
|
6844 6961 | <
|
6845 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6846 - | as ::aws_smithy_http_server::plugin::Plugin<
|
6962 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6963 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6847 6964 | RestJson<L>,
|
6848 6965 | crate::operation_shape::MalformedByte,
|
6849 6966 | ModelPl::Output
|
6850 6967 | >
|
6851 6968 | >::Output
|
6852 6969 | >,
|
6853 6970 |
|
6854 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6971 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6855 6972 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6856 6973 |
|
6857 6974 | {
|
6858 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6859 - | use ::aws_smithy_http_server::plugin::Plugin;
|
6975 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
6976 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6860 6977 | let svc = crate::operation_shape::MalformedByte::from_service(service);
|
6861 6978 | let svc = self.model_plugin.apply(svc);
|
6862 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6979 + | let svc =
|
6980 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6863 6981 | .apply(svc);
|
6864 6982 | let svc = self.http_plugin.apply(svc);
|
6865 6983 | self.malformed_byte_custom(svc)
|
6866 6984 | }
|
6867 6985 |
|
6868 6986 | /// Sets the [`MalformedByte`](crate::operation_shape::MalformedByte) to a custom [`Service`](tower::Service).
|
6869 6987 | /// not constrained by the Smithy contract.
|
6870 6988 | fn malformed_byte_custom<S>(mut self, svc: S) -> Self
|
6871 6989 | where
|
6872 6990 | S: ::tower::Service<
|
6873 6991 | ::http::Request<Body>,
|
6874 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
6992 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
6875 6993 | Error = ::std::convert::Infallible,
|
6876 6994 | > + Clone
|
6877 6995 | + Send
|
6878 6996 | + 'static,
|
6879 6997 | S::Future: Send + 'static,
|
6880 6998 | {
|
6881 - | self.malformed_byte = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
6999 + | self.malformed_byte = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
6882 7000 | self
|
6883 7001 | }
|
6884 7002 |
|
6885 7003 | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
6886 7004 | ///
|
6887 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6888 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7005 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7006 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6889 7007 | ///
|
6890 7008 | /// # Example
|
6891 7009 | ///
|
6892 7010 | /// ```no_run
|
6893 7011 | /// use rest_json::{RestJson, RestJsonConfig};
|
6894 7012 | ///
|
6895 7013 | /// use rest_json::{input, output, error};
|
6896 7014 | ///
|
6897 7015 | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> Result<output::MalformedContentTypeWithBodyOutput, error::MalformedContentTypeWithBodyError> {
|
6898 7016 | /// todo!()
|
6899 7017 | /// }
|
6900 7018 | ///
|
6901 7019 | /// let config = RestJsonConfig::builder().build();
|
6902 7020 | /// let app = RestJson::builder(config)
|
6903 7021 | /// .malformed_content_type_with_body(handler)
|
6904 7022 | /// /* Set other handlers */
|
6905 7023 | /// .build()
|
6906 7024 | /// .unwrap();
|
6907 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7025 + | /// # 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;
|
6908 7026 | /// ```
|
6909 7027 | ///
|
6910 7028 | pub fn malformed_content_type_with_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
6911 7029 | where
|
6912 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithBody, HandlerExtractors>,
|
7030 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithBody, HandlerExtractors>,
|
6913 7031 |
|
6914 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7032 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6915 7033 | RestJson<L>,
|
6916 7034 | crate::operation_shape::MalformedContentTypeWithBody,
|
6917 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithBody, HandlerType>
|
7035 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithBody, HandlerType>
|
6918 7036 | >,
|
6919 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7037 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6920 7038 | RestJson<L>,
|
6921 7039 | crate::operation_shape::MalformedContentTypeWithBody,
|
6922 7040 | ModelPl::Output
|
6923 7041 | >,
|
6924 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7042 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6925 7043 | RestJson<L>,
|
6926 7044 | crate::operation_shape::MalformedContentTypeWithBody,
|
6927 7045 | <
|
6928 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6929 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7046 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7047 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6930 7048 | RestJson<L>,
|
6931 7049 | crate::operation_shape::MalformedContentTypeWithBody,
|
6932 7050 | ModelPl::Output
|
6933 7051 | >
|
6934 7052 | >::Output
|
6935 7053 | >,
|
6936 7054 |
|
6937 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7055 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
6938 7056 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
6939 7057 |
|
6940 7058 | {
|
6941 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
6942 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7059 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7060 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
6943 7061 | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_handler(handler);
|
6944 7062 | let svc = self.model_plugin.apply(svc);
|
6945 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7063 + | let svc =
|
7064 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
6946 7065 | .apply(svc);
|
6947 7066 | let svc = self.http_plugin.apply(svc);
|
6948 7067 | self.malformed_content_type_with_body_custom(svc)
|
6949 7068 | }
|
6950 7069 |
|
6951 7070 | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) operation.
|
6952 7071 | ///
|
6953 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
6954 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7072 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7073 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
6955 7074 | ///
|
6956 7075 | /// # Example
|
6957 7076 | ///
|
6958 7077 | /// ```no_run
|
6959 7078 | /// use rest_json::{RestJson, RestJsonConfig};
|
6960 7079 | ///
|
6961 7080 | /// use rest_json::{input, output, error};
|
6962 7081 | ///
|
6963 7082 | /// async fn handler(input: input::MalformedContentTypeWithBodyInput) -> Result<output::MalformedContentTypeWithBodyOutput, error::MalformedContentTypeWithBodyError> {
|
6964 7083 | /// todo!()
|
6965 7084 | /// }
|
6966 7085 | ///
|
6967 7086 | /// let config = RestJsonConfig::builder().build();
|
6968 7087 | /// let svc = ::tower::util::service_fn(handler);
|
6969 7088 | /// let app = RestJson::builder(config)
|
6970 7089 | /// .malformed_content_type_with_body_service(svc)
|
6971 7090 | /// /* Set other handlers */
|
6972 7091 | /// .build()
|
6973 7092 | /// .unwrap();
|
6974 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7093 + | /// # 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;
|
6975 7094 | /// ```
|
6976 7095 | ///
|
6977 7096 | pub fn malformed_content_type_with_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
6978 7097 | where
|
6979 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithBody, ServiceExtractors>,
|
7098 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithBody, ServiceExtractors>,
|
6980 7099 |
|
6981 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7100 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6982 7101 | RestJson<L>,
|
6983 7102 | crate::operation_shape::MalformedContentTypeWithBody,
|
6984 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithBody, S>
|
7103 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithBody, S>
|
6985 7104 | >,
|
6986 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7105 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6987 7106 | RestJson<L>,
|
6988 7107 | crate::operation_shape::MalformedContentTypeWithBody,
|
6989 7108 | ModelPl::Output
|
6990 7109 | >,
|
6991 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7110 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6992 7111 | RestJson<L>,
|
6993 7112 | crate::operation_shape::MalformedContentTypeWithBody,
|
6994 7113 | <
|
6995 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
6996 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7114 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7115 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
6997 7116 | RestJson<L>,
|
6998 7117 | crate::operation_shape::MalformedContentTypeWithBody,
|
6999 7118 | ModelPl::Output
|
7000 7119 | >
|
7001 7120 | >::Output
|
7002 7121 | >,
|
7003 7122 |
|
7004 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7123 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7005 7124 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7006 7125 |
|
7007 7126 | {
|
7008 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7009 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7127 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7128 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7010 7129 | let svc = crate::operation_shape::MalformedContentTypeWithBody::from_service(service);
|
7011 7130 | let svc = self.model_plugin.apply(svc);
|
7012 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7131 + | let svc =
|
7132 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7013 7133 | .apply(svc);
|
7014 7134 | let svc = self.http_plugin.apply(svc);
|
7015 7135 | self.malformed_content_type_with_body_custom(svc)
|
7016 7136 | }
|
7017 7137 |
|
7018 7138 | /// Sets the [`MalformedContentTypeWithBody`](crate::operation_shape::MalformedContentTypeWithBody) to a custom [`Service`](tower::Service).
|
7019 7139 | /// not constrained by the Smithy contract.
|
7020 7140 | fn malformed_content_type_with_body_custom<S>(mut self, svc: S) -> Self
|
7021 7141 | where
|
7022 7142 | S: ::tower::Service<
|
7023 7143 | ::http::Request<Body>,
|
7024 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7144 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7025 7145 | Error = ::std::convert::Infallible,
|
7026 7146 | > + Clone
|
7027 7147 | + Send
|
7028 7148 | + 'static,
|
7029 7149 | S::Future: Send + 'static,
|
7030 7150 | {
|
7031 7151 | self.malformed_content_type_with_body =
|
7032 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7152 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7033 7153 | self
|
7034 7154 | }
|
7035 7155 |
|
7036 7156 | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
7037 7157 | ///
|
7038 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7039 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7158 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7159 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7040 7160 | ///
|
7041 7161 | /// # Example
|
7042 7162 | ///
|
7043 7163 | /// ```no_run
|
7044 7164 | /// use rest_json::{RestJson, RestJsonConfig};
|
7045 7165 | ///
|
7046 7166 | /// use rest_json::{input, output, error};
|
7047 7167 | ///
|
7048 7168 | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> Result<output::MalformedContentTypeWithGenericStringOutput, error::MalformedContentTypeWithGenericStringError> {
|
7049 7169 | /// todo!()
|
7050 7170 | /// }
|
7051 7171 | ///
|
7052 7172 | /// let config = RestJsonConfig::builder().build();
|
7053 7173 | /// let app = RestJson::builder(config)
|
7054 7174 | /// .malformed_content_type_with_generic_string(handler)
|
7055 7175 | /// /* Set other handlers */
|
7056 7176 | /// .build()
|
7057 7177 | /// .unwrap();
|
7058 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7178 + | /// # 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;
|
7059 7179 | /// ```
|
7060 7180 | ///
|
7061 7181 | pub fn malformed_content_type_with_generic_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7062 7182 | where
|
7063 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerExtractors>,
|
7183 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerExtractors>,
|
7064 7184 |
|
7065 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7185 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7066 7186 | RestJson<L>,
|
7067 7187 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7068 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerType>
|
7188 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithGenericString, HandlerType>
|
7069 7189 | >,
|
7070 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7190 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7071 7191 | RestJson<L>,
|
7072 7192 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7073 7193 | ModelPl::Output
|
7074 7194 | >,
|
7075 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7195 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7076 7196 | RestJson<L>,
|
7077 7197 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7078 7198 | <
|
7079 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7080 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7199 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7200 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7081 7201 | RestJson<L>,
|
7082 7202 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7083 7203 | ModelPl::Output
|
7084 7204 | >
|
7085 7205 | >::Output
|
7086 7206 | >,
|
7087 7207 |
|
7088 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7208 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7089 7209 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7090 7210 |
|
7091 7211 | {
|
7092 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7093 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7212 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7213 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7094 7214 | let svc =
|
7095 7215 | crate::operation_shape::MalformedContentTypeWithGenericString::from_handler(handler);
|
7096 7216 | let svc = self.model_plugin.apply(svc);
|
7097 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7217 + | let svc =
|
7218 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7098 7219 | .apply(svc);
|
7099 7220 | let svc = self.http_plugin.apply(svc);
|
7100 7221 | self.malformed_content_type_with_generic_string_custom(svc)
|
7101 7222 | }
|
7102 7223 |
|
7103 7224 | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) operation.
|
7104 7225 | ///
|
7105 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7106 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7226 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7227 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7107 7228 | ///
|
7108 7229 | /// # Example
|
7109 7230 | ///
|
7110 7231 | /// ```no_run
|
7111 7232 | /// use rest_json::{RestJson, RestJsonConfig};
|
7112 7233 | ///
|
7113 7234 | /// use rest_json::{input, output, error};
|
7114 7235 | ///
|
7115 7236 | /// async fn handler(input: input::MalformedContentTypeWithGenericStringInput) -> Result<output::MalformedContentTypeWithGenericStringOutput, error::MalformedContentTypeWithGenericStringError> {
|
7116 7237 | /// todo!()
|
7117 7238 | /// }
|
7118 7239 | ///
|
7119 7240 | /// let config = RestJsonConfig::builder().build();
|
7120 7241 | /// let svc = ::tower::util::service_fn(handler);
|
7121 7242 | /// let app = RestJson::builder(config)
|
7122 7243 | /// .malformed_content_type_with_generic_string_service(svc)
|
7123 7244 | /// /* Set other handlers */
|
7124 7245 | /// .build()
|
7125 7246 | /// .unwrap();
|
7126 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7247 + | /// # 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;
|
7127 7248 | /// ```
|
7128 7249 | ///
|
7129 7250 | pub fn malformed_content_type_with_generic_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7130 7251 | where
|
7131 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithGenericString, ServiceExtractors>,
|
7252 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithGenericString, ServiceExtractors>,
|
7132 7253 |
|
7133 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7254 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7134 7255 | RestJson<L>,
|
7135 7256 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7136 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithGenericString, S>
|
7257 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithGenericString, S>
|
7137 7258 | >,
|
7138 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7259 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7139 7260 | RestJson<L>,
|
7140 7261 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7141 7262 | ModelPl::Output
|
7142 7263 | >,
|
7143 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7264 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7144 7265 | RestJson<L>,
|
7145 7266 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7146 7267 | <
|
7147 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7148 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7268 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7269 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7149 7270 | RestJson<L>,
|
7150 7271 | crate::operation_shape::MalformedContentTypeWithGenericString,
|
7151 7272 | ModelPl::Output
|
7152 7273 | >
|
7153 7274 | >::Output
|
7154 7275 | >,
|
7155 7276 |
|
7156 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7277 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7157 7278 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7158 7279 |
|
7159 7280 | {
|
7160 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7161 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7281 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7282 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7162 7283 | let svc =
|
7163 7284 | crate::operation_shape::MalformedContentTypeWithGenericString::from_service(service);
|
7164 7285 | let svc = self.model_plugin.apply(svc);
|
7165 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7286 + | let svc =
|
7287 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7166 7288 | .apply(svc);
|
7167 7289 | let svc = self.http_plugin.apply(svc);
|
7168 7290 | self.malformed_content_type_with_generic_string_custom(svc)
|
7169 7291 | }
|
7170 7292 |
|
7171 7293 | /// Sets the [`MalformedContentTypeWithGenericString`](crate::operation_shape::MalformedContentTypeWithGenericString) to a custom [`Service`](tower::Service).
|
7172 7294 | /// not constrained by the Smithy contract.
|
7173 7295 | fn malformed_content_type_with_generic_string_custom<S>(mut self, svc: S) -> Self
|
7174 7296 | where
|
7175 7297 | S: ::tower::Service<
|
7176 7298 | ::http::Request<Body>,
|
7177 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7299 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7178 7300 | Error = ::std::convert::Infallible,
|
7179 7301 | > + Clone
|
7180 7302 | + Send
|
7181 7303 | + 'static,
|
7182 7304 | S::Future: Send + 'static,
|
7183 7305 | {
|
7184 7306 | self.malformed_content_type_with_generic_string =
|
7185 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7307 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7186 7308 | self
|
7187 7309 | }
|
7188 7310 |
|
7189 7311 | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
7190 7312 | ///
|
7191 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7192 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7313 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7314 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7193 7315 | ///
|
7194 7316 | /// # Example
|
7195 7317 | ///
|
7196 7318 | /// ```no_run
|
7197 7319 | /// use rest_json::{RestJson, RestJsonConfig};
|
7198 7320 | ///
|
7199 7321 | /// use rest_json::{input, output, error};
|
7200 7322 | ///
|
7201 7323 | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> Result<output::MalformedContentTypeWithoutBodyOutput, error::MalformedContentTypeWithoutBodyError> {
|
7202 7324 | /// todo!()
|
7203 7325 | /// }
|
7204 7326 | ///
|
7205 7327 | /// let config = RestJsonConfig::builder().build();
|
7206 7328 | /// let app = RestJson::builder(config)
|
7207 7329 | /// .malformed_content_type_without_body(handler)
|
7208 7330 | /// /* Set other handlers */
|
7209 7331 | /// .build()
|
7210 7332 | /// .unwrap();
|
7211 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7333 + | /// # 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;
|
7212 7334 | /// ```
|
7213 7335 | ///
|
7214 7336 | pub fn malformed_content_type_without_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7215 7337 | where
|
7216 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerExtractors>,
|
7338 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerExtractors>,
|
7217 7339 |
|
7218 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7340 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7219 7341 | RestJson<L>,
|
7220 7342 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7221 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerType>
|
7343 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBody, HandlerType>
|
7222 7344 | >,
|
7223 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7345 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7224 7346 | RestJson<L>,
|
7225 7347 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7226 7348 | ModelPl::Output
|
7227 7349 | >,
|
7228 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7350 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7229 7351 | RestJson<L>,
|
7230 7352 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7231 7353 | <
|
7232 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7233 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7354 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7355 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7234 7356 | RestJson<L>,
|
7235 7357 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7236 7358 | ModelPl::Output
|
7237 7359 | >
|
7238 7360 | >::Output
|
7239 7361 | >,
|
7240 7362 |
|
7241 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7363 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7242 7364 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7243 7365 |
|
7244 7366 | {
|
7245 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7246 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7367 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7368 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7247 7369 | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_handler(handler);
|
7248 7370 | let svc = self.model_plugin.apply(svc);
|
7249 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7371 + | let svc =
|
7372 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7250 7373 | .apply(svc);
|
7251 7374 | let svc = self.http_plugin.apply(svc);
|
7252 7375 | self.malformed_content_type_without_body_custom(svc)
|
7253 7376 | }
|
7254 7377 |
|
7255 7378 | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) operation.
|
7256 7379 | ///
|
7257 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7258 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7380 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7381 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7259 7382 | ///
|
7260 7383 | /// # Example
|
7261 7384 | ///
|
7262 7385 | /// ```no_run
|
7263 7386 | /// use rest_json::{RestJson, RestJsonConfig};
|
7264 7387 | ///
|
7265 7388 | /// use rest_json::{input, output, error};
|
7266 7389 | ///
|
7267 7390 | /// async fn handler(input: input::MalformedContentTypeWithoutBodyInput) -> Result<output::MalformedContentTypeWithoutBodyOutput, error::MalformedContentTypeWithoutBodyError> {
|
7268 7391 | /// todo!()
|
7269 7392 | /// }
|
7270 7393 | ///
|
7271 7394 | /// let config = RestJsonConfig::builder().build();
|
7272 7395 | /// let svc = ::tower::util::service_fn(handler);
|
7273 7396 | /// let app = RestJson::builder(config)
|
7274 7397 | /// .malformed_content_type_without_body_service(svc)
|
7275 7398 | /// /* Set other handlers */
|
7276 7399 | /// .build()
|
7277 7400 | /// .unwrap();
|
7278 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7401 + | /// # 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;
|
7279 7402 | /// ```
|
7280 7403 | ///
|
7281 7404 | pub fn malformed_content_type_without_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7282 7405 | where
|
7283 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBody, ServiceExtractors>,
|
7406 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBody, ServiceExtractors>,
|
7284 7407 |
|
7285 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7408 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7286 7409 | RestJson<L>,
|
7287 7410 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7288 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBody, S>
|
7411 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBody, S>
|
7289 7412 | >,
|
7290 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7413 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7291 7414 | RestJson<L>,
|
7292 7415 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7293 7416 | ModelPl::Output
|
7294 7417 | >,
|
7295 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7418 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7296 7419 | RestJson<L>,
|
7297 7420 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7298 7421 | <
|
7299 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7300 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7422 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7423 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7301 7424 | RestJson<L>,
|
7302 7425 | crate::operation_shape::MalformedContentTypeWithoutBody,
|
7303 7426 | ModelPl::Output
|
7304 7427 | >
|
7305 7428 | >::Output
|
7306 7429 | >,
|
7307 7430 |
|
7308 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7431 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7309 7432 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7310 7433 |
|
7311 7434 | {
|
7312 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7313 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7435 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7436 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7314 7437 | let svc = crate::operation_shape::MalformedContentTypeWithoutBody::from_service(service);
|
7315 7438 | let svc = self.model_plugin.apply(svc);
|
7316 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7439 + | let svc =
|
7440 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7317 7441 | .apply(svc);
|
7318 7442 | let svc = self.http_plugin.apply(svc);
|
7319 7443 | self.malformed_content_type_without_body_custom(svc)
|
7320 7444 | }
|
7321 7445 |
|
7322 7446 | /// Sets the [`MalformedContentTypeWithoutBody`](crate::operation_shape::MalformedContentTypeWithoutBody) to a custom [`Service`](tower::Service).
|
7323 7447 | /// not constrained by the Smithy contract.
|
7324 7448 | fn malformed_content_type_without_body_custom<S>(mut self, svc: S) -> Self
|
7325 7449 | where
|
7326 7450 | S: ::tower::Service<
|
7327 7451 | ::http::Request<Body>,
|
7328 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7452 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7329 7453 | Error = ::std::convert::Infallible,
|
7330 7454 | > + Clone
|
7331 7455 | + Send
|
7332 7456 | + 'static,
|
7333 7457 | S::Future: Send + 'static,
|
7334 7458 | {
|
7335 7459 | self.malformed_content_type_without_body =
|
7336 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7460 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7337 7461 | self
|
7338 7462 | }
|
7339 7463 |
|
7340 7464 | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
7341 7465 | ///
|
7342 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7343 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7466 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7467 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7344 7468 | ///
|
7345 7469 | /// # Example
|
7346 7470 | ///
|
7347 7471 | /// ```no_run
|
7348 7472 | /// use rest_json::{RestJson, RestJsonConfig};
|
7349 7473 | ///
|
7350 7474 | /// use rest_json::{input, output, error};
|
7351 7475 | ///
|
7352 7476 | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> Result<output::MalformedContentTypeWithoutBodyEmptyInputOutput, error::MalformedContentTypeWithoutBodyEmptyInputError> {
|
7353 7477 | /// todo!()
|
7354 7478 | /// }
|
7355 7479 | ///
|
7356 7480 | /// let config = RestJsonConfig::builder().build();
|
7357 7481 | /// let app = RestJson::builder(config)
|
7358 7482 | /// .malformed_content_type_without_body_empty_input(handler)
|
7359 7483 | /// /* Set other handlers */
|
7360 7484 | /// .build()
|
7361 7485 | /// .unwrap();
|
7362 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7486 + | /// # 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;
|
7363 7487 | /// ```
|
7364 7488 | ///
|
7365 7489 | pub fn malformed_content_type_without_body_empty_input<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7366 7490 | where
|
7367 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerExtractors>,
|
7491 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerExtractors>,
|
7368 7492 |
|
7369 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7493 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7370 7494 | RestJson<L>,
|
7371 7495 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7372 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerType>
|
7496 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, HandlerType>
|
7373 7497 | >,
|
7374 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7498 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7375 7499 | RestJson<L>,
|
7376 7500 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7377 7501 | ModelPl::Output
|
7378 7502 | >,
|
7379 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7503 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7380 7504 | RestJson<L>,
|
7381 7505 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7382 7506 | <
|
7383 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7384 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7507 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7508 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7385 7509 | RestJson<L>,
|
7386 7510 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7387 7511 | ModelPl::Output
|
7388 7512 | >
|
7389 7513 | >::Output
|
7390 7514 | >,
|
7391 7515 |
|
7392 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7516 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7393 7517 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7394 7518 |
|
7395 7519 | {
|
7396 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7397 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7520 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7521 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7398 7522 | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_handler(
|
7399 7523 | handler,
|
7400 7524 | );
|
7401 7525 | let svc = self.model_plugin.apply(svc);
|
7402 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7526 + | let svc =
|
7527 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7403 7528 | .apply(svc);
|
7404 7529 | let svc = self.http_plugin.apply(svc);
|
7405 7530 | self.malformed_content_type_without_body_empty_input_custom(svc)
|
7406 7531 | }
|
7407 7532 |
|
7408 7533 | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) operation.
|
7409 7534 | ///
|
7410 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7411 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7535 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7536 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7412 7537 | ///
|
7413 7538 | /// # Example
|
7414 7539 | ///
|
7415 7540 | /// ```no_run
|
7416 7541 | /// use rest_json::{RestJson, RestJsonConfig};
|
7417 7542 | ///
|
7418 7543 | /// use rest_json::{input, output, error};
|
7419 7544 | ///
|
7420 7545 | /// async fn handler(input: input::MalformedContentTypeWithoutBodyEmptyInputInput) -> Result<output::MalformedContentTypeWithoutBodyEmptyInputOutput, error::MalformedContentTypeWithoutBodyEmptyInputError> {
|
7421 7546 | /// todo!()
|
7422 7547 | /// }
|
7423 7548 | ///
|
7424 7549 | /// let config = RestJsonConfig::builder().build();
|
7425 7550 | /// let svc = ::tower::util::service_fn(handler);
|
7426 7551 | /// let app = RestJson::builder(config)
|
7427 7552 | /// .malformed_content_type_without_body_empty_input_service(svc)
|
7428 7553 | /// /* Set other handlers */
|
7429 7554 | /// .build()
|
7430 7555 | /// .unwrap();
|
7431 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7556 + | /// # 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;
|
7432 7557 | /// ```
|
7433 7558 | ///
|
7434 7559 | pub fn malformed_content_type_without_body_empty_input_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7435 7560 | where
|
7436 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, ServiceExtractors>,
|
7561 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, ServiceExtractors>,
|
7437 7562 |
|
7438 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7563 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7439 7564 | RestJson<L>,
|
7440 7565 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7441 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, S>
|
7566 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput, S>
|
7442 7567 | >,
|
7443 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7568 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7444 7569 | RestJson<L>,
|
7445 7570 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7446 7571 | ModelPl::Output
|
7447 7572 | >,
|
7448 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7573 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7449 7574 | RestJson<L>,
|
7450 7575 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7451 7576 | <
|
7452 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7453 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7577 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7578 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7454 7579 | RestJson<L>,
|
7455 7580 | crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput,
|
7456 7581 | ModelPl::Output
|
7457 7582 | >
|
7458 7583 | >::Output
|
7459 7584 | >,
|
7460 7585 |
|
7461 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7586 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7462 7587 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7463 7588 |
|
7464 7589 | {
|
7465 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7466 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7590 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7591 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7467 7592 | let svc = crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput::from_service(
|
7468 7593 | service,
|
7469 7594 | );
|
7470 7595 | let svc = self.model_plugin.apply(svc);
|
7471 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7596 + | let svc =
|
7597 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7472 7598 | .apply(svc);
|
7473 7599 | let svc = self.http_plugin.apply(svc);
|
7474 7600 | self.malformed_content_type_without_body_empty_input_custom(svc)
|
7475 7601 | }
|
7476 7602 |
|
7477 7603 | /// Sets the [`MalformedContentTypeWithoutBodyEmptyInput`](crate::operation_shape::MalformedContentTypeWithoutBodyEmptyInput) to a custom [`Service`](tower::Service).
|
7478 7604 | /// not constrained by the Smithy contract.
|
7479 7605 | fn malformed_content_type_without_body_empty_input_custom<S>(mut self, svc: S) -> Self
|
7480 7606 | where
|
7481 7607 | S: ::tower::Service<
|
7482 7608 | ::http::Request<Body>,
|
7483 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7609 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7484 7610 | Error = ::std::convert::Infallible,
|
7485 7611 | > + Clone
|
7486 7612 | + Send
|
7487 7613 | + 'static,
|
7488 7614 | S::Future: Send + 'static,
|
7489 7615 | {
|
7490 7616 | self.malformed_content_type_without_body_empty_input =
|
7491 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7617 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7492 7618 | self
|
7493 7619 | }
|
7494 7620 |
|
7495 7621 | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
7496 7622 | ///
|
7497 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7498 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7623 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7624 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7499 7625 | ///
|
7500 7626 | /// # Example
|
7501 7627 | ///
|
7502 7628 | /// ```no_run
|
7503 7629 | /// use rest_json::{RestJson, RestJsonConfig};
|
7504 7630 | ///
|
7505 7631 | /// use rest_json::{input, output, error};
|
7506 7632 | ///
|
7507 7633 | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> Result<output::MalformedContentTypeWithPayloadOutput, error::MalformedContentTypeWithPayloadError> {
|
7508 7634 | /// todo!()
|
7509 7635 | /// }
|
7510 7636 | ///
|
7511 7637 | /// let config = RestJsonConfig::builder().build();
|
7512 7638 | /// let app = RestJson::builder(config)
|
7513 7639 | /// .malformed_content_type_with_payload(handler)
|
7514 7640 | /// /* Set other handlers */
|
7515 7641 | /// .build()
|
7516 7642 | /// .unwrap();
|
7517 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7643 + | /// # 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;
|
7518 7644 | /// ```
|
7519 7645 | ///
|
7520 7646 | pub fn malformed_content_type_with_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7521 7647 | where
|
7522 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithPayload, HandlerExtractors>,
|
7648 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedContentTypeWithPayload, HandlerExtractors>,
|
7523 7649 |
|
7524 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7650 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7525 7651 | RestJson<L>,
|
7526 7652 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7527 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithPayload, HandlerType>
|
7653 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedContentTypeWithPayload, HandlerType>
|
7528 7654 | >,
|
7529 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7655 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7530 7656 | RestJson<L>,
|
7531 7657 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7532 7658 | ModelPl::Output
|
7533 7659 | >,
|
7534 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7660 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7535 7661 | RestJson<L>,
|
7536 7662 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7537 7663 | <
|
7538 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7539 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7664 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7665 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7540 7666 | RestJson<L>,
|
7541 7667 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7542 7668 | ModelPl::Output
|
7543 7669 | >
|
7544 7670 | >::Output
|
7545 7671 | >,
|
7546 7672 |
|
7547 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7673 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7548 7674 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7549 7675 |
|
7550 7676 | {
|
7551 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7552 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7677 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7678 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7553 7679 | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_handler(handler);
|
7554 7680 | let svc = self.model_plugin.apply(svc);
|
7555 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7681 + | let svc =
|
7682 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7556 7683 | .apply(svc);
|
7557 7684 | let svc = self.http_plugin.apply(svc);
|
7558 7685 | self.malformed_content_type_with_payload_custom(svc)
|
7559 7686 | }
|
7560 7687 |
|
7561 7688 | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) operation.
|
7562 7689 | ///
|
7563 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7564 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7690 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7691 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7565 7692 | ///
|
7566 7693 | /// # Example
|
7567 7694 | ///
|
7568 7695 | /// ```no_run
|
7569 7696 | /// use rest_json::{RestJson, RestJsonConfig};
|
7570 7697 | ///
|
7571 7698 | /// use rest_json::{input, output, error};
|
7572 7699 | ///
|
7573 7700 | /// async fn handler(input: input::MalformedContentTypeWithPayloadInput) -> Result<output::MalformedContentTypeWithPayloadOutput, error::MalformedContentTypeWithPayloadError> {
|
7574 7701 | /// todo!()
|
7575 7702 | /// }
|
7576 7703 | ///
|
7577 7704 | /// let config = RestJsonConfig::builder().build();
|
7578 7705 | /// let svc = ::tower::util::service_fn(handler);
|
7579 7706 | /// let app = RestJson::builder(config)
|
7580 7707 | /// .malformed_content_type_with_payload_service(svc)
|
7581 7708 | /// /* Set other handlers */
|
7582 7709 | /// .build()
|
7583 7710 | /// .unwrap();
|
7584 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7711 + | /// # 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;
|
7585 7712 | /// ```
|
7586 7713 | ///
|
7587 7714 | pub fn malformed_content_type_with_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7588 7715 | where
|
7589 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithPayload, ServiceExtractors>,
|
7716 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedContentTypeWithPayload, ServiceExtractors>,
|
7590 7717 |
|
7591 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7718 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7592 7719 | RestJson<L>,
|
7593 7720 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7594 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithPayload, S>
|
7721 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedContentTypeWithPayload, S>
|
7595 7722 | >,
|
7596 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7723 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7597 7724 | RestJson<L>,
|
7598 7725 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7599 7726 | ModelPl::Output
|
7600 7727 | >,
|
7601 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7728 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7602 7729 | RestJson<L>,
|
7603 7730 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7604 7731 | <
|
7605 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7606 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7732 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7733 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7607 7734 | RestJson<L>,
|
7608 7735 | crate::operation_shape::MalformedContentTypeWithPayload,
|
7609 7736 | ModelPl::Output
|
7610 7737 | >
|
7611 7738 | >::Output
|
7612 7739 | >,
|
7613 7740 |
|
7614 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7741 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7615 7742 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7616 7743 |
|
7617 7744 | {
|
7618 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7619 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7745 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7746 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7620 7747 | let svc = crate::operation_shape::MalformedContentTypeWithPayload::from_service(service);
|
7621 7748 | let svc = self.model_plugin.apply(svc);
|
7622 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7749 + | let svc =
|
7750 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7623 7751 | .apply(svc);
|
7624 7752 | let svc = self.http_plugin.apply(svc);
|
7625 7753 | self.malformed_content_type_with_payload_custom(svc)
|
7626 7754 | }
|
7627 7755 |
|
7628 7756 | /// Sets the [`MalformedContentTypeWithPayload`](crate::operation_shape::MalformedContentTypeWithPayload) to a custom [`Service`](tower::Service).
|
7629 7757 | /// not constrained by the Smithy contract.
|
7630 7758 | fn malformed_content_type_with_payload_custom<S>(mut self, svc: S) -> Self
|
7631 7759 | where
|
7632 7760 | S: ::tower::Service<
|
7633 7761 | ::http::Request<Body>,
|
7634 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7762 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7635 7763 | Error = ::std::convert::Infallible,
|
7636 7764 | > + Clone
|
7637 7765 | + Send
|
7638 7766 | + 'static,
|
7639 7767 | S::Future: Send + 'static,
|
7640 7768 | {
|
7641 7769 | self.malformed_content_type_with_payload =
|
7642 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7770 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7643 7771 | self
|
7644 7772 | }
|
7645 7773 |
|
7646 7774 | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
7647 7775 | ///
|
7648 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7649 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7776 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7777 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7650 7778 | ///
|
7651 7779 | /// # Example
|
7652 7780 | ///
|
7653 7781 | /// ```no_run
|
7654 7782 | /// use rest_json::{RestJson, RestJsonConfig};
|
7655 7783 | ///
|
7656 7784 | /// use rest_json::{input, output, error};
|
7657 7785 | ///
|
7658 7786 | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
7659 7787 | /// todo!()
|
7660 7788 | /// }
|
7661 7789 | ///
|
7662 7790 | /// let config = RestJsonConfig::builder().build();
|
7663 7791 | /// let app = RestJson::builder(config)
|
7664 7792 | /// .malformed_double(handler)
|
7665 7793 | /// /* Set other handlers */
|
7666 7794 | /// .build()
|
7667 7795 | /// .unwrap();
|
7668 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7796 + | /// # 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;
|
7669 7797 | /// ```
|
7670 7798 | ///
|
7671 7799 | pub fn malformed_double<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7672 7800 | where
|
7673 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedDouble, HandlerExtractors>,
|
7801 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedDouble, HandlerExtractors>,
|
7674 7802 |
|
7675 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7803 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7676 7804 | RestJson<L>,
|
7677 7805 | crate::operation_shape::MalformedDouble,
|
7678 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedDouble, HandlerType>
|
7806 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedDouble, HandlerType>
|
7679 7807 | >,
|
7680 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7808 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7681 7809 | RestJson<L>,
|
7682 7810 | crate::operation_shape::MalformedDouble,
|
7683 7811 | ModelPl::Output
|
7684 7812 | >,
|
7685 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7813 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7686 7814 | RestJson<L>,
|
7687 7815 | crate::operation_shape::MalformedDouble,
|
7688 7816 | <
|
7689 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7690 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7817 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7818 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7691 7819 | RestJson<L>,
|
7692 7820 | crate::operation_shape::MalformedDouble,
|
7693 7821 | ModelPl::Output
|
7694 7822 | >
|
7695 7823 | >::Output
|
7696 7824 | >,
|
7697 7825 |
|
7698 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7826 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7699 7827 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7700 7828 |
|
7701 7829 | {
|
7702 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7703 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7830 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7831 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7704 7832 | let svc = crate::operation_shape::MalformedDouble::from_handler(handler);
|
7705 7833 | let svc = self.model_plugin.apply(svc);
|
7706 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7834 + | let svc =
|
7835 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7707 7836 | .apply(svc);
|
7708 7837 | let svc = self.http_plugin.apply(svc);
|
7709 7838 | self.malformed_double_custom(svc)
|
7710 7839 | }
|
7711 7840 |
|
7712 7841 | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) operation.
|
7713 7842 | ///
|
7714 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7715 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7843 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7844 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7716 7845 | ///
|
7717 7846 | /// # Example
|
7718 7847 | ///
|
7719 7848 | /// ```no_run
|
7720 7849 | /// use rest_json::{RestJson, RestJsonConfig};
|
7721 7850 | ///
|
7722 7851 | /// use rest_json::{input, output, error};
|
7723 7852 | ///
|
7724 7853 | /// async fn handler(input: input::MalformedDoubleInput) -> Result<output::MalformedDoubleOutput, error::MalformedDoubleError> {
|
7725 7854 | /// todo!()
|
7726 7855 | /// }
|
7727 7856 | ///
|
7728 7857 | /// let config = RestJsonConfig::builder().build();
|
7729 7858 | /// let svc = ::tower::util::service_fn(handler);
|
7730 7859 | /// let app = RestJson::builder(config)
|
7731 7860 | /// .malformed_double_service(svc)
|
7732 7861 | /// /* Set other handlers */
|
7733 7862 | /// .build()
|
7734 7863 | /// .unwrap();
|
7735 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7864 + | /// # 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;
|
7736 7865 | /// ```
|
7737 7866 | ///
|
7738 7867 | pub fn malformed_double_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7739 7868 | where
|
7740 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedDouble, ServiceExtractors>,
|
7869 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedDouble, ServiceExtractors>,
|
7741 7870 |
|
7742 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7871 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7743 7872 | RestJson<L>,
|
7744 7873 | crate::operation_shape::MalformedDouble,
|
7745 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedDouble, S>
|
7874 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedDouble, S>
|
7746 7875 | >,
|
7747 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7876 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7748 7877 | RestJson<L>,
|
7749 7878 | crate::operation_shape::MalformedDouble,
|
7750 7879 | ModelPl::Output
|
7751 7880 | >,
|
7752 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7881 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7753 7882 | RestJson<L>,
|
7754 7883 | crate::operation_shape::MalformedDouble,
|
7755 7884 | <
|
7756 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7757 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7885 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7886 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7758 7887 | RestJson<L>,
|
7759 7888 | crate::operation_shape::MalformedDouble,
|
7760 7889 | ModelPl::Output
|
7761 7890 | >
|
7762 7891 | >::Output
|
7763 7892 | >,
|
7764 7893 |
|
7765 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7894 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7766 7895 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7767 7896 |
|
7768 7897 | {
|
7769 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7770 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7898 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7899 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7771 7900 | let svc = crate::operation_shape::MalformedDouble::from_service(service);
|
7772 7901 | let svc = self.model_plugin.apply(svc);
|
7773 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7902 + | let svc =
|
7903 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7774 7904 | .apply(svc);
|
7775 7905 | let svc = self.http_plugin.apply(svc);
|
7776 7906 | self.malformed_double_custom(svc)
|
7777 7907 | }
|
7778 7908 |
|
7779 7909 | /// Sets the [`MalformedDouble`](crate::operation_shape::MalformedDouble) to a custom [`Service`](tower::Service).
|
7780 7910 | /// not constrained by the Smithy contract.
|
7781 7911 | fn malformed_double_custom<S>(mut self, svc: S) -> Self
|
7782 7912 | where
|
7783 7913 | S: ::tower::Service<
|
7784 7914 | ::http::Request<Body>,
|
7785 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
7915 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7786 7916 | Error = ::std::convert::Infallible,
|
7787 7917 | > + Clone
|
7788 7918 | + Send
|
7789 7919 | + 'static,
|
7790 7920 | S::Future: Send + 'static,
|
7791 7921 | {
|
7792 - | self.malformed_double = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
7922 + | self.malformed_double = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7793 7923 | self
|
7794 7924 | }
|
7795 7925 |
|
7796 7926 | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
7797 7927 | ///
|
7798 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7799 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7928 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7929 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7800 7930 | ///
|
7801 7931 | /// # Example
|
7802 7932 | ///
|
7803 7933 | /// ```no_run
|
7804 7934 | /// use rest_json::{RestJson, RestJsonConfig};
|
7805 7935 | ///
|
7806 7936 | /// use rest_json::{input, output, error};
|
7807 7937 | ///
|
7808 7938 | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
7809 7939 | /// todo!()
|
7810 7940 | /// }
|
7811 7941 | ///
|
7812 7942 | /// let config = RestJsonConfig::builder().build();
|
7813 7943 | /// let app = RestJson::builder(config)
|
7814 7944 | /// .malformed_float(handler)
|
7815 7945 | /// /* Set other handlers */
|
7816 7946 | /// .build()
|
7817 7947 | /// .unwrap();
|
7818 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
7948 + | /// # 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;
|
7819 7949 | /// ```
|
7820 7950 | ///
|
7821 7951 | pub fn malformed_float<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7822 7952 | where
|
7823 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedFloat, HandlerExtractors>,
|
7953 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedFloat, HandlerExtractors>,
|
7824 7954 |
|
7825 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
7955 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7826 7956 | RestJson<L>,
|
7827 7957 | crate::operation_shape::MalformedFloat,
|
7828 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedFloat, HandlerType>
|
7958 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedFloat, HandlerType>
|
7829 7959 | >,
|
7830 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
7960 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7831 7961 | RestJson<L>,
|
7832 7962 | crate::operation_shape::MalformedFloat,
|
7833 7963 | ModelPl::Output
|
7834 7964 | >,
|
7835 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
7965 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7836 7966 | RestJson<L>,
|
7837 7967 | crate::operation_shape::MalformedFloat,
|
7838 7968 | <
|
7839 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7840 - | as ::aws_smithy_http_server::plugin::Plugin<
|
7969 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7970 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7841 7971 | RestJson<L>,
|
7842 7972 | crate::operation_shape::MalformedFloat,
|
7843 7973 | ModelPl::Output
|
7844 7974 | >
|
7845 7975 | >::Output
|
7846 7976 | >,
|
7847 7977 |
|
7848 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7978 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7849 7979 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7850 7980 |
|
7851 7981 | {
|
7852 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7853 - | use ::aws_smithy_http_server::plugin::Plugin;
|
7982 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
7983 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7854 7984 | let svc = crate::operation_shape::MalformedFloat::from_handler(handler);
|
7855 7985 | let svc = self.model_plugin.apply(svc);
|
7856 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7986 + | let svc =
|
7987 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7857 7988 | .apply(svc);
|
7858 7989 | let svc = self.http_plugin.apply(svc);
|
7859 7990 | self.malformed_float_custom(svc)
|
7860 7991 | }
|
7861 7992 |
|
7862 7993 | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) operation.
|
7863 7994 | ///
|
7864 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7865 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
7995 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
7996 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7866 7997 | ///
|
7867 7998 | /// # Example
|
7868 7999 | ///
|
7869 8000 | /// ```no_run
|
7870 8001 | /// use rest_json::{RestJson, RestJsonConfig};
|
7871 8002 | ///
|
7872 8003 | /// use rest_json::{input, output, error};
|
7873 8004 | ///
|
7874 8005 | /// async fn handler(input: input::MalformedFloatInput) -> Result<output::MalformedFloatOutput, error::MalformedFloatError> {
|
7875 8006 | /// todo!()
|
7876 8007 | /// }
|
7877 8008 | ///
|
7878 8009 | /// let config = RestJsonConfig::builder().build();
|
7879 8010 | /// let svc = ::tower::util::service_fn(handler);
|
7880 8011 | /// let app = RestJson::builder(config)
|
7881 8012 | /// .malformed_float_service(svc)
|
7882 8013 | /// /* Set other handlers */
|
7883 8014 | /// .build()
|
7884 8015 | /// .unwrap();
|
7885 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8016 + | /// # 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;
|
7886 8017 | /// ```
|
7887 8018 | ///
|
7888 8019 | pub fn malformed_float_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
7889 8020 | where
|
7890 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedFloat, ServiceExtractors>,
|
8021 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedFloat, ServiceExtractors>,
|
7891 8022 |
|
7892 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8023 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7893 8024 | RestJson<L>,
|
7894 8025 | crate::operation_shape::MalformedFloat,
|
7895 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedFloat, S>
|
8026 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedFloat, S>
|
7896 8027 | >,
|
7897 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8028 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7898 8029 | RestJson<L>,
|
7899 8030 | crate::operation_shape::MalformedFloat,
|
7900 8031 | ModelPl::Output
|
7901 8032 | >,
|
7902 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8033 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7903 8034 | RestJson<L>,
|
7904 8035 | crate::operation_shape::MalformedFloat,
|
7905 8036 | <
|
7906 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7907 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8037 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8038 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7908 8039 | RestJson<L>,
|
7909 8040 | crate::operation_shape::MalformedFloat,
|
7910 8041 | ModelPl::Output
|
7911 8042 | >
|
7912 8043 | >::Output
|
7913 8044 | >,
|
7914 8045 |
|
7915 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8046 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7916 8047 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
7917 8048 |
|
7918 8049 | {
|
7919 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
7920 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8050 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8051 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
7921 8052 | let svc = crate::operation_shape::MalformedFloat::from_service(service);
|
7922 8053 | let svc = self.model_plugin.apply(svc);
|
7923 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8054 + | let svc =
|
8055 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
7924 8056 | .apply(svc);
|
7925 8057 | let svc = self.http_plugin.apply(svc);
|
7926 8058 | self.malformed_float_custom(svc)
|
7927 8059 | }
|
7928 8060 |
|
7929 8061 | /// Sets the [`MalformedFloat`](crate::operation_shape::MalformedFloat) to a custom [`Service`](tower::Service).
|
7930 8062 | /// not constrained by the Smithy contract.
|
7931 8063 | fn malformed_float_custom<S>(mut self, svc: S) -> Self
|
7932 8064 | where
|
7933 8065 | S: ::tower::Service<
|
7934 8066 | ::http::Request<Body>,
|
7935 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8067 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
7936 8068 | Error = ::std::convert::Infallible,
|
7937 8069 | > + Clone
|
7938 8070 | + Send
|
7939 8071 | + 'static,
|
7940 8072 | S::Future: Send + 'static,
|
7941 8073 | {
|
7942 - | self.malformed_float = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8074 + | self.malformed_float = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
7943 8075 | self
|
7944 8076 | }
|
7945 8077 |
|
7946 8078 | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
7947 8079 | ///
|
7948 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
7949 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8080 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8081 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
7950 8082 | ///
|
7951 8083 | /// # Example
|
7952 8084 | ///
|
7953 8085 | /// ```no_run
|
7954 8086 | /// use rest_json::{RestJson, RestJsonConfig};
|
7955 8087 | ///
|
7956 8088 | /// use rest_json::{input, output, error};
|
7957 8089 | ///
|
7958 8090 | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
7959 8091 | /// todo!()
|
7960 8092 | /// }
|
7961 8093 | ///
|
7962 8094 | /// let config = RestJsonConfig::builder().build();
|
7963 8095 | /// let app = RestJson::builder(config)
|
7964 8096 | /// .malformed_integer(handler)
|
7965 8097 | /// /* Set other handlers */
|
7966 8098 | /// .build()
|
7967 8099 | /// .unwrap();
|
7968 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8100 + | /// # 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;
|
7969 8101 | /// ```
|
7970 8102 | ///
|
7971 8103 | pub fn malformed_integer<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
7972 8104 | where
|
7973 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedInteger, HandlerExtractors>,
|
8105 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedInteger, HandlerExtractors>,
|
7974 8106 |
|
7975 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8107 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7976 8108 | RestJson<L>,
|
7977 8109 | crate::operation_shape::MalformedInteger,
|
7978 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedInteger, HandlerType>
|
8110 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedInteger, HandlerType>
|
7979 8111 | >,
|
7980 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8112 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7981 8113 | RestJson<L>,
|
7982 8114 | crate::operation_shape::MalformedInteger,
|
7983 8115 | ModelPl::Output
|
7984 8116 | >,
|
7985 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8117 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7986 8118 | RestJson<L>,
|
7987 8119 | crate::operation_shape::MalformedInteger,
|
7988 8120 | <
|
7989 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
7990 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8121 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8122 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
7991 8123 | RestJson<L>,
|
7992 8124 | crate::operation_shape::MalformedInteger,
|
7993 8125 | ModelPl::Output
|
7994 8126 | >
|
7995 8127 | >::Output
|
7996 8128 | >,
|
7997 8129 |
|
7998 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8130 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
7999 8131 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8000 8132 |
|
8001 8133 | {
|
8002 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8003 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8134 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8135 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8004 8136 | let svc = crate::operation_shape::MalformedInteger::from_handler(handler);
|
8005 8137 | let svc = self.model_plugin.apply(svc);
|
8006 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8138 + | let svc =
|
8139 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8007 8140 | .apply(svc);
|
8008 8141 | let svc = self.http_plugin.apply(svc);
|
8009 8142 | self.malformed_integer_custom(svc)
|
8010 8143 | }
|
8011 8144 |
|
8012 8145 | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) operation.
|
8013 8146 | ///
|
8014 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8015 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8147 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8148 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8016 8149 | ///
|
8017 8150 | /// # Example
|
8018 8151 | ///
|
8019 8152 | /// ```no_run
|
8020 8153 | /// use rest_json::{RestJson, RestJsonConfig};
|
8021 8154 | ///
|
8022 8155 | /// use rest_json::{input, output, error};
|
8023 8156 | ///
|
8024 8157 | /// async fn handler(input: input::MalformedIntegerInput) -> Result<output::MalformedIntegerOutput, error::MalformedIntegerError> {
|
8025 8158 | /// todo!()
|
8026 8159 | /// }
|
8027 8160 | ///
|
8028 8161 | /// let config = RestJsonConfig::builder().build();
|
8029 8162 | /// let svc = ::tower::util::service_fn(handler);
|
8030 8163 | /// let app = RestJson::builder(config)
|
8031 8164 | /// .malformed_integer_service(svc)
|
8032 8165 | /// /* Set other handlers */
|
8033 8166 | /// .build()
|
8034 8167 | /// .unwrap();
|
8035 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8168 + | /// # 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;
|
8036 8169 | /// ```
|
8037 8170 | ///
|
8038 8171 | pub fn malformed_integer_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8039 8172 | where
|
8040 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedInteger, ServiceExtractors>,
|
8173 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedInteger, ServiceExtractors>,
|
8041 8174 |
|
8042 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8175 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8043 8176 | RestJson<L>,
|
8044 8177 | crate::operation_shape::MalformedInteger,
|
8045 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedInteger, S>
|
8178 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedInteger, S>
|
8046 8179 | >,
|
8047 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8180 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8048 8181 | RestJson<L>,
|
8049 8182 | crate::operation_shape::MalformedInteger,
|
8050 8183 | ModelPl::Output
|
8051 8184 | >,
|
8052 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8185 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8053 8186 | RestJson<L>,
|
8054 8187 | crate::operation_shape::MalformedInteger,
|
8055 8188 | <
|
8056 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8057 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8189 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8190 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8058 8191 | RestJson<L>,
|
8059 8192 | crate::operation_shape::MalformedInteger,
|
8060 8193 | ModelPl::Output
|
8061 8194 | >
|
8062 8195 | >::Output
|
8063 8196 | >,
|
8064 8197 |
|
8065 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8198 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8066 8199 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8067 8200 |
|
8068 8201 | {
|
8069 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8070 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8202 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8203 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8071 8204 | let svc = crate::operation_shape::MalformedInteger::from_service(service);
|
8072 8205 | let svc = self.model_plugin.apply(svc);
|
8073 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8206 + | let svc =
|
8207 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8074 8208 | .apply(svc);
|
8075 8209 | let svc = self.http_plugin.apply(svc);
|
8076 8210 | self.malformed_integer_custom(svc)
|
8077 8211 | }
|
8078 8212 |
|
8079 8213 | /// Sets the [`MalformedInteger`](crate::operation_shape::MalformedInteger) to a custom [`Service`](tower::Service).
|
8080 8214 | /// not constrained by the Smithy contract.
|
8081 8215 | fn malformed_integer_custom<S>(mut self, svc: S) -> Self
|
8082 8216 | where
|
8083 8217 | S: ::tower::Service<
|
8084 8218 | ::http::Request<Body>,
|
8085 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8219 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8086 8220 | Error = ::std::convert::Infallible,
|
8087 8221 | > + Clone
|
8088 8222 | + Send
|
8089 8223 | + 'static,
|
8090 8224 | S::Future: Send + 'static,
|
8091 8225 | {
|
8092 - | self.malformed_integer = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8226 + | self.malformed_integer = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8093 8227 | self
|
8094 8228 | }
|
8095 8229 |
|
8096 8230 | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
8097 8231 | ///
|
8098 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8099 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8232 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8233 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8100 8234 | ///
|
8101 8235 | /// # Example
|
8102 8236 | ///
|
8103 8237 | /// ```no_run
|
8104 8238 | /// use rest_json::{RestJson, RestJsonConfig};
|
8105 8239 | ///
|
8106 8240 | /// use rest_json::{input, output, error};
|
8107 8241 | ///
|
8108 8242 | /// async fn handler(input: input::MalformedListInput) -> Result<output::MalformedListOutput, error::MalformedListError> {
|
8109 8243 | /// todo!()
|
8110 8244 | /// }
|
8111 8245 | ///
|
8112 8246 | /// let config = RestJsonConfig::builder().build();
|
8113 8247 | /// let app = RestJson::builder(config)
|
8114 8248 | /// .malformed_list(handler)
|
8115 8249 | /// /* Set other handlers */
|
8116 8250 | /// .build()
|
8117 8251 | /// .unwrap();
|
8118 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8252 + | /// # 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;
|
8119 8253 | /// ```
|
8120 8254 | ///
|
8121 8255 | pub fn malformed_list<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8122 8256 | where
|
8123 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedList, HandlerExtractors>,
|
8257 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedList, HandlerExtractors>,
|
8124 8258 |
|
8125 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8259 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8126 8260 | RestJson<L>,
|
8127 8261 | crate::operation_shape::MalformedList,
|
8128 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedList, HandlerType>
|
8262 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedList, HandlerType>
|
8129 8263 | >,
|
8130 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8264 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8131 8265 | RestJson<L>,
|
8132 8266 | crate::operation_shape::MalformedList,
|
8133 8267 | ModelPl::Output
|
8134 8268 | >,
|
8135 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8269 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8136 8270 | RestJson<L>,
|
8137 8271 | crate::operation_shape::MalformedList,
|
8138 8272 | <
|
8139 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8140 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8273 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8274 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8141 8275 | RestJson<L>,
|
8142 8276 | crate::operation_shape::MalformedList,
|
8143 8277 | ModelPl::Output
|
8144 8278 | >
|
8145 8279 | >::Output
|
8146 8280 | >,
|
8147 8281 |
|
8148 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8282 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8149 8283 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8150 8284 |
|
8151 8285 | {
|
8152 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8153 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8286 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8287 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8154 8288 | let svc = crate::operation_shape::MalformedList::from_handler(handler);
|
8155 8289 | let svc = self.model_plugin.apply(svc);
|
8156 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8290 + | let svc =
|
8291 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8157 8292 | .apply(svc);
|
8158 8293 | let svc = self.http_plugin.apply(svc);
|
8159 8294 | self.malformed_list_custom(svc)
|
8160 8295 | }
|
8161 8296 |
|
8162 8297 | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) operation.
|
8163 8298 | ///
|
8164 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8165 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8299 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8300 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8166 8301 | ///
|
8167 8302 | /// # Example
|
8168 8303 | ///
|
8169 8304 | /// ```no_run
|
8170 8305 | /// use rest_json::{RestJson, RestJsonConfig};
|
8171 8306 | ///
|
8172 8307 | /// use rest_json::{input, output, error};
|
8173 8308 | ///
|
8174 8309 | /// async fn handler(input: input::MalformedListInput) -> Result<output::MalformedListOutput, error::MalformedListError> {
|
8175 8310 | /// todo!()
|
8176 8311 | /// }
|
8177 8312 | ///
|
8178 8313 | /// let config = RestJsonConfig::builder().build();
|
8179 8314 | /// let svc = ::tower::util::service_fn(handler);
|
8180 8315 | /// let app = RestJson::builder(config)
|
8181 8316 | /// .malformed_list_service(svc)
|
8182 8317 | /// /* Set other handlers */
|
8183 8318 | /// .build()
|
8184 8319 | /// .unwrap();
|
8185 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8320 + | /// # 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;
|
8186 8321 | /// ```
|
8187 8322 | ///
|
8188 8323 | pub fn malformed_list_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8189 8324 | where
|
8190 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedList, ServiceExtractors>,
|
8325 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedList, ServiceExtractors>,
|
8191 8326 |
|
8192 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8327 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8193 8328 | RestJson<L>,
|
8194 8329 | crate::operation_shape::MalformedList,
|
8195 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedList, S>
|
8330 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedList, S>
|
8196 8331 | >,
|
8197 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8332 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8198 8333 | RestJson<L>,
|
8199 8334 | crate::operation_shape::MalformedList,
|
8200 8335 | ModelPl::Output
|
8201 8336 | >,
|
8202 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8337 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8203 8338 | RestJson<L>,
|
8204 8339 | crate::operation_shape::MalformedList,
|
8205 8340 | <
|
8206 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8207 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8341 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8342 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8208 8343 | RestJson<L>,
|
8209 8344 | crate::operation_shape::MalformedList,
|
8210 8345 | ModelPl::Output
|
8211 8346 | >
|
8212 8347 | >::Output
|
8213 8348 | >,
|
8214 8349 |
|
8215 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8350 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8216 8351 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8217 8352 |
|
8218 8353 | {
|
8219 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8220 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8354 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8355 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8221 8356 | let svc = crate::operation_shape::MalformedList::from_service(service);
|
8222 8357 | let svc = self.model_plugin.apply(svc);
|
8223 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8358 + | let svc =
|
8359 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8224 8360 | .apply(svc);
|
8225 8361 | let svc = self.http_plugin.apply(svc);
|
8226 8362 | self.malformed_list_custom(svc)
|
8227 8363 | }
|
8228 8364 |
|
8229 8365 | /// Sets the [`MalformedList`](crate::operation_shape::MalformedList) to a custom [`Service`](tower::Service).
|
8230 8366 | /// not constrained by the Smithy contract.
|
8231 8367 | fn malformed_list_custom<S>(mut self, svc: S) -> Self
|
8232 8368 | where
|
8233 8369 | S: ::tower::Service<
|
8234 8370 | ::http::Request<Body>,
|
8235 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8371 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8236 8372 | Error = ::std::convert::Infallible,
|
8237 8373 | > + Clone
|
8238 8374 | + Send
|
8239 8375 | + 'static,
|
8240 8376 | S::Future: Send + 'static,
|
8241 8377 | {
|
8242 - | self.malformed_list = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8378 + | self.malformed_list = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8243 8379 | self
|
8244 8380 | }
|
8245 8381 |
|
8246 8382 | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
8247 8383 | ///
|
8248 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8249 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8384 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8385 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8250 8386 | ///
|
8251 8387 | /// # Example
|
8252 8388 | ///
|
8253 8389 | /// ```no_run
|
8254 8390 | /// use rest_json::{RestJson, RestJsonConfig};
|
8255 8391 | ///
|
8256 8392 | /// use rest_json::{input, output, error};
|
8257 8393 | ///
|
8258 8394 | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
8259 8395 | /// todo!()
|
8260 8396 | /// }
|
8261 8397 | ///
|
8262 8398 | /// let config = RestJsonConfig::builder().build();
|
8263 8399 | /// let app = RestJson::builder(config)
|
8264 8400 | /// .malformed_long(handler)
|
8265 8401 | /// /* Set other handlers */
|
8266 8402 | /// .build()
|
8267 8403 | /// .unwrap();
|
8268 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8404 + | /// # 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;
|
8269 8405 | /// ```
|
8270 8406 | ///
|
8271 8407 | pub fn malformed_long<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8272 8408 | where
|
8273 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedLong, HandlerExtractors>,
|
8409 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedLong, HandlerExtractors>,
|
8274 8410 |
|
8275 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8411 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8276 8412 | RestJson<L>,
|
8277 8413 | crate::operation_shape::MalformedLong,
|
8278 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedLong, HandlerType>
|
8414 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedLong, HandlerType>
|
8279 8415 | >,
|
8280 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8416 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8281 8417 | RestJson<L>,
|
8282 8418 | crate::operation_shape::MalformedLong,
|
8283 8419 | ModelPl::Output
|
8284 8420 | >,
|
8285 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8421 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8286 8422 | RestJson<L>,
|
8287 8423 | crate::operation_shape::MalformedLong,
|
8288 8424 | <
|
8289 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8290 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8425 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8426 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8291 8427 | RestJson<L>,
|
8292 8428 | crate::operation_shape::MalformedLong,
|
8293 8429 | ModelPl::Output
|
8294 8430 | >
|
8295 8431 | >::Output
|
8296 8432 | >,
|
8297 8433 |
|
8298 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8434 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8299 8435 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8300 8436 |
|
8301 8437 | {
|
8302 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8303 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8438 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8439 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8304 8440 | let svc = crate::operation_shape::MalformedLong::from_handler(handler);
|
8305 8441 | let svc = self.model_plugin.apply(svc);
|
8306 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8442 + | let svc =
|
8443 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8307 8444 | .apply(svc);
|
8308 8445 | let svc = self.http_plugin.apply(svc);
|
8309 8446 | self.malformed_long_custom(svc)
|
8310 8447 | }
|
8311 8448 |
|
8312 8449 | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) operation.
|
8313 8450 | ///
|
8314 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8315 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8451 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8452 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8316 8453 | ///
|
8317 8454 | /// # Example
|
8318 8455 | ///
|
8319 8456 | /// ```no_run
|
8320 8457 | /// use rest_json::{RestJson, RestJsonConfig};
|
8321 8458 | ///
|
8322 8459 | /// use rest_json::{input, output, error};
|
8323 8460 | ///
|
8324 8461 | /// async fn handler(input: input::MalformedLongInput) -> Result<output::MalformedLongOutput, error::MalformedLongError> {
|
8325 8462 | /// todo!()
|
8326 8463 | /// }
|
8327 8464 | ///
|
8328 8465 | /// let config = RestJsonConfig::builder().build();
|
8329 8466 | /// let svc = ::tower::util::service_fn(handler);
|
8330 8467 | /// let app = RestJson::builder(config)
|
8331 8468 | /// .malformed_long_service(svc)
|
8332 8469 | /// /* Set other handlers */
|
8333 8470 | /// .build()
|
8334 8471 | /// .unwrap();
|
8335 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8472 + | /// # 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;
|
8336 8473 | /// ```
|
8337 8474 | ///
|
8338 8475 | pub fn malformed_long_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8339 8476 | where
|
8340 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedLong, ServiceExtractors>,
|
8477 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedLong, ServiceExtractors>,
|
8341 8478 |
|
8342 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8479 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8343 8480 | RestJson<L>,
|
8344 8481 | crate::operation_shape::MalformedLong,
|
8345 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedLong, S>
|
8482 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedLong, S>
|
8346 8483 | >,
|
8347 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8484 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8348 8485 | RestJson<L>,
|
8349 8486 | crate::operation_shape::MalformedLong,
|
8350 8487 | ModelPl::Output
|
8351 8488 | >,
|
8352 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8489 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8353 8490 | RestJson<L>,
|
8354 8491 | crate::operation_shape::MalformedLong,
|
8355 8492 | <
|
8356 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8357 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8493 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8494 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8358 8495 | RestJson<L>,
|
8359 8496 | crate::operation_shape::MalformedLong,
|
8360 8497 | ModelPl::Output
|
8361 8498 | >
|
8362 8499 | >::Output
|
8363 8500 | >,
|
8364 8501 |
|
8365 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8502 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8366 8503 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8367 8504 |
|
8368 8505 | {
|
8369 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8370 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8506 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8507 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8371 8508 | let svc = crate::operation_shape::MalformedLong::from_service(service);
|
8372 8509 | let svc = self.model_plugin.apply(svc);
|
8373 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8510 + | let svc =
|
8511 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8374 8512 | .apply(svc);
|
8375 8513 | let svc = self.http_plugin.apply(svc);
|
8376 8514 | self.malformed_long_custom(svc)
|
8377 8515 | }
|
8378 8516 |
|
8379 8517 | /// Sets the [`MalformedLong`](crate::operation_shape::MalformedLong) to a custom [`Service`](tower::Service).
|
8380 8518 | /// not constrained by the Smithy contract.
|
8381 8519 | fn malformed_long_custom<S>(mut self, svc: S) -> Self
|
8382 8520 | where
|
8383 8521 | S: ::tower::Service<
|
8384 8522 | ::http::Request<Body>,
|
8385 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8523 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8386 8524 | Error = ::std::convert::Infallible,
|
8387 8525 | > + Clone
|
8388 8526 | + Send
|
8389 8527 | + 'static,
|
8390 8528 | S::Future: Send + 'static,
|
8391 8529 | {
|
8392 - | self.malformed_long = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8530 + | self.malformed_long = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8393 8531 | self
|
8394 8532 | }
|
8395 8533 |
|
8396 8534 | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
8397 8535 | ///
|
8398 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8399 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8536 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8537 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8400 8538 | ///
|
8401 8539 | /// # Example
|
8402 8540 | ///
|
8403 8541 | /// ```no_run
|
8404 8542 | /// use rest_json::{RestJson, RestJsonConfig};
|
8405 8543 | ///
|
8406 8544 | /// use rest_json::{input, output, error};
|
8407 8545 | ///
|
8408 8546 | /// async fn handler(input: input::MalformedMapInput) -> Result<output::MalformedMapOutput, error::MalformedMapError> {
|
8409 8547 | /// todo!()
|
8410 8548 | /// }
|
8411 8549 | ///
|
8412 8550 | /// let config = RestJsonConfig::builder().build();
|
8413 8551 | /// let app = RestJson::builder(config)
|
8414 8552 | /// .malformed_map(handler)
|
8415 8553 | /// /* Set other handlers */
|
8416 8554 | /// .build()
|
8417 8555 | /// .unwrap();
|
8418 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8556 + | /// # 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;
|
8419 8557 | /// ```
|
8420 8558 | ///
|
8421 8559 | pub fn malformed_map<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8422 8560 | where
|
8423 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedMap, HandlerExtractors>,
|
8561 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedMap, HandlerExtractors>,
|
8424 8562 |
|
8425 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8563 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8426 8564 | RestJson<L>,
|
8427 8565 | crate::operation_shape::MalformedMap,
|
8428 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedMap, HandlerType>
|
8566 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedMap, HandlerType>
|
8429 8567 | >,
|
8430 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8568 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8431 8569 | RestJson<L>,
|
8432 8570 | crate::operation_shape::MalformedMap,
|
8433 8571 | ModelPl::Output
|
8434 8572 | >,
|
8435 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8573 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8436 8574 | RestJson<L>,
|
8437 8575 | crate::operation_shape::MalformedMap,
|
8438 8576 | <
|
8439 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8440 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8577 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8578 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8441 8579 | RestJson<L>,
|
8442 8580 | crate::operation_shape::MalformedMap,
|
8443 8581 | ModelPl::Output
|
8444 8582 | >
|
8445 8583 | >::Output
|
8446 8584 | >,
|
8447 8585 |
|
8448 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8586 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8449 8587 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8450 8588 |
|
8451 8589 | {
|
8452 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8453 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8590 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8591 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8454 8592 | let svc = crate::operation_shape::MalformedMap::from_handler(handler);
|
8455 8593 | let svc = self.model_plugin.apply(svc);
|
8456 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8594 + | let svc =
|
8595 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8457 8596 | .apply(svc);
|
8458 8597 | let svc = self.http_plugin.apply(svc);
|
8459 8598 | self.malformed_map_custom(svc)
|
8460 8599 | }
|
8461 8600 |
|
8462 8601 | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) operation.
|
8463 8602 | ///
|
8464 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8465 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8603 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8604 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8466 8605 | ///
|
8467 8606 | /// # Example
|
8468 8607 | ///
|
8469 8608 | /// ```no_run
|
8470 8609 | /// use rest_json::{RestJson, RestJsonConfig};
|
8471 8610 | ///
|
8472 8611 | /// use rest_json::{input, output, error};
|
8473 8612 | ///
|
8474 8613 | /// async fn handler(input: input::MalformedMapInput) -> Result<output::MalformedMapOutput, error::MalformedMapError> {
|
8475 8614 | /// todo!()
|
8476 8615 | /// }
|
8477 8616 | ///
|
8478 8617 | /// let config = RestJsonConfig::builder().build();
|
8479 8618 | /// let svc = ::tower::util::service_fn(handler);
|
8480 8619 | /// let app = RestJson::builder(config)
|
8481 8620 | /// .malformed_map_service(svc)
|
8482 8621 | /// /* Set other handlers */
|
8483 8622 | /// .build()
|
8484 8623 | /// .unwrap();
|
8485 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8624 + | /// # 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;
|
8486 8625 | /// ```
|
8487 8626 | ///
|
8488 8627 | pub fn malformed_map_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8489 8628 | where
|
8490 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedMap, ServiceExtractors>,
|
8629 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedMap, ServiceExtractors>,
|
8491 8630 |
|
8492 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8631 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8493 8632 | RestJson<L>,
|
8494 8633 | crate::operation_shape::MalformedMap,
|
8495 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedMap, S>
|
8634 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedMap, S>
|
8496 8635 | >,
|
8497 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8636 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8498 8637 | RestJson<L>,
|
8499 8638 | crate::operation_shape::MalformedMap,
|
8500 8639 | ModelPl::Output
|
8501 8640 | >,
|
8502 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8641 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8503 8642 | RestJson<L>,
|
8504 8643 | crate::operation_shape::MalformedMap,
|
8505 8644 | <
|
8506 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8507 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8645 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8646 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8508 8647 | RestJson<L>,
|
8509 8648 | crate::operation_shape::MalformedMap,
|
8510 8649 | ModelPl::Output
|
8511 8650 | >
|
8512 8651 | >::Output
|
8513 8652 | >,
|
8514 8653 |
|
8515 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8654 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8516 8655 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8517 8656 |
|
8518 8657 | {
|
8519 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8520 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8658 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8659 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8521 8660 | let svc = crate::operation_shape::MalformedMap::from_service(service);
|
8522 8661 | let svc = self.model_plugin.apply(svc);
|
8523 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8662 + | let svc =
|
8663 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8524 8664 | .apply(svc);
|
8525 8665 | let svc = self.http_plugin.apply(svc);
|
8526 8666 | self.malformed_map_custom(svc)
|
8527 8667 | }
|
8528 8668 |
|
8529 8669 | /// Sets the [`MalformedMap`](crate::operation_shape::MalformedMap) to a custom [`Service`](tower::Service).
|
8530 8670 | /// not constrained by the Smithy contract.
|
8531 8671 | fn malformed_map_custom<S>(mut self, svc: S) -> Self
|
8532 8672 | where
|
8533 8673 | S: ::tower::Service<
|
8534 8674 | ::http::Request<Body>,
|
8535 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8675 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8536 8676 | Error = ::std::convert::Infallible,
|
8537 8677 | > + Clone
|
8538 8678 | + Send
|
8539 8679 | + 'static,
|
8540 8680 | S::Future: Send + 'static,
|
8541 8681 | {
|
8542 - | self.malformed_map = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8682 + | self.malformed_map = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8543 8683 | self
|
8544 8684 | }
|
8545 8685 |
|
8546 8686 | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
8547 8687 | ///
|
8548 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8549 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8688 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8689 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8550 8690 | ///
|
8551 8691 | /// # Example
|
8552 8692 | ///
|
8553 8693 | /// ```no_run
|
8554 8694 | /// use rest_json::{RestJson, RestJsonConfig};
|
8555 8695 | ///
|
8556 8696 | /// use rest_json::{input, output, error};
|
8557 8697 | ///
|
8558 8698 | /// async fn handler(input: input::MalformedRequestBodyInput) -> Result<output::MalformedRequestBodyOutput, error::MalformedRequestBodyError> {
|
8559 8699 | /// todo!()
|
8560 8700 | /// }
|
8561 8701 | ///
|
8562 8702 | /// let config = RestJsonConfig::builder().build();
|
8563 8703 | /// let app = RestJson::builder(config)
|
8564 8704 | /// .malformed_request_body(handler)
|
8565 8705 | /// /* Set other handlers */
|
8566 8706 | /// .build()
|
8567 8707 | /// .unwrap();
|
8568 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8708 + | /// # 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;
|
8569 8709 | /// ```
|
8570 8710 | ///
|
8571 8711 | pub fn malformed_request_body<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8572 8712 | where
|
8573 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedRequestBody, HandlerExtractors>,
|
8713 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedRequestBody, HandlerExtractors>,
|
8574 8714 |
|
8575 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8715 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8576 8716 | RestJson<L>,
|
8577 8717 | crate::operation_shape::MalformedRequestBody,
|
8578 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedRequestBody, HandlerType>
|
8718 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedRequestBody, HandlerType>
|
8579 8719 | >,
|
8580 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8720 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8581 8721 | RestJson<L>,
|
8582 8722 | crate::operation_shape::MalformedRequestBody,
|
8583 8723 | ModelPl::Output
|
8584 8724 | >,
|
8585 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8725 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8586 8726 | RestJson<L>,
|
8587 8727 | crate::operation_shape::MalformedRequestBody,
|
8588 8728 | <
|
8589 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8590 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8729 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8730 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8591 8731 | RestJson<L>,
|
8592 8732 | crate::operation_shape::MalformedRequestBody,
|
8593 8733 | ModelPl::Output
|
8594 8734 | >
|
8595 8735 | >::Output
|
8596 8736 | >,
|
8597 8737 |
|
8598 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8738 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8599 8739 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8600 8740 |
|
8601 8741 | {
|
8602 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8603 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8742 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8743 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8604 8744 | let svc = crate::operation_shape::MalformedRequestBody::from_handler(handler);
|
8605 8745 | let svc = self.model_plugin.apply(svc);
|
8606 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8746 + | let svc =
|
8747 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8607 8748 | .apply(svc);
|
8608 8749 | let svc = self.http_plugin.apply(svc);
|
8609 8750 | self.malformed_request_body_custom(svc)
|
8610 8751 | }
|
8611 8752 |
|
8612 8753 | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) operation.
|
8613 8754 | ///
|
8614 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8615 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8755 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8756 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8616 8757 | ///
|
8617 8758 | /// # Example
|
8618 8759 | ///
|
8619 8760 | /// ```no_run
|
8620 8761 | /// use rest_json::{RestJson, RestJsonConfig};
|
8621 8762 | ///
|
8622 8763 | /// use rest_json::{input, output, error};
|
8623 8764 | ///
|
8624 8765 | /// async fn handler(input: input::MalformedRequestBodyInput) -> Result<output::MalformedRequestBodyOutput, error::MalformedRequestBodyError> {
|
8625 8766 | /// todo!()
|
8626 8767 | /// }
|
8627 8768 | ///
|
8628 8769 | /// let config = RestJsonConfig::builder().build();
|
8629 8770 | /// let svc = ::tower::util::service_fn(handler);
|
8630 8771 | /// let app = RestJson::builder(config)
|
8631 8772 | /// .malformed_request_body_service(svc)
|
8632 8773 | /// /* Set other handlers */
|
8633 8774 | /// .build()
|
8634 8775 | /// .unwrap();
|
8635 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8776 + | /// # 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;
|
8636 8777 | /// ```
|
8637 8778 | ///
|
8638 8779 | pub fn malformed_request_body_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8639 8780 | where
|
8640 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedRequestBody, ServiceExtractors>,
|
8781 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedRequestBody, ServiceExtractors>,
|
8641 8782 |
|
8642 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8783 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8643 8784 | RestJson<L>,
|
8644 8785 | crate::operation_shape::MalformedRequestBody,
|
8645 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedRequestBody, S>
|
8786 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedRequestBody, S>
|
8646 8787 | >,
|
8647 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8788 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8648 8789 | RestJson<L>,
|
8649 8790 | crate::operation_shape::MalformedRequestBody,
|
8650 8791 | ModelPl::Output
|
8651 8792 | >,
|
8652 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8793 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8653 8794 | RestJson<L>,
|
8654 8795 | crate::operation_shape::MalformedRequestBody,
|
8655 8796 | <
|
8656 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8657 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8797 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8798 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8658 8799 | RestJson<L>,
|
8659 8800 | crate::operation_shape::MalformedRequestBody,
|
8660 8801 | ModelPl::Output
|
8661 8802 | >
|
8662 8803 | >::Output
|
8663 8804 | >,
|
8664 8805 |
|
8665 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8806 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8666 8807 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8667 8808 |
|
8668 8809 | {
|
8669 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8670 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8810 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8811 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8671 8812 | let svc = crate::operation_shape::MalformedRequestBody::from_service(service);
|
8672 8813 | let svc = self.model_plugin.apply(svc);
|
8673 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8814 + | let svc =
|
8815 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8674 8816 | .apply(svc);
|
8675 8817 | let svc = self.http_plugin.apply(svc);
|
8676 8818 | self.malformed_request_body_custom(svc)
|
8677 8819 | }
|
8678 8820 |
|
8679 8821 | /// Sets the [`MalformedRequestBody`](crate::operation_shape::MalformedRequestBody) to a custom [`Service`](tower::Service).
|
8680 8822 | /// not constrained by the Smithy contract.
|
8681 8823 | fn malformed_request_body_custom<S>(mut self, svc: S) -> Self
|
8682 8824 | where
|
8683 8825 | S: ::tower::Service<
|
8684 8826 | ::http::Request<Body>,
|
8685 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8827 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8686 8828 | Error = ::std::convert::Infallible,
|
8687 8829 | > + Clone
|
8688 8830 | + Send
|
8689 8831 | + 'static,
|
8690 8832 | S::Future: Send + 'static,
|
8691 8833 | {
|
8692 - | self.malformed_request_body = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8834 + | self.malformed_request_body =
|
8835 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8693 8836 | self
|
8694 8837 | }
|
8695 8838 |
|
8696 8839 | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
8697 8840 | ///
|
8698 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8699 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8841 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8842 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8700 8843 | ///
|
8701 8844 | /// # Example
|
8702 8845 | ///
|
8703 8846 | /// ```no_run
|
8704 8847 | /// use rest_json::{RestJson, RestJsonConfig};
|
8705 8848 | ///
|
8706 8849 | /// use rest_json::{input, output, error};
|
8707 8850 | ///
|
8708 8851 | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
8709 8852 | /// todo!()
|
8710 8853 | /// }
|
8711 8854 | ///
|
8712 8855 | /// let config = RestJsonConfig::builder().build();
|
8713 8856 | /// let app = RestJson::builder(config)
|
8714 8857 | /// .malformed_short(handler)
|
8715 8858 | /// /* Set other handlers */
|
8716 8859 | /// .build()
|
8717 8860 | /// .unwrap();
|
8718 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8861 + | /// # 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;
|
8719 8862 | /// ```
|
8720 8863 | ///
|
8721 8864 | pub fn malformed_short<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8722 8865 | where
|
8723 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedShort, HandlerExtractors>,
|
8866 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedShort, HandlerExtractors>,
|
8724 8867 |
|
8725 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8868 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8726 8869 | RestJson<L>,
|
8727 8870 | crate::operation_shape::MalformedShort,
|
8728 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedShort, HandlerType>
|
8871 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedShort, HandlerType>
|
8729 8872 | >,
|
8730 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8873 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8731 8874 | RestJson<L>,
|
8732 8875 | crate::operation_shape::MalformedShort,
|
8733 8876 | ModelPl::Output
|
8734 8877 | >,
|
8735 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8878 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8736 8879 | RestJson<L>,
|
8737 8880 | crate::operation_shape::MalformedShort,
|
8738 8881 | <
|
8739 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8740 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8882 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8883 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8741 8884 | RestJson<L>,
|
8742 8885 | crate::operation_shape::MalformedShort,
|
8743 8886 | ModelPl::Output
|
8744 8887 | >
|
8745 8888 | >::Output
|
8746 8889 | >,
|
8747 8890 |
|
8748 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8891 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8749 8892 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8750 8893 |
|
8751 8894 | {
|
8752 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8753 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8895 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8896 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8754 8897 | let svc = crate::operation_shape::MalformedShort::from_handler(handler);
|
8755 8898 | let svc = self.model_plugin.apply(svc);
|
8756 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8899 + | let svc =
|
8900 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8757 8901 | .apply(svc);
|
8758 8902 | let svc = self.http_plugin.apply(svc);
|
8759 8903 | self.malformed_short_custom(svc)
|
8760 8904 | }
|
8761 8905 |
|
8762 8906 | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) operation.
|
8763 8907 | ///
|
8764 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8765 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8908 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8909 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8766 8910 | ///
|
8767 8911 | /// # Example
|
8768 8912 | ///
|
8769 8913 | /// ```no_run
|
8770 8914 | /// use rest_json::{RestJson, RestJsonConfig};
|
8771 8915 | ///
|
8772 8916 | /// use rest_json::{input, output, error};
|
8773 8917 | ///
|
8774 8918 | /// async fn handler(input: input::MalformedShortInput) -> Result<output::MalformedShortOutput, error::MalformedShortError> {
|
8775 8919 | /// todo!()
|
8776 8920 | /// }
|
8777 8921 | ///
|
8778 8922 | /// let config = RestJsonConfig::builder().build();
|
8779 8923 | /// let svc = ::tower::util::service_fn(handler);
|
8780 8924 | /// let app = RestJson::builder(config)
|
8781 8925 | /// .malformed_short_service(svc)
|
8782 8926 | /// /* Set other handlers */
|
8783 8927 | /// .build()
|
8784 8928 | /// .unwrap();
|
8785 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
8929 + | /// # 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;
|
8786 8930 | /// ```
|
8787 8931 | ///
|
8788 8932 | pub fn malformed_short_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8789 8933 | where
|
8790 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedShort, ServiceExtractors>,
|
8934 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedShort, ServiceExtractors>,
|
8791 8935 |
|
8792 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
8936 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8793 8937 | RestJson<L>,
|
8794 8938 | crate::operation_shape::MalformedShort,
|
8795 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedShort, S>
|
8939 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedShort, S>
|
8796 8940 | >,
|
8797 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
8941 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8798 8942 | RestJson<L>,
|
8799 8943 | crate::operation_shape::MalformedShort,
|
8800 8944 | ModelPl::Output
|
8801 8945 | >,
|
8802 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
8946 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8803 8947 | RestJson<L>,
|
8804 8948 | crate::operation_shape::MalformedShort,
|
8805 8949 | <
|
8806 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8807 - | as ::aws_smithy_http_server::plugin::Plugin<
|
8950 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8951 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8808 8952 | RestJson<L>,
|
8809 8953 | crate::operation_shape::MalformedShort,
|
8810 8954 | ModelPl::Output
|
8811 8955 | >
|
8812 8956 | >::Output
|
8813 8957 | >,
|
8814 8958 |
|
8815 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8959 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8816 8960 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8817 8961 |
|
8818 8962 | {
|
8819 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8820 - | use ::aws_smithy_http_server::plugin::Plugin;
|
8963 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
8964 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8821 8965 | let svc = crate::operation_shape::MalformedShort::from_service(service);
|
8822 8966 | let svc = self.model_plugin.apply(svc);
|
8823 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8967 + | let svc =
|
8968 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8824 8969 | .apply(svc);
|
8825 8970 | let svc = self.http_plugin.apply(svc);
|
8826 8971 | self.malformed_short_custom(svc)
|
8827 8972 | }
|
8828 8973 |
|
8829 8974 | /// Sets the [`MalformedShort`](crate::operation_shape::MalformedShort) to a custom [`Service`](tower::Service).
|
8830 8975 | /// not constrained by the Smithy contract.
|
8831 8976 | fn malformed_short_custom<S>(mut self, svc: S) -> Self
|
8832 8977 | where
|
8833 8978 | S: ::tower::Service<
|
8834 8979 | ::http::Request<Body>,
|
8835 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
8980 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8836 8981 | Error = ::std::convert::Infallible,
|
8837 8982 | > + Clone
|
8838 8983 | + Send
|
8839 8984 | + 'static,
|
8840 8985 | S::Future: Send + 'static,
|
8841 8986 | {
|
8842 - | self.malformed_short = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
8987 + | self.malformed_short = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8843 8988 | self
|
8844 8989 | }
|
8845 8990 |
|
8846 8991 | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
8847 8992 | ///
|
8848 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8849 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
8993 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
8994 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8850 8995 | ///
|
8851 8996 | /// # Example
|
8852 8997 | ///
|
8853 8998 | /// ```no_run
|
8854 8999 | /// use rest_json::{RestJson, RestJsonConfig};
|
8855 9000 | ///
|
8856 9001 | /// use rest_json::{input, output, error};
|
8857 9002 | ///
|
8858 9003 | /// async fn handler(input: input::MalformedStringInput) -> Result<output::MalformedStringOutput, error::MalformedStringError> {
|
8859 9004 | /// todo!()
|
8860 9005 | /// }
|
8861 9006 | ///
|
8862 9007 | /// let config = RestJsonConfig::builder().build();
|
8863 9008 | /// let app = RestJson::builder(config)
|
8864 9009 | /// .malformed_string(handler)
|
8865 9010 | /// /* Set other handlers */
|
8866 9011 | /// .build()
|
8867 9012 | /// .unwrap();
|
8868 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9013 + | /// # 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;
|
8869 9014 | /// ```
|
8870 9015 | ///
|
8871 9016 | pub fn malformed_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
8872 9017 | where
|
8873 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedString, HandlerExtractors>,
|
9018 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedString, HandlerExtractors>,
|
8874 9019 |
|
8875 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9020 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8876 9021 | RestJson<L>,
|
8877 9022 | crate::operation_shape::MalformedString,
|
8878 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedString, HandlerType>
|
9023 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedString, HandlerType>
|
8879 9024 | >,
|
8880 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9025 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8881 9026 | RestJson<L>,
|
8882 9027 | crate::operation_shape::MalformedString,
|
8883 9028 | ModelPl::Output
|
8884 9029 | >,
|
8885 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9030 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8886 9031 | RestJson<L>,
|
8887 9032 | crate::operation_shape::MalformedString,
|
8888 9033 | <
|
8889 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8890 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9034 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9035 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8891 9036 | RestJson<L>,
|
8892 9037 | crate::operation_shape::MalformedString,
|
8893 9038 | ModelPl::Output
|
8894 9039 | >
|
8895 9040 | >::Output
|
8896 9041 | >,
|
8897 9042 |
|
8898 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9043 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8899 9044 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8900 9045 |
|
8901 9046 | {
|
8902 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8903 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9047 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9048 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8904 9049 | let svc = crate::operation_shape::MalformedString::from_handler(handler);
|
8905 9050 | let svc = self.model_plugin.apply(svc);
|
8906 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9051 + | let svc =
|
9052 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8907 9053 | .apply(svc);
|
8908 9054 | let svc = self.http_plugin.apply(svc);
|
8909 9055 | self.malformed_string_custom(svc)
|
8910 9056 | }
|
8911 9057 |
|
8912 9058 | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) operation.
|
8913 9059 | ///
|
8914 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8915 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9060 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9061 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
8916 9062 | ///
|
8917 9063 | /// # Example
|
8918 9064 | ///
|
8919 9065 | /// ```no_run
|
8920 9066 | /// use rest_json::{RestJson, RestJsonConfig};
|
8921 9067 | ///
|
8922 9068 | /// use rest_json::{input, output, error};
|
8923 9069 | ///
|
8924 9070 | /// async fn handler(input: input::MalformedStringInput) -> Result<output::MalformedStringOutput, error::MalformedStringError> {
|
8925 9071 | /// todo!()
|
8926 9072 | /// }
|
8927 9073 | ///
|
8928 9074 | /// let config = RestJsonConfig::builder().build();
|
8929 9075 | /// let svc = ::tower::util::service_fn(handler);
|
8930 9076 | /// let app = RestJson::builder(config)
|
8931 9077 | /// .malformed_string_service(svc)
|
8932 9078 | /// /* Set other handlers */
|
8933 9079 | /// .build()
|
8934 9080 | /// .unwrap();
|
8935 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9081 + | /// # 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;
|
8936 9082 | /// ```
|
8937 9083 | ///
|
8938 9084 | pub fn malformed_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
8939 9085 | where
|
8940 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedString, ServiceExtractors>,
|
9086 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedString, ServiceExtractors>,
|
8941 9087 |
|
8942 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9088 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8943 9089 | RestJson<L>,
|
8944 9090 | crate::operation_shape::MalformedString,
|
8945 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedString, S>
|
9091 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedString, S>
|
8946 9092 | >,
|
8947 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9093 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8948 9094 | RestJson<L>,
|
8949 9095 | crate::operation_shape::MalformedString,
|
8950 9096 | ModelPl::Output
|
8951 9097 | >,
|
8952 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9098 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8953 9099 | RestJson<L>,
|
8954 9100 | crate::operation_shape::MalformedString,
|
8955 9101 | <
|
8956 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
8957 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9102 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9103 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
8958 9104 | RestJson<L>,
|
8959 9105 | crate::operation_shape::MalformedString,
|
8960 9106 | ModelPl::Output
|
8961 9107 | >
|
8962 9108 | >::Output
|
8963 9109 | >,
|
8964 9110 |
|
8965 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9111 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
8966 9112 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
8967 9113 |
|
8968 9114 | {
|
8969 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
8970 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9115 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9116 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
8971 9117 | let svc = crate::operation_shape::MalformedString::from_service(service);
|
8972 9118 | let svc = self.model_plugin.apply(svc);
|
8973 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9119 + | let svc =
|
9120 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
8974 9121 | .apply(svc);
|
8975 9122 | let svc = self.http_plugin.apply(svc);
|
8976 9123 | self.malformed_string_custom(svc)
|
8977 9124 | }
|
8978 9125 |
|
8979 9126 | /// Sets the [`MalformedString`](crate::operation_shape::MalformedString) to a custom [`Service`](tower::Service).
|
8980 9127 | /// not constrained by the Smithy contract.
|
8981 9128 | fn malformed_string_custom<S>(mut self, svc: S) -> Self
|
8982 9129 | where
|
8983 9130 | S: ::tower::Service<
|
8984 9131 | ::http::Request<Body>,
|
8985 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9132 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
8986 9133 | Error = ::std::convert::Infallible,
|
8987 9134 | > + Clone
|
8988 9135 | + Send
|
8989 9136 | + 'static,
|
8990 9137 | S::Future: Send + 'static,
|
8991 9138 | {
|
8992 - | self.malformed_string = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9139 + | self.malformed_string = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
8993 9140 | self
|
8994 9141 | }
|
8995 9142 |
|
8996 9143 | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
8997 9144 | ///
|
8998 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
8999 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9145 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9146 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9000 9147 | ///
|
9001 9148 | /// # Example
|
9002 9149 | ///
|
9003 9150 | /// ```no_run
|
9004 9151 | /// use rest_json::{RestJson, RestJsonConfig};
|
9005 9152 | ///
|
9006 9153 | /// use rest_json::{input, output, error};
|
9007 9154 | ///
|
9008 9155 | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
9009 9156 | /// todo!()
|
9010 9157 | /// }
|
9011 9158 | ///
|
9012 9159 | /// let config = RestJsonConfig::builder().build();
|
9013 9160 | /// let app = RestJson::builder(config)
|
9014 9161 | /// .malformed_timestamp_body_date_time(handler)
|
9015 9162 | /// /* Set other handlers */
|
9016 9163 | /// .build()
|
9017 9164 | /// .unwrap();
|
9018 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9165 + | /// # 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;
|
9019 9166 | /// ```
|
9020 9167 | ///
|
9021 9168 | pub fn malformed_timestamp_body_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9022 9169 | where
|
9023 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerExtractors>,
|
9170 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerExtractors>,
|
9024 9171 |
|
9025 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9172 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9026 9173 | RestJson<L>,
|
9027 9174 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9028 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerType>
|
9175 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDateTime, HandlerType>
|
9029 9176 | >,
|
9030 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9177 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9031 9178 | RestJson<L>,
|
9032 9179 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9033 9180 | ModelPl::Output
|
9034 9181 | >,
|
9035 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9182 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9036 9183 | RestJson<L>,
|
9037 9184 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9038 9185 | <
|
9039 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9040 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9186 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9187 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9041 9188 | RestJson<L>,
|
9042 9189 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9043 9190 | ModelPl::Output
|
9044 9191 | >
|
9045 9192 | >::Output
|
9046 9193 | >,
|
9047 9194 |
|
9048 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9195 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9049 9196 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9050 9197 |
|
9051 9198 | {
|
9052 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9053 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9199 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9200 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9054 9201 | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_handler(handler);
|
9055 9202 | let svc = self.model_plugin.apply(svc);
|
9056 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9203 + | let svc =
|
9204 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9057 9205 | .apply(svc);
|
9058 9206 | let svc = self.http_plugin.apply(svc);
|
9059 9207 | self.malformed_timestamp_body_date_time_custom(svc)
|
9060 9208 | }
|
9061 9209 |
|
9062 9210 | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) operation.
|
9063 9211 | ///
|
9064 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9065 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9212 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9213 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9066 9214 | ///
|
9067 9215 | /// # Example
|
9068 9216 | ///
|
9069 9217 | /// ```no_run
|
9070 9218 | /// use rest_json::{RestJson, RestJsonConfig};
|
9071 9219 | ///
|
9072 9220 | /// use rest_json::{input, output, error};
|
9073 9221 | ///
|
9074 9222 | /// async fn handler(input: input::MalformedTimestampBodyDateTimeInput) -> Result<output::MalformedTimestampBodyDateTimeOutput, error::MalformedTimestampBodyDateTimeError> {
|
9075 9223 | /// todo!()
|
9076 9224 | /// }
|
9077 9225 | ///
|
9078 9226 | /// let config = RestJsonConfig::builder().build();
|
9079 9227 | /// let svc = ::tower::util::service_fn(handler);
|
9080 9228 | /// let app = RestJson::builder(config)
|
9081 9229 | /// .malformed_timestamp_body_date_time_service(svc)
|
9082 9230 | /// /* Set other handlers */
|
9083 9231 | /// .build()
|
9084 9232 | /// .unwrap();
|
9085 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9233 + | /// # 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;
|
9086 9234 | /// ```
|
9087 9235 | ///
|
9088 9236 | pub fn malformed_timestamp_body_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9089 9237 | where
|
9090 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDateTime, ServiceExtractors>,
|
9238 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDateTime, ServiceExtractors>,
|
9091 9239 |
|
9092 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9240 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9093 9241 | RestJson<L>,
|
9094 9242 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9095 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDateTime, S>
|
9243 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDateTime, S>
|
9096 9244 | >,
|
9097 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9245 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9098 9246 | RestJson<L>,
|
9099 9247 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9100 9248 | ModelPl::Output
|
9101 9249 | >,
|
9102 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9250 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9103 9251 | RestJson<L>,
|
9104 9252 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9105 9253 | <
|
9106 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9107 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9254 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9255 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9108 9256 | RestJson<L>,
|
9109 9257 | crate::operation_shape::MalformedTimestampBodyDateTime,
|
9110 9258 | ModelPl::Output
|
9111 9259 | >
|
9112 9260 | >::Output
|
9113 9261 | >,
|
9114 9262 |
|
9115 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9263 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9116 9264 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9117 9265 |
|
9118 9266 | {
|
9119 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9120 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9267 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9268 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9121 9269 | let svc = crate::operation_shape::MalformedTimestampBodyDateTime::from_service(service);
|
9122 9270 | let svc = self.model_plugin.apply(svc);
|
9123 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9271 + | let svc =
|
9272 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9124 9273 | .apply(svc);
|
9125 9274 | let svc = self.http_plugin.apply(svc);
|
9126 9275 | self.malformed_timestamp_body_date_time_custom(svc)
|
9127 9276 | }
|
9128 9277 |
|
9129 9278 | /// Sets the [`MalformedTimestampBodyDateTime`](crate::operation_shape::MalformedTimestampBodyDateTime) to a custom [`Service`](tower::Service).
|
9130 9279 | /// not constrained by the Smithy contract.
|
9131 9280 | fn malformed_timestamp_body_date_time_custom<S>(mut self, svc: S) -> Self
|
9132 9281 | where
|
9133 9282 | S: ::tower::Service<
|
9134 9283 | ::http::Request<Body>,
|
9135 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9284 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9136 9285 | Error = ::std::convert::Infallible,
|
9137 9286 | > + Clone
|
9138 9287 | + Send
|
9139 9288 | + 'static,
|
9140 9289 | S::Future: Send + 'static,
|
9141 9290 | {
|
9142 9291 | self.malformed_timestamp_body_date_time =
|
9143 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9292 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9144 9293 | self
|
9145 9294 | }
|
9146 9295 |
|
9147 9296 | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
9148 9297 | ///
|
9149 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9150 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9298 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9299 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9151 9300 | ///
|
9152 9301 | /// # Example
|
9153 9302 | ///
|
9154 9303 | /// ```no_run
|
9155 9304 | /// use rest_json::{RestJson, RestJsonConfig};
|
9156 9305 | ///
|
9157 9306 | /// use rest_json::{input, output, error};
|
9158 9307 | ///
|
9159 9308 | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
9160 9309 | /// todo!()
|
9161 9310 | /// }
|
9162 9311 | ///
|
9163 9312 | /// let config = RestJsonConfig::builder().build();
|
9164 9313 | /// let app = RestJson::builder(config)
|
9165 9314 | /// .malformed_timestamp_body_default(handler)
|
9166 9315 | /// /* Set other handlers */
|
9167 9316 | /// .build()
|
9168 9317 | /// .unwrap();
|
9169 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9318 + | /// # 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;
|
9170 9319 | /// ```
|
9171 9320 | ///
|
9172 9321 | pub fn malformed_timestamp_body_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9173 9322 | where
|
9174 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDefault, HandlerExtractors>,
|
9323 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyDefault, HandlerExtractors>,
|
9175 9324 |
|
9176 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9325 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9177 9326 | RestJson<L>,
|
9178 9327 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9179 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDefault, HandlerType>
|
9328 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyDefault, HandlerType>
|
9180 9329 | >,
|
9181 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9330 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9182 9331 | RestJson<L>,
|
9183 9332 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9184 9333 | ModelPl::Output
|
9185 9334 | >,
|
9186 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9335 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9187 9336 | RestJson<L>,
|
9188 9337 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9189 9338 | <
|
9190 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9191 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9339 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9340 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9192 9341 | RestJson<L>,
|
9193 9342 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9194 9343 | ModelPl::Output
|
9195 9344 | >
|
9196 9345 | >::Output
|
9197 9346 | >,
|
9198 9347 |
|
9199 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9348 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9200 9349 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9201 9350 |
|
9202 9351 | {
|
9203 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9204 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9352 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9353 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9205 9354 | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_handler(handler);
|
9206 9355 | let svc = self.model_plugin.apply(svc);
|
9207 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9356 + | let svc =
|
9357 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9208 9358 | .apply(svc);
|
9209 9359 | let svc = self.http_plugin.apply(svc);
|
9210 9360 | self.malformed_timestamp_body_default_custom(svc)
|
9211 9361 | }
|
9212 9362 |
|
9213 9363 | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) operation.
|
9214 9364 | ///
|
9215 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9216 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9365 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9366 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9217 9367 | ///
|
9218 9368 | /// # Example
|
9219 9369 | ///
|
9220 9370 | /// ```no_run
|
9221 9371 | /// use rest_json::{RestJson, RestJsonConfig};
|
9222 9372 | ///
|
9223 9373 | /// use rest_json::{input, output, error};
|
9224 9374 | ///
|
9225 9375 | /// async fn handler(input: input::MalformedTimestampBodyDefaultInput) -> Result<output::MalformedTimestampBodyDefaultOutput, error::MalformedTimestampBodyDefaultError> {
|
9226 9376 | /// todo!()
|
9227 9377 | /// }
|
9228 9378 | ///
|
9229 9379 | /// let config = RestJsonConfig::builder().build();
|
9230 9380 | /// let svc = ::tower::util::service_fn(handler);
|
9231 9381 | /// let app = RestJson::builder(config)
|
9232 9382 | /// .malformed_timestamp_body_default_service(svc)
|
9233 9383 | /// /* Set other handlers */
|
9234 9384 | /// .build()
|
9235 9385 | /// .unwrap();
|
9236 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9386 + | /// # 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;
|
9237 9387 | /// ```
|
9238 9388 | ///
|
9239 9389 | pub fn malformed_timestamp_body_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9240 9390 | where
|
9241 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDefault, ServiceExtractors>,
|
9391 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyDefault, ServiceExtractors>,
|
9242 9392 |
|
9243 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9393 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9244 9394 | RestJson<L>,
|
9245 9395 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9246 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDefault, S>
|
9396 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyDefault, S>
|
9247 9397 | >,
|
9248 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9398 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9249 9399 | RestJson<L>,
|
9250 9400 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9251 9401 | ModelPl::Output
|
9252 9402 | >,
|
9253 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9403 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9254 9404 | RestJson<L>,
|
9255 9405 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9256 9406 | <
|
9257 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9258 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9407 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9408 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9259 9409 | RestJson<L>,
|
9260 9410 | crate::operation_shape::MalformedTimestampBodyDefault,
|
9261 9411 | ModelPl::Output
|
9262 9412 | >
|
9263 9413 | >::Output
|
9264 9414 | >,
|
9265 9415 |
|
9266 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9416 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9267 9417 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9268 9418 |
|
9269 9419 | {
|
9270 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9271 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9420 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9421 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9272 9422 | let svc = crate::operation_shape::MalformedTimestampBodyDefault::from_service(service);
|
9273 9423 | let svc = self.model_plugin.apply(svc);
|
9274 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9424 + | let svc =
|
9425 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9275 9426 | .apply(svc);
|
9276 9427 | let svc = self.http_plugin.apply(svc);
|
9277 9428 | self.malformed_timestamp_body_default_custom(svc)
|
9278 9429 | }
|
9279 9430 |
|
9280 9431 | /// Sets the [`MalformedTimestampBodyDefault`](crate::operation_shape::MalformedTimestampBodyDefault) to a custom [`Service`](tower::Service).
|
9281 9432 | /// not constrained by the Smithy contract.
|
9282 9433 | fn malformed_timestamp_body_default_custom<S>(mut self, svc: S) -> Self
|
9283 9434 | where
|
9284 9435 | S: ::tower::Service<
|
9285 9436 | ::http::Request<Body>,
|
9286 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9437 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9287 9438 | Error = ::std::convert::Infallible,
|
9288 9439 | > + Clone
|
9289 9440 | + Send
|
9290 9441 | + 'static,
|
9291 9442 | S::Future: Send + 'static,
|
9292 9443 | {
|
9293 9444 | self.malformed_timestamp_body_default =
|
9294 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9445 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9295 9446 | self
|
9296 9447 | }
|
9297 9448 |
|
9298 9449 | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
9299 9450 | ///
|
9300 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9301 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9451 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9452 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9302 9453 | ///
|
9303 9454 | /// # Example
|
9304 9455 | ///
|
9305 9456 | /// ```no_run
|
9306 9457 | /// use rest_json::{RestJson, RestJsonConfig};
|
9307 9458 | ///
|
9308 9459 | /// use rest_json::{input, output, error};
|
9309 9460 | ///
|
9310 9461 | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
9311 9462 | /// todo!()
|
9312 9463 | /// }
|
9313 9464 | ///
|
9314 9465 | /// let config = RestJsonConfig::builder().build();
|
9315 9466 | /// let app = RestJson::builder(config)
|
9316 9467 | /// .malformed_timestamp_body_http_date(handler)
|
9317 9468 | /// /* Set other handlers */
|
9318 9469 | /// .build()
|
9319 9470 | /// .unwrap();
|
9320 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9471 + | /// # 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;
|
9321 9472 | /// ```
|
9322 9473 | ///
|
9323 9474 | pub fn malformed_timestamp_body_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9324 9475 | where
|
9325 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerExtractors>,
|
9476 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerExtractors>,
|
9326 9477 |
|
9327 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9478 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9328 9479 | RestJson<L>,
|
9329 9480 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9330 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerType>
|
9481 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampBodyHttpDate, HandlerType>
|
9331 9482 | >,
|
9332 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9483 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9333 9484 | RestJson<L>,
|
9334 9485 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9335 9486 | ModelPl::Output
|
9336 9487 | >,
|
9337 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9488 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9338 9489 | RestJson<L>,
|
9339 9490 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9340 9491 | <
|
9341 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9342 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9492 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9493 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9343 9494 | RestJson<L>,
|
9344 9495 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9345 9496 | ModelPl::Output
|
9346 9497 | >
|
9347 9498 | >::Output
|
9348 9499 | >,
|
9349 9500 |
|
9350 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9501 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9351 9502 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9352 9503 |
|
9353 9504 | {
|
9354 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9355 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9505 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9506 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9356 9507 | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_handler(handler);
|
9357 9508 | let svc = self.model_plugin.apply(svc);
|
9358 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9509 + | let svc =
|
9510 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9359 9511 | .apply(svc);
|
9360 9512 | let svc = self.http_plugin.apply(svc);
|
9361 9513 | self.malformed_timestamp_body_http_date_custom(svc)
|
9362 9514 | }
|
9363 9515 |
|
9364 9516 | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) operation.
|
9365 9517 | ///
|
9366 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9367 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9518 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9519 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9368 9520 | ///
|
9369 9521 | /// # Example
|
9370 9522 | ///
|
9371 9523 | /// ```no_run
|
9372 9524 | /// use rest_json::{RestJson, RestJsonConfig};
|
9373 9525 | ///
|
9374 9526 | /// use rest_json::{input, output, error};
|
9375 9527 | ///
|
9376 9528 | /// async fn handler(input: input::MalformedTimestampBodyHttpDateInput) -> Result<output::MalformedTimestampBodyHttpDateOutput, error::MalformedTimestampBodyHttpDateError> {
|
9377 9529 | /// todo!()
|
9378 9530 | /// }
|
9379 9531 | ///
|
9380 9532 | /// let config = RestJsonConfig::builder().build();
|
9381 9533 | /// let svc = ::tower::util::service_fn(handler);
|
9382 9534 | /// let app = RestJson::builder(config)
|
9383 9535 | /// .malformed_timestamp_body_http_date_service(svc)
|
9384 9536 | /// /* Set other handlers */
|
9385 9537 | /// .build()
|
9386 9538 | /// .unwrap();
|
9387 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9539 + | /// # 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 9540 | /// ```
|
9389 9541 | ///
|
9390 9542 | pub fn malformed_timestamp_body_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9391 9543 | where
|
9392 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyHttpDate, ServiceExtractors>,
|
9544 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampBodyHttpDate, ServiceExtractors>,
|
9393 9545 |
|
9394 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9546 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9395 9547 | RestJson<L>,
|
9396 9548 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9397 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyHttpDate, S>
|
9549 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampBodyHttpDate, S>
|
9398 9550 | >,
|
9399 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9551 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9400 9552 | RestJson<L>,
|
9401 9553 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9402 9554 | ModelPl::Output
|
9403 9555 | >,
|
9404 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9556 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9405 9557 | RestJson<L>,
|
9406 9558 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9407 9559 | <
|
9408 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9409 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9560 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9561 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9410 9562 | RestJson<L>,
|
9411 9563 | crate::operation_shape::MalformedTimestampBodyHttpDate,
|
9412 9564 | ModelPl::Output
|
9413 9565 | >
|
9414 9566 | >::Output
|
9415 9567 | >,
|
9416 9568 |
|
9417 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9569 + | 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 9570 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9419 9571 |
|
9420 9572 | {
|
9421 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9422 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9573 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9574 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9423 9575 | let svc = crate::operation_shape::MalformedTimestampBodyHttpDate::from_service(service);
|
9424 9576 | let svc = self.model_plugin.apply(svc);
|
9425 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9577 + | let svc =
|
9578 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9426 9579 | .apply(svc);
|
9427 9580 | let svc = self.http_plugin.apply(svc);
|
9428 9581 | self.malformed_timestamp_body_http_date_custom(svc)
|
9429 9582 | }
|
9430 9583 |
|
9431 9584 | /// Sets the [`MalformedTimestampBodyHttpDate`](crate::operation_shape::MalformedTimestampBodyHttpDate) to a custom [`Service`](tower::Service).
|
9432 9585 | /// not constrained by the Smithy contract.
|
9433 9586 | fn malformed_timestamp_body_http_date_custom<S>(mut self, svc: S) -> Self
|
9434 9587 | where
|
9435 9588 | S: ::tower::Service<
|
9436 9589 | ::http::Request<Body>,
|
9437 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9590 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9438 9591 | Error = ::std::convert::Infallible,
|
9439 9592 | > + Clone
|
9440 9593 | + Send
|
9441 9594 | + 'static,
|
9442 9595 | S::Future: Send + 'static,
|
9443 9596 | {
|
9444 9597 | self.malformed_timestamp_body_http_date =
|
9445 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9598 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9446 9599 | self
|
9447 9600 | }
|
9448 9601 |
|
9449 9602 | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
9450 9603 | ///
|
9451 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9452 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9604 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9605 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9453 9606 | ///
|
9454 9607 | /// # Example
|
9455 9608 | ///
|
9456 9609 | /// ```no_run
|
9457 9610 | /// use rest_json::{RestJson, RestJsonConfig};
|
9458 9611 | ///
|
9459 9612 | /// use rest_json::{input, output, error};
|
9460 9613 | ///
|
9461 9614 | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
9462 9615 | /// todo!()
|
9463 9616 | /// }
|
9464 9617 | ///
|
9465 9618 | /// let config = RestJsonConfig::builder().build();
|
9466 9619 | /// let app = RestJson::builder(config)
|
9467 9620 | /// .malformed_timestamp_header_date_time(handler)
|
9468 9621 | /// /* Set other handlers */
|
9469 9622 | /// .build()
|
9470 9623 | /// .unwrap();
|
9471 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9624 + | /// # 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;
|
9472 9625 | /// ```
|
9473 9626 | ///
|
9474 9627 | pub fn malformed_timestamp_header_date_time<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9475 9628 | where
|
9476 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerExtractors>,
|
9629 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerExtractors>,
|
9477 9630 |
|
9478 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9631 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9479 9632 | RestJson<L>,
|
9480 9633 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9481 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerType>
|
9634 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDateTime, HandlerType>
|
9482 9635 | >,
|
9483 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9636 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9484 9637 | RestJson<L>,
|
9485 9638 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9486 9639 | ModelPl::Output
|
9487 9640 | >,
|
9488 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9641 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9489 9642 | RestJson<L>,
|
9490 9643 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9491 9644 | <
|
9492 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9493 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9645 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9646 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9494 9647 | RestJson<L>,
|
9495 9648 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9496 9649 | ModelPl::Output
|
9497 9650 | >
|
9498 9651 | >::Output
|
9499 9652 | >,
|
9500 9653 |
|
9501 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9654 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9502 9655 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9503 9656 |
|
9504 9657 | {
|
9505 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9506 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9658 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9659 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9507 9660 | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_handler(handler);
|
9508 9661 | let svc = self.model_plugin.apply(svc);
|
9509 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9662 + | let svc =
|
9663 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9510 9664 | .apply(svc);
|
9511 9665 | let svc = self.http_plugin.apply(svc);
|
9512 9666 | self.malformed_timestamp_header_date_time_custom(svc)
|
9513 9667 | }
|
9514 9668 |
|
9515 9669 | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) operation.
|
9516 9670 | ///
|
9517 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9518 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9671 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9672 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9519 9673 | ///
|
9520 9674 | /// # Example
|
9521 9675 | ///
|
9522 9676 | /// ```no_run
|
9523 9677 | /// use rest_json::{RestJson, RestJsonConfig};
|
9524 9678 | ///
|
9525 9679 | /// use rest_json::{input, output, error};
|
9526 9680 | ///
|
9527 9681 | /// async fn handler(input: input::MalformedTimestampHeaderDateTimeInput) -> Result<output::MalformedTimestampHeaderDateTimeOutput, error::MalformedTimestampHeaderDateTimeError> {
|
9528 9682 | /// todo!()
|
9529 9683 | /// }
|
9530 9684 | ///
|
9531 9685 | /// let config = RestJsonConfig::builder().build();
|
9532 9686 | /// let svc = ::tower::util::service_fn(handler);
|
9533 9687 | /// let app = RestJson::builder(config)
|
9534 9688 | /// .malformed_timestamp_header_date_time_service(svc)
|
9535 9689 | /// /* Set other handlers */
|
9536 9690 | /// .build()
|
9537 9691 | /// .unwrap();
|
9538 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9692 + | /// # 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;
|
9539 9693 | /// ```
|
9540 9694 | ///
|
9541 9695 | pub fn malformed_timestamp_header_date_time_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9542 9696 | where
|
9543 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDateTime, ServiceExtractors>,
|
9697 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDateTime, ServiceExtractors>,
|
9544 9698 |
|
9545 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9699 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9546 9700 | RestJson<L>,
|
9547 9701 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9548 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDateTime, S>
|
9702 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDateTime, S>
|
9549 9703 | >,
|
9550 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9704 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9551 9705 | RestJson<L>,
|
9552 9706 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9553 9707 | ModelPl::Output
|
9554 9708 | >,
|
9555 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9709 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9556 9710 | RestJson<L>,
|
9557 9711 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9558 9712 | <
|
9559 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9560 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9713 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9714 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9561 9715 | RestJson<L>,
|
9562 9716 | crate::operation_shape::MalformedTimestampHeaderDateTime,
|
9563 9717 | ModelPl::Output
|
9564 9718 | >
|
9565 9719 | >::Output
|
9566 9720 | >,
|
9567 9721 |
|
9568 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9722 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9569 9723 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9570 9724 |
|
9571 9725 | {
|
9572 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9573 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9726 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9727 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9574 9728 | let svc = crate::operation_shape::MalformedTimestampHeaderDateTime::from_service(service);
|
9575 9729 | let svc = self.model_plugin.apply(svc);
|
9576 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9730 + | let svc =
|
9731 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9577 9732 | .apply(svc);
|
9578 9733 | let svc = self.http_plugin.apply(svc);
|
9579 9734 | self.malformed_timestamp_header_date_time_custom(svc)
|
9580 9735 | }
|
9581 9736 |
|
9582 9737 | /// Sets the [`MalformedTimestampHeaderDateTime`](crate::operation_shape::MalformedTimestampHeaderDateTime) to a custom [`Service`](tower::Service).
|
9583 9738 | /// not constrained by the Smithy contract.
|
9584 9739 | fn malformed_timestamp_header_date_time_custom<S>(mut self, svc: S) -> Self
|
9585 9740 | where
|
9586 9741 | S: ::tower::Service<
|
9587 9742 | ::http::Request<Body>,
|
9588 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9743 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9589 9744 | Error = ::std::convert::Infallible,
|
9590 9745 | > + Clone
|
9591 9746 | + Send
|
9592 9747 | + 'static,
|
9593 9748 | S::Future: Send + 'static,
|
9594 9749 | {
|
9595 9750 | self.malformed_timestamp_header_date_time =
|
9596 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9751 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9597 9752 | self
|
9598 9753 | }
|
9599 9754 |
|
9600 9755 | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
9601 9756 | ///
|
9602 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9603 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9757 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9758 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9604 9759 | ///
|
9605 9760 | /// # Example
|
9606 9761 | ///
|
9607 9762 | /// ```no_run
|
9608 9763 | /// use rest_json::{RestJson, RestJsonConfig};
|
9609 9764 | ///
|
9610 9765 | /// use rest_json::{input, output, error};
|
9611 9766 | ///
|
9612 9767 | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
9613 9768 | /// todo!()
|
9614 9769 | /// }
|
9615 9770 | ///
|
9616 9771 | /// let config = RestJsonConfig::builder().build();
|
9617 9772 | /// let app = RestJson::builder(config)
|
9618 9773 | /// .malformed_timestamp_header_default(handler)
|
9619 9774 | /// /* Set other handlers */
|
9620 9775 | /// .build()
|
9621 9776 | /// .unwrap();
|
9622 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9777 + | /// # 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;
|
9623 9778 | /// ```
|
9624 9779 | ///
|
9625 9780 | pub fn malformed_timestamp_header_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9626 9781 | where
|
9627 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerExtractors>,
|
9782 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerExtractors>,
|
9628 9783 |
|
9629 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9784 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9630 9785 | RestJson<L>,
|
9631 9786 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9632 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerType>
|
9787 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderDefault, HandlerType>
|
9633 9788 | >,
|
9634 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9789 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9635 9790 | RestJson<L>,
|
9636 9791 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9637 9792 | ModelPl::Output
|
9638 9793 | >,
|
9639 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9794 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9640 9795 | RestJson<L>,
|
9641 9796 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9642 9797 | <
|
9643 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9644 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9798 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9799 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9645 9800 | RestJson<L>,
|
9646 9801 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9647 9802 | ModelPl::Output
|
9648 9803 | >
|
9649 9804 | >::Output
|
9650 9805 | >,
|
9651 9806 |
|
9652 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9807 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9653 9808 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9654 9809 |
|
9655 9810 | {
|
9656 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9657 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9811 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9812 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9658 9813 | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_handler(handler);
|
9659 9814 | let svc = self.model_plugin.apply(svc);
|
9660 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9815 + | let svc =
|
9816 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9661 9817 | .apply(svc);
|
9662 9818 | let svc = self.http_plugin.apply(svc);
|
9663 9819 | self.malformed_timestamp_header_default_custom(svc)
|
9664 9820 | }
|
9665 9821 |
|
9666 9822 | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) operation.
|
9667 9823 | ///
|
9668 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9669 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9824 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9825 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9670 9826 | ///
|
9671 9827 | /// # Example
|
9672 9828 | ///
|
9673 9829 | /// ```no_run
|
9674 9830 | /// use rest_json::{RestJson, RestJsonConfig};
|
9675 9831 | ///
|
9676 9832 | /// use rest_json::{input, output, error};
|
9677 9833 | ///
|
9678 9834 | /// async fn handler(input: input::MalformedTimestampHeaderDefaultInput) -> Result<output::MalformedTimestampHeaderDefaultOutput, error::MalformedTimestampHeaderDefaultError> {
|
9679 9835 | /// todo!()
|
9680 9836 | /// }
|
9681 9837 | ///
|
9682 9838 | /// let config = RestJsonConfig::builder().build();
|
9683 9839 | /// let svc = ::tower::util::service_fn(handler);
|
9684 9840 | /// let app = RestJson::builder(config)
|
9685 9841 | /// .malformed_timestamp_header_default_service(svc)
|
9686 9842 | /// /* Set other handlers */
|
9687 9843 | /// .build()
|
9688 9844 | /// .unwrap();
|
9689 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9845 + | /// # 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;
|
9690 9846 | /// ```
|
9691 9847 | ///
|
9692 9848 | pub fn malformed_timestamp_header_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9693 9849 | where
|
9694 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDefault, ServiceExtractors>,
|
9850 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderDefault, ServiceExtractors>,
|
9695 9851 |
|
9696 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9852 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9697 9853 | RestJson<L>,
|
9698 9854 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9699 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDefault, S>
|
9855 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderDefault, S>
|
9700 9856 | >,
|
9701 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9857 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9702 9858 | RestJson<L>,
|
9703 9859 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9704 9860 | ModelPl::Output
|
9705 9861 | >,
|
9706 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9862 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9707 9863 | RestJson<L>,
|
9708 9864 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9709 9865 | <
|
9710 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9711 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9866 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9867 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9712 9868 | RestJson<L>,
|
9713 9869 | crate::operation_shape::MalformedTimestampHeaderDefault,
|
9714 9870 | ModelPl::Output
|
9715 9871 | >
|
9716 9872 | >::Output
|
9717 9873 | >,
|
9718 9874 |
|
9719 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9875 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9720 9876 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9721 9877 |
|
9722 9878 | {
|
9723 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9724 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9879 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9880 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9725 9881 | let svc = crate::operation_shape::MalformedTimestampHeaderDefault::from_service(service);
|
9726 9882 | let svc = self.model_plugin.apply(svc);
|
9727 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9883 + | let svc =
|
9884 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9728 9885 | .apply(svc);
|
9729 9886 | let svc = self.http_plugin.apply(svc);
|
9730 9887 | self.malformed_timestamp_header_default_custom(svc)
|
9731 9888 | }
|
9732 9889 |
|
9733 9890 | /// Sets the [`MalformedTimestampHeaderDefault`](crate::operation_shape::MalformedTimestampHeaderDefault) to a custom [`Service`](tower::Service).
|
9734 9891 | /// not constrained by the Smithy contract.
|
9735 9892 | fn malformed_timestamp_header_default_custom<S>(mut self, svc: S) -> Self
|
9736 9893 | where
|
9737 9894 | S: ::tower::Service<
|
9738 9895 | ::http::Request<Body>,
|
9739 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
9896 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9740 9897 | Error = ::std::convert::Infallible,
|
9741 9898 | > + Clone
|
9742 9899 | + Send
|
9743 9900 | + 'static,
|
9744 9901 | S::Future: Send + 'static,
|
9745 9902 | {
|
9746 9903 | self.malformed_timestamp_header_default =
|
9747 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
9904 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9748 9905 | self
|
9749 9906 | }
|
9750 9907 |
|
9751 9908 | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
9752 9909 | ///
|
9753 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9754 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9910 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9911 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9755 9912 | ///
|
9756 9913 | /// # Example
|
9757 9914 | ///
|
9758 9915 | /// ```no_run
|
9759 9916 | /// use rest_json::{RestJson, RestJsonConfig};
|
9760 9917 | ///
|
9761 9918 | /// use rest_json::{input, output, error};
|
9762 9919 | ///
|
9763 9920 | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
9764 9921 | /// todo!()
|
9765 9922 | /// }
|
9766 9923 | ///
|
9767 9924 | /// let config = RestJsonConfig::builder().build();
|
9768 9925 | /// let app = RestJson::builder(config)
|
9769 9926 | /// .malformed_timestamp_header_epoch(handler)
|
9770 9927 | /// /* Set other handlers */
|
9771 9928 | /// .build()
|
9772 9929 | /// .unwrap();
|
9773 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9930 + | /// # 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;
|
9774 9931 | /// ```
|
9775 9932 | ///
|
9776 9933 | pub fn malformed_timestamp_header_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9777 9934 | where
|
9778 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerExtractors>,
|
9935 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerExtractors>,
|
9779 9936 |
|
9780 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
9937 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9781 9938 | RestJson<L>,
|
9782 9939 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9783 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerType>
|
9940 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampHeaderEpoch, HandlerType>
|
9784 9941 | >,
|
9785 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
9942 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9786 9943 | RestJson<L>,
|
9787 9944 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9788 9945 | ModelPl::Output
|
9789 9946 | >,
|
9790 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
9947 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9791 9948 | RestJson<L>,
|
9792 9949 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9793 9950 | <
|
9794 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9795 - | as ::aws_smithy_http_server::plugin::Plugin<
|
9951 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9952 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9796 9953 | RestJson<L>,
|
9797 9954 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9798 9955 | ModelPl::Output
|
9799 9956 | >
|
9800 9957 | >::Output
|
9801 9958 | >,
|
9802 9959 |
|
9803 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9960 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9804 9961 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9805 9962 |
|
9806 9963 | {
|
9807 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9808 - | use ::aws_smithy_http_server::plugin::Plugin;
|
9964 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
9965 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9809 9966 | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_handler(handler);
|
9810 9967 | let svc = self.model_plugin.apply(svc);
|
9811 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9968 + | let svc =
|
9969 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9812 9970 | .apply(svc);
|
9813 9971 | let svc = self.http_plugin.apply(svc);
|
9814 9972 | self.malformed_timestamp_header_epoch_custom(svc)
|
9815 9973 | }
|
9816 9974 |
|
9817 9975 | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) operation.
|
9818 9976 | ///
|
9819 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9820 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
9977 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
9978 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9821 9979 | ///
|
9822 9980 | /// # Example
|
9823 9981 | ///
|
9824 9982 | /// ```no_run
|
9825 9983 | /// use rest_json::{RestJson, RestJsonConfig};
|
9826 9984 | ///
|
9827 9985 | /// use rest_json::{input, output, error};
|
9828 9986 | ///
|
9829 9987 | /// async fn handler(input: input::MalformedTimestampHeaderEpochInput) -> Result<output::MalformedTimestampHeaderEpochOutput, error::MalformedTimestampHeaderEpochError> {
|
9830 9988 | /// todo!()
|
9831 9989 | /// }
|
9832 9990 | ///
|
9833 9991 | /// let config = RestJsonConfig::builder().build();
|
9834 9992 | /// let svc = ::tower::util::service_fn(handler);
|
9835 9993 | /// let app = RestJson::builder(config)
|
9836 9994 | /// .malformed_timestamp_header_epoch_service(svc)
|
9837 9995 | /// /* Set other handlers */
|
9838 9996 | /// .build()
|
9839 9997 | /// .unwrap();
|
9840 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
9998 + | /// # 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;
|
9841 9999 | /// ```
|
9842 10000 | ///
|
9843 10001 | pub fn malformed_timestamp_header_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9844 10002 | where
|
9845 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderEpoch, ServiceExtractors>,
|
10003 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampHeaderEpoch, ServiceExtractors>,
|
9846 10004 |
|
9847 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10005 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9848 10006 | RestJson<L>,
|
9849 10007 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9850 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderEpoch, S>
|
10008 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampHeaderEpoch, S>
|
9851 10009 | >,
|
9852 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10010 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9853 10011 | RestJson<L>,
|
9854 10012 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9855 10013 | ModelPl::Output
|
9856 10014 | >,
|
9857 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10015 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9858 10016 | RestJson<L>,
|
9859 10017 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9860 10018 | <
|
9861 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9862 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10019 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10020 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9863 10021 | RestJson<L>,
|
9864 10022 | crate::operation_shape::MalformedTimestampHeaderEpoch,
|
9865 10023 | ModelPl::Output
|
9866 10024 | >
|
9867 10025 | >::Output
|
9868 10026 | >,
|
9869 10027 |
|
9870 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10028 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9871 10029 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9872 10030 |
|
9873 10031 | {
|
9874 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9875 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10032 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10033 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9876 10034 | let svc = crate::operation_shape::MalformedTimestampHeaderEpoch::from_service(service);
|
9877 10035 | let svc = self.model_plugin.apply(svc);
|
9878 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10036 + | let svc =
|
10037 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9879 10038 | .apply(svc);
|
9880 10039 | let svc = self.http_plugin.apply(svc);
|
9881 10040 | self.malformed_timestamp_header_epoch_custom(svc)
|
9882 10041 | }
|
9883 10042 |
|
9884 10043 | /// Sets the [`MalformedTimestampHeaderEpoch`](crate::operation_shape::MalformedTimestampHeaderEpoch) to a custom [`Service`](tower::Service).
|
9885 10044 | /// not constrained by the Smithy contract.
|
9886 10045 | fn malformed_timestamp_header_epoch_custom<S>(mut self, svc: S) -> Self
|
9887 10046 | where
|
9888 10047 | S: ::tower::Service<
|
9889 10048 | ::http::Request<Body>,
|
9890 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10049 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
9891 10050 | Error = ::std::convert::Infallible,
|
9892 10051 | > + Clone
|
9893 10052 | + Send
|
9894 10053 | + 'static,
|
9895 10054 | S::Future: Send + 'static,
|
9896 10055 | {
|
9897 10056 | self.malformed_timestamp_header_epoch =
|
9898 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10057 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
9899 10058 | self
|
9900 10059 | }
|
9901 10060 |
|
9902 10061 | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
9903 10062 | ///
|
9904 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9905 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10063 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10064 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9906 10065 | ///
|
9907 10066 | /// # Example
|
9908 10067 | ///
|
9909 10068 | /// ```no_run
|
9910 10069 | /// use rest_json::{RestJson, RestJsonConfig};
|
9911 10070 | ///
|
9912 10071 | /// use rest_json::{input, output, error};
|
9913 10072 | ///
|
9914 10073 | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
9915 10074 | /// todo!()
|
9916 10075 | /// }
|
9917 10076 | ///
|
9918 10077 | /// let config = RestJsonConfig::builder().build();
|
9919 10078 | /// let app = RestJson::builder(config)
|
9920 10079 | /// .malformed_timestamp_path_default(handler)
|
9921 10080 | /// /* Set other handlers */
|
9922 10081 | /// .build()
|
9923 10082 | /// .unwrap();
|
9924 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10083 + | /// # 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;
|
9925 10084 | /// ```
|
9926 10085 | ///
|
9927 10086 | pub fn malformed_timestamp_path_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
9928 10087 | where
|
9929 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathDefault, HandlerExtractors>,
|
10088 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathDefault, HandlerExtractors>,
|
9930 10089 |
|
9931 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10090 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9932 10091 | RestJson<L>,
|
9933 10092 | crate::operation_shape::MalformedTimestampPathDefault,
|
9934 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathDefault, HandlerType>
|
10093 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathDefault, HandlerType>
|
9935 10094 | >,
|
9936 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10095 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9937 10096 | RestJson<L>,
|
9938 10097 | crate::operation_shape::MalformedTimestampPathDefault,
|
9939 10098 | ModelPl::Output
|
9940 10099 | >,
|
9941 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10100 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9942 10101 | RestJson<L>,
|
9943 10102 | crate::operation_shape::MalformedTimestampPathDefault,
|
9944 10103 | <
|
9945 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
9946 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10104 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10105 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9947 10106 | RestJson<L>,
|
9948 10107 | crate::operation_shape::MalformedTimestampPathDefault,
|
9949 10108 | ModelPl::Output
|
9950 10109 | >
|
9951 10110 | >::Output
|
9952 10111 | >,
|
9953 10112 |
|
9954 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10113 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
9955 10114 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
9956 10115 |
|
9957 10116 | {
|
9958 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
9959 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10117 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10118 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
9960 10119 | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_handler(handler);
|
9961 10120 | let svc = self.model_plugin.apply(svc);
|
9962 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10121 + | let svc =
|
10122 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
9963 10123 | .apply(svc);
|
9964 10124 | let svc = self.http_plugin.apply(svc);
|
9965 10125 | self.malformed_timestamp_path_default_custom(svc)
|
9966 10126 | }
|
9967 10127 |
|
9968 10128 | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) operation.
|
9969 10129 | ///
|
9970 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
9971 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10130 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10131 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
9972 10132 | ///
|
9973 10133 | /// # Example
|
9974 10134 | ///
|
9975 10135 | /// ```no_run
|
9976 10136 | /// use rest_json::{RestJson, RestJsonConfig};
|
9977 10137 | ///
|
9978 10138 | /// use rest_json::{input, output, error};
|
9979 10139 | ///
|
9980 10140 | /// async fn handler(input: input::MalformedTimestampPathDefaultInput) -> Result<output::MalformedTimestampPathDefaultOutput, error::MalformedTimestampPathDefaultError> {
|
9981 10141 | /// todo!()
|
9982 10142 | /// }
|
9983 10143 | ///
|
9984 10144 | /// let config = RestJsonConfig::builder().build();
|
9985 10145 | /// let svc = ::tower::util::service_fn(handler);
|
9986 10146 | /// let app = RestJson::builder(config)
|
9987 10147 | /// .malformed_timestamp_path_default_service(svc)
|
9988 10148 | /// /* Set other handlers */
|
9989 10149 | /// .build()
|
9990 10150 | /// .unwrap();
|
9991 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10151 + | /// # 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;
|
9992 10152 | /// ```
|
9993 10153 | ///
|
9994 10154 | pub fn malformed_timestamp_path_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
9995 10155 | where
|
9996 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathDefault, ServiceExtractors>,
|
10156 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathDefault, ServiceExtractors>,
|
9997 10157 |
|
9998 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10158 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
9999 10159 | RestJson<L>,
|
10000 10160 | crate::operation_shape::MalformedTimestampPathDefault,
|
10001 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathDefault, S>
|
10161 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathDefault, S>
|
10002 10162 | >,
|
10003 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10163 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10004 10164 | RestJson<L>,
|
10005 10165 | crate::operation_shape::MalformedTimestampPathDefault,
|
10006 10166 | ModelPl::Output
|
10007 10167 | >,
|
10008 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10168 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10009 10169 | RestJson<L>,
|
10010 10170 | crate::operation_shape::MalformedTimestampPathDefault,
|
10011 10171 | <
|
10012 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10013 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10172 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10173 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10014 10174 | RestJson<L>,
|
10015 10175 | crate::operation_shape::MalformedTimestampPathDefault,
|
10016 10176 | ModelPl::Output
|
10017 10177 | >
|
10018 10178 | >::Output
|
10019 10179 | >,
|
10020 10180 |
|
10021 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10181 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10022 10182 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10023 10183 |
|
10024 10184 | {
|
10025 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10026 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10185 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10186 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10027 10187 | let svc = crate::operation_shape::MalformedTimestampPathDefault::from_service(service);
|
10028 10188 | let svc = self.model_plugin.apply(svc);
|
10029 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10189 + | let svc =
|
10190 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10030 10191 | .apply(svc);
|
10031 10192 | let svc = self.http_plugin.apply(svc);
|
10032 10193 | self.malformed_timestamp_path_default_custom(svc)
|
10033 10194 | }
|
10034 10195 |
|
10035 10196 | /// Sets the [`MalformedTimestampPathDefault`](crate::operation_shape::MalformedTimestampPathDefault) to a custom [`Service`](tower::Service).
|
10036 10197 | /// not constrained by the Smithy contract.
|
10037 10198 | fn malformed_timestamp_path_default_custom<S>(mut self, svc: S) -> Self
|
10038 10199 | where
|
10039 10200 | S: ::tower::Service<
|
10040 10201 | ::http::Request<Body>,
|
10041 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10202 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10042 10203 | Error = ::std::convert::Infallible,
|
10043 10204 | > + Clone
|
10044 10205 | + Send
|
10045 10206 | + 'static,
|
10046 10207 | S::Future: Send + 'static,
|
10047 10208 | {
|
10048 10209 | self.malformed_timestamp_path_default =
|
10049 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10210 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10050 10211 | self
|
10051 10212 | }
|
10052 10213 |
|
10053 10214 | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
10054 10215 | ///
|
10055 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10056 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10216 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10217 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10057 10218 | ///
|
10058 10219 | /// # Example
|
10059 10220 | ///
|
10060 10221 | /// ```no_run
|
10061 10222 | /// use rest_json::{RestJson, RestJsonConfig};
|
10062 10223 | ///
|
10063 10224 | /// use rest_json::{input, output, error};
|
10064 10225 | ///
|
10065 10226 | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
10066 10227 | /// todo!()
|
10067 10228 | /// }
|
10068 10229 | ///
|
10069 10230 | /// let config = RestJsonConfig::builder().build();
|
10070 10231 | /// let app = RestJson::builder(config)
|
10071 10232 | /// .malformed_timestamp_path_epoch(handler)
|
10072 10233 | /// /* Set other handlers */
|
10073 10234 | /// .build()
|
10074 10235 | /// .unwrap();
|
10075 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10236 + | /// # 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;
|
10076 10237 | /// ```
|
10077 10238 | ///
|
10078 10239 | pub fn malformed_timestamp_path_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10079 10240 | where
|
10080 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathEpoch, HandlerExtractors>,
|
10241 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathEpoch, HandlerExtractors>,
|
10081 10242 |
|
10082 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10243 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10083 10244 | RestJson<L>,
|
10084 10245 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10085 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathEpoch, HandlerType>
|
10246 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathEpoch, HandlerType>
|
10086 10247 | >,
|
10087 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10248 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10088 10249 | RestJson<L>,
|
10089 10250 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10090 10251 | ModelPl::Output
|
10091 10252 | >,
|
10092 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10253 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10093 10254 | RestJson<L>,
|
10094 10255 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10095 10256 | <
|
10096 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10097 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10257 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10258 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10098 10259 | RestJson<L>,
|
10099 10260 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10100 10261 | ModelPl::Output
|
10101 10262 | >
|
10102 10263 | >::Output
|
10103 10264 | >,
|
10104 10265 |
|
10105 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10266 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10106 10267 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10107 10268 |
|
10108 10269 | {
|
10109 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10110 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10270 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10271 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10111 10272 | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_handler(handler);
|
10112 10273 | let svc = self.model_plugin.apply(svc);
|
10113 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10274 + | let svc =
|
10275 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10114 10276 | .apply(svc);
|
10115 10277 | let svc = self.http_plugin.apply(svc);
|
10116 10278 | self.malformed_timestamp_path_epoch_custom(svc)
|
10117 10279 | }
|
10118 10280 |
|
10119 10281 | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) operation.
|
10120 10282 | ///
|
10121 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10122 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10283 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10284 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10123 10285 | ///
|
10124 10286 | /// # Example
|
10125 10287 | ///
|
10126 10288 | /// ```no_run
|
10127 10289 | /// use rest_json::{RestJson, RestJsonConfig};
|
10128 10290 | ///
|
10129 10291 | /// use rest_json::{input, output, error};
|
10130 10292 | ///
|
10131 10293 | /// async fn handler(input: input::MalformedTimestampPathEpochInput) -> Result<output::MalformedTimestampPathEpochOutput, error::MalformedTimestampPathEpochError> {
|
10132 10294 | /// todo!()
|
10133 10295 | /// }
|
10134 10296 | ///
|
10135 10297 | /// let config = RestJsonConfig::builder().build();
|
10136 10298 | /// let svc = ::tower::util::service_fn(handler);
|
10137 10299 | /// let app = RestJson::builder(config)
|
10138 10300 | /// .malformed_timestamp_path_epoch_service(svc)
|
10139 10301 | /// /* Set other handlers */
|
10140 10302 | /// .build()
|
10141 10303 | /// .unwrap();
|
10142 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10304 + | /// # 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;
|
10143 10305 | /// ```
|
10144 10306 | ///
|
10145 10307 | pub fn malformed_timestamp_path_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10146 10308 | where
|
10147 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathEpoch, ServiceExtractors>,
|
10309 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathEpoch, ServiceExtractors>,
|
10148 10310 |
|
10149 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10311 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10150 10312 | RestJson<L>,
|
10151 10313 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10152 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathEpoch, S>
|
10314 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathEpoch, S>
|
10153 10315 | >,
|
10154 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10316 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10155 10317 | RestJson<L>,
|
10156 10318 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10157 10319 | ModelPl::Output
|
10158 10320 | >,
|
10159 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10321 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10160 10322 | RestJson<L>,
|
10161 10323 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10162 10324 | <
|
10163 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10164 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10325 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10326 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10165 10327 | RestJson<L>,
|
10166 10328 | crate::operation_shape::MalformedTimestampPathEpoch,
|
10167 10329 | ModelPl::Output
|
10168 10330 | >
|
10169 10331 | >::Output
|
10170 10332 | >,
|
10171 10333 |
|
10172 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10334 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10173 10335 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10174 10336 |
|
10175 10337 | {
|
10176 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10177 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10338 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10339 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10178 10340 | let svc = crate::operation_shape::MalformedTimestampPathEpoch::from_service(service);
|
10179 10341 | let svc = self.model_plugin.apply(svc);
|
10180 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10342 + | let svc =
|
10343 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10181 10344 | .apply(svc);
|
10182 10345 | let svc = self.http_plugin.apply(svc);
|
10183 10346 | self.malformed_timestamp_path_epoch_custom(svc)
|
10184 10347 | }
|
10185 10348 |
|
10186 10349 | /// Sets the [`MalformedTimestampPathEpoch`](crate::operation_shape::MalformedTimestampPathEpoch) to a custom [`Service`](tower::Service).
|
10187 10350 | /// not constrained by the Smithy contract.
|
10188 10351 | fn malformed_timestamp_path_epoch_custom<S>(mut self, svc: S) -> Self
|
10189 10352 | where
|
10190 10353 | S: ::tower::Service<
|
10191 10354 | ::http::Request<Body>,
|
10192 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10355 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10193 10356 | Error = ::std::convert::Infallible,
|
10194 10357 | > + Clone
|
10195 10358 | + Send
|
10196 10359 | + 'static,
|
10197 10360 | S::Future: Send + 'static,
|
10198 10361 | {
|
10199 10362 | self.malformed_timestamp_path_epoch =
|
10200 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10363 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10201 10364 | self
|
10202 10365 | }
|
10203 10366 |
|
10204 10367 | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
10205 10368 | ///
|
10206 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10207 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10369 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10370 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10208 10371 | ///
|
10209 10372 | /// # Example
|
10210 10373 | ///
|
10211 10374 | /// ```no_run
|
10212 10375 | /// use rest_json::{RestJson, RestJsonConfig};
|
10213 10376 | ///
|
10214 10377 | /// use rest_json::{input, output, error};
|
10215 10378 | ///
|
10216 10379 | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
10217 10380 | /// todo!()
|
10218 10381 | /// }
|
10219 10382 | ///
|
10220 10383 | /// let config = RestJsonConfig::builder().build();
|
10221 10384 | /// let app = RestJson::builder(config)
|
10222 10385 | /// .malformed_timestamp_path_http_date(handler)
|
10223 10386 | /// /* Set other handlers */
|
10224 10387 | /// .build()
|
10225 10388 | /// .unwrap();
|
10226 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10389 + | /// # 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;
|
10227 10390 | /// ```
|
10228 10391 | ///
|
10229 10392 | pub fn malformed_timestamp_path_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10230 10393 | where
|
10231 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerExtractors>,
|
10394 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerExtractors>,
|
10232 10395 |
|
10233 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10396 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10234 10397 | RestJson<L>,
|
10235 10398 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10236 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerType>
|
10399 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampPathHttpDate, HandlerType>
|
10237 10400 | >,
|
10238 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10401 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10239 10402 | RestJson<L>,
|
10240 10403 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10241 10404 | ModelPl::Output
|
10242 10405 | >,
|
10243 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10406 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10244 10407 | RestJson<L>,
|
10245 10408 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10246 10409 | <
|
10247 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10248 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10410 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10411 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10249 10412 | RestJson<L>,
|
10250 10413 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10251 10414 | ModelPl::Output
|
10252 10415 | >
|
10253 10416 | >::Output
|
10254 10417 | >,
|
10255 10418 |
|
10256 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10419 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10257 10420 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10258 10421 |
|
10259 10422 | {
|
10260 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10261 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10423 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10424 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10262 10425 | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_handler(handler);
|
10263 10426 | let svc = self.model_plugin.apply(svc);
|
10264 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10427 + | let svc =
|
10428 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10265 10429 | .apply(svc);
|
10266 10430 | let svc = self.http_plugin.apply(svc);
|
10267 10431 | self.malformed_timestamp_path_http_date_custom(svc)
|
10268 10432 | }
|
10269 10433 |
|
10270 10434 | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) operation.
|
10271 10435 | ///
|
10272 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10273 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10436 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10437 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10274 10438 | ///
|
10275 10439 | /// # Example
|
10276 10440 | ///
|
10277 10441 | /// ```no_run
|
10278 10442 | /// use rest_json::{RestJson, RestJsonConfig};
|
10279 10443 | ///
|
10280 10444 | /// use rest_json::{input, output, error};
|
10281 10445 | ///
|
10282 10446 | /// async fn handler(input: input::MalformedTimestampPathHttpDateInput) -> Result<output::MalformedTimestampPathHttpDateOutput, error::MalformedTimestampPathHttpDateError> {
|
10283 10447 | /// todo!()
|
10284 10448 | /// }
|
10285 10449 | ///
|
10286 10450 | /// let config = RestJsonConfig::builder().build();
|
10287 10451 | /// let svc = ::tower::util::service_fn(handler);
|
10288 10452 | /// let app = RestJson::builder(config)
|
10289 10453 | /// .malformed_timestamp_path_http_date_service(svc)
|
10290 10454 | /// /* Set other handlers */
|
10291 10455 | /// .build()
|
10292 10456 | /// .unwrap();
|
10293 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10457 + | /// # 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;
|
10294 10458 | /// ```
|
10295 10459 | ///
|
10296 10460 | pub fn malformed_timestamp_path_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10297 10461 | where
|
10298 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathHttpDate, ServiceExtractors>,
|
10462 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampPathHttpDate, ServiceExtractors>,
|
10299 10463 |
|
10300 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10464 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10301 10465 | RestJson<L>,
|
10302 10466 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10303 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathHttpDate, S>
|
10467 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampPathHttpDate, S>
|
10304 10468 | >,
|
10305 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10469 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10306 10470 | RestJson<L>,
|
10307 10471 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10308 10472 | ModelPl::Output
|
10309 10473 | >,
|
10310 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10474 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10311 10475 | RestJson<L>,
|
10312 10476 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10313 10477 | <
|
10314 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10315 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10478 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10479 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10316 10480 | RestJson<L>,
|
10317 10481 | crate::operation_shape::MalformedTimestampPathHttpDate,
|
10318 10482 | ModelPl::Output
|
10319 10483 | >
|
10320 10484 | >::Output
|
10321 10485 | >,
|
10322 10486 |
|
10323 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10487 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10324 10488 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10325 10489 |
|
10326 10490 | {
|
10327 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10328 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10491 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10492 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10329 10493 | let svc = crate::operation_shape::MalformedTimestampPathHttpDate::from_service(service);
|
10330 10494 | let svc = self.model_plugin.apply(svc);
|
10331 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10495 + | let svc =
|
10496 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10332 10497 | .apply(svc);
|
10333 10498 | let svc = self.http_plugin.apply(svc);
|
10334 10499 | self.malformed_timestamp_path_http_date_custom(svc)
|
10335 10500 | }
|
10336 10501 |
|
10337 10502 | /// Sets the [`MalformedTimestampPathHttpDate`](crate::operation_shape::MalformedTimestampPathHttpDate) to a custom [`Service`](tower::Service).
|
10338 10503 | /// not constrained by the Smithy contract.
|
10339 10504 | fn malformed_timestamp_path_http_date_custom<S>(mut self, svc: S) -> Self
|
10340 10505 | where
|
10341 10506 | S: ::tower::Service<
|
10342 10507 | ::http::Request<Body>,
|
10343 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10508 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10344 10509 | Error = ::std::convert::Infallible,
|
10345 10510 | > + Clone
|
10346 10511 | + Send
|
10347 10512 | + 'static,
|
10348 10513 | S::Future: Send + 'static,
|
10349 10514 | {
|
10350 10515 | self.malformed_timestamp_path_http_date =
|
10351 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10516 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10352 10517 | self
|
10353 10518 | }
|
10354 10519 |
|
10355 10520 | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
10356 10521 | ///
|
10357 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10358 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10522 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10523 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10359 10524 | ///
|
10360 10525 | /// # Example
|
10361 10526 | ///
|
10362 10527 | /// ```no_run
|
10363 10528 | /// use rest_json::{RestJson, RestJsonConfig};
|
10364 10529 | ///
|
10365 10530 | /// use rest_json::{input, output, error};
|
10366 10531 | ///
|
10367 10532 | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
10368 10533 | /// todo!()
|
10369 10534 | /// }
|
10370 10535 | ///
|
10371 10536 | /// let config = RestJsonConfig::builder().build();
|
10372 10537 | /// let app = RestJson::builder(config)
|
10373 10538 | /// .malformed_timestamp_query_default(handler)
|
10374 10539 | /// /* Set other handlers */
|
10375 10540 | /// .build()
|
10376 10541 | /// .unwrap();
|
10377 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10542 + | /// # 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;
|
10378 10543 | /// ```
|
10379 10544 | ///
|
10380 10545 | pub fn malformed_timestamp_query_default<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10381 10546 | where
|
10382 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryDefault, HandlerExtractors>,
|
10547 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryDefault, HandlerExtractors>,
|
10383 10548 |
|
10384 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10549 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10385 10550 | RestJson<L>,
|
10386 10551 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10387 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryDefault, HandlerType>
|
10552 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryDefault, HandlerType>
|
10388 10553 | >,
|
10389 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10554 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10390 10555 | RestJson<L>,
|
10391 10556 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10392 10557 | ModelPl::Output
|
10393 10558 | >,
|
10394 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10559 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10395 10560 | RestJson<L>,
|
10396 10561 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10397 10562 | <
|
10398 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10399 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10563 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10564 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10400 10565 | RestJson<L>,
|
10401 10566 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10402 10567 | ModelPl::Output
|
10403 10568 | >
|
10404 10569 | >::Output
|
10405 10570 | >,
|
10406 10571 |
|
10407 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10572 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10408 10573 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10409 10574 |
|
10410 10575 | {
|
10411 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10412 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10576 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10577 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10413 10578 | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_handler(handler);
|
10414 10579 | let svc = self.model_plugin.apply(svc);
|
10415 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10580 + | let svc =
|
10581 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10416 10582 | .apply(svc);
|
10417 10583 | let svc = self.http_plugin.apply(svc);
|
10418 10584 | self.malformed_timestamp_query_default_custom(svc)
|
10419 10585 | }
|
10420 10586 |
|
10421 10587 | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) operation.
|
10422 10588 | ///
|
10423 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10424 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10589 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10590 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10425 10591 | ///
|
10426 10592 | /// # Example
|
10427 10593 | ///
|
10428 10594 | /// ```no_run
|
10429 10595 | /// use rest_json::{RestJson, RestJsonConfig};
|
10430 10596 | ///
|
10431 10597 | /// use rest_json::{input, output, error};
|
10432 10598 | ///
|
10433 10599 | /// async fn handler(input: input::MalformedTimestampQueryDefaultInput) -> Result<output::MalformedTimestampQueryDefaultOutput, error::MalformedTimestampQueryDefaultError> {
|
10434 10600 | /// todo!()
|
10435 10601 | /// }
|
10436 10602 | ///
|
10437 10603 | /// let config = RestJsonConfig::builder().build();
|
10438 10604 | /// let svc = ::tower::util::service_fn(handler);
|
10439 10605 | /// let app = RestJson::builder(config)
|
10440 10606 | /// .malformed_timestamp_query_default_service(svc)
|
10441 10607 | /// /* Set other handlers */
|
10442 10608 | /// .build()
|
10443 10609 | /// .unwrap();
|
10444 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10610 + | /// # 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;
|
10445 10611 | /// ```
|
10446 10612 | ///
|
10447 10613 | pub fn malformed_timestamp_query_default_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10448 10614 | where
|
10449 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryDefault, ServiceExtractors>,
|
10615 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryDefault, ServiceExtractors>,
|
10450 10616 |
|
10451 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10617 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10452 10618 | RestJson<L>,
|
10453 10619 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10454 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryDefault, S>
|
10620 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryDefault, S>
|
10455 10621 | >,
|
10456 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10622 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10457 10623 | RestJson<L>,
|
10458 10624 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10459 10625 | ModelPl::Output
|
10460 10626 | >,
|
10461 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10627 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10462 10628 | RestJson<L>,
|
10463 10629 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10464 10630 | <
|
10465 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10466 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10631 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10632 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10467 10633 | RestJson<L>,
|
10468 10634 | crate::operation_shape::MalformedTimestampQueryDefault,
|
10469 10635 | ModelPl::Output
|
10470 10636 | >
|
10471 10637 | >::Output
|
10472 10638 | >,
|
10473 10639 |
|
10474 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10640 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10475 10641 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10476 10642 |
|
10477 10643 | {
|
10478 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10479 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10644 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10645 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10480 10646 | let svc = crate::operation_shape::MalformedTimestampQueryDefault::from_service(service);
|
10481 10647 | let svc = self.model_plugin.apply(svc);
|
10482 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10648 + | let svc =
|
10649 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10483 10650 | .apply(svc);
|
10484 10651 | let svc = self.http_plugin.apply(svc);
|
10485 10652 | self.malformed_timestamp_query_default_custom(svc)
|
10486 10653 | }
|
10487 10654 |
|
10488 10655 | /// Sets the [`MalformedTimestampQueryDefault`](crate::operation_shape::MalformedTimestampQueryDefault) to a custom [`Service`](tower::Service).
|
10489 10656 | /// not constrained by the Smithy contract.
|
10490 10657 | fn malformed_timestamp_query_default_custom<S>(mut self, svc: S) -> Self
|
10491 10658 | where
|
10492 10659 | S: ::tower::Service<
|
10493 10660 | ::http::Request<Body>,
|
10494 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10661 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10495 10662 | Error = ::std::convert::Infallible,
|
10496 10663 | > + Clone
|
10497 10664 | + Send
|
10498 10665 | + 'static,
|
10499 10666 | S::Future: Send + 'static,
|
10500 10667 | {
|
10501 10668 | self.malformed_timestamp_query_default =
|
10502 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10669 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10503 10670 | self
|
10504 10671 | }
|
10505 10672 |
|
10506 10673 | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
10507 10674 | ///
|
10508 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10509 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10675 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10676 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10510 10677 | ///
|
10511 10678 | /// # Example
|
10512 10679 | ///
|
10513 10680 | /// ```no_run
|
10514 10681 | /// use rest_json::{RestJson, RestJsonConfig};
|
10515 10682 | ///
|
10516 10683 | /// use rest_json::{input, output, error};
|
10517 10684 | ///
|
10518 10685 | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
10519 10686 | /// todo!()
|
10520 10687 | /// }
|
10521 10688 | ///
|
10522 10689 | /// let config = RestJsonConfig::builder().build();
|
10523 10690 | /// let app = RestJson::builder(config)
|
10524 10691 | /// .malformed_timestamp_query_epoch(handler)
|
10525 10692 | /// /* Set other handlers */
|
10526 10693 | /// .build()
|
10527 10694 | /// .unwrap();
|
10528 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10695 + | /// # 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;
|
10529 10696 | /// ```
|
10530 10697 | ///
|
10531 10698 | pub fn malformed_timestamp_query_epoch<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10532 10699 | where
|
10533 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerExtractors>,
|
10700 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerExtractors>,
|
10534 10701 |
|
10535 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10702 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10536 10703 | RestJson<L>,
|
10537 10704 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10538 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerType>
|
10705 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryEpoch, HandlerType>
|
10539 10706 | >,
|
10540 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10707 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10541 10708 | RestJson<L>,
|
10542 10709 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10543 10710 | ModelPl::Output
|
10544 10711 | >,
|
10545 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10712 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10546 10713 | RestJson<L>,
|
10547 10714 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10548 10715 | <
|
10549 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10550 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10716 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10717 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10551 10718 | RestJson<L>,
|
10552 10719 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10553 10720 | ModelPl::Output
|
10554 10721 | >
|
10555 10722 | >::Output
|
10556 10723 | >,
|
10557 10724 |
|
10558 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10725 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10559 10726 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10560 10727 |
|
10561 10728 | {
|
10562 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10563 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10729 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10730 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10564 10731 | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_handler(handler);
|
10565 10732 | let svc = self.model_plugin.apply(svc);
|
10566 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10733 + | let svc =
|
10734 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10567 10735 | .apply(svc);
|
10568 10736 | let svc = self.http_plugin.apply(svc);
|
10569 10737 | self.malformed_timestamp_query_epoch_custom(svc)
|
10570 10738 | }
|
10571 10739 |
|
10572 10740 | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) operation.
|
10573 10741 | ///
|
10574 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10575 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10742 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10743 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10576 10744 | ///
|
10577 10745 | /// # Example
|
10578 10746 | ///
|
10579 10747 | /// ```no_run
|
10580 10748 | /// use rest_json::{RestJson, RestJsonConfig};
|
10581 10749 | ///
|
10582 10750 | /// use rest_json::{input, output, error};
|
10583 10751 | ///
|
10584 10752 | /// async fn handler(input: input::MalformedTimestampQueryEpochInput) -> Result<output::MalformedTimestampQueryEpochOutput, error::MalformedTimestampQueryEpochError> {
|
10585 10753 | /// todo!()
|
10586 10754 | /// }
|
10587 10755 | ///
|
10588 10756 | /// let config = RestJsonConfig::builder().build();
|
10589 10757 | /// let svc = ::tower::util::service_fn(handler);
|
10590 10758 | /// let app = RestJson::builder(config)
|
10591 10759 | /// .malformed_timestamp_query_epoch_service(svc)
|
10592 10760 | /// /* Set other handlers */
|
10593 10761 | /// .build()
|
10594 10762 | /// .unwrap();
|
10595 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10763 + | /// # 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;
|
10596 10764 | /// ```
|
10597 10765 | ///
|
10598 10766 | pub fn malformed_timestamp_query_epoch_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10599 10767 | where
|
10600 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryEpoch, ServiceExtractors>,
|
10768 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryEpoch, ServiceExtractors>,
|
10601 10769 |
|
10602 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10770 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10603 10771 | RestJson<L>,
|
10604 10772 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10605 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryEpoch, S>
|
10773 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryEpoch, S>
|
10606 10774 | >,
|
10607 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10775 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10608 10776 | RestJson<L>,
|
10609 10777 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10610 10778 | ModelPl::Output
|
10611 10779 | >,
|
10612 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10780 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10613 10781 | RestJson<L>,
|
10614 10782 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10615 10783 | <
|
10616 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10617 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10784 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10785 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10618 10786 | RestJson<L>,
|
10619 10787 | crate::operation_shape::MalformedTimestampQueryEpoch,
|
10620 10788 | ModelPl::Output
|
10621 10789 | >
|
10622 10790 | >::Output
|
10623 10791 | >,
|
10624 10792 |
|
10625 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10793 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10626 10794 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10627 10795 |
|
10628 10796 | {
|
10629 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10630 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10797 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10798 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10631 10799 | let svc = crate::operation_shape::MalformedTimestampQueryEpoch::from_service(service);
|
10632 10800 | let svc = self.model_plugin.apply(svc);
|
10633 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10801 + | let svc =
|
10802 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10634 10803 | .apply(svc);
|
10635 10804 | let svc = self.http_plugin.apply(svc);
|
10636 10805 | self.malformed_timestamp_query_epoch_custom(svc)
|
10637 10806 | }
|
10638 10807 |
|
10639 10808 | /// Sets the [`MalformedTimestampQueryEpoch`](crate::operation_shape::MalformedTimestampQueryEpoch) to a custom [`Service`](tower::Service).
|
10640 10809 | /// not constrained by the Smithy contract.
|
10641 10810 | fn malformed_timestamp_query_epoch_custom<S>(mut self, svc: S) -> Self
|
10642 10811 | where
|
10643 10812 | S: ::tower::Service<
|
10644 10813 | ::http::Request<Body>,
|
10645 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10814 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10646 10815 | Error = ::std::convert::Infallible,
|
10647 10816 | > + Clone
|
10648 10817 | + Send
|
10649 10818 | + 'static,
|
10650 10819 | S::Future: Send + 'static,
|
10651 10820 | {
|
10652 10821 | self.malformed_timestamp_query_epoch =
|
10653 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10822 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10654 10823 | self
|
10655 10824 | }
|
10656 10825 |
|
10657 10826 | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
10658 10827 | ///
|
10659 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10660 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10828 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10829 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10661 10830 | ///
|
10662 10831 | /// # Example
|
10663 10832 | ///
|
10664 10833 | /// ```no_run
|
10665 10834 | /// use rest_json::{RestJson, RestJsonConfig};
|
10666 10835 | ///
|
10667 10836 | /// use rest_json::{input, output, error};
|
10668 10837 | ///
|
10669 10838 | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
10670 10839 | /// todo!()
|
10671 10840 | /// }
|
10672 10841 | ///
|
10673 10842 | /// let config = RestJsonConfig::builder().build();
|
10674 10843 | /// let app = RestJson::builder(config)
|
10675 10844 | /// .malformed_timestamp_query_http_date(handler)
|
10676 10845 | /// /* Set other handlers */
|
10677 10846 | /// .build()
|
10678 10847 | /// .unwrap();
|
10679 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10848 + | /// # 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;
|
10680 10849 | /// ```
|
10681 10850 | ///
|
10682 10851 | pub fn malformed_timestamp_query_http_date<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10683 10852 | where
|
10684 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerExtractors>,
|
10853 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerExtractors>,
|
10685 10854 |
|
10686 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10855 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10687 10856 | RestJson<L>,
|
10688 10857 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10689 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerType>
|
10858 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedTimestampQueryHttpDate, HandlerType>
|
10690 10859 | >,
|
10691 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10860 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10692 10861 | RestJson<L>,
|
10693 10862 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10694 10863 | ModelPl::Output
|
10695 10864 | >,
|
10696 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10865 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10697 10866 | RestJson<L>,
|
10698 10867 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10699 10868 | <
|
10700 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10701 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10869 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10870 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10702 10871 | RestJson<L>,
|
10703 10872 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10704 10873 | ModelPl::Output
|
10705 10874 | >
|
10706 10875 | >::Output
|
10707 10876 | >,
|
10708 10877 |
|
10709 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10878 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10710 10879 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10711 10880 |
|
10712 10881 | {
|
10713 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10714 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10882 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10883 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10715 10884 | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_handler(handler);
|
10716 10885 | let svc = self.model_plugin.apply(svc);
|
10717 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10886 + | let svc =
|
10887 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10718 10888 | .apply(svc);
|
10719 10889 | let svc = self.http_plugin.apply(svc);
|
10720 10890 | self.malformed_timestamp_query_http_date_custom(svc)
|
10721 10891 | }
|
10722 10892 |
|
10723 10893 | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) operation.
|
10724 10894 | ///
|
10725 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10726 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10895 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10896 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10727 10897 | ///
|
10728 10898 | /// # Example
|
10729 10899 | ///
|
10730 10900 | /// ```no_run
|
10731 10901 | /// use rest_json::{RestJson, RestJsonConfig};
|
10732 10902 | ///
|
10733 10903 | /// use rest_json::{input, output, error};
|
10734 10904 | ///
|
10735 10905 | /// async fn handler(input: input::MalformedTimestampQueryHttpDateInput) -> Result<output::MalformedTimestampQueryHttpDateOutput, error::MalformedTimestampQueryHttpDateError> {
|
10736 10906 | /// todo!()
|
10737 10907 | /// }
|
10738 10908 | ///
|
10739 10909 | /// let config = RestJsonConfig::builder().build();
|
10740 10910 | /// let svc = ::tower::util::service_fn(handler);
|
10741 10911 | /// let app = RestJson::builder(config)
|
10742 10912 | /// .malformed_timestamp_query_http_date_service(svc)
|
10743 10913 | /// /* Set other handlers */
|
10744 10914 | /// .build()
|
10745 10915 | /// .unwrap();
|
10746 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
10916 + | /// # 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;
|
10747 10917 | /// ```
|
10748 10918 | ///
|
10749 10919 | pub fn malformed_timestamp_query_http_date_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10750 10920 | where
|
10751 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryHttpDate, ServiceExtractors>,
|
10921 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedTimestampQueryHttpDate, ServiceExtractors>,
|
10752 10922 |
|
10753 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
10923 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10754 10924 | RestJson<L>,
|
10755 10925 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10756 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryHttpDate, S>
|
10926 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedTimestampQueryHttpDate, S>
|
10757 10927 | >,
|
10758 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
10928 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10759 10929 | RestJson<L>,
|
10760 10930 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10761 10931 | ModelPl::Output
|
10762 10932 | >,
|
10763 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
10933 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10764 10934 | RestJson<L>,
|
10765 10935 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10766 10936 | <
|
10767 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10768 - | as ::aws_smithy_http_server::plugin::Plugin<
|
10937 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10938 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10769 10939 | RestJson<L>,
|
10770 10940 | crate::operation_shape::MalformedTimestampQueryHttpDate,
|
10771 10941 | ModelPl::Output
|
10772 10942 | >
|
10773 10943 | >::Output
|
10774 10944 | >,
|
10775 10945 |
|
10776 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10946 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10777 10947 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10778 10948 |
|
10779 10949 | {
|
10780 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10781 - | use ::aws_smithy_http_server::plugin::Plugin;
|
10950 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
10951 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10782 10952 | let svc = crate::operation_shape::MalformedTimestampQueryHttpDate::from_service(service);
|
10783 10953 | let svc = self.model_plugin.apply(svc);
|
10784 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10954 + | let svc =
|
10955 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10785 10956 | .apply(svc);
|
10786 10957 | let svc = self.http_plugin.apply(svc);
|
10787 10958 | self.malformed_timestamp_query_http_date_custom(svc)
|
10788 10959 | }
|
10789 10960 |
|
10790 10961 | /// Sets the [`MalformedTimestampQueryHttpDate`](crate::operation_shape::MalformedTimestampQueryHttpDate) to a custom [`Service`](tower::Service).
|
10791 10962 | /// not constrained by the Smithy contract.
|
10792 10963 | fn malformed_timestamp_query_http_date_custom<S>(mut self, svc: S) -> Self
|
10793 10964 | where
|
10794 10965 | S: ::tower::Service<
|
10795 10966 | ::http::Request<Body>,
|
10796 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
10967 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10797 10968 | Error = ::std::convert::Infallible,
|
10798 10969 | > + Clone
|
10799 10970 | + Send
|
10800 10971 | + 'static,
|
10801 10972 | S::Future: Send + 'static,
|
10802 10973 | {
|
10803 10974 | self.malformed_timestamp_query_http_date =
|
10804 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
10975 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10805 10976 | self
|
10806 10977 | }
|
10807 10978 |
|
10808 10979 | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
10809 10980 | ///
|
10810 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10811 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
10981 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
10982 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10812 10983 | ///
|
10813 10984 | /// # Example
|
10814 10985 | ///
|
10815 10986 | /// ```no_run
|
10816 10987 | /// use rest_json::{RestJson, RestJsonConfig};
|
10817 10988 | ///
|
10818 10989 | /// use rest_json::{input, output, error};
|
10819 10990 | ///
|
10820 10991 | /// async fn handler(input: input::MalformedUnionInput) -> Result<output::MalformedUnionOutput, error::MalformedUnionError> {
|
10821 10992 | /// todo!()
|
10822 10993 | /// }
|
10823 10994 | ///
|
10824 10995 | /// let config = RestJsonConfig::builder().build();
|
10825 10996 | /// let app = RestJson::builder(config)
|
10826 10997 | /// .malformed_union(handler)
|
10827 10998 | /// /* Set other handlers */
|
10828 10999 | /// .build()
|
10829 11000 | /// .unwrap();
|
10830 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11001 + | /// # 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;
|
10831 11002 | /// ```
|
10832 11003 | ///
|
10833 11004 | pub fn malformed_union<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10834 11005 | where
|
10835 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MalformedUnion, HandlerExtractors>,
|
11006 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MalformedUnion, HandlerExtractors>,
|
10836 11007 |
|
10837 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11008 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10838 11009 | RestJson<L>,
|
10839 11010 | crate::operation_shape::MalformedUnion,
|
10840 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MalformedUnion, HandlerType>
|
11011 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MalformedUnion, HandlerType>
|
10841 11012 | >,
|
10842 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11013 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10843 11014 | RestJson<L>,
|
10844 11015 | crate::operation_shape::MalformedUnion,
|
10845 11016 | ModelPl::Output
|
10846 11017 | >,
|
10847 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11018 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10848 11019 | RestJson<L>,
|
10849 11020 | crate::operation_shape::MalformedUnion,
|
10850 11021 | <
|
10851 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10852 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11022 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11023 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10853 11024 | RestJson<L>,
|
10854 11025 | crate::operation_shape::MalformedUnion,
|
10855 11026 | ModelPl::Output
|
10856 11027 | >
|
10857 11028 | >::Output
|
10858 11029 | >,
|
10859 11030 |
|
10860 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11031 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10861 11032 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10862 11033 |
|
10863 11034 | {
|
10864 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10865 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11035 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11036 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10866 11037 | let svc = crate::operation_shape::MalformedUnion::from_handler(handler);
|
10867 11038 | let svc = self.model_plugin.apply(svc);
|
10868 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11039 + | let svc =
|
11040 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10869 11041 | .apply(svc);
|
10870 11042 | let svc = self.http_plugin.apply(svc);
|
10871 11043 | self.malformed_union_custom(svc)
|
10872 11044 | }
|
10873 11045 |
|
10874 11046 | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) operation.
|
10875 11047 | ///
|
10876 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10877 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11048 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11049 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10878 11050 | ///
|
10879 11051 | /// # Example
|
10880 11052 | ///
|
10881 11053 | /// ```no_run
|
10882 11054 | /// use rest_json::{RestJson, RestJsonConfig};
|
10883 11055 | ///
|
10884 11056 | /// use rest_json::{input, output, error};
|
10885 11057 | ///
|
10886 11058 | /// async fn handler(input: input::MalformedUnionInput) -> Result<output::MalformedUnionOutput, error::MalformedUnionError> {
|
10887 11059 | /// todo!()
|
10888 11060 | /// }
|
10889 11061 | ///
|
10890 11062 | /// let config = RestJsonConfig::builder().build();
|
10891 11063 | /// let svc = ::tower::util::service_fn(handler);
|
10892 11064 | /// let app = RestJson::builder(config)
|
10893 11065 | /// .malformed_union_service(svc)
|
10894 11066 | /// /* Set other handlers */
|
10895 11067 | /// .build()
|
10896 11068 | /// .unwrap();
|
10897 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11069 + | /// # 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;
|
10898 11070 | /// ```
|
10899 11071 | ///
|
10900 11072 | pub fn malformed_union_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
10901 11073 | where
|
10902 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MalformedUnion, ServiceExtractors>,
|
11074 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MalformedUnion, ServiceExtractors>,
|
10903 11075 |
|
10904 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11076 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10905 11077 | RestJson<L>,
|
10906 11078 | crate::operation_shape::MalformedUnion,
|
10907 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MalformedUnion, S>
|
11079 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MalformedUnion, S>
|
10908 11080 | >,
|
10909 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11081 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10910 11082 | RestJson<L>,
|
10911 11083 | crate::operation_shape::MalformedUnion,
|
10912 11084 | ModelPl::Output
|
10913 11085 | >,
|
10914 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11086 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10915 11087 | RestJson<L>,
|
10916 11088 | crate::operation_shape::MalformedUnion,
|
10917 11089 | <
|
10918 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
10919 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11090 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11091 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10920 11092 | RestJson<L>,
|
10921 11093 | crate::operation_shape::MalformedUnion,
|
10922 11094 | ModelPl::Output
|
10923 11095 | >
|
10924 11096 | >::Output
|
10925 11097 | >,
|
10926 11098 |
|
10927 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11099 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
10928 11100 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
10929 11101 |
|
10930 11102 | {
|
10931 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
10932 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11103 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11104 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
10933 11105 | let svc = crate::operation_shape::MalformedUnion::from_service(service);
|
10934 11106 | let svc = self.model_plugin.apply(svc);
|
10935 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11107 + | let svc =
|
11108 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
10936 11109 | .apply(svc);
|
10937 11110 | let svc = self.http_plugin.apply(svc);
|
10938 11111 | self.malformed_union_custom(svc)
|
10939 11112 | }
|
10940 11113 |
|
10941 11114 | /// Sets the [`MalformedUnion`](crate::operation_shape::MalformedUnion) to a custom [`Service`](tower::Service).
|
10942 11115 | /// not constrained by the Smithy contract.
|
10943 11116 | fn malformed_union_custom<S>(mut self, svc: S) -> Self
|
10944 11117 | where
|
10945 11118 | S: ::tower::Service<
|
10946 11119 | ::http::Request<Body>,
|
10947 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11120 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
10948 11121 | Error = ::std::convert::Infallible,
|
10949 11122 | > + Clone
|
10950 11123 | + Send
|
10951 11124 | + 'static,
|
10952 11125 | S::Future: Send + 'static,
|
10953 11126 | {
|
10954 - | self.malformed_union = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11127 + | self.malformed_union = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
10955 11128 | self
|
10956 11129 | }
|
10957 11130 |
|
10958 11131 | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
10959 11132 | ///
|
10960 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
10961 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11133 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11134 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
10962 11135 | ///
|
10963 11136 | /// # Example
|
10964 11137 | ///
|
10965 11138 | /// ```no_run
|
10966 11139 | /// use rest_json::{RestJson, RestJsonConfig};
|
10967 11140 | ///
|
10968 11141 | /// use rest_json::{input, output, error};
|
10969 11142 | ///
|
10970 11143 | /// async fn handler(input: input::MediaTypeHeaderInput) -> Result<output::MediaTypeHeaderOutput, error::MediaTypeHeaderError> {
|
10971 11144 | /// todo!()
|
10972 11145 | /// }
|
10973 11146 | ///
|
10974 11147 | /// let config = RestJsonConfig::builder().build();
|
10975 11148 | /// let app = RestJson::builder(config)
|
10976 11149 | /// .media_type_header(handler)
|
10977 11150 | /// /* Set other handlers */
|
10978 11151 | /// .build()
|
10979 11152 | /// .unwrap();
|
10980 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11153 + | /// # 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;
|
10981 11154 | /// ```
|
10982 11155 | ///
|
10983 11156 | pub fn media_type_header<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
10984 11157 | where
|
10985 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::MediaTypeHeader, HandlerExtractors>,
|
11158 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::MediaTypeHeader, HandlerExtractors>,
|
10986 11159 |
|
10987 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11160 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10988 11161 | RestJson<L>,
|
10989 11162 | crate::operation_shape::MediaTypeHeader,
|
10990 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::MediaTypeHeader, HandlerType>
|
11163 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::MediaTypeHeader, HandlerType>
|
10991 11164 | >,
|
10992 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11165 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10993 11166 | RestJson<L>,
|
10994 11167 | crate::operation_shape::MediaTypeHeader,
|
10995 11168 | ModelPl::Output
|
10996 11169 | >,
|
10997 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11170 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
10998 11171 | RestJson<L>,
|
10999 11172 | crate::operation_shape::MediaTypeHeader,
|
11000 11173 | <
|
11001 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11002 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11174 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11175 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11003 11176 | RestJson<L>,
|
11004 11177 | crate::operation_shape::MediaTypeHeader,
|
11005 11178 | ModelPl::Output
|
11006 11179 | >
|
11007 11180 | >::Output
|
11008 11181 | >,
|
11009 11182 |
|
11010 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11183 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11011 11184 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11012 11185 |
|
11013 11186 | {
|
11014 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11015 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11187 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11188 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11016 11189 | let svc = crate::operation_shape::MediaTypeHeader::from_handler(handler);
|
11017 11190 | let svc = self.model_plugin.apply(svc);
|
11018 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11191 + | let svc =
|
11192 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11019 11193 | .apply(svc);
|
11020 11194 | let svc = self.http_plugin.apply(svc);
|
11021 11195 | self.media_type_header_custom(svc)
|
11022 11196 | }
|
11023 11197 |
|
11024 11198 | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) operation.
|
11025 11199 | ///
|
11026 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11027 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11200 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11201 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11028 11202 | ///
|
11029 11203 | /// # Example
|
11030 11204 | ///
|
11031 11205 | /// ```no_run
|
11032 11206 | /// use rest_json::{RestJson, RestJsonConfig};
|
11033 11207 | ///
|
11034 11208 | /// use rest_json::{input, output, error};
|
11035 11209 | ///
|
11036 11210 | /// async fn handler(input: input::MediaTypeHeaderInput) -> Result<output::MediaTypeHeaderOutput, error::MediaTypeHeaderError> {
|
11037 11211 | /// todo!()
|
11038 11212 | /// }
|
11039 11213 | ///
|
11040 11214 | /// let config = RestJsonConfig::builder().build();
|
11041 11215 | /// let svc = ::tower::util::service_fn(handler);
|
11042 11216 | /// let app = RestJson::builder(config)
|
11043 11217 | /// .media_type_header_service(svc)
|
11044 11218 | /// /* Set other handlers */
|
11045 11219 | /// .build()
|
11046 11220 | /// .unwrap();
|
11047 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11221 + | /// # 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;
|
11048 11222 | /// ```
|
11049 11223 | ///
|
11050 11224 | pub fn media_type_header_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11051 11225 | where
|
11052 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::MediaTypeHeader, ServiceExtractors>,
|
11226 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::MediaTypeHeader, ServiceExtractors>,
|
11053 11227 |
|
11054 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11228 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11055 11229 | RestJson<L>,
|
11056 11230 | crate::operation_shape::MediaTypeHeader,
|
11057 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::MediaTypeHeader, S>
|
11231 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::MediaTypeHeader, S>
|
11058 11232 | >,
|
11059 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11233 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11060 11234 | RestJson<L>,
|
11061 11235 | crate::operation_shape::MediaTypeHeader,
|
11062 11236 | ModelPl::Output
|
11063 11237 | >,
|
11064 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11238 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11065 11239 | RestJson<L>,
|
11066 11240 | crate::operation_shape::MediaTypeHeader,
|
11067 11241 | <
|
11068 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11069 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11242 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11243 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11070 11244 | RestJson<L>,
|
11071 11245 | crate::operation_shape::MediaTypeHeader,
|
11072 11246 | ModelPl::Output
|
11073 11247 | >
|
11074 11248 | >::Output
|
11075 11249 | >,
|
11076 11250 |
|
11077 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11251 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11078 11252 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11079 11253 |
|
11080 11254 | {
|
11081 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11082 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11255 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11256 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11083 11257 | let svc = crate::operation_shape::MediaTypeHeader::from_service(service);
|
11084 11258 | let svc = self.model_plugin.apply(svc);
|
11085 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11259 + | let svc =
|
11260 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11086 11261 | .apply(svc);
|
11087 11262 | let svc = self.http_plugin.apply(svc);
|
11088 11263 | self.media_type_header_custom(svc)
|
11089 11264 | }
|
11090 11265 |
|
11091 11266 | /// Sets the [`MediaTypeHeader`](crate::operation_shape::MediaTypeHeader) to a custom [`Service`](tower::Service).
|
11092 11267 | /// not constrained by the Smithy contract.
|
11093 11268 | fn media_type_header_custom<S>(mut self, svc: S) -> Self
|
11094 11269 | where
|
11095 11270 | S: ::tower::Service<
|
11096 11271 | ::http::Request<Body>,
|
11097 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11272 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11098 11273 | Error = ::std::convert::Infallible,
|
11099 11274 | > + Clone
|
11100 11275 | + Send
|
11101 11276 | + 'static,
|
11102 11277 | S::Future: Send + 'static,
|
11103 11278 | {
|
11104 - | self.media_type_header = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11279 + | self.media_type_header = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11105 11280 | self
|
11106 11281 | }
|
11107 11282 |
|
11108 11283 | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
11109 11284 | ///
|
11110 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11111 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11285 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11286 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11112 11287 | ///
|
11113 11288 | /// # Example
|
11114 11289 | ///
|
11115 11290 | /// ```no_run
|
11116 11291 | /// use rest_json::{RestJson, RestJsonConfig};
|
11117 11292 | ///
|
11118 11293 | /// use rest_json::{input, output, error};
|
11119 11294 | ///
|
11120 11295 | /// async fn handler(input: input::NoInputAndNoOutputInput) -> Result<output::NoInputAndNoOutputOutput, error::NoInputAndNoOutputError> {
|
11121 11296 | /// todo!()
|
11122 11297 | /// }
|
11123 11298 | ///
|
11124 11299 | /// let config = RestJsonConfig::builder().build();
|
11125 11300 | /// let app = RestJson::builder(config)
|
11126 11301 | /// .no_input_and_no_output(handler)
|
11127 11302 | /// /* Set other handlers */
|
11128 11303 | /// .build()
|
11129 11304 | /// .unwrap();
|
11130 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11305 + | /// # 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;
|
11131 11306 | /// ```
|
11132 11307 | ///
|
11133 11308 | pub fn no_input_and_no_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11134 11309 | where
|
11135 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::NoInputAndNoOutput, HandlerExtractors>,
|
11310 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndNoOutput, HandlerExtractors>,
|
11136 11311 |
|
11137 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11312 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11138 11313 | RestJson<L>,
|
11139 11314 | crate::operation_shape::NoInputAndNoOutput,
|
11140 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::NoInputAndNoOutput, HandlerType>
|
11315 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndNoOutput, HandlerType>
|
11141 11316 | >,
|
11142 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11317 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11143 11318 | RestJson<L>,
|
11144 11319 | crate::operation_shape::NoInputAndNoOutput,
|
11145 11320 | ModelPl::Output
|
11146 11321 | >,
|
11147 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11322 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11148 11323 | RestJson<L>,
|
11149 11324 | crate::operation_shape::NoInputAndNoOutput,
|
11150 11325 | <
|
11151 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11152 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11326 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11327 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11153 11328 | RestJson<L>,
|
11154 11329 | crate::operation_shape::NoInputAndNoOutput,
|
11155 11330 | ModelPl::Output
|
11156 11331 | >
|
11157 11332 | >::Output
|
11158 11333 | >,
|
11159 11334 |
|
11160 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11335 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11161 11336 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11162 11337 |
|
11163 11338 | {
|
11164 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11165 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11339 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11340 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11166 11341 | let svc = crate::operation_shape::NoInputAndNoOutput::from_handler(handler);
|
11167 11342 | let svc = self.model_plugin.apply(svc);
|
11168 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11343 + | let svc =
|
11344 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11169 11345 | .apply(svc);
|
11170 11346 | let svc = self.http_plugin.apply(svc);
|
11171 11347 | self.no_input_and_no_output_custom(svc)
|
11172 11348 | }
|
11173 11349 |
|
11174 11350 | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) operation.
|
11175 11351 | ///
|
11176 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11177 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11352 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11353 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11178 11354 | ///
|
11179 11355 | /// # Example
|
11180 11356 | ///
|
11181 11357 | /// ```no_run
|
11182 11358 | /// use rest_json::{RestJson, RestJsonConfig};
|
11183 11359 | ///
|
11184 11360 | /// use rest_json::{input, output, error};
|
11185 11361 | ///
|
11186 11362 | /// async fn handler(input: input::NoInputAndNoOutputInput) -> Result<output::NoInputAndNoOutputOutput, error::NoInputAndNoOutputError> {
|
11187 11363 | /// todo!()
|
11188 11364 | /// }
|
11189 11365 | ///
|
11190 11366 | /// let config = RestJsonConfig::builder().build();
|
11191 11367 | /// let svc = ::tower::util::service_fn(handler);
|
11192 11368 | /// let app = RestJson::builder(config)
|
11193 11369 | /// .no_input_and_no_output_service(svc)
|
11194 11370 | /// /* Set other handlers */
|
11195 11371 | /// .build()
|
11196 11372 | /// .unwrap();
|
11197 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11373 + | /// # 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;
|
11198 11374 | /// ```
|
11199 11375 | ///
|
11200 11376 | pub fn no_input_and_no_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11201 11377 | where
|
11202 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::NoInputAndNoOutput, ServiceExtractors>,
|
11378 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndNoOutput, ServiceExtractors>,
|
11203 11379 |
|
11204 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11380 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11205 11381 | RestJson<L>,
|
11206 11382 | crate::operation_shape::NoInputAndNoOutput,
|
11207 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::NoInputAndNoOutput, S>
|
11383 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndNoOutput, S>
|
11208 11384 | >,
|
11209 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11385 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11210 11386 | RestJson<L>,
|
11211 11387 | crate::operation_shape::NoInputAndNoOutput,
|
11212 11388 | ModelPl::Output
|
11213 11389 | >,
|
11214 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11390 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11215 11391 | RestJson<L>,
|
11216 11392 | crate::operation_shape::NoInputAndNoOutput,
|
11217 11393 | <
|
11218 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11219 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11394 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11395 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11220 11396 | RestJson<L>,
|
11221 11397 | crate::operation_shape::NoInputAndNoOutput,
|
11222 11398 | ModelPl::Output
|
11223 11399 | >
|
11224 11400 | >::Output
|
11225 11401 | >,
|
11226 11402 |
|
11227 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11403 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11228 11404 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11229 11405 |
|
11230 11406 | {
|
11231 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11232 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11407 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11408 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11233 11409 | let svc = crate::operation_shape::NoInputAndNoOutput::from_service(service);
|
11234 11410 | let svc = self.model_plugin.apply(svc);
|
11235 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11411 + | let svc =
|
11412 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11236 11413 | .apply(svc);
|
11237 11414 | let svc = self.http_plugin.apply(svc);
|
11238 11415 | self.no_input_and_no_output_custom(svc)
|
11239 11416 | }
|
11240 11417 |
|
11241 11418 | /// Sets the [`NoInputAndNoOutput`](crate::operation_shape::NoInputAndNoOutput) to a custom [`Service`](tower::Service).
|
11242 11419 | /// not constrained by the Smithy contract.
|
11243 11420 | fn no_input_and_no_output_custom<S>(mut self, svc: S) -> Self
|
11244 11421 | where
|
11245 11422 | S: ::tower::Service<
|
11246 11423 | ::http::Request<Body>,
|
11247 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11424 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11248 11425 | Error = ::std::convert::Infallible,
|
11249 11426 | > + Clone
|
11250 11427 | + Send
|
11251 11428 | + 'static,
|
11252 11429 | S::Future: Send + 'static,
|
11253 11430 | {
|
11254 - | self.no_input_and_no_output = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11431 + | self.no_input_and_no_output =
|
11432 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11255 11433 | self
|
11256 11434 | }
|
11257 11435 |
|
11258 11436 | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
11259 11437 | ///
|
11260 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11261 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11438 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11439 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11262 11440 | ///
|
11263 11441 | /// # Example
|
11264 11442 | ///
|
11265 11443 | /// ```no_run
|
11266 11444 | /// use rest_json::{RestJson, RestJsonConfig};
|
11267 11445 | ///
|
11268 11446 | /// use rest_json::{input, output, error};
|
11269 11447 | ///
|
11270 11448 | /// async fn handler(input: input::NoInputAndOutputInput) -> Result<output::NoInputAndOutputOutput, error::NoInputAndOutputError> {
|
11271 11449 | /// todo!()
|
11272 11450 | /// }
|
11273 11451 | ///
|
11274 11452 | /// let config = RestJsonConfig::builder().build();
|
11275 11453 | /// let app = RestJson::builder(config)
|
11276 11454 | /// .no_input_and_output(handler)
|
11277 11455 | /// /* Set other handlers */
|
11278 11456 | /// .build()
|
11279 11457 | /// .unwrap();
|
11280 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11458 + | /// # 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;
|
11281 11459 | /// ```
|
11282 11460 | ///
|
11283 11461 | pub fn no_input_and_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11284 11462 | where
|
11285 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::NoInputAndOutput, HandlerExtractors>,
|
11463 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NoInputAndOutput, HandlerExtractors>,
|
11286 11464 |
|
11287 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11465 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11288 11466 | RestJson<L>,
|
11289 11467 | crate::operation_shape::NoInputAndOutput,
|
11290 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::NoInputAndOutput, HandlerType>
|
11468 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NoInputAndOutput, HandlerType>
|
11291 11469 | >,
|
11292 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11470 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11293 11471 | RestJson<L>,
|
11294 11472 | crate::operation_shape::NoInputAndOutput,
|
11295 11473 | ModelPl::Output
|
11296 11474 | >,
|
11297 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11475 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11298 11476 | RestJson<L>,
|
11299 11477 | crate::operation_shape::NoInputAndOutput,
|
11300 11478 | <
|
11301 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11302 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11479 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11480 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11303 11481 | RestJson<L>,
|
11304 11482 | crate::operation_shape::NoInputAndOutput,
|
11305 11483 | ModelPl::Output
|
11306 11484 | >
|
11307 11485 | >::Output
|
11308 11486 | >,
|
11309 11487 |
|
11310 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11488 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11311 11489 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11312 11490 |
|
11313 11491 | {
|
11314 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11315 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11492 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11493 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11316 11494 | let svc = crate::operation_shape::NoInputAndOutput::from_handler(handler);
|
11317 11495 | let svc = self.model_plugin.apply(svc);
|
11318 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11496 + | let svc =
|
11497 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11319 11498 | .apply(svc);
|
11320 11499 | let svc = self.http_plugin.apply(svc);
|
11321 11500 | self.no_input_and_output_custom(svc)
|
11322 11501 | }
|
11323 11502 |
|
11324 11503 | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) operation.
|
11325 11504 | ///
|
11326 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11327 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11505 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11506 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11328 11507 | ///
|
11329 11508 | /// # Example
|
11330 11509 | ///
|
11331 11510 | /// ```no_run
|
11332 11511 | /// use rest_json::{RestJson, RestJsonConfig};
|
11333 11512 | ///
|
11334 11513 | /// use rest_json::{input, output, error};
|
11335 11514 | ///
|
11336 11515 | /// async fn handler(input: input::NoInputAndOutputInput) -> Result<output::NoInputAndOutputOutput, error::NoInputAndOutputError> {
|
11337 11516 | /// todo!()
|
11338 11517 | /// }
|
11339 11518 | ///
|
11340 11519 | /// let config = RestJsonConfig::builder().build();
|
11341 11520 | /// let svc = ::tower::util::service_fn(handler);
|
11342 11521 | /// let app = RestJson::builder(config)
|
11343 11522 | /// .no_input_and_output_service(svc)
|
11344 11523 | /// /* Set other handlers */
|
11345 11524 | /// .build()
|
11346 11525 | /// .unwrap();
|
11347 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11526 + | /// # 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;
|
11348 11527 | /// ```
|
11349 11528 | ///
|
11350 11529 | pub fn no_input_and_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11351 11530 | where
|
11352 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::NoInputAndOutput, ServiceExtractors>,
|
11531 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NoInputAndOutput, ServiceExtractors>,
|
11353 11532 |
|
11354 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11533 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11355 11534 | RestJson<L>,
|
11356 11535 | crate::operation_shape::NoInputAndOutput,
|
11357 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::NoInputAndOutput, S>
|
11536 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NoInputAndOutput, S>
|
11358 11537 | >,
|
11359 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11538 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11360 11539 | RestJson<L>,
|
11361 11540 | crate::operation_shape::NoInputAndOutput,
|
11362 11541 | ModelPl::Output
|
11363 11542 | >,
|
11364 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11543 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11365 11544 | RestJson<L>,
|
11366 11545 | crate::operation_shape::NoInputAndOutput,
|
11367 11546 | <
|
11368 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11369 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11547 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11548 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11370 11549 | RestJson<L>,
|
11371 11550 | crate::operation_shape::NoInputAndOutput,
|
11372 11551 | ModelPl::Output
|
11373 11552 | >
|
11374 11553 | >::Output
|
11375 11554 | >,
|
11376 11555 |
|
11377 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11556 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11378 11557 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11379 11558 |
|
11380 11559 | {
|
11381 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11382 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11560 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11561 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11383 11562 | let svc = crate::operation_shape::NoInputAndOutput::from_service(service);
|
11384 11563 | let svc = self.model_plugin.apply(svc);
|
11385 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11564 + | let svc =
|
11565 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11386 11566 | .apply(svc);
|
11387 11567 | let svc = self.http_plugin.apply(svc);
|
11388 11568 | self.no_input_and_output_custom(svc)
|
11389 11569 | }
|
11390 11570 |
|
11391 11571 | /// Sets the [`NoInputAndOutput`](crate::operation_shape::NoInputAndOutput) to a custom [`Service`](tower::Service).
|
11392 11572 | /// not constrained by the Smithy contract.
|
11393 11573 | fn no_input_and_output_custom<S>(mut self, svc: S) -> Self
|
11394 11574 | where
|
11395 11575 | S: ::tower::Service<
|
11396 11576 | ::http::Request<Body>,
|
11397 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11577 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11398 11578 | Error = ::std::convert::Infallible,
|
11399 11579 | > + Clone
|
11400 11580 | + Send
|
11401 11581 | + 'static,
|
11402 11582 | S::Future: Send + 'static,
|
11403 11583 | {
|
11404 - | self.no_input_and_output = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11584 + | self.no_input_and_output = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11405 11585 | self
|
11406 11586 | }
|
11407 11587 |
|
11408 11588 | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
11409 11589 | ///
|
11410 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11411 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11590 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11591 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11412 11592 | ///
|
11413 11593 | /// # Example
|
11414 11594 | ///
|
11415 11595 | /// ```no_run
|
11416 11596 | /// use rest_json::{RestJson, RestJsonConfig};
|
11417 11597 | ///
|
11418 11598 | /// use rest_json::{input, output, error};
|
11419 11599 | ///
|
11420 11600 | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> Result<output::NullAndEmptyHeadersClientOutput, error::NullAndEmptyHeadersClientError> {
|
11421 11601 | /// todo!()
|
11422 11602 | /// }
|
11423 11603 | ///
|
11424 11604 | /// let config = RestJsonConfig::builder().build();
|
11425 11605 | /// let app = RestJson::builder(config)
|
11426 11606 | /// .null_and_empty_headers_client(handler)
|
11427 11607 | /// /* Set other handlers */
|
11428 11608 | /// .build()
|
11429 11609 | /// .unwrap();
|
11430 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11610 + | /// # 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;
|
11431 11611 | /// ```
|
11432 11612 | ///
|
11433 11613 | pub fn null_and_empty_headers_client<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11434 11614 | where
|
11435 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersClient, HandlerExtractors>,
|
11615 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersClient, HandlerExtractors>,
|
11436 11616 |
|
11437 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11617 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11438 11618 | RestJson<L>,
|
11439 11619 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11440 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersClient, HandlerType>
|
11620 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersClient, HandlerType>
|
11441 11621 | >,
|
11442 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11622 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11443 11623 | RestJson<L>,
|
11444 11624 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11445 11625 | ModelPl::Output
|
11446 11626 | >,
|
11447 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11627 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11448 11628 | RestJson<L>,
|
11449 11629 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11450 11630 | <
|
11451 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11452 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11631 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11632 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11453 11633 | RestJson<L>,
|
11454 11634 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11455 11635 | ModelPl::Output
|
11456 11636 | >
|
11457 11637 | >::Output
|
11458 11638 | >,
|
11459 11639 |
|
11460 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11640 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11461 11641 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11462 11642 |
|
11463 11643 | {
|
11464 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11465 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11644 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11645 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11466 11646 | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_handler(handler);
|
11467 11647 | let svc = self.model_plugin.apply(svc);
|
11468 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11648 + | let svc =
|
11649 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11469 11650 | .apply(svc);
|
11470 11651 | let svc = self.http_plugin.apply(svc);
|
11471 11652 | self.null_and_empty_headers_client_custom(svc)
|
11472 11653 | }
|
11473 11654 |
|
11474 11655 | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) operation.
|
11475 11656 | ///
|
11476 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11477 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11657 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11658 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11478 11659 | ///
|
11479 11660 | /// # Example
|
11480 11661 | ///
|
11481 11662 | /// ```no_run
|
11482 11663 | /// use rest_json::{RestJson, RestJsonConfig};
|
11483 11664 | ///
|
11484 11665 | /// use rest_json::{input, output, error};
|
11485 11666 | ///
|
11486 11667 | /// async fn handler(input: input::NullAndEmptyHeadersClientInput) -> Result<output::NullAndEmptyHeadersClientOutput, error::NullAndEmptyHeadersClientError> {
|
11487 11668 | /// todo!()
|
11488 11669 | /// }
|
11489 11670 | ///
|
11490 11671 | /// let config = RestJsonConfig::builder().build();
|
11491 11672 | /// let svc = ::tower::util::service_fn(handler);
|
11492 11673 | /// let app = RestJson::builder(config)
|
11493 11674 | /// .null_and_empty_headers_client_service(svc)
|
11494 11675 | /// /* Set other handlers */
|
11495 11676 | /// .build()
|
11496 11677 | /// .unwrap();
|
11497 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11678 + | /// # 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;
|
11498 11679 | /// ```
|
11499 11680 | ///
|
11500 11681 | pub fn null_and_empty_headers_client_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11501 11682 | where
|
11502 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersClient, ServiceExtractors>,
|
11683 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersClient, ServiceExtractors>,
|
11503 11684 |
|
11504 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11685 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11505 11686 | RestJson<L>,
|
11506 11687 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11507 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersClient, S>
|
11688 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersClient, S>
|
11508 11689 | >,
|
11509 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11690 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11510 11691 | RestJson<L>,
|
11511 11692 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11512 11693 | ModelPl::Output
|
11513 11694 | >,
|
11514 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11695 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11515 11696 | RestJson<L>,
|
11516 11697 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11517 11698 | <
|
11518 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11519 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11699 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11700 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11520 11701 | RestJson<L>,
|
11521 11702 | crate::operation_shape::NullAndEmptyHeadersClient,
|
11522 11703 | ModelPl::Output
|
11523 11704 | >
|
11524 11705 | >::Output
|
11525 11706 | >,
|
11526 11707 |
|
11527 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11708 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11528 11709 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11529 11710 |
|
11530 11711 | {
|
11531 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11532 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11712 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11713 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11533 11714 | let svc = crate::operation_shape::NullAndEmptyHeadersClient::from_service(service);
|
11534 11715 | let svc = self.model_plugin.apply(svc);
|
11535 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11716 + | let svc =
|
11717 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11536 11718 | .apply(svc);
|
11537 11719 | let svc = self.http_plugin.apply(svc);
|
11538 11720 | self.null_and_empty_headers_client_custom(svc)
|
11539 11721 | }
|
11540 11722 |
|
11541 11723 | /// Sets the [`NullAndEmptyHeadersClient`](crate::operation_shape::NullAndEmptyHeadersClient) to a custom [`Service`](tower::Service).
|
11542 11724 | /// not constrained by the Smithy contract.
|
11543 11725 | fn null_and_empty_headers_client_custom<S>(mut self, svc: S) -> Self
|
11544 11726 | where
|
11545 11727 | S: ::tower::Service<
|
11546 11728 | ::http::Request<Body>,
|
11547 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11729 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11548 11730 | Error = ::std::convert::Infallible,
|
11549 11731 | > + Clone
|
11550 11732 | + Send
|
11551 11733 | + 'static,
|
11552 11734 | S::Future: Send + 'static,
|
11553 11735 | {
|
11554 11736 | self.null_and_empty_headers_client =
|
11555 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11737 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11556 11738 | self
|
11557 11739 | }
|
11558 11740 |
|
11559 11741 | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
11560 11742 | ///
|
11561 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11562 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11743 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11744 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11563 11745 | ///
|
11564 11746 | /// # Example
|
11565 11747 | ///
|
11566 11748 | /// ```no_run
|
11567 11749 | /// use rest_json::{RestJson, RestJsonConfig};
|
11568 11750 | ///
|
11569 11751 | /// use rest_json::{input, output, error};
|
11570 11752 | ///
|
11571 11753 | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> Result<output::NullAndEmptyHeadersServerOutput, error::NullAndEmptyHeadersServerError> {
|
11572 11754 | /// todo!()
|
11573 11755 | /// }
|
11574 11756 | ///
|
11575 11757 | /// let config = RestJsonConfig::builder().build();
|
11576 11758 | /// let app = RestJson::builder(config)
|
11577 11759 | /// .null_and_empty_headers_server(handler)
|
11578 11760 | /// /* Set other handlers */
|
11579 11761 | /// .build()
|
11580 11762 | /// .unwrap();
|
11581 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11763 + | /// # 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;
|
11582 11764 | /// ```
|
11583 11765 | ///
|
11584 11766 | pub fn null_and_empty_headers_server<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11585 11767 | where
|
11586 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersServer, HandlerExtractors>,
|
11768 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::NullAndEmptyHeadersServer, HandlerExtractors>,
|
11587 11769 |
|
11588 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11770 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11589 11771 | RestJson<L>,
|
11590 11772 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11591 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersServer, HandlerType>
|
11773 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::NullAndEmptyHeadersServer, HandlerType>
|
11592 11774 | >,
|
11593 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11775 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11594 11776 | RestJson<L>,
|
11595 11777 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11596 11778 | ModelPl::Output
|
11597 11779 | >,
|
11598 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11780 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11599 11781 | RestJson<L>,
|
11600 11782 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11601 11783 | <
|
11602 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11603 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11784 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11785 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11604 11786 | RestJson<L>,
|
11605 11787 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11606 11788 | ModelPl::Output
|
11607 11789 | >
|
11608 11790 | >::Output
|
11609 11791 | >,
|
11610 11792 |
|
11611 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11793 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11612 11794 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11613 11795 |
|
11614 11796 | {
|
11615 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11616 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11797 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11798 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11617 11799 | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_handler(handler);
|
11618 11800 | let svc = self.model_plugin.apply(svc);
|
11619 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11801 + | let svc =
|
11802 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11620 11803 | .apply(svc);
|
11621 11804 | let svc = self.http_plugin.apply(svc);
|
11622 11805 | self.null_and_empty_headers_server_custom(svc)
|
11623 11806 | }
|
11624 11807 |
|
11625 11808 | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) operation.
|
11626 11809 | ///
|
11627 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11628 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11810 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11811 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11629 11812 | ///
|
11630 11813 | /// # Example
|
11631 11814 | ///
|
11632 11815 | /// ```no_run
|
11633 11816 | /// use rest_json::{RestJson, RestJsonConfig};
|
11634 11817 | ///
|
11635 11818 | /// use rest_json::{input, output, error};
|
11636 11819 | ///
|
11637 11820 | /// async fn handler(input: input::NullAndEmptyHeadersServerInput) -> Result<output::NullAndEmptyHeadersServerOutput, error::NullAndEmptyHeadersServerError> {
|
11638 11821 | /// todo!()
|
11639 11822 | /// }
|
11640 11823 | ///
|
11641 11824 | /// let config = RestJsonConfig::builder().build();
|
11642 11825 | /// let svc = ::tower::util::service_fn(handler);
|
11643 11826 | /// let app = RestJson::builder(config)
|
11644 11827 | /// .null_and_empty_headers_server_service(svc)
|
11645 11828 | /// /* Set other handlers */
|
11646 11829 | /// .build()
|
11647 11830 | /// .unwrap();
|
11648 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11831 + | /// # 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;
|
11649 11832 | /// ```
|
11650 11833 | ///
|
11651 11834 | pub fn null_and_empty_headers_server_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11652 11835 | where
|
11653 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersServer, ServiceExtractors>,
|
11836 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::NullAndEmptyHeadersServer, ServiceExtractors>,
|
11654 11837 |
|
11655 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11838 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11656 11839 | RestJson<L>,
|
11657 11840 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11658 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersServer, S>
|
11841 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::NullAndEmptyHeadersServer, S>
|
11659 11842 | >,
|
11660 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11843 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11661 11844 | RestJson<L>,
|
11662 11845 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11663 11846 | ModelPl::Output
|
11664 11847 | >,
|
11665 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11848 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11666 11849 | RestJson<L>,
|
11667 11850 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11668 11851 | <
|
11669 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11670 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11852 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11853 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11671 11854 | RestJson<L>,
|
11672 11855 | crate::operation_shape::NullAndEmptyHeadersServer,
|
11673 11856 | ModelPl::Output
|
11674 11857 | >
|
11675 11858 | >::Output
|
11676 11859 | >,
|
11677 11860 |
|
11678 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11861 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11679 11862 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11680 11863 |
|
11681 11864 | {
|
11682 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11683 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11865 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11866 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11684 11867 | let svc = crate::operation_shape::NullAndEmptyHeadersServer::from_service(service);
|
11685 11868 | let svc = self.model_plugin.apply(svc);
|
11686 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11869 + | let svc =
|
11870 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11687 11871 | .apply(svc);
|
11688 11872 | let svc = self.http_plugin.apply(svc);
|
11689 11873 | self.null_and_empty_headers_server_custom(svc)
|
11690 11874 | }
|
11691 11875 |
|
11692 11876 | /// Sets the [`NullAndEmptyHeadersServer`](crate::operation_shape::NullAndEmptyHeadersServer) to a custom [`Service`](tower::Service).
|
11693 11877 | /// not constrained by the Smithy contract.
|
11694 11878 | fn null_and_empty_headers_server_custom<S>(mut self, svc: S) -> Self
|
11695 11879 | where
|
11696 11880 | S: ::tower::Service<
|
11697 11881 | ::http::Request<Body>,
|
11698 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
11882 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11699 11883 | Error = ::std::convert::Infallible,
|
11700 11884 | > + Clone
|
11701 11885 | + Send
|
11702 11886 | + 'static,
|
11703 11887 | S::Future: Send + 'static,
|
11704 11888 | {
|
11705 11889 | self.null_and_empty_headers_server =
|
11706 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
11890 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11707 11891 | self
|
11708 11892 | }
|
11709 11893 |
|
11710 11894 | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
11711 11895 | ///
|
11712 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11713 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11896 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11897 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11714 11898 | ///
|
11715 11899 | /// # Example
|
11716 11900 | ///
|
11717 11901 | /// ```no_run
|
11718 11902 | /// use rest_json::{RestJson, RestJsonConfig};
|
11719 11903 | ///
|
11720 11904 | /// use rest_json::{input, output, error};
|
11721 11905 | ///
|
11722 11906 | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> Result<output::OmitsNullSerializesEmptyStringOutput, error::OmitsNullSerializesEmptyStringError> {
|
11723 11907 | /// todo!()
|
11724 11908 | /// }
|
11725 11909 | ///
|
11726 11910 | /// let config = RestJsonConfig::builder().build();
|
11727 11911 | /// let app = RestJson::builder(config)
|
11728 11912 | /// .omits_null_serializes_empty_string(handler)
|
11729 11913 | /// /* Set other handlers */
|
11730 11914 | /// .build()
|
11731 11915 | /// .unwrap();
|
11732 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11916 + | /// # 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;
|
11733 11917 | /// ```
|
11734 11918 | ///
|
11735 11919 | pub fn omits_null_serializes_empty_string<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11736 11920 | where
|
11737 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerExtractors>,
|
11921 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerExtractors>,
|
11738 11922 |
|
11739 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11923 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11740 11924 | RestJson<L>,
|
11741 11925 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11742 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerType>
|
11926 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsNullSerializesEmptyString, HandlerType>
|
11743 11927 | >,
|
11744 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11928 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11745 11929 | RestJson<L>,
|
11746 11930 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11747 11931 | ModelPl::Output
|
11748 11932 | >,
|
11749 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
11933 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11750 11934 | RestJson<L>,
|
11751 11935 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11752 11936 | <
|
11753 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11754 - | as ::aws_smithy_http_server::plugin::Plugin<
|
11937 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11938 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11755 11939 | RestJson<L>,
|
11756 11940 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11757 11941 | ModelPl::Output
|
11758 11942 | >
|
11759 11943 | >::Output
|
11760 11944 | >,
|
11761 11945 |
|
11762 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11946 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11763 11947 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11764 11948 |
|
11765 11949 | {
|
11766 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11767 - | use ::aws_smithy_http_server::plugin::Plugin;
|
11950 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
11951 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11768 11952 | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_handler(handler);
|
11769 11953 | let svc = self.model_plugin.apply(svc);
|
11770 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11954 + | let svc =
|
11955 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11771 11956 | .apply(svc);
|
11772 11957 | let svc = self.http_plugin.apply(svc);
|
11773 11958 | self.omits_null_serializes_empty_string_custom(svc)
|
11774 11959 | }
|
11775 11960 |
|
11776 11961 | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) operation.
|
11777 11962 | ///
|
11778 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11779 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
11963 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
11964 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11780 11965 | ///
|
11781 11966 | /// # Example
|
11782 11967 | ///
|
11783 11968 | /// ```no_run
|
11784 11969 | /// use rest_json::{RestJson, RestJsonConfig};
|
11785 11970 | ///
|
11786 11971 | /// use rest_json::{input, output, error};
|
11787 11972 | ///
|
11788 11973 | /// async fn handler(input: input::OmitsNullSerializesEmptyStringInput) -> Result<output::OmitsNullSerializesEmptyStringOutput, error::OmitsNullSerializesEmptyStringError> {
|
11789 11974 | /// todo!()
|
11790 11975 | /// }
|
11791 11976 | ///
|
11792 11977 | /// let config = RestJsonConfig::builder().build();
|
11793 11978 | /// let svc = ::tower::util::service_fn(handler);
|
11794 11979 | /// let app = RestJson::builder(config)
|
11795 11980 | /// .omits_null_serializes_empty_string_service(svc)
|
11796 11981 | /// /* Set other handlers */
|
11797 11982 | /// .build()
|
11798 11983 | /// .unwrap();
|
11799 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
11984 + | /// # 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;
|
11800 11985 | /// ```
|
11801 11986 | ///
|
11802 11987 | pub fn omits_null_serializes_empty_string_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11803 11988 | where
|
11804 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::OmitsNullSerializesEmptyString, ServiceExtractors>,
|
11989 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsNullSerializesEmptyString, ServiceExtractors>,
|
11805 11990 |
|
11806 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
11991 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11807 11992 | RestJson<L>,
|
11808 11993 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11809 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::OmitsNullSerializesEmptyString, S>
|
11994 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsNullSerializesEmptyString, S>
|
11810 11995 | >,
|
11811 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
11996 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11812 11997 | RestJson<L>,
|
11813 11998 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11814 11999 | ModelPl::Output
|
11815 12000 | >,
|
11816 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12001 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11817 12002 | RestJson<L>,
|
11818 12003 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11819 12004 | <
|
11820 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11821 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12005 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12006 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11822 12007 | RestJson<L>,
|
11823 12008 | crate::operation_shape::OmitsNullSerializesEmptyString,
|
11824 12009 | ModelPl::Output
|
11825 12010 | >
|
11826 12011 | >::Output
|
11827 12012 | >,
|
11828 12013 |
|
11829 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12014 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11830 12015 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11831 12016 |
|
11832 12017 | {
|
11833 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11834 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12018 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12019 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11835 12020 | let svc = crate::operation_shape::OmitsNullSerializesEmptyString::from_service(service);
|
11836 12021 | let svc = self.model_plugin.apply(svc);
|
11837 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12022 + | let svc =
|
12023 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11838 12024 | .apply(svc);
|
11839 12025 | let svc = self.http_plugin.apply(svc);
|
11840 12026 | self.omits_null_serializes_empty_string_custom(svc)
|
11841 12027 | }
|
11842 12028 |
|
11843 12029 | /// Sets the [`OmitsNullSerializesEmptyString`](crate::operation_shape::OmitsNullSerializesEmptyString) to a custom [`Service`](tower::Service).
|
11844 12030 | /// not constrained by the Smithy contract.
|
11845 12031 | fn omits_null_serializes_empty_string_custom<S>(mut self, svc: S) -> Self
|
11846 12032 | where
|
11847 12033 | S: ::tower::Service<
|
11848 12034 | ::http::Request<Body>,
|
11849 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12035 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
11850 12036 | Error = ::std::convert::Infallible,
|
11851 12037 | > + Clone
|
11852 12038 | + Send
|
11853 12039 | + 'static,
|
11854 12040 | S::Future: Send + 'static,
|
11855 12041 | {
|
11856 12042 | self.omits_null_serializes_empty_string =
|
11857 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12043 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
11858 12044 | self
|
11859 12045 | }
|
11860 12046 |
|
11861 12047 | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
11862 12048 | ///
|
11863 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11864 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12049 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12050 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11865 12051 | ///
|
11866 12052 | /// # Example
|
11867 12053 | ///
|
11868 12054 | /// ```no_run
|
11869 12055 | /// use rest_json::{RestJson, RestJsonConfig};
|
11870 12056 | ///
|
11871 12057 | /// use rest_json::{input, output, error};
|
11872 12058 | ///
|
11873 12059 | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
11874 12060 | /// todo!()
|
11875 12061 | /// }
|
11876 12062 | ///
|
11877 12063 | /// let config = RestJsonConfig::builder().build();
|
11878 12064 | /// let app = RestJson::builder(config)
|
11879 12065 | /// .omits_serializing_empty_lists(handler)
|
11880 12066 | /// /* Set other handlers */
|
11881 12067 | /// .build()
|
11882 12068 | /// .unwrap();
|
11883 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12069 + | /// # 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;
|
11884 12070 | /// ```
|
11885 12071 | ///
|
11886 12072 | pub fn omits_serializing_empty_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
11887 12073 | where
|
11888 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::OmitsSerializingEmptyLists, HandlerExtractors>,
|
12074 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OmitsSerializingEmptyLists, HandlerExtractors>,
|
11889 12075 |
|
11890 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12076 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11891 12077 | RestJson<L>,
|
11892 12078 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11893 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::OmitsSerializingEmptyLists, HandlerType>
|
12079 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OmitsSerializingEmptyLists, HandlerType>
|
11894 12080 | >,
|
11895 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12081 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11896 12082 | RestJson<L>,
|
11897 12083 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11898 12084 | ModelPl::Output
|
11899 12085 | >,
|
11900 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12086 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11901 12087 | RestJson<L>,
|
11902 12088 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11903 12089 | <
|
11904 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11905 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12090 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12091 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11906 12092 | RestJson<L>,
|
11907 12093 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11908 12094 | ModelPl::Output
|
11909 12095 | >
|
11910 12096 | >::Output
|
11911 12097 | >,
|
11912 12098 |
|
11913 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12099 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11914 12100 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11915 12101 |
|
11916 12102 | {
|
11917 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11918 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12103 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12104 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11919 12105 | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_handler(handler);
|
11920 12106 | let svc = self.model_plugin.apply(svc);
|
11921 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12107 + | let svc =
|
12108 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11922 12109 | .apply(svc);
|
11923 12110 | let svc = self.http_plugin.apply(svc);
|
11924 12111 | self.omits_serializing_empty_lists_custom(svc)
|
11925 12112 | }
|
11926 12113 |
|
11927 12114 | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) operation.
|
11928 12115 | ///
|
11929 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
11930 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12116 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12117 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
11931 12118 | ///
|
11932 12119 | /// # Example
|
11933 12120 | ///
|
11934 12121 | /// ```no_run
|
11935 12122 | /// use rest_json::{RestJson, RestJsonConfig};
|
11936 12123 | ///
|
11937 12124 | /// use rest_json::{input, output, error};
|
11938 12125 | ///
|
11939 12126 | /// async fn handler(input: input::OmitsSerializingEmptyListsInput) -> Result<output::OmitsSerializingEmptyListsOutput, error::OmitsSerializingEmptyListsError> {
|
11940 12127 | /// todo!()
|
11941 12128 | /// }
|
11942 12129 | ///
|
11943 12130 | /// let config = RestJsonConfig::builder().build();
|
11944 12131 | /// let svc = ::tower::util::service_fn(handler);
|
11945 12132 | /// let app = RestJson::builder(config)
|
11946 12133 | /// .omits_serializing_empty_lists_service(svc)
|
11947 12134 | /// /* Set other handlers */
|
11948 12135 | /// .build()
|
11949 12136 | /// .unwrap();
|
11950 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12137 + | /// # 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;
|
11951 12138 | /// ```
|
11952 12139 | ///
|
11953 12140 | pub fn omits_serializing_empty_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
11954 12141 | where
|
11955 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::OmitsSerializingEmptyLists, ServiceExtractors>,
|
12142 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OmitsSerializingEmptyLists, ServiceExtractors>,
|
11956 12143 |
|
11957 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12144 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11958 12145 | RestJson<L>,
|
11959 12146 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11960 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::OmitsSerializingEmptyLists, S>
|
12147 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OmitsSerializingEmptyLists, S>
|
11961 12148 | >,
|
11962 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12149 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11963 12150 | RestJson<L>,
|
11964 12151 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11965 12152 | ModelPl::Output
|
11966 12153 | >,
|
11967 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12154 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11968 12155 | RestJson<L>,
|
11969 12156 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11970 12157 | <
|
11971 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
11972 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12158 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12159 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
11973 12160 | RestJson<L>,
|
11974 12161 | crate::operation_shape::OmitsSerializingEmptyLists,
|
11975 12162 | ModelPl::Output
|
11976 12163 | >
|
11977 12164 | >::Output
|
11978 12165 | >,
|
11979 12166 |
|
11980 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12167 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
11981 12168 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
11982 12169 |
|
11983 12170 | {
|
11984 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
11985 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12171 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12172 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
11986 12173 | let svc = crate::operation_shape::OmitsSerializingEmptyLists::from_service(service);
|
11987 12174 | let svc = self.model_plugin.apply(svc);
|
11988 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12175 + | let svc =
|
12176 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
11989 12177 | .apply(svc);
|
11990 12178 | let svc = self.http_plugin.apply(svc);
|
11991 12179 | self.omits_serializing_empty_lists_custom(svc)
|
11992 12180 | }
|
11993 12181 |
|
11994 12182 | /// Sets the [`OmitsSerializingEmptyLists`](crate::operation_shape::OmitsSerializingEmptyLists) to a custom [`Service`](tower::Service).
|
11995 12183 | /// not constrained by the Smithy contract.
|
11996 12184 | fn omits_serializing_empty_lists_custom<S>(mut self, svc: S) -> Self
|
11997 12185 | where
|
11998 12186 | S: ::tower::Service<
|
11999 12187 | ::http::Request<Body>,
|
12000 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12188 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12001 12189 | Error = ::std::convert::Infallible,
|
12002 12190 | > + Clone
|
12003 12191 | + Send
|
12004 12192 | + 'static,
|
12005 12193 | S::Future: Send + 'static,
|
12006 12194 | {
|
12007 12195 | self.omits_serializing_empty_lists =
|
12008 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12196 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12009 12197 | self
|
12010 12198 | }
|
12011 12199 |
|
12012 12200 | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
12013 12201 | ///
|
12014 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12015 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12202 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12203 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12016 12204 | ///
|
12017 12205 | /// # Example
|
12018 12206 | ///
|
12019 12207 | /// ```no_run
|
12020 12208 | /// use rest_json::{RestJson, RestJsonConfig};
|
12021 12209 | ///
|
12022 12210 | /// use rest_json::{input, output, error};
|
12023 12211 | ///
|
12024 12212 | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
12025 12213 | /// todo!()
|
12026 12214 | /// }
|
12027 12215 | ///
|
12028 12216 | /// let config = RestJsonConfig::builder().build();
|
12029 12217 | /// let app = RestJson::builder(config)
|
12030 12218 | /// .operation_with_defaults(handler)
|
12031 12219 | /// /* Set other handlers */
|
12032 12220 | /// .build()
|
12033 12221 | /// .unwrap();
|
12034 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12222 + | /// # 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;
|
12035 12223 | /// ```
|
12036 12224 | ///
|
12037 12225 | pub fn operation_with_defaults<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12038 12226 | where
|
12039 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::OperationWithDefaults, HandlerExtractors>,
|
12227 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithDefaults, HandlerExtractors>,
|
12040 12228 |
|
12041 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12229 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12042 12230 | RestJson<L>,
|
12043 12231 | crate::operation_shape::OperationWithDefaults,
|
12044 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::OperationWithDefaults, HandlerType>
|
12232 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithDefaults, HandlerType>
|
12045 12233 | >,
|
12046 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12234 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12047 12235 | RestJson<L>,
|
12048 12236 | crate::operation_shape::OperationWithDefaults,
|
12049 12237 | ModelPl::Output
|
12050 12238 | >,
|
12051 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12239 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12052 12240 | RestJson<L>,
|
12053 12241 | crate::operation_shape::OperationWithDefaults,
|
12054 12242 | <
|
12055 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12056 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12243 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12244 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12057 12245 | RestJson<L>,
|
12058 12246 | crate::operation_shape::OperationWithDefaults,
|
12059 12247 | ModelPl::Output
|
12060 12248 | >
|
12061 12249 | >::Output
|
12062 12250 | >,
|
12063 12251 |
|
12064 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12252 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12065 12253 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12066 12254 |
|
12067 12255 | {
|
12068 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12069 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12256 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12257 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12070 12258 | let svc = crate::operation_shape::OperationWithDefaults::from_handler(handler);
|
12071 12259 | let svc = self.model_plugin.apply(svc);
|
12072 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12260 + | let svc =
|
12261 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12073 12262 | .apply(svc);
|
12074 12263 | let svc = self.http_plugin.apply(svc);
|
12075 12264 | self.operation_with_defaults_custom(svc)
|
12076 12265 | }
|
12077 12266 |
|
12078 12267 | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) operation.
|
12079 12268 | ///
|
12080 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12081 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12269 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12270 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12082 12271 | ///
|
12083 12272 | /// # Example
|
12084 12273 | ///
|
12085 12274 | /// ```no_run
|
12086 12275 | /// use rest_json::{RestJson, RestJsonConfig};
|
12087 12276 | ///
|
12088 12277 | /// use rest_json::{input, output, error};
|
12089 12278 | ///
|
12090 12279 | /// async fn handler(input: input::OperationWithDefaultsInput) -> Result<output::OperationWithDefaultsOutput, error::OperationWithDefaultsError> {
|
12091 12280 | /// todo!()
|
12092 12281 | /// }
|
12093 12282 | ///
|
12094 12283 | /// let config = RestJsonConfig::builder().build();
|
12095 12284 | /// let svc = ::tower::util::service_fn(handler);
|
12096 12285 | /// let app = RestJson::builder(config)
|
12097 12286 | /// .operation_with_defaults_service(svc)
|
12098 12287 | /// /* Set other handlers */
|
12099 12288 | /// .build()
|
12100 12289 | /// .unwrap();
|
12101 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12290 + | /// # 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;
|
12102 12291 | /// ```
|
12103 12292 | ///
|
12104 12293 | pub fn operation_with_defaults_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12105 12294 | where
|
12106 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::OperationWithDefaults, ServiceExtractors>,
|
12295 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithDefaults, ServiceExtractors>,
|
12107 12296 |
|
12108 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12297 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12109 12298 | RestJson<L>,
|
12110 12299 | crate::operation_shape::OperationWithDefaults,
|
12111 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::OperationWithDefaults, S>
|
12300 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithDefaults, S>
|
12112 12301 | >,
|
12113 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12302 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12114 12303 | RestJson<L>,
|
12115 12304 | crate::operation_shape::OperationWithDefaults,
|
12116 12305 | ModelPl::Output
|
12117 12306 | >,
|
12118 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12307 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12119 12308 | RestJson<L>,
|
12120 12309 | crate::operation_shape::OperationWithDefaults,
|
12121 12310 | <
|
12122 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12123 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12311 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12312 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12124 12313 | RestJson<L>,
|
12125 12314 | crate::operation_shape::OperationWithDefaults,
|
12126 12315 | ModelPl::Output
|
12127 12316 | >
|
12128 12317 | >::Output
|
12129 12318 | >,
|
12130 12319 |
|
12131 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12320 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12132 12321 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12133 12322 |
|
12134 12323 | {
|
12135 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12136 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12324 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12325 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12137 12326 | let svc = crate::operation_shape::OperationWithDefaults::from_service(service);
|
12138 12327 | let svc = self.model_plugin.apply(svc);
|
12139 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12328 + | let svc =
|
12329 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12140 12330 | .apply(svc);
|
12141 12331 | let svc = self.http_plugin.apply(svc);
|
12142 12332 | self.operation_with_defaults_custom(svc)
|
12143 12333 | }
|
12144 12334 |
|
12145 12335 | /// Sets the [`OperationWithDefaults`](crate::operation_shape::OperationWithDefaults) to a custom [`Service`](tower::Service).
|
12146 12336 | /// not constrained by the Smithy contract.
|
12147 12337 | fn operation_with_defaults_custom<S>(mut self, svc: S) -> Self
|
12148 12338 | where
|
12149 12339 | S: ::tower::Service<
|
12150 12340 | ::http::Request<Body>,
|
12151 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12341 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12152 12342 | Error = ::std::convert::Infallible,
|
12153 12343 | > + Clone
|
12154 12344 | + Send
|
12155 12345 | + 'static,
|
12156 12346 | S::Future: Send + 'static,
|
12157 12347 | {
|
12158 - | self.operation_with_defaults = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12348 + | self.operation_with_defaults =
|
12349 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12159 12350 | self
|
12160 12351 | }
|
12161 12352 |
|
12162 12353 | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
12163 12354 | ///
|
12164 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12165 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12355 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12356 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12166 12357 | ///
|
12167 12358 | /// # Example
|
12168 12359 | ///
|
12169 12360 | /// ```no_run
|
12170 12361 | /// use rest_json::{RestJson, RestJsonConfig};
|
12171 12362 | ///
|
12172 12363 | /// use rest_json::{input, output, error};
|
12173 12364 | ///
|
12174 12365 | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
12175 12366 | /// todo!()
|
12176 12367 | /// }
|
12177 12368 | ///
|
12178 12369 | /// let config = RestJsonConfig::builder().build();
|
12179 12370 | /// let app = RestJson::builder(config)
|
12180 12371 | /// .operation_with_nested_structure(handler)
|
12181 12372 | /// /* Set other handlers */
|
12182 12373 | /// .build()
|
12183 12374 | /// .unwrap();
|
12184 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12375 + | /// # 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;
|
12185 12376 | /// ```
|
12186 12377 | ///
|
12187 12378 | pub fn operation_with_nested_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12188 12379 | where
|
12189 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::OperationWithNestedStructure, HandlerExtractors>,
|
12380 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::OperationWithNestedStructure, HandlerExtractors>,
|
12190 12381 |
|
12191 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12382 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12192 12383 | RestJson<L>,
|
12193 12384 | crate::operation_shape::OperationWithNestedStructure,
|
12194 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::OperationWithNestedStructure, HandlerType>
|
12385 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::OperationWithNestedStructure, HandlerType>
|
12195 12386 | >,
|
12196 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12387 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12197 12388 | RestJson<L>,
|
12198 12389 | crate::operation_shape::OperationWithNestedStructure,
|
12199 12390 | ModelPl::Output
|
12200 12391 | >,
|
12201 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12392 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12202 12393 | RestJson<L>,
|
12203 12394 | crate::operation_shape::OperationWithNestedStructure,
|
12204 12395 | <
|
12205 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12206 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12396 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12397 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12207 12398 | RestJson<L>,
|
12208 12399 | crate::operation_shape::OperationWithNestedStructure,
|
12209 12400 | ModelPl::Output
|
12210 12401 | >
|
12211 12402 | >::Output
|
12212 12403 | >,
|
12213 12404 |
|
12214 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12405 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12215 12406 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12216 12407 |
|
12217 12408 | {
|
12218 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12219 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12409 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12410 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12220 12411 | let svc = crate::operation_shape::OperationWithNestedStructure::from_handler(handler);
|
12221 12412 | let svc = self.model_plugin.apply(svc);
|
12222 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12413 + | let svc =
|
12414 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12223 12415 | .apply(svc);
|
12224 12416 | let svc = self.http_plugin.apply(svc);
|
12225 12417 | self.operation_with_nested_structure_custom(svc)
|
12226 12418 | }
|
12227 12419 |
|
12228 12420 | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) operation.
|
12229 12421 | ///
|
12230 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12231 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12422 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12423 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12232 12424 | ///
|
12233 12425 | /// # Example
|
12234 12426 | ///
|
12235 12427 | /// ```no_run
|
12236 12428 | /// use rest_json::{RestJson, RestJsonConfig};
|
12237 12429 | ///
|
12238 12430 | /// use rest_json::{input, output, error};
|
12239 12431 | ///
|
12240 12432 | /// async fn handler(input: input::OperationWithNestedStructureInput) -> Result<output::OperationWithNestedStructureOutput, error::OperationWithNestedStructureError> {
|
12241 12433 | /// todo!()
|
12242 12434 | /// }
|
12243 12435 | ///
|
12244 12436 | /// let config = RestJsonConfig::builder().build();
|
12245 12437 | /// let svc = ::tower::util::service_fn(handler);
|
12246 12438 | /// let app = RestJson::builder(config)
|
12247 12439 | /// .operation_with_nested_structure_service(svc)
|
12248 12440 | /// /* Set other handlers */
|
12249 12441 | /// .build()
|
12250 12442 | /// .unwrap();
|
12251 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12443 + | /// # 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;
|
12252 12444 | /// ```
|
12253 12445 | ///
|
12254 12446 | pub fn operation_with_nested_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12255 12447 | where
|
12256 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::OperationWithNestedStructure, ServiceExtractors>,
|
12448 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::OperationWithNestedStructure, ServiceExtractors>,
|
12257 12449 |
|
12258 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12450 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12259 12451 | RestJson<L>,
|
12260 12452 | crate::operation_shape::OperationWithNestedStructure,
|
12261 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::OperationWithNestedStructure, S>
|
12453 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::OperationWithNestedStructure, S>
|
12262 12454 | >,
|
12263 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12455 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12264 12456 | RestJson<L>,
|
12265 12457 | crate::operation_shape::OperationWithNestedStructure,
|
12266 12458 | ModelPl::Output
|
12267 12459 | >,
|
12268 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12460 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12269 12461 | RestJson<L>,
|
12270 12462 | crate::operation_shape::OperationWithNestedStructure,
|
12271 12463 | <
|
12272 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12273 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12464 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12465 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12274 12466 | RestJson<L>,
|
12275 12467 | crate::operation_shape::OperationWithNestedStructure,
|
12276 12468 | ModelPl::Output
|
12277 12469 | >
|
12278 12470 | >::Output
|
12279 12471 | >,
|
12280 12472 |
|
12281 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12473 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12282 12474 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12283 12475 |
|
12284 12476 | {
|
12285 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12286 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12477 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12478 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12287 12479 | let svc = crate::operation_shape::OperationWithNestedStructure::from_service(service);
|
12288 12480 | let svc = self.model_plugin.apply(svc);
|
12289 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12481 + | let svc =
|
12482 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12290 12483 | .apply(svc);
|
12291 12484 | let svc = self.http_plugin.apply(svc);
|
12292 12485 | self.operation_with_nested_structure_custom(svc)
|
12293 12486 | }
|
12294 12487 |
|
12295 12488 | /// Sets the [`OperationWithNestedStructure`](crate::operation_shape::OperationWithNestedStructure) to a custom [`Service`](tower::Service).
|
12296 12489 | /// not constrained by the Smithy contract.
|
12297 12490 | fn operation_with_nested_structure_custom<S>(mut self, svc: S) -> Self
|
12298 12491 | where
|
12299 12492 | S: ::tower::Service<
|
12300 12493 | ::http::Request<Body>,
|
12301 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12494 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12302 12495 | Error = ::std::convert::Infallible,
|
12303 12496 | > + Clone
|
12304 12497 | + Send
|
12305 12498 | + 'static,
|
12306 12499 | S::Future: Send + 'static,
|
12307 12500 | {
|
12308 12501 | self.operation_with_nested_structure =
|
12309 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12502 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12310 12503 | self
|
12311 12504 | }
|
12312 12505 |
|
12313 12506 | /// Sets the [`PostPlayerAction`](crate::operation_shape::PostPlayerAction) operation.
|
12314 12507 | ///
|
12315 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12316 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12508 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12509 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12317 12510 | ///
|
12318 12511 | /// # Example
|
12319 12512 | ///
|
12320 12513 | /// ```no_run
|
12321 12514 | /// use rest_json::{RestJson, RestJsonConfig};
|
12322 12515 | ///
|
12323 12516 | /// use rest_json::{input, output, error};
|
12324 12517 | ///
|
12325 12518 | /// async fn handler(input: input::PostPlayerActionInput) -> Result<output::PostPlayerActionOutput, error::PostPlayerActionError> {
|
12326 12519 | /// todo!()
|
12327 12520 | /// }
|
12328 12521 | ///
|
12329 12522 | /// let config = RestJsonConfig::builder().build();
|
12330 12523 | /// let app = RestJson::builder(config)
|
12331 12524 | /// .post_player_action(handler)
|
12332 12525 | /// /* Set other handlers */
|
12333 12526 | /// .build()
|
12334 12527 | /// .unwrap();
|
12335 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12528 + | /// # 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;
|
12336 12529 | /// ```
|
12337 12530 | ///
|
12338 12531 | pub fn post_player_action<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12339 12532 | where
|
12340 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::PostPlayerAction, HandlerExtractors>,
|
12533 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::PostPlayerAction, HandlerExtractors>,
|
12341 12534 |
|
12342 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12535 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12343 12536 | RestJson<L>,
|
12344 12537 | crate::operation_shape::PostPlayerAction,
|
12345 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::PostPlayerAction, HandlerType>
|
12538 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::PostPlayerAction, HandlerType>
|
12346 12539 | >,
|
12347 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12540 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12348 12541 | RestJson<L>,
|
12349 12542 | crate::operation_shape::PostPlayerAction,
|
12350 12543 | ModelPl::Output
|
12351 12544 | >,
|
12352 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12545 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12353 12546 | RestJson<L>,
|
12354 12547 | crate::operation_shape::PostPlayerAction,
|
12355 12548 | <
|
12356 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12357 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12549 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12550 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12358 12551 | RestJson<L>,
|
12359 12552 | crate::operation_shape::PostPlayerAction,
|
12360 12553 | ModelPl::Output
|
12361 12554 | >
|
12362 12555 | >::Output
|
12363 12556 | >,
|
12364 12557 |
|
12365 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12558 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12366 12559 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12367 12560 |
|
12368 12561 | {
|
12369 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12370 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12562 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12563 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12371 12564 | let svc = crate::operation_shape::PostPlayerAction::from_handler(handler);
|
12372 12565 | let svc = self.model_plugin.apply(svc);
|
12373 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12566 + | let svc =
|
12567 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12374 12568 | .apply(svc);
|
12375 12569 | let svc = self.http_plugin.apply(svc);
|
12376 12570 | self.post_player_action_custom(svc)
|
12377 12571 | }
|
12378 12572 |
|
12379 12573 | /// Sets the [`PostPlayerAction`](crate::operation_shape::PostPlayerAction) operation.
|
12380 12574 | ///
|
12381 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12382 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12575 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12576 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12383 12577 | ///
|
12384 12578 | /// # Example
|
12385 12579 | ///
|
12386 12580 | /// ```no_run
|
12387 12581 | /// use rest_json::{RestJson, RestJsonConfig};
|
12388 12582 | ///
|
12389 12583 | /// use rest_json::{input, output, error};
|
12390 12584 | ///
|
12391 12585 | /// async fn handler(input: input::PostPlayerActionInput) -> Result<output::PostPlayerActionOutput, error::PostPlayerActionError> {
|
12392 12586 | /// todo!()
|
12393 12587 | /// }
|
12394 12588 | ///
|
12395 12589 | /// let config = RestJsonConfig::builder().build();
|
12396 12590 | /// let svc = ::tower::util::service_fn(handler);
|
12397 12591 | /// let app = RestJson::builder(config)
|
12398 12592 | /// .post_player_action_service(svc)
|
12399 12593 | /// /* Set other handlers */
|
12400 12594 | /// .build()
|
12401 12595 | /// .unwrap();
|
12402 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12596 + | /// # 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;
|
12403 12597 | /// ```
|
12404 12598 | ///
|
12405 12599 | pub fn post_player_action_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12406 12600 | where
|
12407 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::PostPlayerAction, ServiceExtractors>,
|
12601 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::PostPlayerAction, ServiceExtractors>,
|
12408 12602 |
|
12409 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12603 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12410 12604 | RestJson<L>,
|
12411 12605 | crate::operation_shape::PostPlayerAction,
|
12412 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::PostPlayerAction, S>
|
12606 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::PostPlayerAction, S>
|
12413 12607 | >,
|
12414 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12608 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12415 12609 | RestJson<L>,
|
12416 12610 | crate::operation_shape::PostPlayerAction,
|
12417 12611 | ModelPl::Output
|
12418 12612 | >,
|
12419 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12613 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12420 12614 | RestJson<L>,
|
12421 12615 | crate::operation_shape::PostPlayerAction,
|
12422 12616 | <
|
12423 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12424 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12617 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12618 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12425 12619 | RestJson<L>,
|
12426 12620 | crate::operation_shape::PostPlayerAction,
|
12427 12621 | ModelPl::Output
|
12428 12622 | >
|
12429 12623 | >::Output
|
12430 12624 | >,
|
12431 12625 |
|
12432 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12626 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12433 12627 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12434 12628 |
|
12435 12629 | {
|
12436 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12437 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12630 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12631 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12438 12632 | let svc = crate::operation_shape::PostPlayerAction::from_service(service);
|
12439 12633 | let svc = self.model_plugin.apply(svc);
|
12440 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12634 + | let svc =
|
12635 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12441 12636 | .apply(svc);
|
12442 12637 | let svc = self.http_plugin.apply(svc);
|
12443 12638 | self.post_player_action_custom(svc)
|
12444 12639 | }
|
12445 12640 |
|
12446 12641 | /// Sets the [`PostPlayerAction`](crate::operation_shape::PostPlayerAction) to a custom [`Service`](tower::Service).
|
12447 12642 | /// not constrained by the Smithy contract.
|
12448 12643 | fn post_player_action_custom<S>(mut self, svc: S) -> Self
|
12449 12644 | where
|
12450 12645 | S: ::tower::Service<
|
12451 12646 | ::http::Request<Body>,
|
12452 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12647 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12453 12648 | Error = ::std::convert::Infallible,
|
12454 12649 | > + Clone
|
12455 12650 | + Send
|
12456 12651 | + 'static,
|
12457 12652 | S::Future: Send + 'static,
|
12458 12653 | {
|
12459 - | self.post_player_action = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12654 + | self.post_player_action = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12460 12655 | self
|
12461 12656 | }
|
12462 12657 |
|
12463 12658 | /// Sets the [`PostUnionWithJsonName`](crate::operation_shape::PostUnionWithJsonName) operation.
|
12464 12659 | ///
|
12465 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12466 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12660 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12661 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12467 12662 | ///
|
12468 12663 | /// # Example
|
12469 12664 | ///
|
12470 12665 | /// ```no_run
|
12471 12666 | /// use rest_json::{RestJson, RestJsonConfig};
|
12472 12667 | ///
|
12473 12668 | /// use rest_json::{input, output, error};
|
12474 12669 | ///
|
12475 12670 | /// async fn handler(input: input::PostUnionWithJsonNameInput) -> Result<output::PostUnionWithJsonNameOutput, error::PostUnionWithJsonNameError> {
|
12476 12671 | /// todo!()
|
12477 12672 | /// }
|
12478 12673 | ///
|
12479 12674 | /// let config = RestJsonConfig::builder().build();
|
12480 12675 | /// let app = RestJson::builder(config)
|
12481 12676 | /// .post_union_with_json_name(handler)
|
12482 12677 | /// /* Set other handlers */
|
12483 12678 | /// .build()
|
12484 12679 | /// .unwrap();
|
12485 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12680 + | /// # 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;
|
12486 12681 | /// ```
|
12487 12682 | ///
|
12488 12683 | pub fn post_union_with_json_name<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12489 12684 | where
|
12490 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::PostUnionWithJsonName, HandlerExtractors>,
|
12685 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::PostUnionWithJsonName, HandlerExtractors>,
|
12491 12686 |
|
12492 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12687 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12493 12688 | RestJson<L>,
|
12494 12689 | crate::operation_shape::PostUnionWithJsonName,
|
12495 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::PostUnionWithJsonName, HandlerType>
|
12690 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::PostUnionWithJsonName, HandlerType>
|
12496 12691 | >,
|
12497 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12692 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12498 12693 | RestJson<L>,
|
12499 12694 | crate::operation_shape::PostUnionWithJsonName,
|
12500 12695 | ModelPl::Output
|
12501 12696 | >,
|
12502 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12697 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12503 12698 | RestJson<L>,
|
12504 12699 | crate::operation_shape::PostUnionWithJsonName,
|
12505 12700 | <
|
12506 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12507 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12701 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12702 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12508 12703 | RestJson<L>,
|
12509 12704 | crate::operation_shape::PostUnionWithJsonName,
|
12510 12705 | ModelPl::Output
|
12511 12706 | >
|
12512 12707 | >::Output
|
12513 12708 | >,
|
12514 12709 |
|
12515 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12710 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12516 12711 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12517 12712 |
|
12518 12713 | {
|
12519 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12520 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12714 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12715 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12521 12716 | let svc = crate::operation_shape::PostUnionWithJsonName::from_handler(handler);
|
12522 12717 | let svc = self.model_plugin.apply(svc);
|
12523 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12718 + | let svc =
|
12719 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12524 12720 | .apply(svc);
|
12525 12721 | let svc = self.http_plugin.apply(svc);
|
12526 12722 | self.post_union_with_json_name_custom(svc)
|
12527 12723 | }
|
12528 12724 |
|
12529 12725 | /// Sets the [`PostUnionWithJsonName`](crate::operation_shape::PostUnionWithJsonName) operation.
|
12530 12726 | ///
|
12531 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12532 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12727 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12728 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12533 12729 | ///
|
12534 12730 | /// # Example
|
12535 12731 | ///
|
12536 12732 | /// ```no_run
|
12537 12733 | /// use rest_json::{RestJson, RestJsonConfig};
|
12538 12734 | ///
|
12539 12735 | /// use rest_json::{input, output, error};
|
12540 12736 | ///
|
12541 12737 | /// async fn handler(input: input::PostUnionWithJsonNameInput) -> Result<output::PostUnionWithJsonNameOutput, error::PostUnionWithJsonNameError> {
|
12542 12738 | /// todo!()
|
12543 12739 | /// }
|
12544 12740 | ///
|
12545 12741 | /// let config = RestJsonConfig::builder().build();
|
12546 12742 | /// let svc = ::tower::util::service_fn(handler);
|
12547 12743 | /// let app = RestJson::builder(config)
|
12548 12744 | /// .post_union_with_json_name_service(svc)
|
12549 12745 | /// /* Set other handlers */
|
12550 12746 | /// .build()
|
12551 12747 | /// .unwrap();
|
12552 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12748 + | /// # 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;
|
12553 12749 | /// ```
|
12554 12750 | ///
|
12555 12751 | pub fn post_union_with_json_name_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12556 12752 | where
|
12557 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::PostUnionWithJsonName, ServiceExtractors>,
|
12753 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::PostUnionWithJsonName, ServiceExtractors>,
|
12558 12754 |
|
12559 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12755 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12560 12756 | RestJson<L>,
|
12561 12757 | crate::operation_shape::PostUnionWithJsonName,
|
12562 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::PostUnionWithJsonName, S>
|
12758 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::PostUnionWithJsonName, S>
|
12563 12759 | >,
|
12564 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12760 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12565 12761 | RestJson<L>,
|
12566 12762 | crate::operation_shape::PostUnionWithJsonName,
|
12567 12763 | ModelPl::Output
|
12568 12764 | >,
|
12569 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12765 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12570 12766 | RestJson<L>,
|
12571 12767 | crate::operation_shape::PostUnionWithJsonName,
|
12572 12768 | <
|
12573 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12574 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12769 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12770 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12575 12771 | RestJson<L>,
|
12576 12772 | crate::operation_shape::PostUnionWithJsonName,
|
12577 12773 | ModelPl::Output
|
12578 12774 | >
|
12579 12775 | >::Output
|
12580 12776 | >,
|
12581 12777 |
|
12582 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12778 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12583 12779 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12584 12780 |
|
12585 12781 | {
|
12586 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12587 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12782 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12783 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12588 12784 | let svc = crate::operation_shape::PostUnionWithJsonName::from_service(service);
|
12589 12785 | let svc = self.model_plugin.apply(svc);
|
12590 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12786 + | let svc =
|
12787 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12591 12788 | .apply(svc);
|
12592 12789 | let svc = self.http_plugin.apply(svc);
|
12593 12790 | self.post_union_with_json_name_custom(svc)
|
12594 12791 | }
|
12595 12792 |
|
12596 12793 | /// Sets the [`PostUnionWithJsonName`](crate::operation_shape::PostUnionWithJsonName) to a custom [`Service`](tower::Service).
|
12597 12794 | /// not constrained by the Smithy contract.
|
12598 12795 | fn post_union_with_json_name_custom<S>(mut self, svc: S) -> Self
|
12599 12796 | where
|
12600 12797 | S: ::tower::Service<
|
12601 12798 | ::http::Request<Body>,
|
12602 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12799 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12603 12800 | Error = ::std::convert::Infallible,
|
12604 12801 | > + Clone
|
12605 12802 | + Send
|
12606 12803 | + 'static,
|
12607 12804 | S::Future: Send + 'static,
|
12608 12805 | {
|
12609 - | self.post_union_with_json_name = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12806 + | self.post_union_with_json_name =
|
12807 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12610 12808 | self
|
12611 12809 | }
|
12612 12810 |
|
12613 12811 | /// Sets the [`PutWithContentEncoding`](crate::operation_shape::PutWithContentEncoding) operation.
|
12614 12812 | ///
|
12615 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12616 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12813 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12814 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12617 12815 | ///
|
12618 12816 | /// # Example
|
12619 12817 | ///
|
12620 12818 | /// ```no_run
|
12621 12819 | /// use rest_json::{RestJson, RestJsonConfig};
|
12622 12820 | ///
|
12623 12821 | /// use rest_json::{input, output, error};
|
12624 12822 | ///
|
12625 12823 | /// async fn handler(input: input::PutWithContentEncodingInput) -> Result<output::PutWithContentEncodingOutput, error::PutWithContentEncodingError> {
|
12626 12824 | /// todo!()
|
12627 12825 | /// }
|
12628 12826 | ///
|
12629 12827 | /// let config = RestJsonConfig::builder().build();
|
12630 12828 | /// let app = RestJson::builder(config)
|
12631 12829 | /// .put_with_content_encoding(handler)
|
12632 12830 | /// /* Set other handlers */
|
12633 12831 | /// .build()
|
12634 12832 | /// .unwrap();
|
12635 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12833 + | /// # 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;
|
12636 12834 | /// ```
|
12637 12835 | ///
|
12638 12836 | pub fn put_with_content_encoding<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12639 12837 | where
|
12640 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::PutWithContentEncoding, HandlerExtractors>,
|
12838 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::PutWithContentEncoding, HandlerExtractors>,
|
12641 12839 |
|
12642 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12840 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12643 12841 | RestJson<L>,
|
12644 12842 | crate::operation_shape::PutWithContentEncoding,
|
12645 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::PutWithContentEncoding, HandlerType>
|
12843 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::PutWithContentEncoding, HandlerType>
|
12646 12844 | >,
|
12647 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12845 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12648 12846 | RestJson<L>,
|
12649 12847 | crate::operation_shape::PutWithContentEncoding,
|
12650 12848 | ModelPl::Output
|
12651 12849 | >,
|
12652 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12850 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12653 12851 | RestJson<L>,
|
12654 12852 | crate::operation_shape::PutWithContentEncoding,
|
12655 12853 | <
|
12656 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12657 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12854 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12855 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12658 12856 | RestJson<L>,
|
12659 12857 | crate::operation_shape::PutWithContentEncoding,
|
12660 12858 | ModelPl::Output
|
12661 12859 | >
|
12662 12860 | >::Output
|
12663 12861 | >,
|
12664 12862 |
|
12665 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12863 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12666 12864 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12667 12865 |
|
12668 12866 | {
|
12669 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12670 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12867 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12868 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12671 12869 | let svc = crate::operation_shape::PutWithContentEncoding::from_handler(handler);
|
12672 12870 | let svc = self.model_plugin.apply(svc);
|
12673 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12871 + | let svc =
|
12872 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12674 12873 | .apply(svc);
|
12675 12874 | let svc = self.http_plugin.apply(svc);
|
12676 12875 | self.put_with_content_encoding_custom(svc)
|
12677 12876 | }
|
12678 12877 |
|
12679 12878 | /// Sets the [`PutWithContentEncoding`](crate::operation_shape::PutWithContentEncoding) operation.
|
12680 12879 | ///
|
12681 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12682 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12880 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12881 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12683 12882 | ///
|
12684 12883 | /// # Example
|
12685 12884 | ///
|
12686 12885 | /// ```no_run
|
12687 12886 | /// use rest_json::{RestJson, RestJsonConfig};
|
12688 12887 | ///
|
12689 12888 | /// use rest_json::{input, output, error};
|
12690 12889 | ///
|
12691 12890 | /// async fn handler(input: input::PutWithContentEncodingInput) -> Result<output::PutWithContentEncodingOutput, error::PutWithContentEncodingError> {
|
12692 12891 | /// todo!()
|
12693 12892 | /// }
|
12694 12893 | ///
|
12695 12894 | /// let config = RestJsonConfig::builder().build();
|
12696 12895 | /// let svc = ::tower::util::service_fn(handler);
|
12697 12896 | /// let app = RestJson::builder(config)
|
12698 12897 | /// .put_with_content_encoding_service(svc)
|
12699 12898 | /// /* Set other handlers */
|
12700 12899 | /// .build()
|
12701 12900 | /// .unwrap();
|
12702 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12901 + | /// # 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;
|
12703 12902 | /// ```
|
12704 12903 | ///
|
12705 12904 | pub fn put_with_content_encoding_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12706 12905 | where
|
12707 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::PutWithContentEncoding, ServiceExtractors>,
|
12906 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::PutWithContentEncoding, ServiceExtractors>,
|
12708 12907 |
|
12709 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12908 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12710 12909 | RestJson<L>,
|
12711 12910 | crate::operation_shape::PutWithContentEncoding,
|
12712 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::PutWithContentEncoding, S>
|
12911 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::PutWithContentEncoding, S>
|
12713 12912 | >,
|
12714 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12913 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12715 12914 | RestJson<L>,
|
12716 12915 | crate::operation_shape::PutWithContentEncoding,
|
12717 12916 | ModelPl::Output
|
12718 12917 | >,
|
12719 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
12918 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12720 12919 | RestJson<L>,
|
12721 12920 | crate::operation_shape::PutWithContentEncoding,
|
12722 12921 | <
|
12723 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12724 - | as ::aws_smithy_http_server::plugin::Plugin<
|
12922 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12923 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12725 12924 | RestJson<L>,
|
12726 12925 | crate::operation_shape::PutWithContentEncoding,
|
12727 12926 | ModelPl::Output
|
12728 12927 | >
|
12729 12928 | >::Output
|
12730 12929 | >,
|
12731 12930 |
|
12732 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12931 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12733 12932 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12734 12933 |
|
12735 12934 | {
|
12736 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12737 - | use ::aws_smithy_http_server::plugin::Plugin;
|
12935 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
12936 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12738 12937 | let svc = crate::operation_shape::PutWithContentEncoding::from_service(service);
|
12739 12938 | let svc = self.model_plugin.apply(svc);
|
12740 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12939 + | let svc =
|
12940 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12741 12941 | .apply(svc);
|
12742 12942 | let svc = self.http_plugin.apply(svc);
|
12743 12943 | self.put_with_content_encoding_custom(svc)
|
12744 12944 | }
|
12745 12945 |
|
12746 12946 | /// Sets the [`PutWithContentEncoding`](crate::operation_shape::PutWithContentEncoding) to a custom [`Service`](tower::Service).
|
12747 12947 | /// not constrained by the Smithy contract.
|
12748 12948 | fn put_with_content_encoding_custom<S>(mut self, svc: S) -> Self
|
12749 12949 | where
|
12750 12950 | S: ::tower::Service<
|
12751 12951 | ::http::Request<Body>,
|
12752 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
12952 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12753 12953 | Error = ::std::convert::Infallible,
|
12754 12954 | > + Clone
|
12755 12955 | + Send
|
12756 12956 | + 'static,
|
12757 12957 | S::Future: Send + 'static,
|
12758 12958 | {
|
12759 - | self.put_with_content_encoding = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
12959 + | self.put_with_content_encoding =
|
12960 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12760 12961 | self
|
12761 12962 | }
|
12762 12963 |
|
12763 12964 | /// Sets the [`QueryIdempotencyTokenAutoFill`](crate::operation_shape::QueryIdempotencyTokenAutoFill) operation.
|
12764 12965 | ///
|
12765 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12766 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
12966 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
12967 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12767 12968 | ///
|
12768 12969 | /// # Example
|
12769 12970 | ///
|
12770 12971 | /// ```no_run
|
12771 12972 | /// use rest_json::{RestJson, RestJsonConfig};
|
12772 12973 | ///
|
12773 12974 | /// use rest_json::{input, output, error};
|
12774 12975 | ///
|
12775 12976 | /// async fn handler(input: input::QueryIdempotencyTokenAutoFillInput) -> Result<output::QueryIdempotencyTokenAutoFillOutput, error::QueryIdempotencyTokenAutoFillError> {
|
12776 12977 | /// todo!()
|
12777 12978 | /// }
|
12778 12979 | ///
|
12779 12980 | /// let config = RestJsonConfig::builder().build();
|
12780 12981 | /// let app = RestJson::builder(config)
|
12781 12982 | /// .query_idempotency_token_auto_fill(handler)
|
12782 12983 | /// /* Set other handlers */
|
12783 12984 | /// .build()
|
12784 12985 | /// .unwrap();
|
12785 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
12986 + | /// # 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;
|
12786 12987 | /// ```
|
12787 12988 | ///
|
12788 12989 | pub fn query_idempotency_token_auto_fill<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12789 12990 | where
|
12790 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::QueryIdempotencyTokenAutoFill, HandlerExtractors>,
|
12991 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::QueryIdempotencyTokenAutoFill, HandlerExtractors>,
|
12791 12992 |
|
12792 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
12993 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12793 12994 | RestJson<L>,
|
12794 12995 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12795 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::QueryIdempotencyTokenAutoFill, HandlerType>
|
12996 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::QueryIdempotencyTokenAutoFill, HandlerType>
|
12796 12997 | >,
|
12797 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
12998 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12798 12999 | RestJson<L>,
|
12799 13000 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12800 13001 | ModelPl::Output
|
12801 13002 | >,
|
12802 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13003 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12803 13004 | RestJson<L>,
|
12804 13005 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12805 13006 | <
|
12806 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12807 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13007 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13008 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12808 13009 | RestJson<L>,
|
12809 13010 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12810 13011 | ModelPl::Output
|
12811 13012 | >
|
12812 13013 | >::Output
|
12813 13014 | >,
|
12814 13015 |
|
12815 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13016 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12816 13017 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12817 13018 |
|
12818 13019 | {
|
12819 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12820 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13020 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13021 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12821 13022 | let svc = crate::operation_shape::QueryIdempotencyTokenAutoFill::from_handler(handler);
|
12822 13023 | let svc = self.model_plugin.apply(svc);
|
12823 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13024 + | let svc =
|
13025 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12824 13026 | .apply(svc);
|
12825 13027 | let svc = self.http_plugin.apply(svc);
|
12826 13028 | self.query_idempotency_token_auto_fill_custom(svc)
|
12827 13029 | }
|
12828 13030 |
|
12829 13031 | /// Sets the [`QueryIdempotencyTokenAutoFill`](crate::operation_shape::QueryIdempotencyTokenAutoFill) operation.
|
12830 13032 | ///
|
12831 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12832 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13033 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13034 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12833 13035 | ///
|
12834 13036 | /// # Example
|
12835 13037 | ///
|
12836 13038 | /// ```no_run
|
12837 13039 | /// use rest_json::{RestJson, RestJsonConfig};
|
12838 13040 | ///
|
12839 13041 | /// use rest_json::{input, output, error};
|
12840 13042 | ///
|
12841 13043 | /// async fn handler(input: input::QueryIdempotencyTokenAutoFillInput) -> Result<output::QueryIdempotencyTokenAutoFillOutput, error::QueryIdempotencyTokenAutoFillError> {
|
12842 13044 | /// todo!()
|
12843 13045 | /// }
|
12844 13046 | ///
|
12845 13047 | /// let config = RestJsonConfig::builder().build();
|
12846 13048 | /// let svc = ::tower::util::service_fn(handler);
|
12847 13049 | /// let app = RestJson::builder(config)
|
12848 13050 | /// .query_idempotency_token_auto_fill_service(svc)
|
12849 13051 | /// /* Set other handlers */
|
12850 13052 | /// .build()
|
12851 13053 | /// .unwrap();
|
12852 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13054 + | /// # 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;
|
12853 13055 | /// ```
|
12854 13056 | ///
|
12855 13057 | pub fn query_idempotency_token_auto_fill_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
12856 13058 | where
|
12857 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::QueryIdempotencyTokenAutoFill, ServiceExtractors>,
|
13059 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::QueryIdempotencyTokenAutoFill, ServiceExtractors>,
|
12858 13060 |
|
12859 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13061 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12860 13062 | RestJson<L>,
|
12861 13063 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12862 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::QueryIdempotencyTokenAutoFill, S>
|
13064 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::QueryIdempotencyTokenAutoFill, S>
|
12863 13065 | >,
|
12864 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13066 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12865 13067 | RestJson<L>,
|
12866 13068 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12867 13069 | ModelPl::Output
|
12868 13070 | >,
|
12869 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13071 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12870 13072 | RestJson<L>,
|
12871 13073 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12872 13074 | <
|
12873 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12874 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13075 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13076 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12875 13077 | RestJson<L>,
|
12876 13078 | crate::operation_shape::QueryIdempotencyTokenAutoFill,
|
12877 13079 | ModelPl::Output
|
12878 13080 | >
|
12879 13081 | >::Output
|
12880 13082 | >,
|
12881 13083 |
|
12882 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13084 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12883 13085 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12884 13086 |
|
12885 13087 | {
|
12886 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12887 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13088 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13089 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12888 13090 | let svc = crate::operation_shape::QueryIdempotencyTokenAutoFill::from_service(service);
|
12889 13091 | let svc = self.model_plugin.apply(svc);
|
12890 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13092 + | let svc =
|
13093 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12891 13094 | .apply(svc);
|
12892 13095 | let svc = self.http_plugin.apply(svc);
|
12893 13096 | self.query_idempotency_token_auto_fill_custom(svc)
|
12894 13097 | }
|
12895 13098 |
|
12896 13099 | /// Sets the [`QueryIdempotencyTokenAutoFill`](crate::operation_shape::QueryIdempotencyTokenAutoFill) to a custom [`Service`](tower::Service).
|
12897 13100 | /// not constrained by the Smithy contract.
|
12898 13101 | fn query_idempotency_token_auto_fill_custom<S>(mut self, svc: S) -> Self
|
12899 13102 | where
|
12900 13103 | S: ::tower::Service<
|
12901 13104 | ::http::Request<Body>,
|
12902 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13105 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
12903 13106 | Error = ::std::convert::Infallible,
|
12904 13107 | > + Clone
|
12905 13108 | + Send
|
12906 13109 | + 'static,
|
12907 13110 | S::Future: Send + 'static,
|
12908 13111 | {
|
12909 13112 | self.query_idempotency_token_auto_fill =
|
12910 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13113 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
12911 13114 | self
|
12912 13115 | }
|
12913 13116 |
|
12914 13117 | /// Sets the [`QueryParamsAsStringListMap`](crate::operation_shape::QueryParamsAsStringListMap) operation.
|
12915 13118 | ///
|
12916 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12917 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13119 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13120 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12918 13121 | ///
|
12919 13122 | /// # Example
|
12920 13123 | ///
|
12921 13124 | /// ```no_run
|
12922 13125 | /// use rest_json::{RestJson, RestJsonConfig};
|
12923 13126 | ///
|
12924 13127 | /// use rest_json::{input, output, error};
|
12925 13128 | ///
|
12926 13129 | /// async fn handler(input: input::QueryParamsAsStringListMapInput) -> Result<output::QueryParamsAsStringListMapOutput, error::QueryParamsAsStringListMapError> {
|
12927 13130 | /// todo!()
|
12928 13131 | /// }
|
12929 13132 | ///
|
12930 13133 | /// let config = RestJsonConfig::builder().build();
|
12931 13134 | /// let app = RestJson::builder(config)
|
12932 13135 | /// .query_params_as_string_list_map(handler)
|
12933 13136 | /// /* Set other handlers */
|
12934 13137 | /// .build()
|
12935 13138 | /// .unwrap();
|
12936 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13139 + | /// # 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;
|
12937 13140 | /// ```
|
12938 13141 | ///
|
12939 13142 | pub fn query_params_as_string_list_map<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
12940 13143 | where
|
12941 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::QueryParamsAsStringListMap, HandlerExtractors>,
|
13144 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::QueryParamsAsStringListMap, HandlerExtractors>,
|
12942 13145 |
|
12943 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13146 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12944 13147 | RestJson<L>,
|
12945 13148 | crate::operation_shape::QueryParamsAsStringListMap,
|
12946 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::QueryParamsAsStringListMap, HandlerType>
|
13149 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::QueryParamsAsStringListMap, HandlerType>
|
12947 13150 | >,
|
12948 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13151 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12949 13152 | RestJson<L>,
|
12950 13153 | crate::operation_shape::QueryParamsAsStringListMap,
|
12951 13154 | ModelPl::Output
|
12952 13155 | >,
|
12953 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13156 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12954 13157 | RestJson<L>,
|
12955 13158 | crate::operation_shape::QueryParamsAsStringListMap,
|
12956 13159 | <
|
12957 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
12958 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13160 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13161 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
12959 13162 | RestJson<L>,
|
12960 13163 | crate::operation_shape::QueryParamsAsStringListMap,
|
12961 13164 | ModelPl::Output
|
12962 13165 | >
|
12963 13166 | >::Output
|
12964 13167 | >,
|
12965 13168 |
|
12966 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13169 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
12967 13170 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
12968 13171 |
|
12969 13172 | {
|
12970 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
12971 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13173 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13174 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
12972 13175 | let svc = crate::operation_shape::QueryParamsAsStringListMap::from_handler(handler);
|
12973 13176 | let svc = self.model_plugin.apply(svc);
|
12974 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13177 + | let svc =
|
13178 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
12975 13179 | .apply(svc);
|
12976 13180 | let svc = self.http_plugin.apply(svc);
|
12977 13181 | self.query_params_as_string_list_map_custom(svc)
|
12978 13182 | }
|
12979 13183 |
|
12980 13184 | /// Sets the [`QueryParamsAsStringListMap`](crate::operation_shape::QueryParamsAsStringListMap) operation.
|
12981 13185 | ///
|
12982 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
12983 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13186 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13187 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
12984 13188 | ///
|
12985 13189 | /// # Example
|
12986 13190 | ///
|
12987 13191 | /// ```no_run
|
12988 13192 | /// use rest_json::{RestJson, RestJsonConfig};
|
12989 13193 | ///
|
12990 13194 | /// use rest_json::{input, output, error};
|
12991 13195 | ///
|
12992 13196 | /// async fn handler(input: input::QueryParamsAsStringListMapInput) -> Result<output::QueryParamsAsStringListMapOutput, error::QueryParamsAsStringListMapError> {
|
12993 13197 | /// todo!()
|
12994 13198 | /// }
|
12995 13199 | ///
|
12996 13200 | /// let config = RestJsonConfig::builder().build();
|
12997 13201 | /// let svc = ::tower::util::service_fn(handler);
|
12998 13202 | /// let app = RestJson::builder(config)
|
12999 13203 | /// .query_params_as_string_list_map_service(svc)
|
13000 13204 | /// /* Set other handlers */
|
13001 13205 | /// .build()
|
13002 13206 | /// .unwrap();
|
13003 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13207 + | /// # 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;
|
13004 13208 | /// ```
|
13005 13209 | ///
|
13006 13210 | pub fn query_params_as_string_list_map_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13007 13211 | where
|
13008 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::QueryParamsAsStringListMap, ServiceExtractors>,
|
13212 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::QueryParamsAsStringListMap, ServiceExtractors>,
|
13009 13213 |
|
13010 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13214 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13011 13215 | RestJson<L>,
|
13012 13216 | crate::operation_shape::QueryParamsAsStringListMap,
|
13013 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::QueryParamsAsStringListMap, S>
|
13217 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::QueryParamsAsStringListMap, S>
|
13014 13218 | >,
|
13015 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13219 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13016 13220 | RestJson<L>,
|
13017 13221 | crate::operation_shape::QueryParamsAsStringListMap,
|
13018 13222 | ModelPl::Output
|
13019 13223 | >,
|
13020 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13224 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13021 13225 | RestJson<L>,
|
13022 13226 | crate::operation_shape::QueryParamsAsStringListMap,
|
13023 13227 | <
|
13024 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13025 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13228 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13229 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13026 13230 | RestJson<L>,
|
13027 13231 | crate::operation_shape::QueryParamsAsStringListMap,
|
13028 13232 | ModelPl::Output
|
13029 13233 | >
|
13030 13234 | >::Output
|
13031 13235 | >,
|
13032 13236 |
|
13033 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13237 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13034 13238 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13035 13239 |
|
13036 13240 | {
|
13037 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13038 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13241 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13242 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13039 13243 | let svc = crate::operation_shape::QueryParamsAsStringListMap::from_service(service);
|
13040 13244 | let svc = self.model_plugin.apply(svc);
|
13041 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13245 + | let svc =
|
13246 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13042 13247 | .apply(svc);
|
13043 13248 | let svc = self.http_plugin.apply(svc);
|
13044 13249 | self.query_params_as_string_list_map_custom(svc)
|
13045 13250 | }
|
13046 13251 |
|
13047 13252 | /// Sets the [`QueryParamsAsStringListMap`](crate::operation_shape::QueryParamsAsStringListMap) to a custom [`Service`](tower::Service).
|
13048 13253 | /// not constrained by the Smithy contract.
|
13049 13254 | fn query_params_as_string_list_map_custom<S>(mut self, svc: S) -> Self
|
13050 13255 | where
|
13051 13256 | S: ::tower::Service<
|
13052 13257 | ::http::Request<Body>,
|
13053 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13258 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13054 13259 | Error = ::std::convert::Infallible,
|
13055 13260 | > + Clone
|
13056 13261 | + Send
|
13057 13262 | + 'static,
|
13058 13263 | S::Future: Send + 'static,
|
13059 13264 | {
|
13060 13265 | self.query_params_as_string_list_map =
|
13061 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13266 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13062 13267 | self
|
13063 13268 | }
|
13064 13269 |
|
13065 13270 | /// Sets the [`QueryPrecedence`](crate::operation_shape::QueryPrecedence) operation.
|
13066 13271 | ///
|
13067 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13068 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13272 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13273 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13069 13274 | ///
|
13070 13275 | /// # Example
|
13071 13276 | ///
|
13072 13277 | /// ```no_run
|
13073 13278 | /// use rest_json::{RestJson, RestJsonConfig};
|
13074 13279 | ///
|
13075 13280 | /// use rest_json::{input, output, error};
|
13076 13281 | ///
|
13077 13282 | /// async fn handler(input: input::QueryPrecedenceInput) -> Result<output::QueryPrecedenceOutput, error::QueryPrecedenceError> {
|
13078 13283 | /// todo!()
|
13079 13284 | /// }
|
13080 13285 | ///
|
13081 13286 | /// let config = RestJsonConfig::builder().build();
|
13082 13287 | /// let app = RestJson::builder(config)
|
13083 13288 | /// .query_precedence(handler)
|
13084 13289 | /// /* Set other handlers */
|
13085 13290 | /// .build()
|
13086 13291 | /// .unwrap();
|
13087 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13292 + | /// # 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;
|
13088 13293 | /// ```
|
13089 13294 | ///
|
13090 13295 | pub fn query_precedence<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13091 13296 | where
|
13092 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::QueryPrecedence, HandlerExtractors>,
|
13297 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::QueryPrecedence, HandlerExtractors>,
|
13093 13298 |
|
13094 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13299 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13095 13300 | RestJson<L>,
|
13096 13301 | crate::operation_shape::QueryPrecedence,
|
13097 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::QueryPrecedence, HandlerType>
|
13302 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::QueryPrecedence, HandlerType>
|
13098 13303 | >,
|
13099 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13304 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13100 13305 | RestJson<L>,
|
13101 13306 | crate::operation_shape::QueryPrecedence,
|
13102 13307 | ModelPl::Output
|
13103 13308 | >,
|
13104 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13309 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13105 13310 | RestJson<L>,
|
13106 13311 | crate::operation_shape::QueryPrecedence,
|
13107 13312 | <
|
13108 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13109 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13313 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13314 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13110 13315 | RestJson<L>,
|
13111 13316 | crate::operation_shape::QueryPrecedence,
|
13112 13317 | ModelPl::Output
|
13113 13318 | >
|
13114 13319 | >::Output
|
13115 13320 | >,
|
13116 13321 |
|
13117 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13322 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13118 13323 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13119 13324 |
|
13120 13325 | {
|
13121 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13122 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13326 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13327 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13123 13328 | let svc = crate::operation_shape::QueryPrecedence::from_handler(handler);
|
13124 13329 | let svc = self.model_plugin.apply(svc);
|
13125 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13330 + | let svc =
|
13331 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13126 13332 | .apply(svc);
|
13127 13333 | let svc = self.http_plugin.apply(svc);
|
13128 13334 | self.query_precedence_custom(svc)
|
13129 13335 | }
|
13130 13336 |
|
13131 13337 | /// Sets the [`QueryPrecedence`](crate::operation_shape::QueryPrecedence) operation.
|
13132 13338 | ///
|
13133 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13134 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13339 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13340 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13135 13341 | ///
|
13136 13342 | /// # Example
|
13137 13343 | ///
|
13138 13344 | /// ```no_run
|
13139 13345 | /// use rest_json::{RestJson, RestJsonConfig};
|
13140 13346 | ///
|
13141 13347 | /// use rest_json::{input, output, error};
|
13142 13348 | ///
|
13143 13349 | /// async fn handler(input: input::QueryPrecedenceInput) -> Result<output::QueryPrecedenceOutput, error::QueryPrecedenceError> {
|
13144 13350 | /// todo!()
|
13145 13351 | /// }
|
13146 13352 | ///
|
13147 13353 | /// let config = RestJsonConfig::builder().build();
|
13148 13354 | /// let svc = ::tower::util::service_fn(handler);
|
13149 13355 | /// let app = RestJson::builder(config)
|
13150 13356 | /// .query_precedence_service(svc)
|
13151 13357 | /// /* Set other handlers */
|
13152 13358 | /// .build()
|
13153 13359 | /// .unwrap();
|
13154 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13360 + | /// # 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;
|
13155 13361 | /// ```
|
13156 13362 | ///
|
13157 13363 | pub fn query_precedence_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13158 13364 | where
|
13159 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::QueryPrecedence, ServiceExtractors>,
|
13365 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::QueryPrecedence, ServiceExtractors>,
|
13160 13366 |
|
13161 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13367 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13162 13368 | RestJson<L>,
|
13163 13369 | crate::operation_shape::QueryPrecedence,
|
13164 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::QueryPrecedence, S>
|
13370 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::QueryPrecedence, S>
|
13165 13371 | >,
|
13166 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13372 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13167 13373 | RestJson<L>,
|
13168 13374 | crate::operation_shape::QueryPrecedence,
|
13169 13375 | ModelPl::Output
|
13170 13376 | >,
|
13171 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13377 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13172 13378 | RestJson<L>,
|
13173 13379 | crate::operation_shape::QueryPrecedence,
|
13174 13380 | <
|
13175 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13176 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13381 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13382 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13177 13383 | RestJson<L>,
|
13178 13384 | crate::operation_shape::QueryPrecedence,
|
13179 13385 | ModelPl::Output
|
13180 13386 | >
|
13181 13387 | >::Output
|
13182 13388 | >,
|
13183 13389 |
|
13184 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13390 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13185 13391 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13186 13392 |
|
13187 13393 | {
|
13188 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13189 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13394 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13395 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13190 13396 | let svc = crate::operation_shape::QueryPrecedence::from_service(service);
|
13191 13397 | let svc = self.model_plugin.apply(svc);
|
13192 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13398 + | let svc =
|
13399 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13193 13400 | .apply(svc);
|
13194 13401 | let svc = self.http_plugin.apply(svc);
|
13195 13402 | self.query_precedence_custom(svc)
|
13196 13403 | }
|
13197 13404 |
|
13198 13405 | /// Sets the [`QueryPrecedence`](crate::operation_shape::QueryPrecedence) to a custom [`Service`](tower::Service).
|
13199 13406 | /// not constrained by the Smithy contract.
|
13200 13407 | fn query_precedence_custom<S>(mut self, svc: S) -> Self
|
13201 13408 | where
|
13202 13409 | S: ::tower::Service<
|
13203 13410 | ::http::Request<Body>,
|
13204 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13411 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13205 13412 | Error = ::std::convert::Infallible,
|
13206 13413 | > + Clone
|
13207 13414 | + Send
|
13208 13415 | + 'static,
|
13209 13416 | S::Future: Send + 'static,
|
13210 13417 | {
|
13211 - | self.query_precedence = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13418 + | self.query_precedence = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13212 13419 | self
|
13213 13420 | }
|
13214 13421 |
|
13215 13422 | /// Sets the [`RecursiveShapes`](crate::operation_shape::RecursiveShapes) operation.
|
13216 13423 | ///
|
13217 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13218 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13424 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13425 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13219 13426 | ///
|
13220 13427 | /// # Example
|
13221 13428 | ///
|
13222 13429 | /// ```no_run
|
13223 13430 | /// use rest_json::{RestJson, RestJsonConfig};
|
13224 13431 | ///
|
13225 13432 | /// use rest_json::{input, output, error};
|
13226 13433 | ///
|
13227 13434 | /// async fn handler(input: input::RecursiveShapesInput) -> Result<output::RecursiveShapesOutput, error::RecursiveShapesError> {
|
13228 13435 | /// todo!()
|
13229 13436 | /// }
|
13230 13437 | ///
|
13231 13438 | /// let config = RestJsonConfig::builder().build();
|
13232 13439 | /// let app = RestJson::builder(config)
|
13233 13440 | /// .recursive_shapes(handler)
|
13234 13441 | /// /* Set other handlers */
|
13235 13442 | /// .build()
|
13236 13443 | /// .unwrap();
|
13237 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13444 + | /// # 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;
|
13238 13445 | /// ```
|
13239 13446 | ///
|
13240 13447 | pub fn recursive_shapes<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13241 13448 | where
|
13242 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::RecursiveShapes, HandlerExtractors>,
|
13449 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::RecursiveShapes, HandlerExtractors>,
|
13243 13450 |
|
13244 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13451 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13245 13452 | RestJson<L>,
|
13246 13453 | crate::operation_shape::RecursiveShapes,
|
13247 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::RecursiveShapes, HandlerType>
|
13454 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::RecursiveShapes, HandlerType>
|
13248 13455 | >,
|
13249 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13456 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13250 13457 | RestJson<L>,
|
13251 13458 | crate::operation_shape::RecursiveShapes,
|
13252 13459 | ModelPl::Output
|
13253 13460 | >,
|
13254 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13461 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13255 13462 | RestJson<L>,
|
13256 13463 | crate::operation_shape::RecursiveShapes,
|
13257 13464 | <
|
13258 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13259 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13465 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13466 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13260 13467 | RestJson<L>,
|
13261 13468 | crate::operation_shape::RecursiveShapes,
|
13262 13469 | ModelPl::Output
|
13263 13470 | >
|
13264 13471 | >::Output
|
13265 13472 | >,
|
13266 13473 |
|
13267 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13474 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13268 13475 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13269 13476 |
|
13270 13477 | {
|
13271 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13272 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13478 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13479 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13273 13480 | let svc = crate::operation_shape::RecursiveShapes::from_handler(handler);
|
13274 13481 | let svc = self.model_plugin.apply(svc);
|
13275 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13482 + | let svc =
|
13483 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13276 13484 | .apply(svc);
|
13277 13485 | let svc = self.http_plugin.apply(svc);
|
13278 13486 | self.recursive_shapes_custom(svc)
|
13279 13487 | }
|
13280 13488 |
|
13281 13489 | /// Sets the [`RecursiveShapes`](crate::operation_shape::RecursiveShapes) operation.
|
13282 13490 | ///
|
13283 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13284 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13491 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13492 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13285 13493 | ///
|
13286 13494 | /// # Example
|
13287 13495 | ///
|
13288 13496 | /// ```no_run
|
13289 13497 | /// use rest_json::{RestJson, RestJsonConfig};
|
13290 13498 | ///
|
13291 13499 | /// use rest_json::{input, output, error};
|
13292 13500 | ///
|
13293 13501 | /// async fn handler(input: input::RecursiveShapesInput) -> Result<output::RecursiveShapesOutput, error::RecursiveShapesError> {
|
13294 13502 | /// todo!()
|
13295 13503 | /// }
|
13296 13504 | ///
|
13297 13505 | /// let config = RestJsonConfig::builder().build();
|
13298 13506 | /// let svc = ::tower::util::service_fn(handler);
|
13299 13507 | /// let app = RestJson::builder(config)
|
13300 13508 | /// .recursive_shapes_service(svc)
|
13301 13509 | /// /* Set other handlers */
|
13302 13510 | /// .build()
|
13303 13511 | /// .unwrap();
|
13304 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13512 + | /// # 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;
|
13305 13513 | /// ```
|
13306 13514 | ///
|
13307 13515 | pub fn recursive_shapes_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13308 13516 | where
|
13309 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::RecursiveShapes, ServiceExtractors>,
|
13517 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::RecursiveShapes, ServiceExtractors>,
|
13310 13518 |
|
13311 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13519 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13312 13520 | RestJson<L>,
|
13313 13521 | crate::operation_shape::RecursiveShapes,
|
13314 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::RecursiveShapes, S>
|
13522 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::RecursiveShapes, S>
|
13315 13523 | >,
|
13316 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13524 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13317 13525 | RestJson<L>,
|
13318 13526 | crate::operation_shape::RecursiveShapes,
|
13319 13527 | ModelPl::Output
|
13320 13528 | >,
|
13321 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13529 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13322 13530 | RestJson<L>,
|
13323 13531 | crate::operation_shape::RecursiveShapes,
|
13324 13532 | <
|
13325 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13326 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13533 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13534 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13327 13535 | RestJson<L>,
|
13328 13536 | crate::operation_shape::RecursiveShapes,
|
13329 13537 | ModelPl::Output
|
13330 13538 | >
|
13331 13539 | >::Output
|
13332 13540 | >,
|
13333 13541 |
|
13334 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13542 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13335 13543 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13336 13544 |
|
13337 13545 | {
|
13338 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13339 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13546 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13547 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13340 13548 | let svc = crate::operation_shape::RecursiveShapes::from_service(service);
|
13341 13549 | let svc = self.model_plugin.apply(svc);
|
13342 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13550 + | let svc =
|
13551 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13343 13552 | .apply(svc);
|
13344 13553 | let svc = self.http_plugin.apply(svc);
|
13345 13554 | self.recursive_shapes_custom(svc)
|
13346 13555 | }
|
13347 13556 |
|
13348 13557 | /// Sets the [`RecursiveShapes`](crate::operation_shape::RecursiveShapes) to a custom [`Service`](tower::Service).
|
13349 13558 | /// not constrained by the Smithy contract.
|
13350 13559 | fn recursive_shapes_custom<S>(mut self, svc: S) -> Self
|
13351 13560 | where
|
13352 13561 | S: ::tower::Service<
|
13353 13562 | ::http::Request<Body>,
|
13354 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13563 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13355 13564 | Error = ::std::convert::Infallible,
|
13356 13565 | > + Clone
|
13357 13566 | + Send
|
13358 13567 | + 'static,
|
13359 13568 | S::Future: Send + 'static,
|
13360 13569 | {
|
13361 - | self.recursive_shapes = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13570 + | self.recursive_shapes = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13362 13571 | self
|
13363 13572 | }
|
13364 13573 |
|
13365 13574 | /// Sets the [`ResponseCodeHttpFallback`](crate::operation_shape::ResponseCodeHttpFallback) operation.
|
13366 13575 | ///
|
13367 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13368 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13576 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13577 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13369 13578 | ///
|
13370 13579 | /// # Example
|
13371 13580 | ///
|
13372 13581 | /// ```no_run
|
13373 13582 | /// use rest_json::{RestJson, RestJsonConfig};
|
13374 13583 | ///
|
13375 13584 | /// use rest_json::{input, output, error};
|
13376 13585 | ///
|
13377 13586 | /// async fn handler(input: input::ResponseCodeHttpFallbackInput) -> Result<output::ResponseCodeHttpFallbackOutput, error::ResponseCodeHttpFallbackError> {
|
13378 13587 | /// todo!()
|
13379 13588 | /// }
|
13380 13589 | ///
|
13381 13590 | /// let config = RestJsonConfig::builder().build();
|
13382 13591 | /// let app = RestJson::builder(config)
|
13383 13592 | /// .response_code_http_fallback(handler)
|
13384 13593 | /// /* Set other handlers */
|
13385 13594 | /// .build()
|
13386 13595 | /// .unwrap();
|
13387 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13596 + | /// # 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;
|
13388 13597 | /// ```
|
13389 13598 | ///
|
13390 13599 | pub fn response_code_http_fallback<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13391 13600 | where
|
13392 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ResponseCodeHttpFallback, HandlerExtractors>,
|
13601 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ResponseCodeHttpFallback, HandlerExtractors>,
|
13393 13602 |
|
13394 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13603 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13395 13604 | RestJson<L>,
|
13396 13605 | crate::operation_shape::ResponseCodeHttpFallback,
|
13397 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ResponseCodeHttpFallback, HandlerType>
|
13606 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ResponseCodeHttpFallback, HandlerType>
|
13398 13607 | >,
|
13399 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13608 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13400 13609 | RestJson<L>,
|
13401 13610 | crate::operation_shape::ResponseCodeHttpFallback,
|
13402 13611 | ModelPl::Output
|
13403 13612 | >,
|
13404 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13613 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13405 13614 | RestJson<L>,
|
13406 13615 | crate::operation_shape::ResponseCodeHttpFallback,
|
13407 13616 | <
|
13408 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13409 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13617 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13618 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13410 13619 | RestJson<L>,
|
13411 13620 | crate::operation_shape::ResponseCodeHttpFallback,
|
13412 13621 | ModelPl::Output
|
13413 13622 | >
|
13414 13623 | >::Output
|
13415 13624 | >,
|
13416 13625 |
|
13417 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13626 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13418 13627 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13419 13628 |
|
13420 13629 | {
|
13421 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13422 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13630 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13631 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13423 13632 | let svc = crate::operation_shape::ResponseCodeHttpFallback::from_handler(handler);
|
13424 13633 | let svc = self.model_plugin.apply(svc);
|
13425 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13634 + | let svc =
|
13635 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13426 13636 | .apply(svc);
|
13427 13637 | let svc = self.http_plugin.apply(svc);
|
13428 13638 | self.response_code_http_fallback_custom(svc)
|
13429 13639 | }
|
13430 13640 |
|
13431 13641 | /// Sets the [`ResponseCodeHttpFallback`](crate::operation_shape::ResponseCodeHttpFallback) operation.
|
13432 13642 | ///
|
13433 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13434 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13643 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13644 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13435 13645 | ///
|
13436 13646 | /// # Example
|
13437 13647 | ///
|
13438 13648 | /// ```no_run
|
13439 13649 | /// use rest_json::{RestJson, RestJsonConfig};
|
13440 13650 | ///
|
13441 13651 | /// use rest_json::{input, output, error};
|
13442 13652 | ///
|
13443 13653 | /// async fn handler(input: input::ResponseCodeHttpFallbackInput) -> Result<output::ResponseCodeHttpFallbackOutput, error::ResponseCodeHttpFallbackError> {
|
13444 13654 | /// todo!()
|
13445 13655 | /// }
|
13446 13656 | ///
|
13447 13657 | /// let config = RestJsonConfig::builder().build();
|
13448 13658 | /// let svc = ::tower::util::service_fn(handler);
|
13449 13659 | /// let app = RestJson::builder(config)
|
13450 13660 | /// .response_code_http_fallback_service(svc)
|
13451 13661 | /// /* Set other handlers */
|
13452 13662 | /// .build()
|
13453 13663 | /// .unwrap();
|
13454 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13664 + | /// # 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;
|
13455 13665 | /// ```
|
13456 13666 | ///
|
13457 13667 | pub fn response_code_http_fallback_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13458 13668 | where
|
13459 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ResponseCodeHttpFallback, ServiceExtractors>,
|
13669 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ResponseCodeHttpFallback, ServiceExtractors>,
|
13460 13670 |
|
13461 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13671 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13462 13672 | RestJson<L>,
|
13463 13673 | crate::operation_shape::ResponseCodeHttpFallback,
|
13464 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ResponseCodeHttpFallback, S>
|
13674 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ResponseCodeHttpFallback, S>
|
13465 13675 | >,
|
13466 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13676 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13467 13677 | RestJson<L>,
|
13468 13678 | crate::operation_shape::ResponseCodeHttpFallback,
|
13469 13679 | ModelPl::Output
|
13470 13680 | >,
|
13471 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13681 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13472 13682 | RestJson<L>,
|
13473 13683 | crate::operation_shape::ResponseCodeHttpFallback,
|
13474 13684 | <
|
13475 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13476 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13685 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13686 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13477 13687 | RestJson<L>,
|
13478 13688 | crate::operation_shape::ResponseCodeHttpFallback,
|
13479 13689 | ModelPl::Output
|
13480 13690 | >
|
13481 13691 | >::Output
|
13482 13692 | >,
|
13483 13693 |
|
13484 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13694 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13485 13695 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13486 13696 |
|
13487 13697 | {
|
13488 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13489 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13698 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13699 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13490 13700 | let svc = crate::operation_shape::ResponseCodeHttpFallback::from_service(service);
|
13491 13701 | let svc = self.model_plugin.apply(svc);
|
13492 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13702 + | let svc =
|
13703 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13493 13704 | .apply(svc);
|
13494 13705 | let svc = self.http_plugin.apply(svc);
|
13495 13706 | self.response_code_http_fallback_custom(svc)
|
13496 13707 | }
|
13497 13708 |
|
13498 13709 | /// Sets the [`ResponseCodeHttpFallback`](crate::operation_shape::ResponseCodeHttpFallback) to a custom [`Service`](tower::Service).
|
13499 13710 | /// not constrained by the Smithy contract.
|
13500 13711 | fn response_code_http_fallback_custom<S>(mut self, svc: S) -> Self
|
13501 13712 | where
|
13502 13713 | S: ::tower::Service<
|
13503 13714 | ::http::Request<Body>,
|
13504 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13715 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13505 13716 | Error = ::std::convert::Infallible,
|
13506 13717 | > + Clone
|
13507 13718 | + Send
|
13508 13719 | + 'static,
|
13509 13720 | S::Future: Send + 'static,
|
13510 13721 | {
|
13511 - | self.response_code_http_fallback = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13722 + | self.response_code_http_fallback =
|
13723 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13512 13724 | self
|
13513 13725 | }
|
13514 13726 |
|
13515 13727 | /// Sets the [`ResponseCodeRequired`](crate::operation_shape::ResponseCodeRequired) operation.
|
13516 13728 | ///
|
13517 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13518 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13729 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13730 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13519 13731 | ///
|
13520 13732 | /// # Example
|
13521 13733 | ///
|
13522 13734 | /// ```no_run
|
13523 13735 | /// use rest_json::{RestJson, RestJsonConfig};
|
13524 13736 | ///
|
13525 13737 | /// use rest_json::{input, output, error};
|
13526 13738 | ///
|
13527 13739 | /// async fn handler(input: input::ResponseCodeRequiredInput) -> Result<output::ResponseCodeRequiredOutput, error::ResponseCodeRequiredError> {
|
13528 13740 | /// todo!()
|
13529 13741 | /// }
|
13530 13742 | ///
|
13531 13743 | /// let config = RestJsonConfig::builder().build();
|
13532 13744 | /// let app = RestJson::builder(config)
|
13533 13745 | /// .response_code_required(handler)
|
13534 13746 | /// /* Set other handlers */
|
13535 13747 | /// .build()
|
13536 13748 | /// .unwrap();
|
13537 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13749 + | /// # 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;
|
13538 13750 | /// ```
|
13539 13751 | ///
|
13540 13752 | pub fn response_code_required<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13541 13753 | where
|
13542 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::ResponseCodeRequired, HandlerExtractors>,
|
13754 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::ResponseCodeRequired, HandlerExtractors>,
|
13543 13755 |
|
13544 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13756 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13545 13757 | RestJson<L>,
|
13546 13758 | crate::operation_shape::ResponseCodeRequired,
|
13547 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::ResponseCodeRequired, HandlerType>
|
13759 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::ResponseCodeRequired, HandlerType>
|
13548 13760 | >,
|
13549 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13761 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13550 13762 | RestJson<L>,
|
13551 13763 | crate::operation_shape::ResponseCodeRequired,
|
13552 13764 | ModelPl::Output
|
13553 13765 | >,
|
13554 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13766 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13555 13767 | RestJson<L>,
|
13556 13768 | crate::operation_shape::ResponseCodeRequired,
|
13557 13769 | <
|
13558 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13559 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13770 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13771 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13560 13772 | RestJson<L>,
|
13561 13773 | crate::operation_shape::ResponseCodeRequired,
|
13562 13774 | ModelPl::Output
|
13563 13775 | >
|
13564 13776 | >::Output
|
13565 13777 | >,
|
13566 13778 |
|
13567 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13779 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13568 13780 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13569 13781 |
|
13570 13782 | {
|
13571 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13572 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13783 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13784 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13573 13785 | let svc = crate::operation_shape::ResponseCodeRequired::from_handler(handler);
|
13574 13786 | let svc = self.model_plugin.apply(svc);
|
13575 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13787 + | let svc =
|
13788 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13576 13789 | .apply(svc);
|
13577 13790 | let svc = self.http_plugin.apply(svc);
|
13578 13791 | self.response_code_required_custom(svc)
|
13579 13792 | }
|
13580 13793 |
|
13581 13794 | /// Sets the [`ResponseCodeRequired`](crate::operation_shape::ResponseCodeRequired) operation.
|
13582 13795 | ///
|
13583 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13584 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13796 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13797 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13585 13798 | ///
|
13586 13799 | /// # Example
|
13587 13800 | ///
|
13588 13801 | /// ```no_run
|
13589 13802 | /// use rest_json::{RestJson, RestJsonConfig};
|
13590 13803 | ///
|
13591 13804 | /// use rest_json::{input, output, error};
|
13592 13805 | ///
|
13593 13806 | /// async fn handler(input: input::ResponseCodeRequiredInput) -> Result<output::ResponseCodeRequiredOutput, error::ResponseCodeRequiredError> {
|
13594 13807 | /// todo!()
|
13595 13808 | /// }
|
13596 13809 | ///
|
13597 13810 | /// let config = RestJsonConfig::builder().build();
|
13598 13811 | /// let svc = ::tower::util::service_fn(handler);
|
13599 13812 | /// let app = RestJson::builder(config)
|
13600 13813 | /// .response_code_required_service(svc)
|
13601 13814 | /// /* Set other handlers */
|
13602 13815 | /// .build()
|
13603 13816 | /// .unwrap();
|
13604 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13817 + | /// # 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;
|
13605 13818 | /// ```
|
13606 13819 | ///
|
13607 13820 | pub fn response_code_required_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13608 13821 | where
|
13609 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::ResponseCodeRequired, ServiceExtractors>,
|
13822 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::ResponseCodeRequired, ServiceExtractors>,
|
13610 13823 |
|
13611 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13824 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13612 13825 | RestJson<L>,
|
13613 13826 | crate::operation_shape::ResponseCodeRequired,
|
13614 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::ResponseCodeRequired, S>
|
13827 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::ResponseCodeRequired, S>
|
13615 13828 | >,
|
13616 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13829 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13617 13830 | RestJson<L>,
|
13618 13831 | crate::operation_shape::ResponseCodeRequired,
|
13619 13832 | ModelPl::Output
|
13620 13833 | >,
|
13621 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13834 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13622 13835 | RestJson<L>,
|
13623 13836 | crate::operation_shape::ResponseCodeRequired,
|
13624 13837 | <
|
13625 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13626 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13838 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13839 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13627 13840 | RestJson<L>,
|
13628 13841 | crate::operation_shape::ResponseCodeRequired,
|
13629 13842 | ModelPl::Output
|
13630 13843 | >
|
13631 13844 | >::Output
|
13632 13845 | >,
|
13633 13846 |
|
13634 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13847 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13635 13848 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13636 13849 |
|
13637 13850 | {
|
13638 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13639 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13851 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13852 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13640 13853 | let svc = crate::operation_shape::ResponseCodeRequired::from_service(service);
|
13641 13854 | let svc = self.model_plugin.apply(svc);
|
13642 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13855 + | let svc =
|
13856 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13643 13857 | .apply(svc);
|
13644 13858 | let svc = self.http_plugin.apply(svc);
|
13645 13859 | self.response_code_required_custom(svc)
|
13646 13860 | }
|
13647 13861 |
|
13648 13862 | /// Sets the [`ResponseCodeRequired`](crate::operation_shape::ResponseCodeRequired) to a custom [`Service`](tower::Service).
|
13649 13863 | /// not constrained by the Smithy contract.
|
13650 13864 | fn response_code_required_custom<S>(mut self, svc: S) -> Self
|
13651 13865 | where
|
13652 13866 | S: ::tower::Service<
|
13653 13867 | ::http::Request<Body>,
|
13654 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
13868 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13655 13869 | Error = ::std::convert::Infallible,
|
13656 13870 | > + Clone
|
13657 13871 | + Send
|
13658 13872 | + 'static,
|
13659 13873 | S::Future: Send + 'static,
|
13660 13874 | {
|
13661 - | self.response_code_required = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
13875 + | self.response_code_required =
|
13876 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13662 13877 | self
|
13663 13878 | }
|
13664 13879 |
|
13665 13880 | /// Sets the [`SimpleScalarProperties`](crate::operation_shape::SimpleScalarProperties) operation.
|
13666 13881 | ///
|
13667 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13668 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13882 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13883 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13669 13884 | ///
|
13670 13885 | /// # Example
|
13671 13886 | ///
|
13672 13887 | /// ```no_run
|
13673 13888 | /// use rest_json::{RestJson, RestJsonConfig};
|
13674 13889 | ///
|
13675 13890 | /// use rest_json::{input, output, error};
|
13676 13891 | ///
|
13677 13892 | /// async fn handler(input: input::SimpleScalarPropertiesInput) -> Result<output::SimpleScalarPropertiesOutput, error::SimpleScalarPropertiesError> {
|
13678 13893 | /// todo!()
|
13679 13894 | /// }
|
13680 13895 | ///
|
13681 13896 | /// let config = RestJsonConfig::builder().build();
|
13682 13897 | /// let app = RestJson::builder(config)
|
13683 13898 | /// .simple_scalar_properties(handler)
|
13684 13899 | /// /* Set other handlers */
|
13685 13900 | /// .build()
|
13686 13901 | /// .unwrap();
|
13687 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13902 + | /// # 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;
|
13688 13903 | /// ```
|
13689 13904 | ///
|
13690 13905 | pub fn simple_scalar_properties<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13691 13906 | where
|
13692 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::SimpleScalarProperties, HandlerExtractors>,
|
13907 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::SimpleScalarProperties, HandlerExtractors>,
|
13693 13908 |
|
13694 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13909 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13695 13910 | RestJson<L>,
|
13696 13911 | crate::operation_shape::SimpleScalarProperties,
|
13697 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::SimpleScalarProperties, HandlerType>
|
13912 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::SimpleScalarProperties, HandlerType>
|
13698 13913 | >,
|
13699 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13914 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13700 13915 | RestJson<L>,
|
13701 13916 | crate::operation_shape::SimpleScalarProperties,
|
13702 13917 | ModelPl::Output
|
13703 13918 | >,
|
13704 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13919 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13705 13920 | RestJson<L>,
|
13706 13921 | crate::operation_shape::SimpleScalarProperties,
|
13707 13922 | <
|
13708 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13709 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13923 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13924 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13710 13925 | RestJson<L>,
|
13711 13926 | crate::operation_shape::SimpleScalarProperties,
|
13712 13927 | ModelPl::Output
|
13713 13928 | >
|
13714 13929 | >::Output
|
13715 13930 | >,
|
13716 13931 |
|
13717 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13932 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13718 13933 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13719 13934 |
|
13720 13935 | {
|
13721 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13722 - | use ::aws_smithy_http_server::plugin::Plugin;
|
13936 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
13937 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13723 13938 | let svc = crate::operation_shape::SimpleScalarProperties::from_handler(handler);
|
13724 13939 | let svc = self.model_plugin.apply(svc);
|
13725 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13940 + | let svc =
|
13941 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13726 13942 | .apply(svc);
|
13727 13943 | let svc = self.http_plugin.apply(svc);
|
13728 13944 | self.simple_scalar_properties_custom(svc)
|
13729 13945 | }
|
13730 13946 |
|
13731 13947 | /// Sets the [`SimpleScalarProperties`](crate::operation_shape::SimpleScalarProperties) operation.
|
13732 13948 | ///
|
13733 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13734 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
13949 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
13950 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13735 13951 | ///
|
13736 13952 | /// # Example
|
13737 13953 | ///
|
13738 13954 | /// ```no_run
|
13739 13955 | /// use rest_json::{RestJson, RestJsonConfig};
|
13740 13956 | ///
|
13741 13957 | /// use rest_json::{input, output, error};
|
13742 13958 | ///
|
13743 13959 | /// async fn handler(input: input::SimpleScalarPropertiesInput) -> Result<output::SimpleScalarPropertiesOutput, error::SimpleScalarPropertiesError> {
|
13744 13960 | /// todo!()
|
13745 13961 | /// }
|
13746 13962 | ///
|
13747 13963 | /// let config = RestJsonConfig::builder().build();
|
13748 13964 | /// let svc = ::tower::util::service_fn(handler);
|
13749 13965 | /// let app = RestJson::builder(config)
|
13750 13966 | /// .simple_scalar_properties_service(svc)
|
13751 13967 | /// /* Set other handlers */
|
13752 13968 | /// .build()
|
13753 13969 | /// .unwrap();
|
13754 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
13970 + | /// # 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;
|
13755 13971 | /// ```
|
13756 13972 | ///
|
13757 13973 | pub fn simple_scalar_properties_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13758 13974 | where
|
13759 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::SimpleScalarProperties, ServiceExtractors>,
|
13975 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::SimpleScalarProperties, ServiceExtractors>,
|
13760 13976 |
|
13761 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
13977 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13762 13978 | RestJson<L>,
|
13763 13979 | crate::operation_shape::SimpleScalarProperties,
|
13764 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::SimpleScalarProperties, S>
|
13980 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::SimpleScalarProperties, S>
|
13765 13981 | >,
|
13766 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
13982 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13767 13983 | RestJson<L>,
|
13768 13984 | crate::operation_shape::SimpleScalarProperties,
|
13769 13985 | ModelPl::Output
|
13770 13986 | >,
|
13771 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
13987 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13772 13988 | RestJson<L>,
|
13773 13989 | crate::operation_shape::SimpleScalarProperties,
|
13774 13990 | <
|
13775 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13776 - | as ::aws_smithy_http_server::plugin::Plugin<
|
13991 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13992 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13777 13993 | RestJson<L>,
|
13778 13994 | crate::operation_shape::SimpleScalarProperties,
|
13779 13995 | ModelPl::Output
|
13780 13996 | >
|
13781 13997 | >::Output
|
13782 13998 | >,
|
13783 13999 |
|
13784 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14000 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13785 14001 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13786 14002 |
|
13787 14003 | {
|
13788 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13789 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14004 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14005 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13790 14006 | let svc = crate::operation_shape::SimpleScalarProperties::from_service(service);
|
13791 14007 | let svc = self.model_plugin.apply(svc);
|
13792 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14008 + | let svc =
|
14009 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13793 14010 | .apply(svc);
|
13794 14011 | let svc = self.http_plugin.apply(svc);
|
13795 14012 | self.simple_scalar_properties_custom(svc)
|
13796 14013 | }
|
13797 14014 |
|
13798 14015 | /// Sets the [`SimpleScalarProperties`](crate::operation_shape::SimpleScalarProperties) to a custom [`Service`](tower::Service).
|
13799 14016 | /// not constrained by the Smithy contract.
|
13800 14017 | fn simple_scalar_properties_custom<S>(mut self, svc: S) -> Self
|
13801 14018 | where
|
13802 14019 | S: ::tower::Service<
|
13803 14020 | ::http::Request<Body>,
|
13804 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14021 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13805 14022 | Error = ::std::convert::Infallible,
|
13806 14023 | > + Clone
|
13807 14024 | + Send
|
13808 14025 | + 'static,
|
13809 14026 | S::Future: Send + 'static,
|
13810 14027 | {
|
13811 - | self.simple_scalar_properties = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14028 + | self.simple_scalar_properties =
|
14029 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13812 14030 | self
|
13813 14031 | }
|
13814 14032 |
|
13815 14033 | /// Sets the [`SparseJsonLists`](crate::operation_shape::SparseJsonLists) operation.
|
13816 14034 | ///
|
13817 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13818 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14035 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14036 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13819 14037 | ///
|
13820 14038 | /// # Example
|
13821 14039 | ///
|
13822 14040 | /// ```no_run
|
13823 14041 | /// use rest_json::{RestJson, RestJsonConfig};
|
13824 14042 | ///
|
13825 14043 | /// use rest_json::{input, output, error};
|
13826 14044 | ///
|
13827 14045 | /// async fn handler(input: input::SparseJsonListsInput) -> Result<output::SparseJsonListsOutput, error::SparseJsonListsError> {
|
13828 14046 | /// todo!()
|
13829 14047 | /// }
|
13830 14048 | ///
|
13831 14049 | /// let config = RestJsonConfig::builder().build();
|
13832 14050 | /// let app = RestJson::builder(config)
|
13833 14051 | /// .sparse_json_lists(handler)
|
13834 14052 | /// /* Set other handlers */
|
13835 14053 | /// .build()
|
13836 14054 | /// .unwrap();
|
13837 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14055 + | /// # 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;
|
13838 14056 | /// ```
|
13839 14057 | ///
|
13840 14058 | pub fn sparse_json_lists<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13841 14059 | where
|
13842 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::SparseJsonLists, HandlerExtractors>,
|
14060 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::SparseJsonLists, HandlerExtractors>,
|
13843 14061 |
|
13844 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14062 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13845 14063 | RestJson<L>,
|
13846 14064 | crate::operation_shape::SparseJsonLists,
|
13847 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::SparseJsonLists, HandlerType>
|
14065 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::SparseJsonLists, HandlerType>
|
13848 14066 | >,
|
13849 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14067 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13850 14068 | RestJson<L>,
|
13851 14069 | crate::operation_shape::SparseJsonLists,
|
13852 14070 | ModelPl::Output
|
13853 14071 | >,
|
13854 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14072 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13855 14073 | RestJson<L>,
|
13856 14074 | crate::operation_shape::SparseJsonLists,
|
13857 14075 | <
|
13858 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13859 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14076 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14077 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13860 14078 | RestJson<L>,
|
13861 14079 | crate::operation_shape::SparseJsonLists,
|
13862 14080 | ModelPl::Output
|
13863 14081 | >
|
13864 14082 | >::Output
|
13865 14083 | >,
|
13866 14084 |
|
13867 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14085 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13868 14086 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13869 14087 |
|
13870 14088 | {
|
13871 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13872 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14089 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14090 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13873 14091 | let svc = crate::operation_shape::SparseJsonLists::from_handler(handler);
|
13874 14092 | let svc = self.model_plugin.apply(svc);
|
13875 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14093 + | let svc =
|
14094 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13876 14095 | .apply(svc);
|
13877 14096 | let svc = self.http_plugin.apply(svc);
|
13878 14097 | self.sparse_json_lists_custom(svc)
|
13879 14098 | }
|
13880 14099 |
|
13881 14100 | /// Sets the [`SparseJsonLists`](crate::operation_shape::SparseJsonLists) operation.
|
13882 14101 | ///
|
13883 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13884 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14102 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14103 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13885 14104 | ///
|
13886 14105 | /// # Example
|
13887 14106 | ///
|
13888 14107 | /// ```no_run
|
13889 14108 | /// use rest_json::{RestJson, RestJsonConfig};
|
13890 14109 | ///
|
13891 14110 | /// use rest_json::{input, output, error};
|
13892 14111 | ///
|
13893 14112 | /// async fn handler(input: input::SparseJsonListsInput) -> Result<output::SparseJsonListsOutput, error::SparseJsonListsError> {
|
13894 14113 | /// todo!()
|
13895 14114 | /// }
|
13896 14115 | ///
|
13897 14116 | /// let config = RestJsonConfig::builder().build();
|
13898 14117 | /// let svc = ::tower::util::service_fn(handler);
|
13899 14118 | /// let app = RestJson::builder(config)
|
13900 14119 | /// .sparse_json_lists_service(svc)
|
13901 14120 | /// /* Set other handlers */
|
13902 14121 | /// .build()
|
13903 14122 | /// .unwrap();
|
13904 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14123 + | /// # 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;
|
13905 14124 | /// ```
|
13906 14125 | ///
|
13907 14126 | pub fn sparse_json_lists_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
13908 14127 | where
|
13909 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::SparseJsonLists, ServiceExtractors>,
|
14128 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::SparseJsonLists, ServiceExtractors>,
|
13910 14129 |
|
13911 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14130 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13912 14131 | RestJson<L>,
|
13913 14132 | crate::operation_shape::SparseJsonLists,
|
13914 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::SparseJsonLists, S>
|
14133 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::SparseJsonLists, S>
|
13915 14134 | >,
|
13916 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14135 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13917 14136 | RestJson<L>,
|
13918 14137 | crate::operation_shape::SparseJsonLists,
|
13919 14138 | ModelPl::Output
|
13920 14139 | >,
|
13921 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14140 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13922 14141 | RestJson<L>,
|
13923 14142 | crate::operation_shape::SparseJsonLists,
|
13924 14143 | <
|
13925 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
13926 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14144 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14145 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13927 14146 | RestJson<L>,
|
13928 14147 | crate::operation_shape::SparseJsonLists,
|
13929 14148 | ModelPl::Output
|
13930 14149 | >
|
13931 14150 | >::Output
|
13932 14151 | >,
|
13933 14152 |
|
13934 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14153 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
13935 14154 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
13936 14155 |
|
13937 14156 | {
|
13938 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
13939 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14157 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14158 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
13940 14159 | let svc = crate::operation_shape::SparseJsonLists::from_service(service);
|
13941 14160 | let svc = self.model_plugin.apply(svc);
|
13942 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14161 + | let svc =
|
14162 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
13943 14163 | .apply(svc);
|
13944 14164 | let svc = self.http_plugin.apply(svc);
|
13945 14165 | self.sparse_json_lists_custom(svc)
|
13946 14166 | }
|
13947 14167 |
|
13948 14168 | /// Sets the [`SparseJsonLists`](crate::operation_shape::SparseJsonLists) to a custom [`Service`](tower::Service).
|
13949 14169 | /// not constrained by the Smithy contract.
|
13950 14170 | fn sparse_json_lists_custom<S>(mut self, svc: S) -> Self
|
13951 14171 | where
|
13952 14172 | S: ::tower::Service<
|
13953 14173 | ::http::Request<Body>,
|
13954 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14174 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
13955 14175 | Error = ::std::convert::Infallible,
|
13956 14176 | > + Clone
|
13957 14177 | + Send
|
13958 14178 | + 'static,
|
13959 14179 | S::Future: Send + 'static,
|
13960 14180 | {
|
13961 - | self.sparse_json_lists = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14181 + | self.sparse_json_lists = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
13962 14182 | self
|
13963 14183 | }
|
13964 14184 |
|
13965 14185 | /// Sets the [`SparseJsonMaps`](crate::operation_shape::SparseJsonMaps) operation.
|
13966 14186 | ///
|
13967 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
13968 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14187 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14188 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
13969 14189 | ///
|
13970 14190 | /// # Example
|
13971 14191 | ///
|
13972 14192 | /// ```no_run
|
13973 14193 | /// use rest_json::{RestJson, RestJsonConfig};
|
13974 14194 | ///
|
13975 14195 | /// use rest_json::{input, output, error};
|
13976 14196 | ///
|
13977 14197 | /// async fn handler(input: input::SparseJsonMapsInput) -> Result<output::SparseJsonMapsOutput, error::SparseJsonMapsError> {
|
13978 14198 | /// todo!()
|
13979 14199 | /// }
|
13980 14200 | ///
|
13981 14201 | /// let config = RestJsonConfig::builder().build();
|
13982 14202 | /// let app = RestJson::builder(config)
|
13983 14203 | /// .sparse_json_maps(handler)
|
13984 14204 | /// /* Set other handlers */
|
13985 14205 | /// .build()
|
13986 14206 | /// .unwrap();
|
13987 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14207 + | /// # 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;
|
13988 14208 | /// ```
|
13989 14209 | ///
|
13990 14210 | pub fn sparse_json_maps<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
13991 14211 | where
|
13992 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::SparseJsonMaps, HandlerExtractors>,
|
14212 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::SparseJsonMaps, HandlerExtractors>,
|
13993 14213 |
|
13994 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14214 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
13995 14215 | RestJson<L>,
|
13996 14216 | crate::operation_shape::SparseJsonMaps,
|
13997 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::SparseJsonMaps, HandlerType>
|
14217 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::SparseJsonMaps, HandlerType>
|
13998 14218 | >,
|
13999 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14219 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14000 14220 | RestJson<L>,
|
14001 14221 | crate::operation_shape::SparseJsonMaps,
|
14002 14222 | ModelPl::Output
|
14003 14223 | >,
|
14004 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14224 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14005 14225 | RestJson<L>,
|
14006 14226 | crate::operation_shape::SparseJsonMaps,
|
14007 14227 | <
|
14008 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14009 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14228 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14229 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14010 14230 | RestJson<L>,
|
14011 14231 | crate::operation_shape::SparseJsonMaps,
|
14012 14232 | ModelPl::Output
|
14013 14233 | >
|
14014 14234 | >::Output
|
14015 14235 | >,
|
14016 14236 |
|
14017 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14237 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14018 14238 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14019 14239 |
|
14020 14240 | {
|
14021 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14022 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14241 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14242 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14023 14243 | let svc = crate::operation_shape::SparseJsonMaps::from_handler(handler);
|
14024 14244 | let svc = self.model_plugin.apply(svc);
|
14025 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14245 + | let svc =
|
14246 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14026 14247 | .apply(svc);
|
14027 14248 | let svc = self.http_plugin.apply(svc);
|
14028 14249 | self.sparse_json_maps_custom(svc)
|
14029 14250 | }
|
14030 14251 |
|
14031 14252 | /// Sets the [`SparseJsonMaps`](crate::operation_shape::SparseJsonMaps) operation.
|
14032 14253 | ///
|
14033 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14034 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14254 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14255 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14035 14256 | ///
|
14036 14257 | /// # Example
|
14037 14258 | ///
|
14038 14259 | /// ```no_run
|
14039 14260 | /// use rest_json::{RestJson, RestJsonConfig};
|
14040 14261 | ///
|
14041 14262 | /// use rest_json::{input, output, error};
|
14042 14263 | ///
|
14043 14264 | /// async fn handler(input: input::SparseJsonMapsInput) -> Result<output::SparseJsonMapsOutput, error::SparseJsonMapsError> {
|
14044 14265 | /// todo!()
|
14045 14266 | /// }
|
14046 14267 | ///
|
14047 14268 | /// let config = RestJsonConfig::builder().build();
|
14048 14269 | /// let svc = ::tower::util::service_fn(handler);
|
14049 14270 | /// let app = RestJson::builder(config)
|
14050 14271 | /// .sparse_json_maps_service(svc)
|
14051 14272 | /// /* Set other handlers */
|
14052 14273 | /// .build()
|
14053 14274 | /// .unwrap();
|
14054 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14275 + | /// # 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;
|
14055 14276 | /// ```
|
14056 14277 | ///
|
14057 14278 | pub fn sparse_json_maps_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14058 14279 | where
|
14059 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::SparseJsonMaps, ServiceExtractors>,
|
14280 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::SparseJsonMaps, ServiceExtractors>,
|
14060 14281 |
|
14061 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14282 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14062 14283 | RestJson<L>,
|
14063 14284 | crate::operation_shape::SparseJsonMaps,
|
14064 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::SparseJsonMaps, S>
|
14285 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::SparseJsonMaps, S>
|
14065 14286 | >,
|
14066 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14287 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14067 14288 | RestJson<L>,
|
14068 14289 | crate::operation_shape::SparseJsonMaps,
|
14069 14290 | ModelPl::Output
|
14070 14291 | >,
|
14071 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14292 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14072 14293 | RestJson<L>,
|
14073 14294 | crate::operation_shape::SparseJsonMaps,
|
14074 14295 | <
|
14075 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14076 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14296 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14297 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14077 14298 | RestJson<L>,
|
14078 14299 | crate::operation_shape::SparseJsonMaps,
|
14079 14300 | ModelPl::Output
|
14080 14301 | >
|
14081 14302 | >::Output
|
14082 14303 | >,
|
14083 14304 |
|
14084 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14305 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14085 14306 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14086 14307 |
|
14087 14308 | {
|
14088 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14089 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14309 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14310 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14090 14311 | let svc = crate::operation_shape::SparseJsonMaps::from_service(service);
|
14091 14312 | let svc = self.model_plugin.apply(svc);
|
14092 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14313 + | let svc =
|
14314 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14093 14315 | .apply(svc);
|
14094 14316 | let svc = self.http_plugin.apply(svc);
|
14095 14317 | self.sparse_json_maps_custom(svc)
|
14096 14318 | }
|
14097 14319 |
|
14098 14320 | /// Sets the [`SparseJsonMaps`](crate::operation_shape::SparseJsonMaps) to a custom [`Service`](tower::Service).
|
14099 14321 | /// not constrained by the Smithy contract.
|
14100 14322 | fn sparse_json_maps_custom<S>(mut self, svc: S) -> Self
|
14101 14323 | where
|
14102 14324 | S: ::tower::Service<
|
14103 14325 | ::http::Request<Body>,
|
14104 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14326 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14105 14327 | Error = ::std::convert::Infallible,
|
14106 14328 | > + Clone
|
14107 14329 | + Send
|
14108 14330 | + 'static,
|
14109 14331 | S::Future: Send + 'static,
|
14110 14332 | {
|
14111 - | self.sparse_json_maps = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14333 + | self.sparse_json_maps = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14112 14334 | self
|
14113 14335 | }
|
14114 14336 |
|
14115 14337 | /// Sets the [`StreamingTraits`](crate::operation_shape::StreamingTraits) operation.
|
14116 14338 | ///
|
14117 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14118 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14339 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14340 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14119 14341 | ///
|
14120 14342 | /// # Example
|
14121 14343 | ///
|
14122 14344 | /// ```no_run
|
14123 14345 | /// use rest_json::{RestJson, RestJsonConfig};
|
14124 14346 | ///
|
14125 14347 | /// use rest_json::{input, output, error};
|
14126 14348 | ///
|
14127 14349 | /// async fn handler(input: input::StreamingTraitsInput) -> Result<output::StreamingTraitsOutput, error::StreamingTraitsError> {
|
14128 14350 | /// todo!()
|
14129 14351 | /// }
|
14130 14352 | ///
|
14131 14353 | /// let config = RestJsonConfig::builder().build();
|
14132 14354 | /// let app = RestJson::builder(config)
|
14133 14355 | /// .streaming_traits(handler)
|
14134 14356 | /// /* Set other handlers */
|
14135 14357 | /// .build()
|
14136 14358 | /// .unwrap();
|
14137 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14359 + | /// # 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;
|
14138 14360 | /// ```
|
14139 14361 | ///
|
14140 14362 | pub fn streaming_traits<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14141 14363 | where
|
14142 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::StreamingTraits, HandlerExtractors>,
|
14364 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::StreamingTraits, HandlerExtractors>,
|
14143 14365 |
|
14144 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14366 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14145 14367 | RestJson<L>,
|
14146 14368 | crate::operation_shape::StreamingTraits,
|
14147 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::StreamingTraits, HandlerType>
|
14369 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::StreamingTraits, HandlerType>
|
14148 14370 | >,
|
14149 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14371 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14150 14372 | RestJson<L>,
|
14151 14373 | crate::operation_shape::StreamingTraits,
|
14152 14374 | ModelPl::Output
|
14153 14375 | >,
|
14154 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14376 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14155 14377 | RestJson<L>,
|
14156 14378 | crate::operation_shape::StreamingTraits,
|
14157 14379 | <
|
14158 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14159 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14380 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14381 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14160 14382 | RestJson<L>,
|
14161 14383 | crate::operation_shape::StreamingTraits,
|
14162 14384 | ModelPl::Output
|
14163 14385 | >
|
14164 14386 | >::Output
|
14165 14387 | >,
|
14166 14388 |
|
14167 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14389 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14168 14390 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14169 14391 |
|
14170 14392 | {
|
14171 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14172 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14393 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14394 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14173 14395 | let svc = crate::operation_shape::StreamingTraits::from_handler(handler);
|
14174 14396 | let svc = self.model_plugin.apply(svc);
|
14175 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14397 + | let svc =
|
14398 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14176 14399 | .apply(svc);
|
14177 14400 | let svc = self.http_plugin.apply(svc);
|
14178 14401 | self.streaming_traits_custom(svc)
|
14179 14402 | }
|
14180 14403 |
|
14181 14404 | /// Sets the [`StreamingTraits`](crate::operation_shape::StreamingTraits) operation.
|
14182 14405 | ///
|
14183 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14184 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14406 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14407 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14185 14408 | ///
|
14186 14409 | /// # Example
|
14187 14410 | ///
|
14188 14411 | /// ```no_run
|
14189 14412 | /// use rest_json::{RestJson, RestJsonConfig};
|
14190 14413 | ///
|
14191 14414 | /// use rest_json::{input, output, error};
|
14192 14415 | ///
|
14193 14416 | /// async fn handler(input: input::StreamingTraitsInput) -> Result<output::StreamingTraitsOutput, error::StreamingTraitsError> {
|
14194 14417 | /// todo!()
|
14195 14418 | /// }
|
14196 14419 | ///
|
14197 14420 | /// let config = RestJsonConfig::builder().build();
|
14198 14421 | /// let svc = ::tower::util::service_fn(handler);
|
14199 14422 | /// let app = RestJson::builder(config)
|
14200 14423 | /// .streaming_traits_service(svc)
|
14201 14424 | /// /* Set other handlers */
|
14202 14425 | /// .build()
|
14203 14426 | /// .unwrap();
|
14204 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14427 + | /// # 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;
|
14205 14428 | /// ```
|
14206 14429 | ///
|
14207 14430 | pub fn streaming_traits_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14208 14431 | where
|
14209 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::StreamingTraits, ServiceExtractors>,
|
14432 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::StreamingTraits, ServiceExtractors>,
|
14210 14433 |
|
14211 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14434 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14212 14435 | RestJson<L>,
|
14213 14436 | crate::operation_shape::StreamingTraits,
|
14214 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::StreamingTraits, S>
|
14437 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::StreamingTraits, S>
|
14215 14438 | >,
|
14216 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14439 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14217 14440 | RestJson<L>,
|
14218 14441 | crate::operation_shape::StreamingTraits,
|
14219 14442 | ModelPl::Output
|
14220 14443 | >,
|
14221 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14444 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14222 14445 | RestJson<L>,
|
14223 14446 | crate::operation_shape::StreamingTraits,
|
14224 14447 | <
|
14225 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14226 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14448 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14449 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14227 14450 | RestJson<L>,
|
14228 14451 | crate::operation_shape::StreamingTraits,
|
14229 14452 | ModelPl::Output
|
14230 14453 | >
|
14231 14454 | >::Output
|
14232 14455 | >,
|
14233 14456 |
|
14234 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14457 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14235 14458 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14236 14459 |
|
14237 14460 | {
|
14238 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14239 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14461 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14462 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14240 14463 | let svc = crate::operation_shape::StreamingTraits::from_service(service);
|
14241 14464 | let svc = self.model_plugin.apply(svc);
|
14242 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14465 + | let svc =
|
14466 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14243 14467 | .apply(svc);
|
14244 14468 | let svc = self.http_plugin.apply(svc);
|
14245 14469 | self.streaming_traits_custom(svc)
|
14246 14470 | }
|
14247 14471 |
|
14248 14472 | /// Sets the [`StreamingTraits`](crate::operation_shape::StreamingTraits) to a custom [`Service`](tower::Service).
|
14249 14473 | /// not constrained by the Smithy contract.
|
14250 14474 | fn streaming_traits_custom<S>(mut self, svc: S) -> Self
|
14251 14475 | where
|
14252 14476 | S: ::tower::Service<
|
14253 14477 | ::http::Request<Body>,
|
14254 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14478 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14255 14479 | Error = ::std::convert::Infallible,
|
14256 14480 | > + Clone
|
14257 14481 | + Send
|
14258 14482 | + 'static,
|
14259 14483 | S::Future: Send + 'static,
|
14260 14484 | {
|
14261 - | self.streaming_traits = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14485 + | self.streaming_traits = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14262 14486 | self
|
14263 14487 | }
|
14264 14488 |
|
14265 14489 | /// Sets the [`StreamingTraitsRequireLength`](crate::operation_shape::StreamingTraitsRequireLength) operation.
|
14266 14490 | ///
|
14267 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14268 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14491 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14492 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14269 14493 | ///
|
14270 14494 | /// # Example
|
14271 14495 | ///
|
14272 14496 | /// ```no_run
|
14273 14497 | /// use rest_json::{RestJson, RestJsonConfig};
|
14274 14498 | ///
|
14275 14499 | /// use rest_json::{input, output, error};
|
14276 14500 | ///
|
14277 14501 | /// async fn handler(input: input::StreamingTraitsRequireLengthInput) -> Result<output::StreamingTraitsRequireLengthOutput, error::StreamingTraitsRequireLengthError> {
|
14278 14502 | /// todo!()
|
14279 14503 | /// }
|
14280 14504 | ///
|
14281 14505 | /// let config = RestJsonConfig::builder().build();
|
14282 14506 | /// let app = RestJson::builder(config)
|
14283 14507 | /// .streaming_traits_require_length(handler)
|
14284 14508 | /// /* Set other handlers */
|
14285 14509 | /// .build()
|
14286 14510 | /// .unwrap();
|
14287 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14511 + | /// # 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;
|
14288 14512 | /// ```
|
14289 14513 | ///
|
14290 14514 | pub fn streaming_traits_require_length<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14291 14515 | where
|
14292 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::StreamingTraitsRequireLength, HandlerExtractors>,
|
14516 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::StreamingTraitsRequireLength, HandlerExtractors>,
|
14293 14517 |
|
14294 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14518 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14295 14519 | RestJson<L>,
|
14296 14520 | crate::operation_shape::StreamingTraitsRequireLength,
|
14297 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::StreamingTraitsRequireLength, HandlerType>
|
14521 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::StreamingTraitsRequireLength, HandlerType>
|
14298 14522 | >,
|
14299 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14523 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14300 14524 | RestJson<L>,
|
14301 14525 | crate::operation_shape::StreamingTraitsRequireLength,
|
14302 14526 | ModelPl::Output
|
14303 14527 | >,
|
14304 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14528 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14305 14529 | RestJson<L>,
|
14306 14530 | crate::operation_shape::StreamingTraitsRequireLength,
|
14307 14531 | <
|
14308 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14309 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14532 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14533 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14310 14534 | RestJson<L>,
|
14311 14535 | crate::operation_shape::StreamingTraitsRequireLength,
|
14312 14536 | ModelPl::Output
|
14313 14537 | >
|
14314 14538 | >::Output
|
14315 14539 | >,
|
14316 14540 |
|
14317 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14541 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14318 14542 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14319 14543 |
|
14320 14544 | {
|
14321 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14322 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14545 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14546 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14323 14547 | let svc = crate::operation_shape::StreamingTraitsRequireLength::from_handler(handler);
|
14324 14548 | let svc = self.model_plugin.apply(svc);
|
14325 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14549 + | let svc =
|
14550 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14326 14551 | .apply(svc);
|
14327 14552 | let svc = self.http_plugin.apply(svc);
|
14328 14553 | self.streaming_traits_require_length_custom(svc)
|
14329 14554 | }
|
14330 14555 |
|
14331 14556 | /// Sets the [`StreamingTraitsRequireLength`](crate::operation_shape::StreamingTraitsRequireLength) operation.
|
14332 14557 | ///
|
14333 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14334 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14558 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14559 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14335 14560 | ///
|
14336 14561 | /// # Example
|
14337 14562 | ///
|
14338 14563 | /// ```no_run
|
14339 14564 | /// use rest_json::{RestJson, RestJsonConfig};
|
14340 14565 | ///
|
14341 14566 | /// use rest_json::{input, output, error};
|
14342 14567 | ///
|
14343 14568 | /// async fn handler(input: input::StreamingTraitsRequireLengthInput) -> Result<output::StreamingTraitsRequireLengthOutput, error::StreamingTraitsRequireLengthError> {
|
14344 14569 | /// todo!()
|
14345 14570 | /// }
|
14346 14571 | ///
|
14347 14572 | /// let config = RestJsonConfig::builder().build();
|
14348 14573 | /// let svc = ::tower::util::service_fn(handler);
|
14349 14574 | /// let app = RestJson::builder(config)
|
14350 14575 | /// .streaming_traits_require_length_service(svc)
|
14351 14576 | /// /* Set other handlers */
|
14352 14577 | /// .build()
|
14353 14578 | /// .unwrap();
|
14354 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14579 + | /// # 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;
|
14355 14580 | /// ```
|
14356 14581 | ///
|
14357 14582 | pub fn streaming_traits_require_length_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14358 14583 | where
|
14359 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::StreamingTraitsRequireLength, ServiceExtractors>,
|
14584 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::StreamingTraitsRequireLength, ServiceExtractors>,
|
14360 14585 |
|
14361 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14586 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14362 14587 | RestJson<L>,
|
14363 14588 | crate::operation_shape::StreamingTraitsRequireLength,
|
14364 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::StreamingTraitsRequireLength, S>
|
14589 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::StreamingTraitsRequireLength, S>
|
14365 14590 | >,
|
14366 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14591 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14367 14592 | RestJson<L>,
|
14368 14593 | crate::operation_shape::StreamingTraitsRequireLength,
|
14369 14594 | ModelPl::Output
|
14370 14595 | >,
|
14371 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14596 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14372 14597 | RestJson<L>,
|
14373 14598 | crate::operation_shape::StreamingTraitsRequireLength,
|
14374 14599 | <
|
14375 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14376 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14600 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14601 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14377 14602 | RestJson<L>,
|
14378 14603 | crate::operation_shape::StreamingTraitsRequireLength,
|
14379 14604 | ModelPl::Output
|
14380 14605 | >
|
14381 14606 | >::Output
|
14382 14607 | >,
|
14383 14608 |
|
14384 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14609 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14385 14610 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14386 14611 |
|
14387 14612 | {
|
14388 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14389 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14613 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14614 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14390 14615 | let svc = crate::operation_shape::StreamingTraitsRequireLength::from_service(service);
|
14391 14616 | let svc = self.model_plugin.apply(svc);
|
14392 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14617 + | let svc =
|
14618 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14393 14619 | .apply(svc);
|
14394 14620 | let svc = self.http_plugin.apply(svc);
|
14395 14621 | self.streaming_traits_require_length_custom(svc)
|
14396 14622 | }
|
14397 14623 |
|
14398 14624 | /// Sets the [`StreamingTraitsRequireLength`](crate::operation_shape::StreamingTraitsRequireLength) to a custom [`Service`](tower::Service).
|
14399 14625 | /// not constrained by the Smithy contract.
|
14400 14626 | fn streaming_traits_require_length_custom<S>(mut self, svc: S) -> Self
|
14401 14627 | where
|
14402 14628 | S: ::tower::Service<
|
14403 14629 | ::http::Request<Body>,
|
14404 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14630 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14405 14631 | Error = ::std::convert::Infallible,
|
14406 14632 | > + Clone
|
14407 14633 | + Send
|
14408 14634 | + 'static,
|
14409 14635 | S::Future: Send + 'static,
|
14410 14636 | {
|
14411 14637 | self.streaming_traits_require_length =
|
14412 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14638 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14413 14639 | self
|
14414 14640 | }
|
14415 14641 |
|
14416 14642 | /// Sets the [`StreamingTraitsWithMediaType`](crate::operation_shape::StreamingTraitsWithMediaType) operation.
|
14417 14643 | ///
|
14418 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14419 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14644 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14645 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14420 14646 | ///
|
14421 14647 | /// # Example
|
14422 14648 | ///
|
14423 14649 | /// ```no_run
|
14424 14650 | /// use rest_json::{RestJson, RestJsonConfig};
|
14425 14651 | ///
|
14426 14652 | /// use rest_json::{input, output, error};
|
14427 14653 | ///
|
14428 14654 | /// async fn handler(input: input::StreamingTraitsWithMediaTypeInput) -> Result<output::StreamingTraitsWithMediaTypeOutput, error::StreamingTraitsWithMediaTypeError> {
|
14429 14655 | /// todo!()
|
14430 14656 | /// }
|
14431 14657 | ///
|
14432 14658 | /// let config = RestJsonConfig::builder().build();
|
14433 14659 | /// let app = RestJson::builder(config)
|
14434 14660 | /// .streaming_traits_with_media_type(handler)
|
14435 14661 | /// /* Set other handlers */
|
14436 14662 | /// .build()
|
14437 14663 | /// .unwrap();
|
14438 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14664 + | /// # 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;
|
14439 14665 | /// ```
|
14440 14666 | ///
|
14441 14667 | pub fn streaming_traits_with_media_type<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14442 14668 | where
|
14443 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::StreamingTraitsWithMediaType, HandlerExtractors>,
|
14669 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::StreamingTraitsWithMediaType, HandlerExtractors>,
|
14444 14670 |
|
14445 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14671 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14446 14672 | RestJson<L>,
|
14447 14673 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14448 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::StreamingTraitsWithMediaType, HandlerType>
|
14674 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::StreamingTraitsWithMediaType, HandlerType>
|
14449 14675 | >,
|
14450 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14676 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14451 14677 | RestJson<L>,
|
14452 14678 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14453 14679 | ModelPl::Output
|
14454 14680 | >,
|
14455 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14681 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14456 14682 | RestJson<L>,
|
14457 14683 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14458 14684 | <
|
14459 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14460 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14685 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14686 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14461 14687 | RestJson<L>,
|
14462 14688 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14463 14689 | ModelPl::Output
|
14464 14690 | >
|
14465 14691 | >::Output
|
14466 14692 | >,
|
14467 14693 |
|
14468 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14694 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14469 14695 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14470 14696 |
|
14471 14697 | {
|
14472 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14473 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14698 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14699 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14474 14700 | let svc = crate::operation_shape::StreamingTraitsWithMediaType::from_handler(handler);
|
14475 14701 | let svc = self.model_plugin.apply(svc);
|
14476 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14702 + | let svc =
|
14703 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14477 14704 | .apply(svc);
|
14478 14705 | let svc = self.http_plugin.apply(svc);
|
14479 14706 | self.streaming_traits_with_media_type_custom(svc)
|
14480 14707 | }
|
14481 14708 |
|
14482 14709 | /// Sets the [`StreamingTraitsWithMediaType`](crate::operation_shape::StreamingTraitsWithMediaType) operation.
|
14483 14710 | ///
|
14484 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14485 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14711 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14712 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14486 14713 | ///
|
14487 14714 | /// # Example
|
14488 14715 | ///
|
14489 14716 | /// ```no_run
|
14490 14717 | /// use rest_json::{RestJson, RestJsonConfig};
|
14491 14718 | ///
|
14492 14719 | /// use rest_json::{input, output, error};
|
14493 14720 | ///
|
14494 14721 | /// async fn handler(input: input::StreamingTraitsWithMediaTypeInput) -> Result<output::StreamingTraitsWithMediaTypeOutput, error::StreamingTraitsWithMediaTypeError> {
|
14495 14722 | /// todo!()
|
14496 14723 | /// }
|
14497 14724 | ///
|
14498 14725 | /// let config = RestJsonConfig::builder().build();
|
14499 14726 | /// let svc = ::tower::util::service_fn(handler);
|
14500 14727 | /// let app = RestJson::builder(config)
|
14501 14728 | /// .streaming_traits_with_media_type_service(svc)
|
14502 14729 | /// /* Set other handlers */
|
14503 14730 | /// .build()
|
14504 14731 | /// .unwrap();
|
14505 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14732 + | /// # 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;
|
14506 14733 | /// ```
|
14507 14734 | ///
|
14508 14735 | pub fn streaming_traits_with_media_type_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14509 14736 | where
|
14510 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::StreamingTraitsWithMediaType, ServiceExtractors>,
|
14737 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::StreamingTraitsWithMediaType, ServiceExtractors>,
|
14511 14738 |
|
14512 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14739 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14513 14740 | RestJson<L>,
|
14514 14741 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14515 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::StreamingTraitsWithMediaType, S>
|
14742 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::StreamingTraitsWithMediaType, S>
|
14516 14743 | >,
|
14517 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14744 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14518 14745 | RestJson<L>,
|
14519 14746 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14520 14747 | ModelPl::Output
|
14521 14748 | >,
|
14522 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14749 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14523 14750 | RestJson<L>,
|
14524 14751 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14525 14752 | <
|
14526 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14527 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14753 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14754 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14528 14755 | RestJson<L>,
|
14529 14756 | crate::operation_shape::StreamingTraitsWithMediaType,
|
14530 14757 | ModelPl::Output
|
14531 14758 | >
|
14532 14759 | >::Output
|
14533 14760 | >,
|
14534 14761 |
|
14535 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14762 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14536 14763 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14537 14764 |
|
14538 14765 | {
|
14539 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14540 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14766 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14767 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14541 14768 | let svc = crate::operation_shape::StreamingTraitsWithMediaType::from_service(service);
|
14542 14769 | let svc = self.model_plugin.apply(svc);
|
14543 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14770 + | let svc =
|
14771 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14544 14772 | .apply(svc);
|
14545 14773 | let svc = self.http_plugin.apply(svc);
|
14546 14774 | self.streaming_traits_with_media_type_custom(svc)
|
14547 14775 | }
|
14548 14776 |
|
14549 14777 | /// Sets the [`StreamingTraitsWithMediaType`](crate::operation_shape::StreamingTraitsWithMediaType) to a custom [`Service`](tower::Service).
|
14550 14778 | /// not constrained by the Smithy contract.
|
14551 14779 | fn streaming_traits_with_media_type_custom<S>(mut self, svc: S) -> Self
|
14552 14780 | where
|
14553 14781 | S: ::tower::Service<
|
14554 14782 | ::http::Request<Body>,
|
14555 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14783 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14556 14784 | Error = ::std::convert::Infallible,
|
14557 14785 | > + Clone
|
14558 14786 | + Send
|
14559 14787 | + 'static,
|
14560 14788 | S::Future: Send + 'static,
|
14561 14789 | {
|
14562 14790 | self.streaming_traits_with_media_type =
|
14563 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14791 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14564 14792 | self
|
14565 14793 | }
|
14566 14794 |
|
14567 14795 | /// Sets the [`TestBodyStructure`](crate::operation_shape::TestBodyStructure) operation.
|
14568 14796 | ///
|
14569 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14570 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14797 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14798 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14571 14799 | ///
|
14572 14800 | /// # Example
|
14573 14801 | ///
|
14574 14802 | /// ```no_run
|
14575 14803 | /// use rest_json::{RestJson, RestJsonConfig};
|
14576 14804 | ///
|
14577 14805 | /// use rest_json::{input, output, error};
|
14578 14806 | ///
|
14579 14807 | /// async fn handler(input: input::TestBodyStructureInput) -> Result<output::TestBodyStructureOutput, error::TestBodyStructureError> {
|
14580 14808 | /// todo!()
|
14581 14809 | /// }
|
14582 14810 | ///
|
14583 14811 | /// let config = RestJsonConfig::builder().build();
|
14584 14812 | /// let app = RestJson::builder(config)
|
14585 14813 | /// .test_body_structure(handler)
|
14586 14814 | /// /* Set other handlers */
|
14587 14815 | /// .build()
|
14588 14816 | /// .unwrap();
|
14589 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14817 + | /// # 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;
|
14590 14818 | /// ```
|
14591 14819 | ///
|
14592 14820 | pub fn test_body_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14593 14821 | where
|
14594 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestBodyStructure, HandlerExtractors>,
|
14822 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestBodyStructure, HandlerExtractors>,
|
14595 14823 |
|
14596 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14824 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14597 14825 | RestJson<L>,
|
14598 14826 | crate::operation_shape::TestBodyStructure,
|
14599 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestBodyStructure, HandlerType>
|
14827 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestBodyStructure, HandlerType>
|
14600 14828 | >,
|
14601 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14829 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14602 14830 | RestJson<L>,
|
14603 14831 | crate::operation_shape::TestBodyStructure,
|
14604 14832 | ModelPl::Output
|
14605 14833 | >,
|
14606 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14834 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14607 14835 | RestJson<L>,
|
14608 14836 | crate::operation_shape::TestBodyStructure,
|
14609 14837 | <
|
14610 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14611 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14838 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14839 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14612 14840 | RestJson<L>,
|
14613 14841 | crate::operation_shape::TestBodyStructure,
|
14614 14842 | ModelPl::Output
|
14615 14843 | >
|
14616 14844 | >::Output
|
14617 14845 | >,
|
14618 14846 |
|
14619 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14847 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14620 14848 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14621 14849 |
|
14622 14850 | {
|
14623 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14624 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14851 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14852 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14625 14853 | let svc = crate::operation_shape::TestBodyStructure::from_handler(handler);
|
14626 14854 | let svc = self.model_plugin.apply(svc);
|
14627 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14855 + | let svc =
|
14856 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14628 14857 | .apply(svc);
|
14629 14858 | let svc = self.http_plugin.apply(svc);
|
14630 14859 | self.test_body_structure_custom(svc)
|
14631 14860 | }
|
14632 14861 |
|
14633 14862 | /// Sets the [`TestBodyStructure`](crate::operation_shape::TestBodyStructure) operation.
|
14634 14863 | ///
|
14635 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14636 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14864 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14865 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14637 14866 | ///
|
14638 14867 | /// # Example
|
14639 14868 | ///
|
14640 14869 | /// ```no_run
|
14641 14870 | /// use rest_json::{RestJson, RestJsonConfig};
|
14642 14871 | ///
|
14643 14872 | /// use rest_json::{input, output, error};
|
14644 14873 | ///
|
14645 14874 | /// async fn handler(input: input::TestBodyStructureInput) -> Result<output::TestBodyStructureOutput, error::TestBodyStructureError> {
|
14646 14875 | /// todo!()
|
14647 14876 | /// }
|
14648 14877 | ///
|
14649 14878 | /// let config = RestJsonConfig::builder().build();
|
14650 14879 | /// let svc = ::tower::util::service_fn(handler);
|
14651 14880 | /// let app = RestJson::builder(config)
|
14652 14881 | /// .test_body_structure_service(svc)
|
14653 14882 | /// /* Set other handlers */
|
14654 14883 | /// .build()
|
14655 14884 | /// .unwrap();
|
14656 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14885 + | /// # 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;
|
14657 14886 | /// ```
|
14658 14887 | ///
|
14659 14888 | pub fn test_body_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14660 14889 | where
|
14661 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestBodyStructure, ServiceExtractors>,
|
14890 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestBodyStructure, ServiceExtractors>,
|
14662 14891 |
|
14663 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14892 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14664 14893 | RestJson<L>,
|
14665 14894 | crate::operation_shape::TestBodyStructure,
|
14666 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestBodyStructure, S>
|
14895 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestBodyStructure, S>
|
14667 14896 | >,
|
14668 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14897 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14669 14898 | RestJson<L>,
|
14670 14899 | crate::operation_shape::TestBodyStructure,
|
14671 14900 | ModelPl::Output
|
14672 14901 | >,
|
14673 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14902 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14674 14903 | RestJson<L>,
|
14675 14904 | crate::operation_shape::TestBodyStructure,
|
14676 14905 | <
|
14677 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14678 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14906 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14907 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14679 14908 | RestJson<L>,
|
14680 14909 | crate::operation_shape::TestBodyStructure,
|
14681 14910 | ModelPl::Output
|
14682 14911 | >
|
14683 14912 | >::Output
|
14684 14913 | >,
|
14685 14914 |
|
14686 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14915 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14687 14916 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14688 14917 |
|
14689 14918 | {
|
14690 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14691 - | use ::aws_smithy_http_server::plugin::Plugin;
|
14919 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
14920 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14692 14921 | let svc = crate::operation_shape::TestBodyStructure::from_service(service);
|
14693 14922 | let svc = self.model_plugin.apply(svc);
|
14694 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14923 + | let svc =
|
14924 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14695 14925 | .apply(svc);
|
14696 14926 | let svc = self.http_plugin.apply(svc);
|
14697 14927 | self.test_body_structure_custom(svc)
|
14698 14928 | }
|
14699 14929 |
|
14700 14930 | /// Sets the [`TestBodyStructure`](crate::operation_shape::TestBodyStructure) to a custom [`Service`](tower::Service).
|
14701 14931 | /// not constrained by the Smithy contract.
|
14702 14932 | fn test_body_structure_custom<S>(mut self, svc: S) -> Self
|
14703 14933 | where
|
14704 14934 | S: ::tower::Service<
|
14705 14935 | ::http::Request<Body>,
|
14706 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
14936 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14707 14937 | Error = ::std::convert::Infallible,
|
14708 14938 | > + Clone
|
14709 14939 | + Send
|
14710 14940 | + 'static,
|
14711 14941 | S::Future: Send + 'static,
|
14712 14942 | {
|
14713 - | self.test_body_structure = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
14943 + | self.test_body_structure = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14714 14944 | self
|
14715 14945 | }
|
14716 14946 |
|
14717 14947 | /// Sets the [`TestGetNoInputNoPayload`](crate::operation_shape::TestGetNoInputNoPayload) operation.
|
14718 14948 | ///
|
14719 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14720 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
14949 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
14950 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14721 14951 | ///
|
14722 14952 | /// # Example
|
14723 14953 | ///
|
14724 14954 | /// ```no_run
|
14725 14955 | /// use rest_json::{RestJson, RestJsonConfig};
|
14726 14956 | ///
|
14727 14957 | /// use rest_json::{input, output, error};
|
14728 14958 | ///
|
14729 14959 | /// async fn handler(input: input::TestGetNoInputNoPayloadInput) -> Result<output::TestGetNoInputNoPayloadOutput, error::TestGetNoInputNoPayloadError> {
|
14730 14960 | /// todo!()
|
14731 14961 | /// }
|
14732 14962 | ///
|
14733 14963 | /// let config = RestJsonConfig::builder().build();
|
14734 14964 | /// let app = RestJson::builder(config)
|
14735 14965 | /// .test_get_no_input_no_payload(handler)
|
14736 14966 | /// /* Set other handlers */
|
14737 14967 | /// .build()
|
14738 14968 | /// .unwrap();
|
14739 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
14969 + | /// # 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;
|
14740 14970 | /// ```
|
14741 14971 | ///
|
14742 14972 | pub fn test_get_no_input_no_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14743 14973 | where
|
14744 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestGetNoInputNoPayload, HandlerExtractors>,
|
14974 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestGetNoInputNoPayload, HandlerExtractors>,
|
14745 14975 |
|
14746 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
14976 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14747 14977 | RestJson<L>,
|
14748 14978 | crate::operation_shape::TestGetNoInputNoPayload,
|
14749 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestGetNoInputNoPayload, HandlerType>
|
14979 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestGetNoInputNoPayload, HandlerType>
|
14750 14980 | >,
|
14751 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
14981 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14752 14982 | RestJson<L>,
|
14753 14983 | crate::operation_shape::TestGetNoInputNoPayload,
|
14754 14984 | ModelPl::Output
|
14755 14985 | >,
|
14756 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
14986 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14757 14987 | RestJson<L>,
|
14758 14988 | crate::operation_shape::TestGetNoInputNoPayload,
|
14759 14989 | <
|
14760 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14761 - | as ::aws_smithy_http_server::plugin::Plugin<
|
14990 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14991 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14762 14992 | RestJson<L>,
|
14763 14993 | crate::operation_shape::TestGetNoInputNoPayload,
|
14764 14994 | ModelPl::Output
|
14765 14995 | >
|
14766 14996 | >::Output
|
14767 14997 | >,
|
14768 14998 |
|
14769 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14999 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14770 15000 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14771 15001 |
|
14772 15002 | {
|
14773 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14774 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15003 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15004 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14775 15005 | let svc = crate::operation_shape::TestGetNoInputNoPayload::from_handler(handler);
|
14776 15006 | let svc = self.model_plugin.apply(svc);
|
14777 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15007 + | let svc =
|
15008 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14778 15009 | .apply(svc);
|
14779 15010 | let svc = self.http_plugin.apply(svc);
|
14780 15011 | self.test_get_no_input_no_payload_custom(svc)
|
14781 15012 | }
|
14782 15013 |
|
14783 15014 | /// Sets the [`TestGetNoInputNoPayload`](crate::operation_shape::TestGetNoInputNoPayload) operation.
|
14784 15015 | ///
|
14785 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14786 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15016 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15017 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14787 15018 | ///
|
14788 15019 | /// # Example
|
14789 15020 | ///
|
14790 15021 | /// ```no_run
|
14791 15022 | /// use rest_json::{RestJson, RestJsonConfig};
|
14792 15023 | ///
|
14793 15024 | /// use rest_json::{input, output, error};
|
14794 15025 | ///
|
14795 15026 | /// async fn handler(input: input::TestGetNoInputNoPayloadInput) -> Result<output::TestGetNoInputNoPayloadOutput, error::TestGetNoInputNoPayloadError> {
|
14796 15027 | /// todo!()
|
14797 15028 | /// }
|
14798 15029 | ///
|
14799 15030 | /// let config = RestJsonConfig::builder().build();
|
14800 15031 | /// let svc = ::tower::util::service_fn(handler);
|
14801 15032 | /// let app = RestJson::builder(config)
|
14802 15033 | /// .test_get_no_input_no_payload_service(svc)
|
14803 15034 | /// /* Set other handlers */
|
14804 15035 | /// .build()
|
14805 15036 | /// .unwrap();
|
14806 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15037 + | /// # 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;
|
14807 15038 | /// ```
|
14808 15039 | ///
|
14809 15040 | pub fn test_get_no_input_no_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14810 15041 | where
|
14811 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestGetNoInputNoPayload, ServiceExtractors>,
|
15042 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestGetNoInputNoPayload, ServiceExtractors>,
|
14812 15043 |
|
14813 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15044 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14814 15045 | RestJson<L>,
|
14815 15046 | crate::operation_shape::TestGetNoInputNoPayload,
|
14816 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestGetNoInputNoPayload, S>
|
15047 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestGetNoInputNoPayload, S>
|
14817 15048 | >,
|
14818 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15049 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14819 15050 | RestJson<L>,
|
14820 15051 | crate::operation_shape::TestGetNoInputNoPayload,
|
14821 15052 | ModelPl::Output
|
14822 15053 | >,
|
14823 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15054 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14824 15055 | RestJson<L>,
|
14825 15056 | crate::operation_shape::TestGetNoInputNoPayload,
|
14826 15057 | <
|
14827 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14828 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15058 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15059 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14829 15060 | RestJson<L>,
|
14830 15061 | crate::operation_shape::TestGetNoInputNoPayload,
|
14831 15062 | ModelPl::Output
|
14832 15063 | >
|
14833 15064 | >::Output
|
14834 15065 | >,
|
14835 15066 |
|
14836 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15067 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14837 15068 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14838 15069 |
|
14839 15070 | {
|
14840 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14841 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15071 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15072 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14842 15073 | let svc = crate::operation_shape::TestGetNoInputNoPayload::from_service(service);
|
14843 15074 | let svc = self.model_plugin.apply(svc);
|
14844 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15075 + | let svc =
|
15076 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14845 15077 | .apply(svc);
|
14846 15078 | let svc = self.http_plugin.apply(svc);
|
14847 15079 | self.test_get_no_input_no_payload_custom(svc)
|
14848 15080 | }
|
14849 15081 |
|
14850 15082 | /// Sets the [`TestGetNoInputNoPayload`](crate::operation_shape::TestGetNoInputNoPayload) to a custom [`Service`](tower::Service).
|
14851 15083 | /// not constrained by the Smithy contract.
|
14852 15084 | fn test_get_no_input_no_payload_custom<S>(mut self, svc: S) -> Self
|
14853 15085 | where
|
14854 15086 | S: ::tower::Service<
|
14855 15087 | ::http::Request<Body>,
|
14856 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15088 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
14857 15089 | Error = ::std::convert::Infallible,
|
14858 15090 | > + Clone
|
14859 15091 | + Send
|
14860 15092 | + 'static,
|
14861 15093 | S::Future: Send + 'static,
|
14862 15094 | {
|
14863 15095 | self.test_get_no_input_no_payload =
|
14864 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15096 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
14865 15097 | self
|
14866 15098 | }
|
14867 15099 |
|
14868 15100 | /// Sets the [`TestGetNoPayload`](crate::operation_shape::TestGetNoPayload) operation.
|
14869 15101 | ///
|
14870 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14871 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15102 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15103 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14872 15104 | ///
|
14873 15105 | /// # Example
|
14874 15106 | ///
|
14875 15107 | /// ```no_run
|
14876 15108 | /// use rest_json::{RestJson, RestJsonConfig};
|
14877 15109 | ///
|
14878 15110 | /// use rest_json::{input, output, error};
|
14879 15111 | ///
|
14880 15112 | /// async fn handler(input: input::TestGetNoPayloadInput) -> Result<output::TestGetNoPayloadOutput, error::TestGetNoPayloadError> {
|
14881 15113 | /// todo!()
|
14882 15114 | /// }
|
14883 15115 | ///
|
14884 15116 | /// let config = RestJsonConfig::builder().build();
|
14885 15117 | /// let app = RestJson::builder(config)
|
14886 15118 | /// .test_get_no_payload(handler)
|
14887 15119 | /// /* Set other handlers */
|
14888 15120 | /// .build()
|
14889 15121 | /// .unwrap();
|
14890 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15122 + | /// # 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;
|
14891 15123 | /// ```
|
14892 15124 | ///
|
14893 15125 | pub fn test_get_no_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
14894 15126 | where
|
14895 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestGetNoPayload, HandlerExtractors>,
|
15127 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestGetNoPayload, HandlerExtractors>,
|
14896 15128 |
|
14897 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15129 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14898 15130 | RestJson<L>,
|
14899 15131 | crate::operation_shape::TestGetNoPayload,
|
14900 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestGetNoPayload, HandlerType>
|
15132 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestGetNoPayload, HandlerType>
|
14901 15133 | >,
|
14902 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15134 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14903 15135 | RestJson<L>,
|
14904 15136 | crate::operation_shape::TestGetNoPayload,
|
14905 15137 | ModelPl::Output
|
14906 15138 | >,
|
14907 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15139 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14908 15140 | RestJson<L>,
|
14909 15141 | crate::operation_shape::TestGetNoPayload,
|
14910 15142 | <
|
14911 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14912 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15143 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15144 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14913 15145 | RestJson<L>,
|
14914 15146 | crate::operation_shape::TestGetNoPayload,
|
14915 15147 | ModelPl::Output
|
14916 15148 | >
|
14917 15149 | >::Output
|
14918 15150 | >,
|
14919 15151 |
|
14920 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15152 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14921 15153 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14922 15154 |
|
14923 15155 | {
|
14924 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14925 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15156 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15157 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14926 15158 | let svc = crate::operation_shape::TestGetNoPayload::from_handler(handler);
|
14927 15159 | let svc = self.model_plugin.apply(svc);
|
14928 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15160 + | let svc =
|
15161 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14929 15162 | .apply(svc);
|
14930 15163 | let svc = self.http_plugin.apply(svc);
|
14931 15164 | self.test_get_no_payload_custom(svc)
|
14932 15165 | }
|
14933 15166 |
|
14934 15167 | /// Sets the [`TestGetNoPayload`](crate::operation_shape::TestGetNoPayload) operation.
|
14935 15168 | ///
|
14936 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
14937 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15169 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15170 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
14938 15171 | ///
|
14939 15172 | /// # Example
|
14940 15173 | ///
|
14941 15174 | /// ```no_run
|
14942 15175 | /// use rest_json::{RestJson, RestJsonConfig};
|
14943 15176 | ///
|
14944 15177 | /// use rest_json::{input, output, error};
|
14945 15178 | ///
|
14946 15179 | /// async fn handler(input: input::TestGetNoPayloadInput) -> Result<output::TestGetNoPayloadOutput, error::TestGetNoPayloadError> {
|
14947 15180 | /// todo!()
|
14948 15181 | /// }
|
14949 15182 | ///
|
14950 15183 | /// let config = RestJsonConfig::builder().build();
|
14951 15184 | /// let svc = ::tower::util::service_fn(handler);
|
14952 15185 | /// let app = RestJson::builder(config)
|
14953 15186 | /// .test_get_no_payload_service(svc)
|
14954 15187 | /// /* Set other handlers */
|
14955 15188 | /// .build()
|
14956 15189 | /// .unwrap();
|
14957 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15190 + | /// # 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;
|
14958 15191 | /// ```
|
14959 15192 | ///
|
14960 15193 | pub fn test_get_no_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
14961 15194 | where
|
14962 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestGetNoPayload, ServiceExtractors>,
|
15195 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestGetNoPayload, ServiceExtractors>,
|
14963 15196 |
|
14964 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15197 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14965 15198 | RestJson<L>,
|
14966 15199 | crate::operation_shape::TestGetNoPayload,
|
14967 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestGetNoPayload, S>
|
15200 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestGetNoPayload, S>
|
14968 15201 | >,
|
14969 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15202 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14970 15203 | RestJson<L>,
|
14971 15204 | crate::operation_shape::TestGetNoPayload,
|
14972 15205 | ModelPl::Output
|
14973 15206 | >,
|
14974 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15207 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14975 15208 | RestJson<L>,
|
14976 15209 | crate::operation_shape::TestGetNoPayload,
|
14977 15210 | <
|
14978 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
14979 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15211 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15212 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
14980 15213 | RestJson<L>,
|
14981 15214 | crate::operation_shape::TestGetNoPayload,
|
14982 15215 | ModelPl::Output
|
14983 15216 | >
|
14984 15217 | >::Output
|
14985 15218 | >,
|
14986 15219 |
|
14987 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15220 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
14988 15221 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
14989 15222 |
|
14990 15223 | {
|
14991 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
14992 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15224 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15225 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
14993 15226 | let svc = crate::operation_shape::TestGetNoPayload::from_service(service);
|
14994 15227 | let svc = self.model_plugin.apply(svc);
|
14995 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15228 + | let svc =
|
15229 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
14996 15230 | .apply(svc);
|
14997 15231 | let svc = self.http_plugin.apply(svc);
|
14998 15232 | self.test_get_no_payload_custom(svc)
|
14999 15233 | }
|
15000 15234 |
|
15001 15235 | /// Sets the [`TestGetNoPayload`](crate::operation_shape::TestGetNoPayload) to a custom [`Service`](tower::Service).
|
15002 15236 | /// not constrained by the Smithy contract.
|
15003 15237 | fn test_get_no_payload_custom<S>(mut self, svc: S) -> Self
|
15004 15238 | where
|
15005 15239 | S: ::tower::Service<
|
15006 15240 | ::http::Request<Body>,
|
15007 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15241 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15008 15242 | Error = ::std::convert::Infallible,
|
15009 15243 | > + Clone
|
15010 15244 | + Send
|
15011 15245 | + 'static,
|
15012 15246 | S::Future: Send + 'static,
|
15013 15247 | {
|
15014 - | self.test_get_no_payload = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15248 + | self.test_get_no_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15015 15249 | self
|
15016 15250 | }
|
15017 15251 |
|
15018 15252 | /// Sets the [`TestPayloadBlob`](crate::operation_shape::TestPayloadBlob) operation.
|
15019 15253 | ///
|
15020 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15021 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15254 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15255 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15022 15256 | ///
|
15023 15257 | /// # Example
|
15024 15258 | ///
|
15025 15259 | /// ```no_run
|
15026 15260 | /// use rest_json::{RestJson, RestJsonConfig};
|
15027 15261 | ///
|
15028 15262 | /// use rest_json::{input, output, error};
|
15029 15263 | ///
|
15030 15264 | /// async fn handler(input: input::TestPayloadBlobInput) -> Result<output::TestPayloadBlobOutput, error::TestPayloadBlobError> {
|
15031 15265 | /// todo!()
|
15032 15266 | /// }
|
15033 15267 | ///
|
15034 15268 | /// let config = RestJsonConfig::builder().build();
|
15035 15269 | /// let app = RestJson::builder(config)
|
15036 15270 | /// .test_payload_blob(handler)
|
15037 15271 | /// /* Set other handlers */
|
15038 15272 | /// .build()
|
15039 15273 | /// .unwrap();
|
15040 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15274 + | /// # 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;
|
15041 15275 | /// ```
|
15042 15276 | ///
|
15043 15277 | pub fn test_payload_blob<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15044 15278 | where
|
15045 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestPayloadBlob, HandlerExtractors>,
|
15279 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestPayloadBlob, HandlerExtractors>,
|
15046 15280 |
|
15047 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15281 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15048 15282 | RestJson<L>,
|
15049 15283 | crate::operation_shape::TestPayloadBlob,
|
15050 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestPayloadBlob, HandlerType>
|
15284 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestPayloadBlob, HandlerType>
|
15051 15285 | >,
|
15052 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15286 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15053 15287 | RestJson<L>,
|
15054 15288 | crate::operation_shape::TestPayloadBlob,
|
15055 15289 | ModelPl::Output
|
15056 15290 | >,
|
15057 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15291 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15058 15292 | RestJson<L>,
|
15059 15293 | crate::operation_shape::TestPayloadBlob,
|
15060 15294 | <
|
15061 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15062 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15295 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15296 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15063 15297 | RestJson<L>,
|
15064 15298 | crate::operation_shape::TestPayloadBlob,
|
15065 15299 | ModelPl::Output
|
15066 15300 | >
|
15067 15301 | >::Output
|
15068 15302 | >,
|
15069 15303 |
|
15070 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15304 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15071 15305 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15072 15306 |
|
15073 15307 | {
|
15074 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15075 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15308 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15309 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15076 15310 | let svc = crate::operation_shape::TestPayloadBlob::from_handler(handler);
|
15077 15311 | let svc = self.model_plugin.apply(svc);
|
15078 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15312 + | let svc =
|
15313 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15079 15314 | .apply(svc);
|
15080 15315 | let svc = self.http_plugin.apply(svc);
|
15081 15316 | self.test_payload_blob_custom(svc)
|
15082 15317 | }
|
15083 15318 |
|
15084 15319 | /// Sets the [`TestPayloadBlob`](crate::operation_shape::TestPayloadBlob) operation.
|
15085 15320 | ///
|
15086 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15087 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15321 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15322 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15088 15323 | ///
|
15089 15324 | /// # Example
|
15090 15325 | ///
|
15091 15326 | /// ```no_run
|
15092 15327 | /// use rest_json::{RestJson, RestJsonConfig};
|
15093 15328 | ///
|
15094 15329 | /// use rest_json::{input, output, error};
|
15095 15330 | ///
|
15096 15331 | /// async fn handler(input: input::TestPayloadBlobInput) -> Result<output::TestPayloadBlobOutput, error::TestPayloadBlobError> {
|
15097 15332 | /// todo!()
|
15098 15333 | /// }
|
15099 15334 | ///
|
15100 15335 | /// let config = RestJsonConfig::builder().build();
|
15101 15336 | /// let svc = ::tower::util::service_fn(handler);
|
15102 15337 | /// let app = RestJson::builder(config)
|
15103 15338 | /// .test_payload_blob_service(svc)
|
15104 15339 | /// /* Set other handlers */
|
15105 15340 | /// .build()
|
15106 15341 | /// .unwrap();
|
15107 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15342 + | /// # 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;
|
15108 15343 | /// ```
|
15109 15344 | ///
|
15110 15345 | pub fn test_payload_blob_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15111 15346 | where
|
15112 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestPayloadBlob, ServiceExtractors>,
|
15347 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestPayloadBlob, ServiceExtractors>,
|
15113 15348 |
|
15114 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15349 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15115 15350 | RestJson<L>,
|
15116 15351 | crate::operation_shape::TestPayloadBlob,
|
15117 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestPayloadBlob, S>
|
15352 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestPayloadBlob, S>
|
15118 15353 | >,
|
15119 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15354 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15120 15355 | RestJson<L>,
|
15121 15356 | crate::operation_shape::TestPayloadBlob,
|
15122 15357 | ModelPl::Output
|
15123 15358 | >,
|
15124 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15359 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15125 15360 | RestJson<L>,
|
15126 15361 | crate::operation_shape::TestPayloadBlob,
|
15127 15362 | <
|
15128 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15129 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15363 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15364 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15130 15365 | RestJson<L>,
|
15131 15366 | crate::operation_shape::TestPayloadBlob,
|
15132 15367 | ModelPl::Output
|
15133 15368 | >
|
15134 15369 | >::Output
|
15135 15370 | >,
|
15136 15371 |
|
15137 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15372 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15138 15373 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15139 15374 |
|
15140 15375 | {
|
15141 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15142 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15376 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15377 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15143 15378 | let svc = crate::operation_shape::TestPayloadBlob::from_service(service);
|
15144 15379 | let svc = self.model_plugin.apply(svc);
|
15145 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15380 + | let svc =
|
15381 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15146 15382 | .apply(svc);
|
15147 15383 | let svc = self.http_plugin.apply(svc);
|
15148 15384 | self.test_payload_blob_custom(svc)
|
15149 15385 | }
|
15150 15386 |
|
15151 15387 | /// Sets the [`TestPayloadBlob`](crate::operation_shape::TestPayloadBlob) to a custom [`Service`](tower::Service).
|
15152 15388 | /// not constrained by the Smithy contract.
|
15153 15389 | fn test_payload_blob_custom<S>(mut self, svc: S) -> Self
|
15154 15390 | where
|
15155 15391 | S: ::tower::Service<
|
15156 15392 | ::http::Request<Body>,
|
15157 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15393 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15158 15394 | Error = ::std::convert::Infallible,
|
15159 15395 | > + Clone
|
15160 15396 | + Send
|
15161 15397 | + 'static,
|
15162 15398 | S::Future: Send + 'static,
|
15163 15399 | {
|
15164 - | self.test_payload_blob = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15400 + | self.test_payload_blob = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15165 15401 | self
|
15166 15402 | }
|
15167 15403 |
|
15168 15404 | /// Sets the [`TestPayloadStructure`](crate::operation_shape::TestPayloadStructure) operation.
|
15169 15405 | ///
|
15170 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15171 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15406 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15407 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15172 15408 | ///
|
15173 15409 | /// # Example
|
15174 15410 | ///
|
15175 15411 | /// ```no_run
|
15176 15412 | /// use rest_json::{RestJson, RestJsonConfig};
|
15177 15413 | ///
|
15178 15414 | /// use rest_json::{input, output, error};
|
15179 15415 | ///
|
15180 15416 | /// async fn handler(input: input::TestPayloadStructureInput) -> Result<output::TestPayloadStructureOutput, error::TestPayloadStructureError> {
|
15181 15417 | /// todo!()
|
15182 15418 | /// }
|
15183 15419 | ///
|
15184 15420 | /// let config = RestJsonConfig::builder().build();
|
15185 15421 | /// let app = RestJson::builder(config)
|
15186 15422 | /// .test_payload_structure(handler)
|
15187 15423 | /// /* Set other handlers */
|
15188 15424 | /// .build()
|
15189 15425 | /// .unwrap();
|
15190 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15426 + | /// # 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;
|
15191 15427 | /// ```
|
15192 15428 | ///
|
15193 15429 | pub fn test_payload_structure<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15194 15430 | where
|
15195 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestPayloadStructure, HandlerExtractors>,
|
15431 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestPayloadStructure, HandlerExtractors>,
|
15196 15432 |
|
15197 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15433 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15198 15434 | RestJson<L>,
|
15199 15435 | crate::operation_shape::TestPayloadStructure,
|
15200 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestPayloadStructure, HandlerType>
|
15436 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestPayloadStructure, HandlerType>
|
15201 15437 | >,
|
15202 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15438 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15203 15439 | RestJson<L>,
|
15204 15440 | crate::operation_shape::TestPayloadStructure,
|
15205 15441 | ModelPl::Output
|
15206 15442 | >,
|
15207 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15443 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15208 15444 | RestJson<L>,
|
15209 15445 | crate::operation_shape::TestPayloadStructure,
|
15210 15446 | <
|
15211 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15212 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15447 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15448 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15213 15449 | RestJson<L>,
|
15214 15450 | crate::operation_shape::TestPayloadStructure,
|
15215 15451 | ModelPl::Output
|
15216 15452 | >
|
15217 15453 | >::Output
|
15218 15454 | >,
|
15219 15455 |
|
15220 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15456 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15221 15457 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15222 15458 |
|
15223 15459 | {
|
15224 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15225 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15460 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15461 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15226 15462 | let svc = crate::operation_shape::TestPayloadStructure::from_handler(handler);
|
15227 15463 | let svc = self.model_plugin.apply(svc);
|
15228 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15464 + | let svc =
|
15465 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15229 15466 | .apply(svc);
|
15230 15467 | let svc = self.http_plugin.apply(svc);
|
15231 15468 | self.test_payload_structure_custom(svc)
|
15232 15469 | }
|
15233 15470 |
|
15234 15471 | /// Sets the [`TestPayloadStructure`](crate::operation_shape::TestPayloadStructure) operation.
|
15235 15472 | ///
|
15236 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15237 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15473 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15474 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15238 15475 | ///
|
15239 15476 | /// # Example
|
15240 15477 | ///
|
15241 15478 | /// ```no_run
|
15242 15479 | /// use rest_json::{RestJson, RestJsonConfig};
|
15243 15480 | ///
|
15244 15481 | /// use rest_json::{input, output, error};
|
15245 15482 | ///
|
15246 15483 | /// async fn handler(input: input::TestPayloadStructureInput) -> Result<output::TestPayloadStructureOutput, error::TestPayloadStructureError> {
|
15247 15484 | /// todo!()
|
15248 15485 | /// }
|
15249 15486 | ///
|
15250 15487 | /// let config = RestJsonConfig::builder().build();
|
15251 15488 | /// let svc = ::tower::util::service_fn(handler);
|
15252 15489 | /// let app = RestJson::builder(config)
|
15253 15490 | /// .test_payload_structure_service(svc)
|
15254 15491 | /// /* Set other handlers */
|
15255 15492 | /// .build()
|
15256 15493 | /// .unwrap();
|
15257 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15494 + | /// # 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;
|
15258 15495 | /// ```
|
15259 15496 | ///
|
15260 15497 | pub fn test_payload_structure_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15261 15498 | where
|
15262 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestPayloadStructure, ServiceExtractors>,
|
15499 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestPayloadStructure, ServiceExtractors>,
|
15263 15500 |
|
15264 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15501 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15265 15502 | RestJson<L>,
|
15266 15503 | crate::operation_shape::TestPayloadStructure,
|
15267 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestPayloadStructure, S>
|
15504 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestPayloadStructure, S>
|
15268 15505 | >,
|
15269 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15506 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15270 15507 | RestJson<L>,
|
15271 15508 | crate::operation_shape::TestPayloadStructure,
|
15272 15509 | ModelPl::Output
|
15273 15510 | >,
|
15274 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15511 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15275 15512 | RestJson<L>,
|
15276 15513 | crate::operation_shape::TestPayloadStructure,
|
15277 15514 | <
|
15278 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15279 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15515 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15516 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15280 15517 | RestJson<L>,
|
15281 15518 | crate::operation_shape::TestPayloadStructure,
|
15282 15519 | ModelPl::Output
|
15283 15520 | >
|
15284 15521 | >::Output
|
15285 15522 | >,
|
15286 15523 |
|
15287 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15524 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15288 15525 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15289 15526 |
|
15290 15527 | {
|
15291 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15292 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15528 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15529 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15293 15530 | let svc = crate::operation_shape::TestPayloadStructure::from_service(service);
|
15294 15531 | let svc = self.model_plugin.apply(svc);
|
15295 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15532 + | let svc =
|
15533 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15296 15534 | .apply(svc);
|
15297 15535 | let svc = self.http_plugin.apply(svc);
|
15298 15536 | self.test_payload_structure_custom(svc)
|
15299 15537 | }
|
15300 15538 |
|
15301 15539 | /// Sets the [`TestPayloadStructure`](crate::operation_shape::TestPayloadStructure) to a custom [`Service`](tower::Service).
|
15302 15540 | /// not constrained by the Smithy contract.
|
15303 15541 | fn test_payload_structure_custom<S>(mut self, svc: S) -> Self
|
15304 15542 | where
|
15305 15543 | S: ::tower::Service<
|
15306 15544 | ::http::Request<Body>,
|
15307 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15545 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15308 15546 | Error = ::std::convert::Infallible,
|
15309 15547 | > + Clone
|
15310 15548 | + Send
|
15311 15549 | + 'static,
|
15312 15550 | S::Future: Send + 'static,
|
15313 15551 | {
|
15314 - | self.test_payload_structure = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15552 + | self.test_payload_structure =
|
15553 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15315 15554 | self
|
15316 15555 | }
|
15317 15556 |
|
15318 15557 | /// Sets the [`TestPostNoInputNoPayload`](crate::operation_shape::TestPostNoInputNoPayload) operation.
|
15319 15558 | ///
|
15320 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15321 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15559 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15560 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15322 15561 | ///
|
15323 15562 | /// # Example
|
15324 15563 | ///
|
15325 15564 | /// ```no_run
|
15326 15565 | /// use rest_json::{RestJson, RestJsonConfig};
|
15327 15566 | ///
|
15328 15567 | /// use rest_json::{input, output, error};
|
15329 15568 | ///
|
15330 15569 | /// async fn handler(input: input::TestPostNoInputNoPayloadInput) -> Result<output::TestPostNoInputNoPayloadOutput, error::TestPostNoInputNoPayloadError> {
|
15331 15570 | /// todo!()
|
15332 15571 | /// }
|
15333 15572 | ///
|
15334 15573 | /// let config = RestJsonConfig::builder().build();
|
15335 15574 | /// let app = RestJson::builder(config)
|
15336 15575 | /// .test_post_no_input_no_payload(handler)
|
15337 15576 | /// /* Set other handlers */
|
15338 15577 | /// .build()
|
15339 15578 | /// .unwrap();
|
15340 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15579 + | /// # 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;
|
15341 15580 | /// ```
|
15342 15581 | ///
|
15343 15582 | pub fn test_post_no_input_no_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15344 15583 | where
|
15345 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestPostNoInputNoPayload, HandlerExtractors>,
|
15584 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestPostNoInputNoPayload, HandlerExtractors>,
|
15346 15585 |
|
15347 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15586 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15348 15587 | RestJson<L>,
|
15349 15588 | crate::operation_shape::TestPostNoInputNoPayload,
|
15350 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestPostNoInputNoPayload, HandlerType>
|
15589 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestPostNoInputNoPayload, HandlerType>
|
15351 15590 | >,
|
15352 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15591 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15353 15592 | RestJson<L>,
|
15354 15593 | crate::operation_shape::TestPostNoInputNoPayload,
|
15355 15594 | ModelPl::Output
|
15356 15595 | >,
|
15357 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15596 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15358 15597 | RestJson<L>,
|
15359 15598 | crate::operation_shape::TestPostNoInputNoPayload,
|
15360 15599 | <
|
15361 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15362 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15600 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15601 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15363 15602 | RestJson<L>,
|
15364 15603 | crate::operation_shape::TestPostNoInputNoPayload,
|
15365 15604 | ModelPl::Output
|
15366 15605 | >
|
15367 15606 | >::Output
|
15368 15607 | >,
|
15369 15608 |
|
15370 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15609 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15371 15610 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15372 15611 |
|
15373 15612 | {
|
15374 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15375 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15613 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15614 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15376 15615 | let svc = crate::operation_shape::TestPostNoInputNoPayload::from_handler(handler);
|
15377 15616 | let svc = self.model_plugin.apply(svc);
|
15378 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15617 + | let svc =
|
15618 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15379 15619 | .apply(svc);
|
15380 15620 | let svc = self.http_plugin.apply(svc);
|
15381 15621 | self.test_post_no_input_no_payload_custom(svc)
|
15382 15622 | }
|
15383 15623 |
|
15384 15624 | /// Sets the [`TestPostNoInputNoPayload`](crate::operation_shape::TestPostNoInputNoPayload) operation.
|
15385 15625 | ///
|
15386 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15387 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15626 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15627 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15388 15628 | ///
|
15389 15629 | /// # Example
|
15390 15630 | ///
|
15391 15631 | /// ```no_run
|
15392 15632 | /// use rest_json::{RestJson, RestJsonConfig};
|
15393 15633 | ///
|
15394 15634 | /// use rest_json::{input, output, error};
|
15395 15635 | ///
|
15396 15636 | /// async fn handler(input: input::TestPostNoInputNoPayloadInput) -> Result<output::TestPostNoInputNoPayloadOutput, error::TestPostNoInputNoPayloadError> {
|
15397 15637 | /// todo!()
|
15398 15638 | /// }
|
15399 15639 | ///
|
15400 15640 | /// let config = RestJsonConfig::builder().build();
|
15401 15641 | /// let svc = ::tower::util::service_fn(handler);
|
15402 15642 | /// let app = RestJson::builder(config)
|
15403 15643 | /// .test_post_no_input_no_payload_service(svc)
|
15404 15644 | /// /* Set other handlers */
|
15405 15645 | /// .build()
|
15406 15646 | /// .unwrap();
|
15407 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15647 + | /// # 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;
|
15408 15648 | /// ```
|
15409 15649 | ///
|
15410 15650 | pub fn test_post_no_input_no_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15411 15651 | where
|
15412 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestPostNoInputNoPayload, ServiceExtractors>,
|
15652 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestPostNoInputNoPayload, ServiceExtractors>,
|
15413 15653 |
|
15414 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15654 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15415 15655 | RestJson<L>,
|
15416 15656 | crate::operation_shape::TestPostNoInputNoPayload,
|
15417 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestPostNoInputNoPayload, S>
|
15657 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestPostNoInputNoPayload, S>
|
15418 15658 | >,
|
15419 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15659 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15420 15660 | RestJson<L>,
|
15421 15661 | crate::operation_shape::TestPostNoInputNoPayload,
|
15422 15662 | ModelPl::Output
|
15423 15663 | >,
|
15424 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15664 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15425 15665 | RestJson<L>,
|
15426 15666 | crate::operation_shape::TestPostNoInputNoPayload,
|
15427 15667 | <
|
15428 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15429 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15668 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15669 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15430 15670 | RestJson<L>,
|
15431 15671 | crate::operation_shape::TestPostNoInputNoPayload,
|
15432 15672 | ModelPl::Output
|
15433 15673 | >
|
15434 15674 | >::Output
|
15435 15675 | >,
|
15436 15676 |
|
15437 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15677 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15438 15678 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15439 15679 |
|
15440 15680 | {
|
15441 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15442 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15681 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15682 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15443 15683 | let svc = crate::operation_shape::TestPostNoInputNoPayload::from_service(service);
|
15444 15684 | let svc = self.model_plugin.apply(svc);
|
15445 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15685 + | let svc =
|
15686 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15446 15687 | .apply(svc);
|
15447 15688 | let svc = self.http_plugin.apply(svc);
|
15448 15689 | self.test_post_no_input_no_payload_custom(svc)
|
15449 15690 | }
|
15450 15691 |
|
15451 15692 | /// Sets the [`TestPostNoInputNoPayload`](crate::operation_shape::TestPostNoInputNoPayload) to a custom [`Service`](tower::Service).
|
15452 15693 | /// not constrained by the Smithy contract.
|
15453 15694 | fn test_post_no_input_no_payload_custom<S>(mut self, svc: S) -> Self
|
15454 15695 | where
|
15455 15696 | S: ::tower::Service<
|
15456 15697 | ::http::Request<Body>,
|
15457 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15698 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15458 15699 | Error = ::std::convert::Infallible,
|
15459 15700 | > + Clone
|
15460 15701 | + Send
|
15461 15702 | + 'static,
|
15462 15703 | S::Future: Send + 'static,
|
15463 15704 | {
|
15464 15705 | self.test_post_no_input_no_payload =
|
15465 - | Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15706 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15466 15707 | self
|
15467 15708 | }
|
15468 15709 |
|
15469 15710 | /// Sets the [`TestPostNoPayload`](crate::operation_shape::TestPostNoPayload) operation.
|
15470 15711 | ///
|
15471 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15472 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15712 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15713 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15473 15714 | ///
|
15474 15715 | /// # Example
|
15475 15716 | ///
|
15476 15717 | /// ```no_run
|
15477 15718 | /// use rest_json::{RestJson, RestJsonConfig};
|
15478 15719 | ///
|
15479 15720 | /// use rest_json::{input, output, error};
|
15480 15721 | ///
|
15481 15722 | /// async fn handler(input: input::TestPostNoPayloadInput) -> Result<output::TestPostNoPayloadOutput, error::TestPostNoPayloadError> {
|
15482 15723 | /// todo!()
|
15483 15724 | /// }
|
15484 15725 | ///
|
15485 15726 | /// let config = RestJsonConfig::builder().build();
|
15486 15727 | /// let app = RestJson::builder(config)
|
15487 15728 | /// .test_post_no_payload(handler)
|
15488 15729 | /// /* Set other handlers */
|
15489 15730 | /// .build()
|
15490 15731 | /// .unwrap();
|
15491 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15732 + | /// # 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;
|
15492 15733 | /// ```
|
15493 15734 | ///
|
15494 15735 | pub fn test_post_no_payload<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15495 15736 | where
|
15496 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TestPostNoPayload, HandlerExtractors>,
|
15737 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TestPostNoPayload, HandlerExtractors>,
|
15497 15738 |
|
15498 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15739 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15499 15740 | RestJson<L>,
|
15500 15741 | crate::operation_shape::TestPostNoPayload,
|
15501 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TestPostNoPayload, HandlerType>
|
15742 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TestPostNoPayload, HandlerType>
|
15502 15743 | >,
|
15503 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15744 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15504 15745 | RestJson<L>,
|
15505 15746 | crate::operation_shape::TestPostNoPayload,
|
15506 15747 | ModelPl::Output
|
15507 15748 | >,
|
15508 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15749 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15509 15750 | RestJson<L>,
|
15510 15751 | crate::operation_shape::TestPostNoPayload,
|
15511 15752 | <
|
15512 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15513 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15753 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15754 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15514 15755 | RestJson<L>,
|
15515 15756 | crate::operation_shape::TestPostNoPayload,
|
15516 15757 | ModelPl::Output
|
15517 15758 | >
|
15518 15759 | >::Output
|
15519 15760 | >,
|
15520 15761 |
|
15521 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15762 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15522 15763 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15523 15764 |
|
15524 15765 | {
|
15525 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15526 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15766 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15767 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15527 15768 | let svc = crate::operation_shape::TestPostNoPayload::from_handler(handler);
|
15528 15769 | let svc = self.model_plugin.apply(svc);
|
15529 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15770 + | let svc =
|
15771 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15530 15772 | .apply(svc);
|
15531 15773 | let svc = self.http_plugin.apply(svc);
|
15532 15774 | self.test_post_no_payload_custom(svc)
|
15533 15775 | }
|
15534 15776 |
|
15535 15777 | /// Sets the [`TestPostNoPayload`](crate::operation_shape::TestPostNoPayload) operation.
|
15536 15778 | ///
|
15537 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15538 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15779 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15780 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15539 15781 | ///
|
15540 15782 | /// # Example
|
15541 15783 | ///
|
15542 15784 | /// ```no_run
|
15543 15785 | /// use rest_json::{RestJson, RestJsonConfig};
|
15544 15786 | ///
|
15545 15787 | /// use rest_json::{input, output, error};
|
15546 15788 | ///
|
15547 15789 | /// async fn handler(input: input::TestPostNoPayloadInput) -> Result<output::TestPostNoPayloadOutput, error::TestPostNoPayloadError> {
|
15548 15790 | /// todo!()
|
15549 15791 | /// }
|
15550 15792 | ///
|
15551 15793 | /// let config = RestJsonConfig::builder().build();
|
15552 15794 | /// let svc = ::tower::util::service_fn(handler);
|
15553 15795 | /// let app = RestJson::builder(config)
|
15554 15796 | /// .test_post_no_payload_service(svc)
|
15555 15797 | /// /* Set other handlers */
|
15556 15798 | /// .build()
|
15557 15799 | /// .unwrap();
|
15558 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15800 + | /// # 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;
|
15559 15801 | /// ```
|
15560 15802 | ///
|
15561 15803 | pub fn test_post_no_payload_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15562 15804 | where
|
15563 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TestPostNoPayload, ServiceExtractors>,
|
15805 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TestPostNoPayload, ServiceExtractors>,
|
15564 15806 |
|
15565 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15807 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15566 15808 | RestJson<L>,
|
15567 15809 | crate::operation_shape::TestPostNoPayload,
|
15568 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TestPostNoPayload, S>
|
15810 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TestPostNoPayload, S>
|
15569 15811 | >,
|
15570 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15812 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15571 15813 | RestJson<L>,
|
15572 15814 | crate::operation_shape::TestPostNoPayload,
|
15573 15815 | ModelPl::Output
|
15574 15816 | >,
|
15575 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15817 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15576 15818 | RestJson<L>,
|
15577 15819 | crate::operation_shape::TestPostNoPayload,
|
15578 15820 | <
|
15579 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15580 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15821 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15822 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15581 15823 | RestJson<L>,
|
15582 15824 | crate::operation_shape::TestPostNoPayload,
|
15583 15825 | ModelPl::Output
|
15584 15826 | >
|
15585 15827 | >::Output
|
15586 15828 | >,
|
15587 15829 |
|
15588 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15830 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15589 15831 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15590 15832 |
|
15591 15833 | {
|
15592 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15593 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15834 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15835 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15594 15836 | let svc = crate::operation_shape::TestPostNoPayload::from_service(service);
|
15595 15837 | let svc = self.model_plugin.apply(svc);
|
15596 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15838 + | let svc =
|
15839 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15597 15840 | .apply(svc);
|
15598 15841 | let svc = self.http_plugin.apply(svc);
|
15599 15842 | self.test_post_no_payload_custom(svc)
|
15600 15843 | }
|
15601 15844 |
|
15602 15845 | /// Sets the [`TestPostNoPayload`](crate::operation_shape::TestPostNoPayload) to a custom [`Service`](tower::Service).
|
15603 15846 | /// not constrained by the Smithy contract.
|
15604 15847 | fn test_post_no_payload_custom<S>(mut self, svc: S) -> Self
|
15605 15848 | where
|
15606 15849 | S: ::tower::Service<
|
15607 15850 | ::http::Request<Body>,
|
15608 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
15851 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15609 15852 | Error = ::std::convert::Infallible,
|
15610 15853 | > + Clone
|
15611 15854 | + Send
|
15612 15855 | + 'static,
|
15613 15856 | S::Future: Send + 'static,
|
15614 15857 | {
|
15615 - | self.test_post_no_payload = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
15858 + | self.test_post_no_payload = Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15616 15859 | self
|
15617 15860 | }
|
15618 15861 |
|
15619 15862 | /// Sets the [`TimestampFormatHeaders`](crate::operation_shape::TimestampFormatHeaders) operation.
|
15620 15863 | ///
|
15621 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15622 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15864 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15865 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15623 15866 | ///
|
15624 15867 | /// # Example
|
15625 15868 | ///
|
15626 15869 | /// ```no_run
|
15627 15870 | /// use rest_json::{RestJson, RestJsonConfig};
|
15628 15871 | ///
|
15629 15872 | /// use rest_json::{input, output, error};
|
15630 15873 | ///
|
15631 15874 | /// async fn handler(input: input::TimestampFormatHeadersInput) -> Result<output::TimestampFormatHeadersOutput, error::TimestampFormatHeadersError> {
|
15632 15875 | /// todo!()
|
15633 15876 | /// }
|
15634 15877 | ///
|
15635 15878 | /// let config = RestJsonConfig::builder().build();
|
15636 15879 | /// let app = RestJson::builder(config)
|
15637 15880 | /// .timestamp_format_headers(handler)
|
15638 15881 | /// /* Set other handlers */
|
15639 15882 | /// .build()
|
15640 15883 | /// .unwrap();
|
15641 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15884 + | /// # 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;
|
15642 15885 | /// ```
|
15643 15886 | ///
|
15644 15887 | pub fn timestamp_format_headers<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15645 15888 | where
|
15646 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::TimestampFormatHeaders, HandlerExtractors>,
|
15889 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::TimestampFormatHeaders, HandlerExtractors>,
|
15647 15890 |
|
15648 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15891 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15649 15892 | RestJson<L>,
|
15650 15893 | crate::operation_shape::TimestampFormatHeaders,
|
15651 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::TimestampFormatHeaders, HandlerType>
|
15894 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::TimestampFormatHeaders, HandlerType>
|
15652 15895 | >,
|
15653 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15896 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15654 15897 | RestJson<L>,
|
15655 15898 | crate::operation_shape::TimestampFormatHeaders,
|
15656 15899 | ModelPl::Output
|
15657 15900 | >,
|
15658 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15901 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15659 15902 | RestJson<L>,
|
15660 15903 | crate::operation_shape::TimestampFormatHeaders,
|
15661 15904 | <
|
15662 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15663 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15905 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15906 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15664 15907 | RestJson<L>,
|
15665 15908 | crate::operation_shape::TimestampFormatHeaders,
|
15666 15909 | ModelPl::Output
|
15667 15910 | >
|
15668 15911 | >::Output
|
15669 15912 | >,
|
15670 15913 |
|
15671 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15914 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15672 15915 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15673 15916 |
|
15674 15917 | {
|
15675 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15676 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15918 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15919 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15677 15920 | let svc = crate::operation_shape::TimestampFormatHeaders::from_handler(handler);
|
15678 15921 | let svc = self.model_plugin.apply(svc);
|
15679 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15922 + | let svc =
|
15923 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15680 15924 | .apply(svc);
|
15681 15925 | let svc = self.http_plugin.apply(svc);
|
15682 15926 | self.timestamp_format_headers_custom(svc)
|
15683 15927 | }
|
15684 15928 |
|
15685 15929 | /// Sets the [`TimestampFormatHeaders`](crate::operation_shape::TimestampFormatHeaders) operation.
|
15686 15930 | ///
|
15687 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15688 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
15931 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
15932 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15689 15933 | ///
|
15690 15934 | /// # Example
|
15691 15935 | ///
|
15692 15936 | /// ```no_run
|
15693 15937 | /// use rest_json::{RestJson, RestJsonConfig};
|
15694 15938 | ///
|
15695 15939 | /// use rest_json::{input, output, error};
|
15696 15940 | ///
|
15697 15941 | /// async fn handler(input: input::TimestampFormatHeadersInput) -> Result<output::TimestampFormatHeadersOutput, error::TimestampFormatHeadersError> {
|
15698 15942 | /// todo!()
|
15699 15943 | /// }
|
15700 15944 | ///
|
15701 15945 | /// let config = RestJsonConfig::builder().build();
|
15702 15946 | /// let svc = ::tower::util::service_fn(handler);
|
15703 15947 | /// let app = RestJson::builder(config)
|
15704 15948 | /// .timestamp_format_headers_service(svc)
|
15705 15949 | /// /* Set other handlers */
|
15706 15950 | /// .build()
|
15707 15951 | /// .unwrap();
|
15708 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
15952 + | /// # 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;
|
15709 15953 | /// ```
|
15710 15954 | ///
|
15711 15955 | pub fn timestamp_format_headers_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15712 15956 | where
|
15713 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::TimestampFormatHeaders, ServiceExtractors>,
|
15957 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::TimestampFormatHeaders, ServiceExtractors>,
|
15714 15958 |
|
15715 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
15959 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15716 15960 | RestJson<L>,
|
15717 15961 | crate::operation_shape::TimestampFormatHeaders,
|
15718 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::TimestampFormatHeaders, S>
|
15962 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::TimestampFormatHeaders, S>
|
15719 15963 | >,
|
15720 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
15964 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15721 15965 | RestJson<L>,
|
15722 15966 | crate::operation_shape::TimestampFormatHeaders,
|
15723 15967 | ModelPl::Output
|
15724 15968 | >,
|
15725 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
15969 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15726 15970 | RestJson<L>,
|
15727 15971 | crate::operation_shape::TimestampFormatHeaders,
|
15728 15972 | <
|
15729 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15730 - | as ::aws_smithy_http_server::plugin::Plugin<
|
15973 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15974 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15731 15975 | RestJson<L>,
|
15732 15976 | crate::operation_shape::TimestampFormatHeaders,
|
15733 15977 | ModelPl::Output
|
15734 15978 | >
|
15735 15979 | >::Output
|
15736 15980 | >,
|
15737 15981 |
|
15738 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15982 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15739 15983 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15740 15984 |
|
15741 15985 | {
|
15742 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15743 - | use ::aws_smithy_http_server::plugin::Plugin;
|
15986 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
15987 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15744 15988 | let svc = crate::operation_shape::TimestampFormatHeaders::from_service(service);
|
15745 15989 | let svc = self.model_plugin.apply(svc);
|
15746 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15990 + | let svc =
|
15991 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15747 15992 | .apply(svc);
|
15748 15993 | let svc = self.http_plugin.apply(svc);
|
15749 15994 | self.timestamp_format_headers_custom(svc)
|
15750 15995 | }
|
15751 15996 |
|
15752 15997 | /// Sets the [`TimestampFormatHeaders`](crate::operation_shape::TimestampFormatHeaders) to a custom [`Service`](tower::Service).
|
15753 15998 | /// not constrained by the Smithy contract.
|
15754 15999 | fn timestamp_format_headers_custom<S>(mut self, svc: S) -> Self
|
15755 16000 | where
|
15756 16001 | S: ::tower::Service<
|
15757 16002 | ::http::Request<Body>,
|
15758 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
16003 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15759 16004 | Error = ::std::convert::Infallible,
|
15760 16005 | > + Clone
|
15761 16006 | + Send
|
15762 16007 | + 'static,
|
15763 16008 | S::Future: Send + 'static,
|
15764 16009 | {
|
15765 - | self.timestamp_format_headers = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
16010 + | self.timestamp_format_headers =
|
16011 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15766 16012 | self
|
15767 16013 | }
|
15768 16014 |
|
15769 16015 | /// Sets the [`UnitInputAndOutput`](crate::operation_shape::UnitInputAndOutput) operation.
|
15770 16016 | ///
|
15771 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15772 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
16017 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
16018 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15773 16019 | ///
|
15774 16020 | /// # Example
|
15775 16021 | ///
|
15776 16022 | /// ```no_run
|
15777 16023 | /// use rest_json::{RestJson, RestJsonConfig};
|
15778 16024 | ///
|
15779 16025 | /// use rest_json::{input, output, error};
|
15780 16026 | ///
|
15781 16027 | /// async fn handler(input: input::UnitInputAndOutputInput) -> Result<output::UnitInputAndOutputOutput, error::UnitInputAndOutputError> {
|
15782 16028 | /// todo!()
|
15783 16029 | /// }
|
15784 16030 | ///
|
15785 16031 | /// let config = RestJsonConfig::builder().build();
|
15786 16032 | /// let app = RestJson::builder(config)
|
15787 16033 | /// .unit_input_and_output(handler)
|
15788 16034 | /// /* Set other handlers */
|
15789 16035 | /// .build()
|
15790 16036 | /// .unwrap();
|
15791 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
16037 + | /// # 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;
|
15792 16038 | /// ```
|
15793 16039 | ///
|
15794 16040 | pub fn unit_input_and_output<HandlerType, HandlerExtractors, UpgradeExtractors>(self, handler: HandlerType) -> Self
|
15795 16041 | where
|
15796 - | HandlerType: ::aws_smithy_http_server::operation::Handler<crate::operation_shape::UnitInputAndOutput, HandlerExtractors>,
|
16042 + | HandlerType: ::aws_smithy_legacy_http_server::operation::Handler<crate::operation_shape::UnitInputAndOutput, HandlerExtractors>,
|
15797 16043 |
|
15798 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
16044 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15799 16045 | RestJson<L>,
|
15800 16046 | crate::operation_shape::UnitInputAndOutput,
|
15801 - | ::aws_smithy_http_server::operation::IntoService<crate::operation_shape::UnitInputAndOutput, HandlerType>
|
16047 + | ::aws_smithy_legacy_http_server::operation::IntoService<crate::operation_shape::UnitInputAndOutput, HandlerType>
|
15802 16048 | >,
|
15803 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
16049 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15804 16050 | RestJson<L>,
|
15805 16051 | crate::operation_shape::UnitInputAndOutput,
|
15806 16052 | ModelPl::Output
|
15807 16053 | >,
|
15808 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
16054 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15809 16055 | RestJson<L>,
|
15810 16056 | crate::operation_shape::UnitInputAndOutput,
|
15811 16057 | <
|
15812 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15813 - | as ::aws_smithy_http_server::plugin::Plugin<
|
16058 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
16059 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15814 16060 | RestJson<L>,
|
15815 16061 | crate::operation_shape::UnitInputAndOutput,
|
15816 16062 | ModelPl::Output
|
15817 16063 | >
|
15818 16064 | >::Output
|
15819 16065 | >,
|
15820 16066 |
|
15821 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
16067 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15822 16068 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15823 16069 |
|
15824 16070 | {
|
15825 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15826 - | use ::aws_smithy_http_server::plugin::Plugin;
|
16071 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
16072 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15827 16073 | let svc = crate::operation_shape::UnitInputAndOutput::from_handler(handler);
|
15828 16074 | let svc = self.model_plugin.apply(svc);
|
15829 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
16075 + | let svc =
|
16076 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15830 16077 | .apply(svc);
|
15831 16078 | let svc = self.http_plugin.apply(svc);
|
15832 16079 | self.unit_input_and_output_custom(svc)
|
15833 16080 | }
|
15834 16081 |
|
15835 16082 | /// Sets the [`UnitInputAndOutput`](crate::operation_shape::UnitInputAndOutput) operation.
|
15836 16083 | ///
|
15837 - | /// This should be an async function satisfying the [`Handler`](::aws_smithy_http_server::operation::Handler) trait.
|
15838 - | /// See the [operation module documentation](::aws_smithy_http_server::operation) for more information.
|
16084 + | /// This should be an async function satisfying the [`Handler`](::aws_smithy_legacy_http_server::operation::Handler) trait.
|
16085 + | /// See the [operation module documentation](::aws_smithy_legacy_http_server::operation) for more information.
|
15839 16086 | ///
|
15840 16087 | /// # Example
|
15841 16088 | ///
|
15842 16089 | /// ```no_run
|
15843 16090 | /// use rest_json::{RestJson, RestJsonConfig};
|
15844 16091 | ///
|
15845 16092 | /// use rest_json::{input, output, error};
|
15846 16093 | ///
|
15847 16094 | /// async fn handler(input: input::UnitInputAndOutputInput) -> Result<output::UnitInputAndOutputOutput, error::UnitInputAndOutputError> {
|
15848 16095 | /// todo!()
|
15849 16096 | /// }
|
15850 16097 | ///
|
15851 16098 | /// let config = RestJsonConfig::builder().build();
|
15852 16099 | /// let svc = ::tower::util::service_fn(handler);
|
15853 16100 | /// let app = RestJson::builder(config)
|
15854 16101 | /// .unit_input_and_output_service(svc)
|
15855 16102 | /// /* Set other handlers */
|
15856 16103 | /// .build()
|
15857 16104 | /// .unwrap();
|
15858 - | /// # let app: RestJson<::aws_smithy_http_server::routing::RoutingService<::aws_smithy_http_server::protocol::rest::router::RestRouter<::aws_smithy_http_server::routing::Route>, ::aws_smithy_http_server::protocol::rest_json_1::RestJson1>> = app;
|
16105 + | /// # 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;
|
15859 16106 | /// ```
|
15860 16107 | ///
|
15861 16108 | pub fn unit_input_and_output_service<S, ServiceExtractors, UpgradeExtractors>(self, service: S) -> Self
|
15862 16109 | where
|
15863 - | S: ::aws_smithy_http_server::operation::OperationService<crate::operation_shape::UnitInputAndOutput, ServiceExtractors>,
|
16110 + | S: ::aws_smithy_legacy_http_server::operation::OperationService<crate::operation_shape::UnitInputAndOutput, ServiceExtractors>,
|
15864 16111 |
|
15865 - | ModelPl: ::aws_smithy_http_server::plugin::Plugin<
|
16112 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15866 16113 | RestJson<L>,
|
15867 16114 | crate::operation_shape::UnitInputAndOutput,
|
15868 - | ::aws_smithy_http_server::operation::Normalize<crate::operation_shape::UnitInputAndOutput, S>
|
16115 + | ::aws_smithy_legacy_http_server::operation::Normalize<crate::operation_shape::UnitInputAndOutput, S>
|
15869 16116 | >,
|
15870 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_http_server::plugin::Plugin<
|
16117 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15871 16118 | RestJson<L>,
|
15872 16119 | crate::operation_shape::UnitInputAndOutput,
|
15873 16120 | ModelPl::Output
|
15874 16121 | >,
|
15875 - | HttpPl: ::aws_smithy_http_server::plugin::Plugin<
|
16122 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15876 16123 | RestJson<L>,
|
15877 16124 | crate::operation_shape::UnitInputAndOutput,
|
15878 16125 | <
|
15879 - | ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
15880 - | as ::aws_smithy_http_server::plugin::Plugin<
|
16126 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>
|
16127 + | as ::aws_smithy_legacy_http_server::plugin::Plugin<
|
15881 16128 | RestJson<L>,
|
15882 16129 | crate::operation_shape::UnitInputAndOutput,
|
15883 16130 | ModelPl::Output
|
15884 16131 | >
|
15885 16132 | >::Output
|
15886 16133 | >,
|
15887 16134 |
|
15888 - | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
16135 + | HttpPl::Output: ::tower::Service<::http::Request<Body>, Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>, Error = ::std::convert::Infallible> + Clone + Send + 'static,
|
15889 16136 | <HttpPl::Output as ::tower::Service<::http::Request<Body>>>::Future: Send + 'static,
|
15890 16137 |
|
15891 16138 | {
|
15892 - | use ::aws_smithy_http_server::operation::OperationShapeExt;
|
15893 - | use ::aws_smithy_http_server::plugin::Plugin;
|
16139 + | use ::aws_smithy_legacy_http_server::operation::OperationShapeExt;
|
16140 + | use ::aws_smithy_legacy_http_server::plugin::Plugin;
|
15894 16141 | let svc = crate::operation_shape::UnitInputAndOutput::from_service(service);
|
15895 16142 | let svc = self.model_plugin.apply(svc);
|
15896 - | let svc = ::aws_smithy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
16143 + | let svc =
|
16144 + | ::aws_smithy_legacy_http_server::operation::UpgradePlugin::<UpgradeExtractors>::new()
|
15897 16145 | .apply(svc);
|
15898 16146 | let svc = self.http_plugin.apply(svc);
|
15899 16147 | self.unit_input_and_output_custom(svc)
|
15900 16148 | }
|
15901 16149 |
|
15902 16150 | /// Sets the [`UnitInputAndOutput`](crate::operation_shape::UnitInputAndOutput) to a custom [`Service`](tower::Service).
|
15903 16151 | /// not constrained by the Smithy contract.
|
15904 16152 | fn unit_input_and_output_custom<S>(mut self, svc: S) -> Self
|
15905 16153 | where
|
15906 16154 | S: ::tower::Service<
|
15907 16155 | ::http::Request<Body>,
|
15908 - | Response = ::http::Response<::aws_smithy_http_server::body::BoxBody>,
|
16156 + | Response = ::http::Response<::aws_smithy_legacy_http_server::body::BoxBody>,
|
15909 16157 | Error = ::std::convert::Infallible,
|
15910 16158 | > + Clone
|
15911 16159 | + Send
|
15912 16160 | + 'static,
|
15913 16161 | S::Future: Send + 'static,
|
15914 16162 | {
|
15915 - | self.unit_input_and_output = Some(::aws_smithy_http_server::routing::Route::new(svc));
|
16163 + | self.unit_input_and_output =
|
16164 + | Some(::aws_smithy_legacy_http_server::routing::Route::new(svc));
|
15916 16165 | self
|
15917 16166 | }
|
15918 16167 | }
|
15919 16168 |
|
15920 16169 | impl<Body, L, HttpPl, ModelPl> RestJsonBuilder<Body, L, HttpPl, ModelPl> {
|
15921 16170 | /// Constructs a [`RestJson`] from the arguments provided to the builder.
|
15922 16171 | ///
|
15923 16172 | /// Forgetting to register a handler for one or more operations will result in an error.
|
15924 16173 | ///
|
15925 16174 | /// Check out [`RestJsonBuilder::build_unchecked`] if you'd prefer the service to return status code 500 when an
|
15926 16175 | /// unspecified route is requested.
|
15927 16176 | pub fn build(
|
15928 16177 | self,
|
15929 16178 | ) -> ::std::result::Result<
|
15930 16179 | RestJson<
|
15931 - | ::aws_smithy_http_server::routing::RoutingService<
|
15932 - | ::aws_smithy_http_server::protocol::rest::router::RestRouter<L::Service>,
|
15933 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
16180 + | ::aws_smithy_legacy_http_server::routing::RoutingService<
|
16181 + | ::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<L::Service>,
|
16182 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
15934 16183 | >,
|
15935 16184 | >,
|
15936 16185 | MissingOperationsError,
|
15937 16186 | >
|
15938 16187 | where
|
15939 - | L: ::tower::Layer<::aws_smithy_http_server::routing::Route<Body>>,
|
16188 + | L: ::tower::Layer<::aws_smithy_legacy_http_server::routing::Route<Body>>,
|
15940 16189 | {
|
15941 16190 | let router = {
|
15942 - | use ::aws_smithy_http_server::operation::OperationShape;
|
16191 + | use ::aws_smithy_legacy_http_server::operation::OperationShape;
|
15943 16192 | let mut missing_operation_names = std::collections::HashMap::new();
|
15944 16193 | if self.all_query_string_types.is_none() {
|
15945 16194 | missing_operation_names.insert(
|
15946 16195 | crate::operation_shape::AllQueryStringTypes::ID,
|
15947 16196 | ".all_query_string_types()",
|
15948 16197 | );
|
15949 16198 | }
|
15950 16199 | if self.constant_and_variable_query_string.is_none() {
|
15951 16200 | missing_operation_names.insert(
|
15952 16201 | crate::operation_shape::ConstantAndVariableQueryString::ID,
|
17026 17275 | (
|
17027 17276 | request_specs::timestamp_format_headers(),
|
17028 17277 | self.timestamp_format_headers.expect(unexpected_error_msg),
|
17029 17278 | ),
|
17030 17279 | (
|
17031 17280 | request_specs::unit_input_and_output(),
|
17032 17281 | self.unit_input_and_output.expect(unexpected_error_msg),
|
17033 17282 | ),
|
17034 17283 | ])
|
17035 17284 | };
|
17036 - | let svc = ::aws_smithy_http_server::routing::RoutingService::new(router);
|
17285 + | let svc = ::aws_smithy_legacy_http_server::routing::RoutingService::new(router);
|
17037 17286 | let svc = svc.map(|s| s.layer(self.layer));
|
17038 17287 | Ok(RestJson { svc })
|
17039 17288 | }
|
17040 17289 |
|
17041 17290 | /// Constructs a [`RestJson`] from the arguments provided to the builder.
|
17042 17291 | /// Operations without a handler default to returning 500 Internal Server Error to the caller.
|
17043 17292 | ///
|
17044 17293 | /// Check out [`RestJsonBuilder::build`] if you'd prefer the builder to fail if one or more operations do
|
17045 17294 | /// not have a registered handler.
|
17046 17295 | pub fn build_unchecked(self) -> RestJson<L::Service>
|
17047 17296 | where
|
17048 17297 | Body: Send + 'static,
|
17049 17298 | L: ::tower::Layer<
|
17050 - | ::aws_smithy_http_server::routing::RoutingService<
|
17051 - | ::aws_smithy_http_server::protocol::rest::router::RestRouter<
|
17052 - | ::aws_smithy_http_server::routing::Route<Body>,
|
17299 + | ::aws_smithy_legacy_http_server::routing::RoutingService<
|
17300 + | ::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<
|
17301 + | ::aws_smithy_legacy_http_server::routing::Route<Body>,
|
17053 17302 | >,
|
17054 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17303 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17055 17304 | >,
|
17056 17305 | >,
|
17057 17306 | {
|
17058 - | let router = ::aws_smithy_http_server::protocol::rest::router::RestRouter::from_iter([
|
17307 + | let router =
|
17308 + | ::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter::from_iter([
|
17059 17309 | (
|
17060 17310 | request_specs::all_query_string_types(),
|
17061 17311 | self.all_query_string_types.unwrap_or_else(|| {
|
17062 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17063 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17312 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17313 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17064 17314 | >::default();
|
17065 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17315 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17066 17316 | }),
|
17067 17317 | ),
|
17068 17318 | (
|
17069 17319 | request_specs::constant_and_variable_query_string(),
|
17070 17320 | self.constant_and_variable_query_string.unwrap_or_else(|| {
|
17071 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17072 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17321 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17322 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17073 17323 | >::default();
|
17074 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17324 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17075 17325 | }),
|
17076 17326 | ),
|
17077 17327 | (
|
17078 17328 | request_specs::constant_query_string(),
|
17079 17329 | self.constant_query_string.unwrap_or_else(|| {
|
17080 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17081 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17330 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17331 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17082 17332 | >::default();
|
17083 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17333 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17084 17334 | }),
|
17085 17335 | ),
|
17086 17336 | (
|
17087 17337 | request_specs::content_type_parameters(),
|
17088 17338 | self.content_type_parameters.unwrap_or_else(|| {
|
17089 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17090 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17339 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17340 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17091 17341 | >::default();
|
17092 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17342 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17093 17343 | }),
|
17094 17344 | ),
|
17095 17345 | (
|
17096 17346 | request_specs::datetime_offsets(),
|
17097 17347 | self.datetime_offsets.unwrap_or_else(|| {
|
17098 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17099 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17348 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17349 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17100 17350 | >::default();
|
17101 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17351 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17102 17352 | }),
|
17103 17353 | ),
|
17104 17354 | (
|
17105 17355 | request_specs::document_type(),
|
17106 17356 | self.document_type.unwrap_or_else(|| {
|
17107 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17108 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17357 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17358 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17109 17359 | >::default();
|
17110 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17360 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17111 17361 | }),
|
17112 17362 | ),
|
17113 17363 | (
|
17114 17364 | request_specs::document_type_as_map_value(),
|
17115 17365 | self.document_type_as_map_value.unwrap_or_else(|| {
|
17116 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17117 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17366 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17367 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17118 17368 | >::default();
|
17119 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17369 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17120 17370 | }),
|
17121 17371 | ),
|
17122 17372 | (
|
17123 17373 | request_specs::document_type_as_payload(),
|
17124 17374 | self.document_type_as_payload.unwrap_or_else(|| {
|
17125 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17126 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17375 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17376 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17127 17377 | >::default();
|
17128 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17378 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17129 17379 | }),
|
17130 17380 | ),
|
17131 17381 | (
|
17132 17382 | request_specs::empty_input_and_empty_output(),
|
17133 17383 | self.empty_input_and_empty_output.unwrap_or_else(|| {
|
17134 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17135 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17384 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17385 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17136 17386 | >::default();
|
17137 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17387 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17138 17388 | }),
|
17139 17389 | ),
|
17140 17390 | (
|
17141 17391 | request_specs::endpoint_operation(),
|
17142 17392 | self.endpoint_operation.unwrap_or_else(|| {
|
17143 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17144 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17393 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17394 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17145 17395 | >::default();
|
17146 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17396 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17147 17397 | }),
|
17148 17398 | ),
|
17149 17399 | (
|
17150 17400 | request_specs::endpoint_with_host_label_operation(),
|
17151 17401 | self.endpoint_with_host_label_operation.unwrap_or_else(|| {
|
17152 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17153 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17402 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17403 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17154 17404 | >::default();
|
17155 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17405 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17156 17406 | }),
|
17157 17407 | ),
|
17158 17408 | (
|
17159 17409 | request_specs::fractional_seconds(),
|
17160 17410 | self.fractional_seconds.unwrap_or_else(|| {
|
17161 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17162 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17411 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17412 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17163 17413 | >::default();
|
17164 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17414 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17165 17415 | }),
|
17166 17416 | ),
|
17167 17417 | (
|
17168 17418 | request_specs::greeting_with_errors(),
|
17169 17419 | self.greeting_with_errors.unwrap_or_else(|| {
|
17170 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17171 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17420 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17421 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17172 17422 | >::default();
|
17173 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17423 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17174 17424 | }),
|
17175 17425 | ),
|
17176 17426 | (
|
17177 17427 | request_specs::host_with_path_operation(),
|
17178 17428 | self.host_with_path_operation.unwrap_or_else(|| {
|
17179 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17180 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17429 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17430 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17181 17431 | >::default();
|
17182 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17432 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17183 17433 | }),
|
17184 17434 | ),
|
17185 17435 | (
|
17186 17436 | request_specs::http_checksum_required(),
|
17187 17437 | self.http_checksum_required.unwrap_or_else(|| {
|
17188 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17189 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17438 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17439 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17190 17440 | >::default();
|
17191 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17441 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17192 17442 | }),
|
17193 17443 | ),
|
17194 17444 | (
|
17195 17445 | request_specs::http_empty_prefix_headers(),
|
17196 17446 | self.http_empty_prefix_headers.unwrap_or_else(|| {
|
17197 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17198 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17447 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17448 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17199 17449 | >::default();
|
17200 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17450 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17201 17451 | }),
|
17202 17452 | ),
|
17203 17453 | (
|
17204 17454 | request_specs::http_enum_payload(),
|
17205 17455 | self.http_enum_payload.unwrap_or_else(|| {
|
17206 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17207 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17456 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17457 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17208 17458 | >::default();
|
17209 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17459 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17210 17460 | }),
|
17211 17461 | ),
|
17212 17462 | (
|
17213 17463 | request_specs::http_payload_traits(),
|
17214 17464 | self.http_payload_traits.unwrap_or_else(|| {
|
17215 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17216 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17465 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17466 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17217 17467 | >::default();
|
17218 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17468 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17219 17469 | }),
|
17220 17470 | ),
|
17221 17471 | (
|
17222 17472 | request_specs::http_payload_traits_with_media_type(),
|
17223 17473 | self.http_payload_traits_with_media_type.unwrap_or_else(|| {
|
17224 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17225 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17474 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17475 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17226 17476 | >::default();
|
17227 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17477 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17228 17478 | }),
|
17229 17479 | ),
|
17230 17480 | (
|
17231 17481 | request_specs::http_payload_with_structure(),
|
17232 17482 | self.http_payload_with_structure.unwrap_or_else(|| {
|
17233 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17234 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17483 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17484 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17235 17485 | >::default();
|
17236 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17486 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17237 17487 | }),
|
17238 17488 | ),
|
17239 17489 | (
|
17240 17490 | request_specs::http_payload_with_union(),
|
17241 17491 | self.http_payload_with_union.unwrap_or_else(|| {
|
17242 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17243 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17492 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17493 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17244 17494 | >::default();
|
17245 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17495 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17246 17496 | }),
|
17247 17497 | ),
|
17248 17498 | (
|
17249 17499 | request_specs::http_prefix_headers(),
|
17250 17500 | self.http_prefix_headers.unwrap_or_else(|| {
|
17251 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17252 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17501 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17502 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17253 17503 | >::default();
|
17254 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17504 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17255 17505 | }),
|
17256 17506 | ),
|
17257 17507 | (
|
17258 17508 | request_specs::http_prefix_headers_in_response(),
|
17259 17509 | self.http_prefix_headers_in_response.unwrap_or_else(|| {
|
17260 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17261 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17510 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17511 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17262 17512 | >::default();
|
17263 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17513 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17264 17514 | }),
|
17265 17515 | ),
|
17266 17516 | (
|
17267 17517 | request_specs::http_request_with_float_labels(),
|
17268 17518 | self.http_request_with_float_labels.unwrap_or_else(|| {
|
17269 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17270 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17519 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17520 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17271 17521 | >::default();
|
17272 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17522 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17273 17523 | }),
|
17274 17524 | ),
|
17275 17525 | (
|
17276 17526 | request_specs::http_request_with_greedy_label_in_path(),
|
17277 17527 | self.http_request_with_greedy_label_in_path
|
17278 17528 | .unwrap_or_else(|| {
|
17279 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17280 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17529 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17530 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17281 17531 | >::default();
|
17282 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17532 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17283 17533 | }),
|
17284 17534 | ),
|
17285 17535 | (
|
17286 17536 | request_specs::http_request_with_labels(),
|
17287 17537 | self.http_request_with_labels.unwrap_or_else(|| {
|
17288 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17289 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17538 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17539 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17290 17540 | >::default();
|
17291 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17541 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17292 17542 | }),
|
17293 17543 | ),
|
17294 17544 | (
|
17295 17545 | request_specs::http_request_with_labels_and_timestamp_format(),
|
17296 17546 | self.http_request_with_labels_and_timestamp_format
|
17297 17547 | .unwrap_or_else(|| {
|
17298 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17299 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17548 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17549 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17300 17550 | >::default();
|
17301 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17551 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17302 17552 | }),
|
17303 17553 | ),
|
17304 17554 | (
|
17305 17555 | request_specs::http_request_with_regex_literal(),
|
17306 17556 | self.http_request_with_regex_literal.unwrap_or_else(|| {
|
17307 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17308 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17557 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17558 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17309 17559 | >::default();
|
17310 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17560 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17311 17561 | }),
|
17312 17562 | ),
|
17313 17563 | (
|
17314 17564 | request_specs::http_response_code(),
|
17315 17565 | self.http_response_code.unwrap_or_else(|| {
|
17316 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17317 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17566 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17567 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17318 17568 | >::default();
|
17319 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17569 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17320 17570 | }),
|
17321 17571 | ),
|
17322 17572 | (
|
17323 17573 | request_specs::http_string_payload(),
|
17324 17574 | self.http_string_payload.unwrap_or_else(|| {
|
17325 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17326 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17575 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17576 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17327 17577 | >::default();
|
17328 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17578 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17329 17579 | }),
|
17330 17580 | ),
|
17331 17581 | (
|
17332 17582 | request_specs::ignore_query_params_in_response(),
|
17333 17583 | self.ignore_query_params_in_response.unwrap_or_else(|| {
|
17334 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17335 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17584 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17585 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17336 17586 | >::default();
|
17337 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17587 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17338 17588 | }),
|
17339 17589 | ),
|
17340 17590 | (
|
17341 17591 | request_specs::input_and_output_with_headers(),
|
17342 17592 | self.input_and_output_with_headers.unwrap_or_else(|| {
|
17343 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17344 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17593 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17594 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17345 17595 | >::default();
|
17346 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17596 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17347 17597 | }),
|
17348 17598 | ),
|
17349 17599 | (
|
17350 17600 | request_specs::json_blobs(),
|
17351 17601 | self.json_blobs.unwrap_or_else(|| {
|
17352 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17353 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17602 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17603 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17354 17604 | >::default();
|
17355 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17605 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17356 17606 | }),
|
17357 17607 | ),
|
17358 17608 | (
|
17359 17609 | request_specs::json_enums(),
|
17360 17610 | self.json_enums.unwrap_or_else(|| {
|
17361 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17362 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17611 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17612 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17363 17613 | >::default();
|
17364 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17614 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17365 17615 | }),
|
17366 17616 | ),
|
17367 17617 | (
|
17368 17618 | request_specs::json_int_enums(),
|
17369 17619 | self.json_int_enums.unwrap_or_else(|| {
|
17370 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17371 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17620 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17621 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17372 17622 | >::default();
|
17373 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17623 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17374 17624 | }),
|
17375 17625 | ),
|
17376 17626 | (
|
17377 17627 | request_specs::json_lists(),
|
17378 17628 | self.json_lists.unwrap_or_else(|| {
|
17379 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17380 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17629 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17630 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17381 17631 | >::default();
|
17382 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17632 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17383 17633 | }),
|
17384 17634 | ),
|
17385 17635 | (
|
17386 17636 | request_specs::json_maps(),
|
17387 17637 | self.json_maps.unwrap_or_else(|| {
|
17388 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17389 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17638 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17639 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17390 17640 | >::default();
|
17391 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17641 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17392 17642 | }),
|
17393 17643 | ),
|
17394 17644 | (
|
17395 17645 | request_specs::json_timestamps(),
|
17396 17646 | self.json_timestamps.unwrap_or_else(|| {
|
17397 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17398 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17647 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17648 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17399 17649 | >::default();
|
17400 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17650 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17401 17651 | }),
|
17402 17652 | ),
|
17403 17653 | (
|
17404 17654 | request_specs::json_unions(),
|
17405 17655 | self.json_unions.unwrap_or_else(|| {
|
17406 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17407 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17656 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17657 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17408 17658 | >::default();
|
17409 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17659 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17410 17660 | }),
|
17411 17661 | ),
|
17412 17662 | (
|
17413 17663 | request_specs::malformed_accept_with_body(),
|
17414 17664 | self.malformed_accept_with_body.unwrap_or_else(|| {
|
17415 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17416 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17665 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17666 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17417 17667 | >::default();
|
17418 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17668 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17419 17669 | }),
|
17420 17670 | ),
|
17421 17671 | (
|
17422 17672 | request_specs::malformed_accept_with_generic_string(),
|
17423 17673 | self.malformed_accept_with_generic_string
|
17424 17674 | .unwrap_or_else(|| {
|
17425 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17426 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17675 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17676 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17427 17677 | >::default();
|
17428 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17678 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17429 17679 | }),
|
17430 17680 | ),
|
17431 17681 | (
|
17432 17682 | request_specs::malformed_accept_with_payload(),
|
17433 17683 | self.malformed_accept_with_payload.unwrap_or_else(|| {
|
17434 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17435 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17684 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17685 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17436 17686 | >::default();
|
17437 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17687 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17438 17688 | }),
|
17439 17689 | ),
|
17440 17690 | (
|
17441 17691 | request_specs::malformed_blob(),
|
17442 17692 | self.malformed_blob.unwrap_or_else(|| {
|
17443 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17444 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17693 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17694 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17445 17695 | >::default();
|
17446 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17696 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17447 17697 | }),
|
17448 17698 | ),
|
17449 17699 | (
|
17450 17700 | request_specs::malformed_boolean(),
|
17451 17701 | self.malformed_boolean.unwrap_or_else(|| {
|
17452 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17453 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17702 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17703 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17454 17704 | >::default();
|
17455 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17705 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17456 17706 | }),
|
17457 17707 | ),
|
17458 17708 | (
|
17459 17709 | request_specs::malformed_byte(),
|
17460 17710 | self.malformed_byte.unwrap_or_else(|| {
|
17461 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17462 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17711 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17712 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17463 17713 | >::default();
|
17464 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17714 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17465 17715 | }),
|
17466 17716 | ),
|
17467 17717 | (
|
17468 17718 | request_specs::malformed_content_type_with_body(),
|
17469 17719 | self.malformed_content_type_with_body.unwrap_or_else(|| {
|
17470 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17471 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17720 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17721 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17472 17722 | >::default();
|
17473 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17723 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17474 17724 | }),
|
17475 17725 | ),
|
17476 17726 | (
|
17477 17727 | request_specs::malformed_content_type_with_generic_string(),
|
17478 17728 | self.malformed_content_type_with_generic_string
|
17479 17729 | .unwrap_or_else(|| {
|
17480 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17481 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17730 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17731 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17482 17732 | >::default();
|
17483 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17733 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17484 17734 | }),
|
17485 17735 | ),
|
17486 17736 | (
|
17487 17737 | request_specs::malformed_content_type_without_body(),
|
17488 17738 | self.malformed_content_type_without_body.unwrap_or_else(|| {
|
17489 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17490 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17739 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17740 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17491 17741 | >::default();
|
17492 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17742 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17493 17743 | }),
|
17494 17744 | ),
|
17495 17745 | (
|
17496 17746 | request_specs::malformed_content_type_without_body_empty_input(),
|
17497 17747 | self.malformed_content_type_without_body_empty_input
|
17498 17748 | .unwrap_or_else(|| {
|
17499 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17500 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17749 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17750 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17501 17751 | >::default();
|
17502 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17752 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17503 17753 | }),
|
17504 17754 | ),
|
17505 17755 | (
|
17506 17756 | request_specs::malformed_content_type_with_payload(),
|
17507 17757 | self.malformed_content_type_with_payload.unwrap_or_else(|| {
|
17508 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17509 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17758 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17759 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17510 17760 | >::default();
|
17511 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17761 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17512 17762 | }),
|
17513 17763 | ),
|
17514 17764 | (
|
17515 17765 | request_specs::malformed_double(),
|
17516 17766 | self.malformed_double.unwrap_or_else(|| {
|
17517 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17518 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17767 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17768 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17519 17769 | >::default();
|
17520 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17770 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17521 17771 | }),
|
17522 17772 | ),
|
17523 17773 | (
|
17524 17774 | request_specs::malformed_float(),
|
17525 17775 | self.malformed_float.unwrap_or_else(|| {
|
17526 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17527 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17776 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17777 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17528 17778 | >::default();
|
17529 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17779 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17530 17780 | }),
|
17531 17781 | ),
|
17532 17782 | (
|
17533 17783 | request_specs::malformed_integer(),
|
17534 17784 | self.malformed_integer.unwrap_or_else(|| {
|
17535 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17536 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17785 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17786 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17537 17787 | >::default();
|
17538 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17788 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17539 17789 | }),
|
17540 17790 | ),
|
17541 17791 | (
|
17542 17792 | request_specs::malformed_list(),
|
17543 17793 | self.malformed_list.unwrap_or_else(|| {
|
17544 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17545 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17794 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17795 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17546 17796 | >::default();
|
17547 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17797 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17548 17798 | }),
|
17549 17799 | ),
|
17550 17800 | (
|
17551 17801 | request_specs::malformed_long(),
|
17552 17802 | self.malformed_long.unwrap_or_else(|| {
|
17553 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17554 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17803 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17804 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17555 17805 | >::default();
|
17556 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17806 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17557 17807 | }),
|
17558 17808 | ),
|
17559 17809 | (
|
17560 17810 | request_specs::malformed_map(),
|
17561 17811 | self.malformed_map.unwrap_or_else(|| {
|
17562 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17563 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17812 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17813 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17564 17814 | >::default();
|
17565 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17815 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17566 17816 | }),
|
17567 17817 | ),
|
17568 17818 | (
|
17569 17819 | request_specs::malformed_request_body(),
|
17570 17820 | self.malformed_request_body.unwrap_or_else(|| {
|
17571 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17572 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17821 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17822 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17573 17823 | >::default();
|
17574 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17824 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17575 17825 | }),
|
17576 17826 | ),
|
17577 17827 | (
|
17578 17828 | request_specs::malformed_short(),
|
17579 17829 | self.malformed_short.unwrap_or_else(|| {
|
17580 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17581 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17830 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17831 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17582 17832 | >::default();
|
17583 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17833 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17584 17834 | }),
|
17585 17835 | ),
|
17586 17836 | (
|
17587 17837 | request_specs::malformed_string(),
|
17588 17838 | self.malformed_string.unwrap_or_else(|| {
|
17589 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17590 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17839 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17840 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17591 17841 | >::default();
|
17592 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17842 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17593 17843 | }),
|
17594 17844 | ),
|
17595 17845 | (
|
17596 17846 | request_specs::malformed_timestamp_body_date_time(),
|
17597 17847 | self.malformed_timestamp_body_date_time.unwrap_or_else(|| {
|
17598 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17599 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17848 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17849 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17600 17850 | >::default();
|
17601 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17851 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17602 17852 | }),
|
17603 17853 | ),
|
17604 17854 | (
|
17605 17855 | request_specs::malformed_timestamp_body_default(),
|
17606 17856 | self.malformed_timestamp_body_default.unwrap_or_else(|| {
|
17607 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17608 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17857 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17858 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17609 17859 | >::default();
|
17610 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17860 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17611 17861 | }),
|
17612 17862 | ),
|
17613 17863 | (
|
17614 17864 | request_specs::malformed_timestamp_body_http_date(),
|
17615 17865 | self.malformed_timestamp_body_http_date.unwrap_or_else(|| {
|
17616 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17617 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17866 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17867 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17618 17868 | >::default();
|
17619 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17869 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17620 17870 | }),
|
17621 17871 | ),
|
17622 17872 | (
|
17623 17873 | request_specs::malformed_timestamp_header_date_time(),
|
17624 17874 | self.malformed_timestamp_header_date_time
|
17625 17875 | .unwrap_or_else(|| {
|
17626 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17627 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17876 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17877 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17628 17878 | >::default();
|
17629 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17879 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17630 17880 | }),
|
17631 17881 | ),
|
17632 17882 | (
|
17633 17883 | request_specs::malformed_timestamp_header_default(),
|
17634 17884 | self.malformed_timestamp_header_default.unwrap_or_else(|| {
|
17635 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17636 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17885 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17886 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17637 17887 | >::default();
|
17638 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17888 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17639 17889 | }),
|
17640 17890 | ),
|
17641 17891 | (
|
17642 17892 | request_specs::malformed_timestamp_header_epoch(),
|
17643 17893 | self.malformed_timestamp_header_epoch.unwrap_or_else(|| {
|
17644 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17645 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17894 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17895 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17646 17896 | >::default();
|
17647 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17897 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17648 17898 | }),
|
17649 17899 | ),
|
17650 17900 | (
|
17651 17901 | request_specs::malformed_timestamp_path_default(),
|
17652 17902 | self.malformed_timestamp_path_default.unwrap_or_else(|| {
|
17653 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17654 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17903 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17904 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17655 17905 | >::default();
|
17656 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17906 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17657 17907 | }),
|
17658 17908 | ),
|
17659 17909 | (
|
17660 17910 | request_specs::malformed_timestamp_path_epoch(),
|
17661 17911 | self.malformed_timestamp_path_epoch.unwrap_or_else(|| {
|
17662 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17663 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17912 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17913 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17664 17914 | >::default();
|
17665 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17915 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17666 17916 | }),
|
17667 17917 | ),
|
17668 17918 | (
|
17669 17919 | request_specs::malformed_timestamp_path_http_date(),
|
17670 17920 | self.malformed_timestamp_path_http_date.unwrap_or_else(|| {
|
17671 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17672 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17921 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17922 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17673 17923 | >::default();
|
17674 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17924 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17675 17925 | }),
|
17676 17926 | ),
|
17677 17927 | (
|
17678 17928 | request_specs::malformed_timestamp_query_default(),
|
17679 17929 | self.malformed_timestamp_query_default.unwrap_or_else(|| {
|
17680 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17681 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17930 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17931 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17682 17932 | >::default();
|
17683 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17933 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17684 17934 | }),
|
17685 17935 | ),
|
17686 17936 | (
|
17687 17937 | request_specs::malformed_timestamp_query_epoch(),
|
17688 17938 | self.malformed_timestamp_query_epoch.unwrap_or_else(|| {
|
17689 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17690 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17939 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17940 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17691 17941 | >::default();
|
17692 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17942 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17693 17943 | }),
|
17694 17944 | ),
|
17695 17945 | (
|
17696 17946 | request_specs::malformed_timestamp_query_http_date(),
|
17697 17947 | self.malformed_timestamp_query_http_date.unwrap_or_else(|| {
|
17698 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17699 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17948 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17949 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17700 17950 | >::default();
|
17701 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17951 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17702 17952 | }),
|
17703 17953 | ),
|
17704 17954 | (
|
17705 17955 | request_specs::malformed_union(),
|
17706 17956 | self.malformed_union.unwrap_or_else(|| {
|
17707 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17708 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17957 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17958 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17709 17959 | >::default();
|
17710 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17960 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17711 17961 | }),
|
17712 17962 | ),
|
17713 17963 | (
|
17714 17964 | request_specs::media_type_header(),
|
17715 17965 | self.media_type_header.unwrap_or_else(|| {
|
17716 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17717 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17966 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17967 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17718 17968 | >::default();
|
17719 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17969 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17720 17970 | }),
|
17721 17971 | ),
|
17722 17972 | (
|
17723 17973 | request_specs::no_input_and_no_output(),
|
17724 17974 | self.no_input_and_no_output.unwrap_or_else(|| {
|
17725 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17726 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17975 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17976 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17727 17977 | >::default();
|
17728 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17978 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17729 17979 | }),
|
17730 17980 | ),
|
17731 17981 | (
|
17732 17982 | request_specs::no_input_and_output(),
|
17733 17983 | self.no_input_and_output.unwrap_or_else(|| {
|
17734 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17735 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17984 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17985 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17736 17986 | >::default();
|
17737 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17987 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17738 17988 | }),
|
17739 17989 | ),
|
17740 17990 | (
|
17741 17991 | request_specs::null_and_empty_headers_client(),
|
17742 17992 | self.null_and_empty_headers_client.unwrap_or_else(|| {
|
17743 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17744 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
17993 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
17994 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17745 17995 | >::default();
|
17746 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
17996 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17747 17997 | }),
|
17748 17998 | ),
|
17749 17999 | (
|
17750 18000 | request_specs::null_and_empty_headers_server(),
|
17751 18001 | self.null_and_empty_headers_server.unwrap_or_else(|| {
|
17752 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17753 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18002 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18003 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17754 18004 | >::default();
|
17755 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18005 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17756 18006 | }),
|
17757 18007 | ),
|
17758 18008 | (
|
17759 18009 | request_specs::omits_null_serializes_empty_string(),
|
17760 18010 | self.omits_null_serializes_empty_string.unwrap_or_else(|| {
|
17761 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17762 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18011 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18012 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17763 18013 | >::default();
|
17764 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18014 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17765 18015 | }),
|
17766 18016 | ),
|
17767 18017 | (
|
17768 18018 | request_specs::omits_serializing_empty_lists(),
|
17769 18019 | self.omits_serializing_empty_lists.unwrap_or_else(|| {
|
17770 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17771 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18020 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18021 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17772 18022 | >::default();
|
17773 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18023 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17774 18024 | }),
|
17775 18025 | ),
|
17776 18026 | (
|
17777 18027 | request_specs::operation_with_defaults(),
|
17778 18028 | self.operation_with_defaults.unwrap_or_else(|| {
|
17779 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17780 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18029 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18030 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17781 18031 | >::default();
|
17782 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18032 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17783 18033 | }),
|
17784 18034 | ),
|
17785 18035 | (
|
17786 18036 | request_specs::operation_with_nested_structure(),
|
17787 18037 | self.operation_with_nested_structure.unwrap_or_else(|| {
|
17788 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17789 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18038 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18039 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17790 18040 | >::default();
|
17791 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18041 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17792 18042 | }),
|
17793 18043 | ),
|
17794 18044 | (
|
17795 18045 | request_specs::post_player_action(),
|
17796 18046 | self.post_player_action.unwrap_or_else(|| {
|
17797 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17798 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18047 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18048 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17799 18049 | >::default();
|
17800 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18050 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17801 18051 | }),
|
17802 18052 | ),
|
17803 18053 | (
|
17804 18054 | request_specs::post_union_with_json_name(),
|
17805 18055 | self.post_union_with_json_name.unwrap_or_else(|| {
|
17806 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17807 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18056 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18057 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17808 18058 | >::default();
|
17809 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18059 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17810 18060 | }),
|
17811 18061 | ),
|
17812 18062 | (
|
17813 18063 | request_specs::put_with_content_encoding(),
|
17814 18064 | self.put_with_content_encoding.unwrap_or_else(|| {
|
17815 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17816 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18065 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18066 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17817 18067 | >::default();
|
17818 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18068 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17819 18069 | }),
|
17820 18070 | ),
|
17821 18071 | (
|
17822 18072 | request_specs::query_idempotency_token_auto_fill(),
|
17823 18073 | self.query_idempotency_token_auto_fill.unwrap_or_else(|| {
|
17824 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17825 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18074 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18075 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17826 18076 | >::default();
|
17827 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18077 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17828 18078 | }),
|
17829 18079 | ),
|
17830 18080 | (
|
17831 18081 | request_specs::query_params_as_string_list_map(),
|
17832 18082 | self.query_params_as_string_list_map.unwrap_or_else(|| {
|
17833 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17834 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18083 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18084 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17835 18085 | >::default();
|
17836 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18086 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17837 18087 | }),
|
17838 18088 | ),
|
17839 18089 | (
|
17840 18090 | request_specs::query_precedence(),
|
17841 18091 | self.query_precedence.unwrap_or_else(|| {
|
17842 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17843 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18092 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18093 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17844 18094 | >::default();
|
17845 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18095 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17846 18096 | }),
|
17847 18097 | ),
|
17848 18098 | (
|
17849 18099 | request_specs::recursive_shapes(),
|
17850 18100 | self.recursive_shapes.unwrap_or_else(|| {
|
17851 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17852 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18101 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18102 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17853 18103 | >::default();
|
17854 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18104 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17855 18105 | }),
|
17856 18106 | ),
|
17857 18107 | (
|
17858 18108 | request_specs::response_code_http_fallback(),
|
17859 18109 | self.response_code_http_fallback.unwrap_or_else(|| {
|
17860 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17861 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18110 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18111 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17862 18112 | >::default();
|
17863 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18113 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17864 18114 | }),
|
17865 18115 | ),
|
17866 18116 | (
|
17867 18117 | request_specs::response_code_required(),
|
17868 18118 | self.response_code_required.unwrap_or_else(|| {
|
17869 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17870 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18119 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18120 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17871 18121 | >::default();
|
17872 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18122 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17873 18123 | }),
|
17874 18124 | ),
|
17875 18125 | (
|
17876 18126 | request_specs::simple_scalar_properties(),
|
17877 18127 | self.simple_scalar_properties.unwrap_or_else(|| {
|
17878 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17879 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18128 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18129 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17880 18130 | >::default();
|
17881 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18131 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17882 18132 | }),
|
17883 18133 | ),
|
17884 18134 | (
|
17885 18135 | request_specs::sparse_json_lists(),
|
17886 18136 | self.sparse_json_lists.unwrap_or_else(|| {
|
17887 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17888 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18137 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18138 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17889 18139 | >::default();
|
17890 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18140 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17891 18141 | }),
|
17892 18142 | ),
|
17893 18143 | (
|
17894 18144 | request_specs::sparse_json_maps(),
|
17895 18145 | self.sparse_json_maps.unwrap_or_else(|| {
|
17896 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17897 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18146 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18147 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17898 18148 | >::default();
|
17899 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18149 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17900 18150 | }),
|
17901 18151 | ),
|
17902 18152 | (
|
17903 18153 | request_specs::streaming_traits(),
|
17904 18154 | self.streaming_traits.unwrap_or_else(|| {
|
17905 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17906 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18155 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18156 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17907 18157 | >::default();
|
17908 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18158 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17909 18159 | }),
|
17910 18160 | ),
|
17911 18161 | (
|
17912 18162 | request_specs::streaming_traits_require_length(),
|
17913 18163 | self.streaming_traits_require_length.unwrap_or_else(|| {
|
17914 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17915 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18164 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18165 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17916 18166 | >::default();
|
17917 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18167 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17918 18168 | }),
|
17919 18169 | ),
|
17920 18170 | (
|
17921 18171 | request_specs::streaming_traits_with_media_type(),
|
17922 18172 | self.streaming_traits_with_media_type.unwrap_or_else(|| {
|
17923 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17924 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18173 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18174 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17925 18175 | >::default();
|
17926 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18176 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17927 18177 | }),
|
17928 18178 | ),
|
17929 18179 | (
|
17930 18180 | request_specs::test_body_structure(),
|
17931 18181 | self.test_body_structure.unwrap_or_else(|| {
|
17932 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17933 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18182 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18183 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17934 18184 | >::default();
|
17935 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18185 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17936 18186 | }),
|
17937 18187 | ),
|
17938 18188 | (
|
17939 18189 | request_specs::test_get_no_input_no_payload(),
|
17940 18190 | self.test_get_no_input_no_payload.unwrap_or_else(|| {
|
17941 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17942 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18191 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18192 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17943 18193 | >::default();
|
17944 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18194 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17945 18195 | }),
|
17946 18196 | ),
|
17947 18197 | (
|
17948 18198 | request_specs::test_get_no_payload(),
|
17949 18199 | self.test_get_no_payload.unwrap_or_else(|| {
|
17950 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17951 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18200 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18201 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17952 18202 | >::default();
|
17953 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18203 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17954 18204 | }),
|
17955 18205 | ),
|
17956 18206 | (
|
17957 18207 | request_specs::test_payload_blob(),
|
17958 18208 | self.test_payload_blob.unwrap_or_else(|| {
|
17959 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17960 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18209 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18210 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17961 18211 | >::default();
|
17962 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18212 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17963 18213 | }),
|
17964 18214 | ),
|
17965 18215 | (
|
17966 18216 | request_specs::test_payload_structure(),
|
17967 18217 | self.test_payload_structure.unwrap_or_else(|| {
|
17968 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17969 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18218 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18219 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17970 18220 | >::default();
|
17971 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18221 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17972 18222 | }),
|
17973 18223 | ),
|
17974 18224 | (
|
17975 18225 | request_specs::test_post_no_input_no_payload(),
|
17976 18226 | self.test_post_no_input_no_payload.unwrap_or_else(|| {
|
17977 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17978 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18227 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18228 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17979 18229 | >::default();
|
17980 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18230 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17981 18231 | }),
|
17982 18232 | ),
|
17983 18233 | (
|
17984 18234 | request_specs::test_post_no_payload(),
|
17985 18235 | self.test_post_no_payload.unwrap_or_else(|| {
|
17986 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17987 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18236 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18237 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17988 18238 | >::default();
|
17989 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18239 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17990 18240 | }),
|
17991 18241 | ),
|
17992 18242 | (
|
17993 18243 | request_specs::timestamp_format_headers(),
|
17994 18244 | self.timestamp_format_headers.unwrap_or_else(|| {
|
17995 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
17996 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18245 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18246 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
17997 18247 | >::default();
|
17998 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18248 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
17999 18249 | }),
|
18000 18250 | ),
|
18001 18251 | (
|
18002 18252 | request_specs::unit_input_and_output(),
|
18003 18253 | self.unit_input_and_output.unwrap_or_else(|| {
|
18004 - | let svc = ::aws_smithy_http_server::operation::MissingFailure::<
|
18005 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
18254 + | let svc = ::aws_smithy_legacy_http_server::operation::MissingFailure::<
|
18255 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
18006 18256 | >::default();
|
18007 - | ::aws_smithy_http_server::routing::Route::new(svc)
|
18257 + | ::aws_smithy_legacy_http_server::routing::Route::new(svc)
|
18008 18258 | }),
|
18009 18259 | ),
|
18010 18260 | ]);
|
18011 18261 | let svc = self
|
18012 18262 | .layer
|
18013 - | .layer(::aws_smithy_http_server::routing::RoutingService::new(
|
18014 - | router,
|
18015 - | ));
|
18263 + | .layer(::aws_smithy_legacy_http_server::routing::RoutingService::new(router));
|
18016 18264 | RestJson { svc }
|
18017 18265 | }
|
18018 18266 | }
|
18019 18267 |
|
18020 18268 | /// The error encountered when calling the [`RestJsonBuilder::build`] method if one or more operation handlers are not
|
18021 18269 | /// specified.
|
18022 18270 | #[derive(Debug)]
|
18023 18271 | pub struct MissingOperationsError {
|
18024 18272 | operation_names2setter_methods:
|
18025 - | std::collections::HashMap<::aws_smithy_http_server::shape_id::ShapeId, &'static str>,
|
18273 + | std::collections::HashMap<::aws_smithy_legacy_http_server::shape_id::ShapeId, &'static str>,
|
18026 18274 | }
|
18027 18275 |
|
18028 18276 | impl std::fmt::Display for MissingOperationsError {
|
18029 18277 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
18030 18278 | write!(
|
18031 18279 | f,
|
18032 18280 | "You must specify a handler for all operations attached to `RestJson`.\n\
|
18033 18281 | We are missing handlers for the following operations:\n",
|
18034 18282 | )?;
|
18035 18283 | for operation_name in self.operation_names2setter_methods.keys() {
|
18036 18284 | writeln!(f, "- {}", operation_name.absolute())?;
|
18037 18285 | }
|
18038 18286 |
|
18039 18287 | writeln!(
|
18040 18288 | f,
|
18041 18289 | "\nUse the dedicated methods on `RestJsonBuilder` to register the missing handlers:"
|
18042 18290 | )?;
|
18043 18291 | for setter_name in self.operation_names2setter_methods.values() {
|
18044 18292 | writeln!(f, "- {}", setter_name)?;
|
18045 18293 | }
|
18046 18294 | Ok(())
|
18047 18295 | }
|
18048 18296 | }
|
18049 18297 |
|
18050 18298 | impl std::error::Error for MissingOperationsError {}
|
18051 18299 |
|
18052 18300 | mod request_specs {
|
18053 18301 | pub(super) fn all_query_string_types(
|
18054 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18055 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18302 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18303 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18056 18304 | ::http::Method::GET,
|
18057 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18058 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18059 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18060 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("AllQueryStringTypesInput")),
|
18305 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18306 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18307 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18308 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("AllQueryStringTypesInput")),
|
18061 18309 | ]),
|
18062 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18310 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18063 18311 | ])
|
18064 18312 | )
|
18065 18313 | ),
|
18066 18314 | )
|
18067 18315 | }
|
18068 18316 | pub(super) fn constant_and_variable_query_string(
|
18069 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18070 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18317 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18318 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18071 18319 | ::http::Method::GET,
|
18072 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18073 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18074 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18075 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("ConstantAndVariableQueryString")),
|
18320 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18321 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18322 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18323 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("ConstantAndVariableQueryString")),
|
18076 18324 | ]),
|
18077 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18078 - | ::aws_smithy_http_server::routing::request_spec::QuerySegment::KeyValue(String::from("foo"), String::from("bar")),
|
18325 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18326 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySegment::KeyValue(String::from("foo"), String::from("bar")),
|
18079 18327 | ])
|
18080 18328 | )
|
18081 18329 | ),
|
18082 18330 | )
|
18083 18331 | }
|
18084 18332 | pub(super) fn constant_query_string(
|
18085 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18086 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18333 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18334 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18087 18335 | ::http::Method::GET,
|
18088 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18089 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18090 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18091 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("ConstantQueryString")),
|
18092 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18336 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18337 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18338 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18339 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("ConstantQueryString")),
|
18340 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18093 18341 | ]),
|
18094 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18095 - | ::aws_smithy_http_server::routing::request_spec::QuerySegment::KeyValue(String::from("foo"), String::from("bar")),
|
18096 - | ::aws_smithy_http_server::routing::request_spec::QuerySegment::Key(String::from("hello")),
|
18342 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18343 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySegment::KeyValue(String::from("foo"), String::from("bar")),
|
18344 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySegment::Key(String::from("hello")),
|
18097 18345 | ])
|
18098 18346 | )
|
18099 18347 | ),
|
18100 18348 | )
|
18101 18349 | }
|
18102 18350 | pub(super) fn content_type_parameters(
|
18103 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18104 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18351 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18352 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18105 18353 | ::http::Method::POST,
|
18106 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18107 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18108 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18109 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("ContentTypeParameters")),
|
18354 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18355 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18356 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18357 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("ContentTypeParameters")),
|
18110 18358 | ]),
|
18111 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18359 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18112 18360 | ])
|
18113 18361 | )
|
18114 18362 | ),
|
18115 18363 | )
|
18116 18364 | }
|
18117 - | pub(super) fn datetime_offsets() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18118 - | {
|
18119 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18365 + | pub(super) fn datetime_offsets(
|
18366 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18367 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18120 18368 | ::http::Method::POST,
|
18121 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18122 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18123 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18124 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("DatetimeOffsets")),
|
18369 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18370 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18371 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18372 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("DatetimeOffsets")),
|
18125 18373 | ]),
|
18126 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18374 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18127 18375 | ])
|
18128 18376 | )
|
18129 18377 | ),
|
18130 18378 | )
|
18131 18379 | }
|
18132 - | pub(super) fn document_type() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18133 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18380 + | pub(super) fn document_type(
|
18381 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18382 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18134 18383 | ::http::Method::PUT,
|
18135 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18136 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18137 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18138 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentType")),
|
18384 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18385 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18386 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18387 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentType")),
|
18139 18388 | ]),
|
18140 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18389 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18141 18390 | ])
|
18142 18391 | )
|
18143 18392 | ),
|
18144 18393 | )
|
18145 18394 | }
|
18146 18395 | pub(super) fn document_type_as_map_value(
|
18147 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18148 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18396 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18397 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18149 18398 | ::http::Method::PUT,
|
18150 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18151 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18152 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18153 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentTypeAsMapValue")),
|
18399 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18400 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18401 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18402 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentTypeAsMapValue")),
|
18154 18403 | ]),
|
18155 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18404 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18156 18405 | ])
|
18157 18406 | )
|
18158 18407 | ),
|
18159 18408 | )
|
18160 18409 | }
|
18161 18410 | pub(super) fn document_type_as_payload(
|
18162 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18163 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18411 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18412 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18164 18413 | ::http::Method::PUT,
|
18165 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18166 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18167 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18168 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentTypeAsPayload")),
|
18414 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18415 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18416 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18417 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("DocumentTypeAsPayload")),
|
18169 18418 | ]),
|
18170 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18419 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18171 18420 | ])
|
18172 18421 | )
|
18173 18422 | ),
|
18174 18423 | )
|
18175 18424 | }
|
18176 18425 | pub(super) fn empty_input_and_empty_output(
|
18177 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18178 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18426 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18427 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18179 18428 | ::http::Method::POST,
|
18180 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18181 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18182 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18183 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("EmptyInputAndEmptyOutput")),
|
18429 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18430 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18431 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18432 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("EmptyInputAndEmptyOutput")),
|
18184 18433 | ]),
|
18185 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18434 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18186 18435 | ])
|
18187 18436 | )
|
18188 18437 | ),
|
18189 18438 | )
|
18190 18439 | }
|
18191 18440 | pub(super) fn endpoint_operation(
|
18192 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18193 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18441 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18442 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18194 18443 | ::http::Method::POST,
|
18195 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18196 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18197 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18198 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("EndpointOperation")),
|
18444 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18445 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18446 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18447 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("EndpointOperation")),
|
18199 18448 | ]),
|
18200 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18449 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18201 18450 | ])
|
18202 18451 | )
|
18203 18452 | ),
|
18204 18453 | )
|
18205 18454 | }
|
18206 18455 | pub(super) fn endpoint_with_host_label_operation(
|
18207 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18208 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18456 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18457 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18209 18458 | ::http::Method::POST,
|
18210 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18211 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18212 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18213 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("EndpointWithHostLabelOperation")),
|
18459 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18460 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18461 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18462 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("EndpointWithHostLabelOperation")),
|
18214 18463 | ]),
|
18215 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18464 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18216 18465 | ])
|
18217 18466 | )
|
18218 18467 | ),
|
18219 18468 | )
|
18220 18469 | }
|
18221 18470 | pub(super) fn fractional_seconds(
|
18222 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18223 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18471 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18472 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18224 18473 | ::http::Method::POST,
|
18225 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18226 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18227 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18228 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("FractionalSeconds")),
|
18474 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18475 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18476 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18477 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("FractionalSeconds")),
|
18229 18478 | ]),
|
18230 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18479 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18231 18480 | ])
|
18232 18481 | )
|
18233 18482 | ),
|
18234 18483 | )
|
18235 18484 | }
|
18236 18485 | pub(super) fn greeting_with_errors(
|
18237 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18238 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18486 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18487 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18239 18488 | ::http::Method::PUT,
|
18240 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18241 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18242 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18243 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("GreetingWithErrors")),
|
18489 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18490 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18491 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18492 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("GreetingWithErrors")),
|
18244 18493 | ]),
|
18245 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18494 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18246 18495 | ])
|
18247 18496 | )
|
18248 18497 | ),
|
18249 18498 | )
|
18250 18499 | }
|
18251 18500 | pub(super) fn host_with_path_operation(
|
18252 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18253 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18501 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18502 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18254 18503 | ::http::Method::GET,
|
18255 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18256 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18257 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18258 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HostWithPathOperation")),
|
18504 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18505 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18506 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18507 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HostWithPathOperation")),
|
18259 18508 | ]),
|
18260 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18509 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18261 18510 | ])
|
18262 18511 | )
|
18263 18512 | ),
|
18264 18513 | )
|
18265 18514 | }
|
18266 18515 | pub(super) fn http_checksum_required(
|
18267 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18268 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18516 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18517 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18269 18518 | ::http::Method::POST,
|
18270 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18271 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18272 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18273 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpChecksumRequired")),
|
18519 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18520 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18521 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18522 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpChecksumRequired")),
|
18274 18523 | ]),
|
18275 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18524 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18276 18525 | ])
|
18277 18526 | )
|
18278 18527 | ),
|
18279 18528 | )
|
18280 18529 | }
|
18281 18530 | pub(super) fn http_empty_prefix_headers(
|
18282 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18283 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18531 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18532 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18284 18533 | ::http::Method::GET,
|
18285 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18286 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18287 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18288 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpEmptyPrefixHeaders")),
|
18534 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18535 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18536 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18537 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpEmptyPrefixHeaders")),
|
18289 18538 | ]),
|
18290 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18539 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18291 18540 | ])
|
18292 18541 | )
|
18293 18542 | ),
|
18294 18543 | )
|
18295 18544 | }
|
18296 - | pub(super) fn http_enum_payload() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18297 - | {
|
18298 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18545 + | pub(super) fn http_enum_payload(
|
18546 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18547 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18299 18548 | ::http::Method::POST,
|
18300 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18301 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18302 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18303 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("EnumPayload")),
|
18549 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18550 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18551 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18552 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("EnumPayload")),
|
18304 18553 | ]),
|
18305 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18554 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18306 18555 | ])
|
18307 18556 | )
|
18308 18557 | ),
|
18309 18558 | )
|
18310 18559 | }
|
18311 18560 | pub(super) fn http_payload_traits(
|
18312 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18313 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18561 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18562 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18314 18563 | ::http::Method::POST,
|
18315 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18316 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18317 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18318 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadTraits")),
|
18564 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18565 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18566 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18567 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadTraits")),
|
18319 18568 | ]),
|
18320 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18569 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18321 18570 | ])
|
18322 18571 | )
|
18323 18572 | ),
|
18324 18573 | )
|
18325 18574 | }
|
18326 18575 | pub(super) fn http_payload_traits_with_media_type(
|
18327 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18328 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18576 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18577 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18329 18578 | ::http::Method::POST,
|
18330 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18331 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18332 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18333 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadTraitsWithMediaType")),
|
18579 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18580 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18581 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18582 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadTraitsWithMediaType")),
|
18334 18583 | ]),
|
18335 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18584 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18336 18585 | ])
|
18337 18586 | )
|
18338 18587 | ),
|
18339 18588 | )
|
18340 18589 | }
|
18341 18590 | pub(super) fn http_payload_with_structure(
|
18342 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18343 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18591 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18592 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18344 18593 | ::http::Method::PUT,
|
18345 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18346 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18347 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18348 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadWithStructure")),
|
18594 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18595 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18596 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18597 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadWithStructure")),
|
18349 18598 | ]),
|
18350 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18599 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18351 18600 | ])
|
18352 18601 | )
|
18353 18602 | ),
|
18354 18603 | )
|
18355 18604 | }
|
18356 18605 | pub(super) fn http_payload_with_union(
|
18357 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18358 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18606 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18607 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18359 18608 | ::http::Method::PUT,
|
18360 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18361 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18362 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18363 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadWithUnion")),
|
18609 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18610 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18611 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18612 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPayloadWithUnion")),
|
18364 18613 | ]),
|
18365 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18614 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18366 18615 | ])
|
18367 18616 | )
|
18368 18617 | ),
|
18369 18618 | )
|
18370 18619 | }
|
18371 18620 | pub(super) fn http_prefix_headers(
|
18372 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18373 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18621 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18622 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18374 18623 | ::http::Method::GET,
|
18375 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18376 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18377 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18378 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPrefixHeaders")),
|
18624 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18625 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18626 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18627 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPrefixHeaders")),
|
18379 18628 | ]),
|
18380 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18629 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18381 18630 | ])
|
18382 18631 | )
|
18383 18632 | ),
|
18384 18633 | )
|
18385 18634 | }
|
18386 18635 | pub(super) fn http_prefix_headers_in_response(
|
18387 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18388 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18636 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18637 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18389 18638 | ::http::Method::GET,
|
18390 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18391 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18392 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18393 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPrefixHeadersResponse")),
|
18639 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18640 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18641 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18642 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpPrefixHeadersResponse")),
|
18394 18643 | ]),
|
18395 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18644 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18396 18645 | ])
|
18397 18646 | )
|
18398 18647 | ),
|
18399 18648 | )
|
18400 18649 | }
|
18401 18650 | pub(super) fn http_request_with_float_labels(
|
18402 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18403 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18651 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18652 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18404 18653 | ::http::Method::GET,
|
18405 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18406 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18407 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18408 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("FloatHttpLabels")),
|
18409 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18410 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18654 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18655 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18656 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18657 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("FloatHttpLabels")),
|
18658 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18659 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18411 18660 | ]),
|
18412 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18661 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18413 18662 | ])
|
18414 18663 | )
|
18415 18664 | ),
|
18416 18665 | )
|
18417 18666 | }
|
18418 18667 | pub(super) fn http_request_with_greedy_label_in_path(
|
18419 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18420 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18668 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18669 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18421 18670 | ::http::Method::GET,
|
18422 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18423 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18424 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18425 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithGreedyLabelInPath")),
|
18426 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("foo")),
|
18427 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18428 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("baz")),
|
18429 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Greedy,
|
18671 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18672 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18673 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18674 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithGreedyLabelInPath")),
|
18675 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("foo")),
|
18676 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18677 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("baz")),
|
18678 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Greedy,
|
18430 18679 | ]),
|
18431 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18680 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18432 18681 | ])
|
18433 18682 | )
|
18434 18683 | ),
|
18435 18684 | )
|
18436 18685 | }
|
18437 18686 | pub(super) fn http_request_with_labels(
|
18438 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18439 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18687 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18688 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18440 18689 | ::http::Method::GET,
|
18441 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18442 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18443 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18444 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithLabels")),
|
18445 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18446 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18447 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18448 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18449 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18450 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18451 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18452 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18690 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18691 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18692 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18693 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithLabels")),
|
18694 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18695 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18696 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18697 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18698 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18699 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18700 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18701 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18453 18702 | ]),
|
18454 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18703 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18455 18704 | ])
|
18456 18705 | )
|
18457 18706 | ),
|
18458 18707 | )
|
18459 18708 | }
|
18460 18709 | pub(super) fn http_request_with_labels_and_timestamp_format(
|
18461 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18462 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18710 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18711 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18463 18712 | ::http::Method::GET,
|
18464 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18465 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18466 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18467 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithLabelsAndTimestampFormat")),
|
18468 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18469 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18470 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18471 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18472 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18473 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18474 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18713 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18714 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18715 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18716 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpRequestWithLabelsAndTimestampFormat")),
|
18717 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18718 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18719 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18720 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18721 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18722 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18723 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18475 18724 | ]),
|
18476 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18725 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18477 18726 | ])
|
18478 18727 | )
|
18479 18728 | ),
|
18480 18729 | )
|
18481 18730 | }
|
18482 18731 | pub(super) fn http_request_with_regex_literal(
|
18483 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18484 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18732 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18733 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18485 18734 | ::http::Method::GET,
|
18486 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18487 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18488 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18489 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("ReDosLiteral")),
|
18490 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18491 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("(a+)+")),
|
18735 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18736 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18737 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18738 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("ReDosLiteral")),
|
18739 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18740 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("(a+)+")),
|
18492 18741 | ]),
|
18493 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18742 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18494 18743 | ])
|
18495 18744 | )
|
18496 18745 | ),
|
18497 18746 | )
|
18498 18747 | }
|
18499 18748 | pub(super) fn http_response_code(
|
18500 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18501 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18749 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18750 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18502 18751 | ::http::Method::PUT,
|
18503 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18504 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18505 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18506 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpResponseCode")),
|
18752 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18753 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18754 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18755 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("HttpResponseCode")),
|
18507 18756 | ]),
|
18508 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18757 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18509 18758 | ])
|
18510 18759 | )
|
18511 18760 | ),
|
18512 18761 | )
|
18513 18762 | }
|
18514 18763 | pub(super) fn http_string_payload(
|
18515 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18516 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18764 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18765 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18517 18766 | ::http::Method::POST,
|
18518 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18519 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18520 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18521 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("StringPayload")),
|
18767 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18768 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18769 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18770 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("StringPayload")),
|
18522 18771 | ]),
|
18523 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18772 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18524 18773 | ])
|
18525 18774 | )
|
18526 18775 | ),
|
18527 18776 | )
|
18528 18777 | }
|
18529 18778 | pub(super) fn ignore_query_params_in_response(
|
18530 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18531 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18779 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18780 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18532 18781 | ::http::Method::GET,
|
18533 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18534 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18535 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18536 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("IgnoreQueryParamsInResponse")),
|
18782 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18783 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18784 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18785 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("IgnoreQueryParamsInResponse")),
|
18537 18786 | ]),
|
18538 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18787 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18539 18788 | ])
|
18540 18789 | )
|
18541 18790 | ),
|
18542 18791 | )
|
18543 18792 | }
|
18544 18793 | pub(super) fn input_and_output_with_headers(
|
18545 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18546 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18794 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18795 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18547 18796 | ::http::Method::POST,
|
18548 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18549 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18550 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18551 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("InputAndOutputWithHeaders")),
|
18797 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18798 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18799 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18800 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("InputAndOutputWithHeaders")),
|
18552 18801 | ]),
|
18553 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18802 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18554 18803 | ])
|
18555 18804 | )
|
18556 18805 | ),
|
18557 18806 | )
|
18558 18807 | }
|
18559 - | pub(super) fn json_blobs() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18560 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18808 + | pub(super) fn json_blobs() -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec
|
18809 + | {
|
18810 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18561 18811 | ::http::Method::POST,
|
18562 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18563 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18564 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18565 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonBlobs")),
|
18812 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18813 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18814 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18815 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonBlobs")),
|
18566 18816 | ]),
|
18567 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18817 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18568 18818 | ])
|
18569 18819 | )
|
18570 18820 | ),
|
18571 18821 | )
|
18572 18822 | }
|
18573 - | pub(super) fn json_enums() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18574 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18823 + | pub(super) fn json_enums() -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec
|
18824 + | {
|
18825 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18575 18826 | ::http::Method::PUT,
|
18576 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18577 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18578 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18579 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonEnums")),
|
18827 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18828 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18829 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18830 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonEnums")),
|
18580 18831 | ]),
|
18581 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18832 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18582 18833 | ])
|
18583 18834 | )
|
18584 18835 | ),
|
18585 18836 | )
|
18586 18837 | }
|
18587 - | pub(super) fn json_int_enums() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18588 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18838 + | pub(super) fn json_int_enums(
|
18839 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18840 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18589 18841 | ::http::Method::PUT,
|
18590 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18591 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18592 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18593 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonIntEnums")),
|
18842 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18843 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18844 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18845 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonIntEnums")),
|
18594 18846 | ]),
|
18595 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18847 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18596 18848 | ])
|
18597 18849 | )
|
18598 18850 | ),
|
18599 18851 | )
|
18600 18852 | }
|
18601 - | pub(super) fn json_lists() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18602 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18853 + | pub(super) fn json_lists() -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec
|
18854 + | {
|
18855 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18603 18856 | ::http::Method::PUT,
|
18604 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18605 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18606 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18607 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonLists")),
|
18857 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18858 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18859 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18860 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonLists")),
|
18608 18861 | ]),
|
18609 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18862 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18610 18863 | ])
|
18611 18864 | )
|
18612 18865 | ),
|
18613 18866 | )
|
18614 18867 | }
|
18615 - | pub(super) fn json_maps() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18616 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18868 + | pub(super) fn json_maps() -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec
|
18869 + | {
|
18870 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18617 18871 | ::http::Method::POST,
|
18618 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18619 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18620 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18621 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonMaps")),
|
18872 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18873 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18874 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18875 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonMaps")),
|
18622 18876 | ]),
|
18623 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18877 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18624 18878 | ])
|
18625 18879 | )
|
18626 18880 | ),
|
18627 18881 | )
|
18628 18882 | }
|
18629 - | pub(super) fn json_timestamps() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18630 - | {
|
18631 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18883 + | pub(super) fn json_timestamps(
|
18884 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18885 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18632 18886 | ::http::Method::POST,
|
18633 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18634 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18635 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18636 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonTimestamps")),
|
18887 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18888 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18889 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18890 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonTimestamps")),
|
18637 18891 | ]),
|
18638 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18892 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18639 18893 | ])
|
18640 18894 | )
|
18641 18895 | ),
|
18642 18896 | )
|
18643 18897 | }
|
18644 - | pub(super) fn json_unions() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18645 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18898 + | pub(super) fn json_unions(
|
18899 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18900 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18646 18901 | ::http::Method::PUT,
|
18647 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18648 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18649 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18650 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonUnions")),
|
18902 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18903 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18904 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18905 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("JsonUnions")),
|
18651 18906 | ]),
|
18652 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18907 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18653 18908 | ])
|
18654 18909 | )
|
18655 18910 | ),
|
18656 18911 | )
|
18657 18912 | }
|
18658 18913 | pub(super) fn malformed_accept_with_body(
|
18659 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18660 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18914 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18915 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18661 18916 | ::http::Method::POST,
|
18662 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18663 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18664 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18665 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithBody")),
|
18917 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18918 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18919 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18920 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithBody")),
|
18666 18921 | ]),
|
18667 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18922 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18668 18923 | ])
|
18669 18924 | )
|
18670 18925 | ),
|
18671 18926 | )
|
18672 18927 | }
|
18673 18928 | pub(super) fn malformed_accept_with_generic_string(
|
18674 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18675 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18929 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18930 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18676 18931 | ::http::Method::POST,
|
18677 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18678 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18679 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18680 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithGenericString")),
|
18932 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18933 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18934 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18935 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithGenericString")),
|
18681 18936 | ]),
|
18682 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18937 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18683 18938 | ])
|
18684 18939 | )
|
18685 18940 | ),
|
18686 18941 | )
|
18687 18942 | }
|
18688 18943 | pub(super) fn malformed_accept_with_payload(
|
18689 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18690 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18944 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18945 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18691 18946 | ::http::Method::POST,
|
18692 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18693 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18694 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18695 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithPayload")),
|
18947 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18948 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18949 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18950 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedAcceptWithPayload")),
|
18696 18951 | ]),
|
18697 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18952 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18698 18953 | ])
|
18699 18954 | )
|
18700 18955 | ),
|
18701 18956 | )
|
18702 18957 | }
|
18703 - | pub(super) fn malformed_blob() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18704 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18958 + | pub(super) fn malformed_blob(
|
18959 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18960 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18705 18961 | ::http::Method::POST,
|
18706 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18707 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18708 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18709 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedBlob")),
|
18962 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18963 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18964 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18965 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedBlob")),
|
18710 18966 | ]),
|
18711 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18967 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18712 18968 | ])
|
18713 18969 | )
|
18714 18970 | ),
|
18715 18971 | )
|
18716 18972 | }
|
18717 - | pub(super) fn malformed_boolean() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18718 - | {
|
18719 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18973 + | pub(super) fn malformed_boolean(
|
18974 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18975 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18720 18976 | ::http::Method::POST,
|
18721 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18722 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18723 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18724 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedBoolean")),
|
18725 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18977 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18978 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18979 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18980 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedBoolean")),
|
18981 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18726 18982 | ]),
|
18727 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18983 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18728 18984 | ])
|
18729 18985 | )
|
18730 18986 | ),
|
18731 18987 | )
|
18732 18988 | }
|
18733 - | pub(super) fn malformed_byte() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18734 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
18989 + | pub(super) fn malformed_byte(
|
18990 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
18991 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18735 18992 | ::http::Method::POST,
|
18736 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18737 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18738 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18739 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedByte")),
|
18740 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
18993 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
18994 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18995 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18996 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedByte")),
|
18997 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18741 18998 | ]),
|
18742 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18999 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18743 19000 | ])
|
18744 19001 | )
|
18745 19002 | ),
|
18746 19003 | )
|
18747 19004 | }
|
18748 19005 | pub(super) fn malformed_content_type_with_body(
|
18749 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18750 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19006 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19007 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18751 19008 | ::http::Method::POST,
|
18752 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18753 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18754 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18755 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithBody")),
|
19009 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19010 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19011 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19012 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithBody")),
|
18756 19013 | ]),
|
18757 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19014 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18758 19015 | ])
|
18759 19016 | )
|
18760 19017 | ),
|
18761 19018 | )
|
18762 19019 | }
|
18763 19020 | pub(super) fn malformed_content_type_with_generic_string(
|
18764 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18765 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19021 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19022 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18766 19023 | ::http::Method::POST,
|
18767 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18768 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18769 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18770 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithGenericString")),
|
19024 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19025 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19026 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19027 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithGenericString")),
|
18771 19028 | ]),
|
18772 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19029 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18773 19030 | ])
|
18774 19031 | )
|
18775 19032 | ),
|
18776 19033 | )
|
18777 19034 | }
|
18778 19035 | pub(super) fn malformed_content_type_without_body(
|
18779 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18780 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19036 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19037 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18781 19038 | ::http::Method::POST,
|
18782 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18783 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18784 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18785 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithoutBody")),
|
19039 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19040 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19041 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19042 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithoutBody")),
|
18786 19043 | ]),
|
18787 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19044 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18788 19045 | ])
|
18789 19046 | )
|
18790 19047 | ),
|
18791 19048 | )
|
18792 19049 | }
|
18793 19050 | pub(super) fn malformed_content_type_without_body_empty_input(
|
18794 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18795 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19051 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19052 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18796 19053 | ::http::Method::POST,
|
18797 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18798 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18799 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18800 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithoutBodyEmptyInput")),
|
19054 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19055 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19056 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19057 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithoutBodyEmptyInput")),
|
18801 19058 | ]),
|
18802 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19059 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18803 19060 | ])
|
18804 19061 | )
|
18805 19062 | ),
|
18806 19063 | )
|
18807 19064 | }
|
18808 19065 | pub(super) fn malformed_content_type_with_payload(
|
18809 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18810 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19066 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19067 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18811 19068 | ::http::Method::POST,
|
18812 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18813 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18814 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18815 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithPayload")),
|
19069 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19070 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19071 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19072 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedContentTypeWithPayload")),
|
18816 19073 | ]),
|
18817 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19074 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18818 19075 | ])
|
18819 19076 | )
|
18820 19077 | ),
|
18821 19078 | )
|
18822 19079 | }
|
18823 - | pub(super) fn malformed_double() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18824 - | {
|
18825 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19080 + | pub(super) fn malformed_double(
|
19081 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19082 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18826 19083 | ::http::Method::POST,
|
18827 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18828 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18829 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18830 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedDouble")),
|
18831 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19084 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19085 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19086 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19087 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedDouble")),
|
19088 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18832 19089 | ]),
|
18833 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19090 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18834 19091 | ])
|
18835 19092 | )
|
18836 19093 | ),
|
18837 19094 | )
|
18838 19095 | }
|
18839 - | pub(super) fn malformed_float() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18840 - | {
|
18841 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19096 + | pub(super) fn malformed_float(
|
19097 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19098 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18842 19099 | ::http::Method::POST,
|
18843 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18844 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18845 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18846 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedFloat")),
|
18847 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19100 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19101 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19102 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19103 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedFloat")),
|
19104 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18848 19105 | ]),
|
18849 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19106 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18850 19107 | ])
|
18851 19108 | )
|
18852 19109 | ),
|
18853 19110 | )
|
18854 19111 | }
|
18855 - | pub(super) fn malformed_integer() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18856 - | {
|
18857 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19112 + | pub(super) fn malformed_integer(
|
19113 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19114 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18858 19115 | ::http::Method::POST,
|
18859 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18860 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18861 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18862 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedInteger")),
|
18863 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19116 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19117 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19118 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19119 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedInteger")),
|
19120 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18864 19121 | ]),
|
18865 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19122 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18866 19123 | ])
|
18867 19124 | )
|
18868 19125 | ),
|
18869 19126 | )
|
18870 19127 | }
|
18871 - | pub(super) fn malformed_list() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18872 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19128 + | pub(super) fn malformed_list(
|
19129 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19130 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18873 19131 | ::http::Method::POST,
|
18874 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18875 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18876 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18877 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedList")),
|
19132 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19133 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19134 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19135 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedList")),
|
18878 19136 | ]),
|
18879 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19137 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18880 19138 | ])
|
18881 19139 | )
|
18882 19140 | ),
|
18883 19141 | )
|
18884 19142 | }
|
18885 - | pub(super) fn malformed_long() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18886 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19143 + | pub(super) fn malformed_long(
|
19144 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19145 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18887 19146 | ::http::Method::POST,
|
18888 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18889 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18890 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18891 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedLong")),
|
18892 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19147 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19148 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19149 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19150 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedLong")),
|
19151 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18893 19152 | ]),
|
18894 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19153 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18895 19154 | ])
|
18896 19155 | )
|
18897 19156 | ),
|
18898 19157 | )
|
18899 19158 | }
|
18900 - | pub(super) fn malformed_map() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18901 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19159 + | pub(super) fn malformed_map(
|
19160 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19161 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18902 19162 | ::http::Method::POST,
|
18903 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18904 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18905 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18906 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedMap")),
|
19163 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19164 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19165 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19166 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedMap")),
|
18907 19167 | ]),
|
18908 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19168 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18909 19169 | ])
|
18910 19170 | )
|
18911 19171 | ),
|
18912 19172 | )
|
18913 19173 | }
|
18914 19174 | pub(super) fn malformed_request_body(
|
18915 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18916 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19175 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19176 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18917 19177 | ::http::Method::POST,
|
18918 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18919 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18920 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18921 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedRequestBody")),
|
19178 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19179 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19180 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19181 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedRequestBody")),
|
18922 19182 | ]),
|
18923 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19183 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18924 19184 | ])
|
18925 19185 | )
|
18926 19186 | ),
|
18927 19187 | )
|
18928 19188 | }
|
18929 - | pub(super) fn malformed_short() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18930 - | {
|
18931 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19189 + | pub(super) fn malformed_short(
|
19190 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19191 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18932 19192 | ::http::Method::POST,
|
18933 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18934 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18935 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18936 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedShort")),
|
18937 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19193 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19194 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19195 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19196 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedShort")),
|
19197 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
18938 19198 | ]),
|
18939 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19199 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18940 19200 | ])
|
18941 19201 | )
|
18942 19202 | ),
|
18943 19203 | )
|
18944 19204 | }
|
18945 - | pub(super) fn malformed_string() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
18946 - | {
|
18947 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19205 + | pub(super) fn malformed_string(
|
19206 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19207 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18948 19208 | ::http::Method::POST,
|
18949 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18950 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18951 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18952 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedString")),
|
19209 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19210 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19211 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19212 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedString")),
|
18953 19213 | ]),
|
18954 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19214 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18955 19215 | ])
|
18956 19216 | )
|
18957 19217 | ),
|
18958 19218 | )
|
18959 19219 | }
|
18960 19220 | pub(super) fn malformed_timestamp_body_date_time(
|
18961 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18962 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19221 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19222 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18963 19223 | ::http::Method::POST,
|
18964 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18965 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18966 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18967 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyDateTime")),
|
19224 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19225 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19226 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19227 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyDateTime")),
|
18968 19228 | ]),
|
18969 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19229 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18970 19230 | ])
|
18971 19231 | )
|
18972 19232 | ),
|
18973 19233 | )
|
18974 19234 | }
|
18975 19235 | pub(super) fn malformed_timestamp_body_default(
|
18976 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18977 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19236 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19237 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18978 19238 | ::http::Method::POST,
|
18979 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18980 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18981 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18982 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyDefault")),
|
19239 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19240 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19241 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19242 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyDefault")),
|
18983 19243 | ]),
|
18984 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19244 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
18985 19245 | ])
|
18986 19246 | )
|
18987 19247 | ),
|
18988 19248 | )
|
18989 19249 | }
|
18990 19250 | pub(super) fn malformed_timestamp_body_http_date(
|
18991 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
18992 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19251 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19252 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
18993 19253 | ::http::Method::POST,
|
18994 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
18995 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
18996 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
18997 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyHttpDate")),
|
19254 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19255 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19256 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19257 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampBodyHttpDate")),
|
18998 19258 | ]),
|
18999 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19259 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19000 19260 | ])
|
19001 19261 | )
|
19002 19262 | ),
|
19003 19263 | )
|
19004 19264 | }
|
19005 19265 | pub(super) fn malformed_timestamp_header_date_time(
|
19006 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19007 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19266 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19267 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19008 19268 | ::http::Method::POST,
|
19009 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19010 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19011 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19012 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderDateTime")),
|
19269 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19270 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19271 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19272 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderDateTime")),
|
19013 19273 | ]),
|
19014 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19274 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19015 19275 | ])
|
19016 19276 | )
|
19017 19277 | ),
|
19018 19278 | )
|
19019 19279 | }
|
19020 19280 | pub(super) fn malformed_timestamp_header_default(
|
19021 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19022 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19281 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19282 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19023 19283 | ::http::Method::POST,
|
19024 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19025 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19026 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19027 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderDefault")),
|
19284 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19285 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19286 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19287 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderDefault")),
|
19028 19288 | ]),
|
19029 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19289 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19030 19290 | ])
|
19031 19291 | )
|
19032 19292 | ),
|
19033 19293 | )
|
19034 19294 | }
|
19035 19295 | pub(super) fn malformed_timestamp_header_epoch(
|
19036 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19037 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19296 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19297 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19038 19298 | ::http::Method::POST,
|
19039 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19040 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19041 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19042 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderEpoch")),
|
19299 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19300 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19301 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19302 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampHeaderEpoch")),
|
19043 19303 | ]),
|
19044 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19304 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19045 19305 | ])
|
19046 19306 | )
|
19047 19307 | ),
|
19048 19308 | )
|
19049 19309 | }
|
19050 19310 | pub(super) fn malformed_timestamp_path_default(
|
19051 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19052 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19311 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19312 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19053 19313 | ::http::Method::POST,
|
19054 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19055 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19056 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19057 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathDefault")),
|
19058 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19314 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19315 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19316 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19317 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathDefault")),
|
19318 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
19059 19319 | ]),
|
19060 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19320 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19061 19321 | ])
|
19062 19322 | )
|
19063 19323 | ),
|
19064 19324 | )
|
19065 19325 | }
|
19066 19326 | pub(super) fn malformed_timestamp_path_epoch(
|
19067 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19068 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19327 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19328 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19069 19329 | ::http::Method::POST,
|
19070 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19071 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19072 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19073 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathEpoch")),
|
19074 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19330 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19331 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19332 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19333 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathEpoch")),
|
19334 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
19075 19335 | ]),
|
19076 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19336 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19077 19337 | ])
|
19078 19338 | )
|
19079 19339 | ),
|
19080 19340 | )
|
19081 19341 | }
|
19082 19342 | pub(super) fn malformed_timestamp_path_http_date(
|
19083 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19084 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19343 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19344 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19085 19345 | ::http::Method::POST,
|
19086 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19087 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19088 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19089 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathHttpDate")),
|
19090 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Label,
|
19346 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19347 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19348 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19349 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampPathHttpDate")),
|
19350 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Label,
|
19091 19351 | ]),
|
19092 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19352 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19093 19353 | ])
|
19094 19354 | )
|
19095 19355 | ),
|
19096 19356 | )
|
19097 19357 | }
|
19098 19358 | pub(super) fn malformed_timestamp_query_default(
|
19099 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19100 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19359 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19360 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19101 19361 | ::http::Method::POST,
|
19102 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19103 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19104 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19105 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryDefault")),
|
19362 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19363 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19364 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19365 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryDefault")),
|
19106 19366 | ]),
|
19107 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19367 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19108 19368 | ])
|
19109 19369 | )
|
19110 19370 | ),
|
19111 19371 | )
|
19112 19372 | }
|
19113 19373 | pub(super) fn malformed_timestamp_query_epoch(
|
19114 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19115 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19374 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19375 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19116 19376 | ::http::Method::POST,
|
19117 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19118 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19119 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19120 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryEpoch")),
|
19377 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19378 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19379 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19380 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryEpoch")),
|
19121 19381 | ]),
|
19122 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19382 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19123 19383 | ])
|
19124 19384 | )
|
19125 19385 | ),
|
19126 19386 | )
|
19127 19387 | }
|
19128 19388 | pub(super) fn malformed_timestamp_query_http_date(
|
19129 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19130 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19389 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19390 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19131 19391 | ::http::Method::POST,
|
19132 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19133 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19134 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19135 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryHttpDate")),
|
19392 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19393 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19394 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19395 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedTimestampQueryHttpDate")),
|
19136 19396 | ]),
|
19137 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19397 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19138 19398 | ])
|
19139 19399 | )
|
19140 19400 | ),
|
19141 19401 | )
|
19142 19402 | }
|
19143 - | pub(super) fn malformed_union() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19144 - | {
|
19145 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19403 + | pub(super) fn malformed_union(
|
19404 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19405 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19146 19406 | ::http::Method::POST,
|
19147 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19148 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19149 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19150 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedUnion")),
|
19407 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19408 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19409 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19410 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MalformedUnion")),
|
19151 19411 | ]),
|
19152 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19412 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19153 19413 | ])
|
19154 19414 | )
|
19155 19415 | ),
|
19156 19416 | )
|
19157 19417 | }
|
19158 - | pub(super) fn media_type_header() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19159 - | {
|
19160 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19418 + | pub(super) fn media_type_header(
|
19419 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19420 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19161 19421 | ::http::Method::GET,
|
19162 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19163 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19164 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19165 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("MediaTypeHeader")),
|
19422 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19423 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19424 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19425 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("MediaTypeHeader")),
|
19166 19426 | ]),
|
19167 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19427 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19168 19428 | ])
|
19169 19429 | )
|
19170 19430 | ),
|
19171 19431 | )
|
19172 19432 | }
|
19173 19433 | pub(super) fn no_input_and_no_output(
|
19174 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19175 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19434 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19435 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19176 19436 | ::http::Method::POST,
|
19177 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19178 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19179 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19180 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("NoInputAndNoOutput")),
|
19437 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19438 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19439 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19440 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("NoInputAndNoOutput")),
|
19181 19441 | ]),
|
19182 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19442 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19183 19443 | ])
|
19184 19444 | )
|
19185 19445 | ),
|
19186 19446 | )
|
19187 19447 | }
|
19188 19448 | pub(super) fn no_input_and_output(
|
19189 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19190 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19449 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19450 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19191 19451 | ::http::Method::POST,
|
19192 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19193 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19194 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19195 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("NoInputAndOutputOutput")),
|
19452 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19453 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19454 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19455 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("NoInputAndOutputOutput")),
|
19196 19456 | ]),
|
19197 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19457 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19198 19458 | ])
|
19199 19459 | )
|
19200 19460 | ),
|
19201 19461 | )
|
19202 19462 | }
|
19203 19463 | pub(super) fn null_and_empty_headers_client(
|
19204 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19205 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19464 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19465 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19206 19466 | ::http::Method::GET,
|
19207 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19208 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19209 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19210 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("NullAndEmptyHeadersClient")),
|
19467 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19468 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19469 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19470 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("NullAndEmptyHeadersClient")),
|
19211 19471 | ]),
|
19212 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19472 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19213 19473 | ])
|
19214 19474 | )
|
19215 19475 | ),
|
19216 19476 | )
|
19217 19477 | }
|
19218 19478 | pub(super) fn null_and_empty_headers_server(
|
19219 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19220 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19479 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19480 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19221 19481 | ::http::Method::GET,
|
19222 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19223 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19224 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19225 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("NullAndEmptyHeadersServer")),
|
19482 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19483 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19484 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19485 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("NullAndEmptyHeadersServer")),
|
19226 19486 | ]),
|
19227 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19487 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19228 19488 | ])
|
19229 19489 | )
|
19230 19490 | ),
|
19231 19491 | )
|
19232 19492 | }
|
19233 19493 | pub(super) fn omits_null_serializes_empty_string(
|
19234 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19235 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19494 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19495 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19236 19496 | ::http::Method::GET,
|
19237 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19238 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19239 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19240 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("OmitsNullSerializesEmptyString")),
|
19497 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19498 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19499 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19500 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("OmitsNullSerializesEmptyString")),
|
19241 19501 | ]),
|
19242 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19502 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19243 19503 | ])
|
19244 19504 | )
|
19245 19505 | ),
|
19246 19506 | )
|
19247 19507 | }
|
19248 19508 | pub(super) fn omits_serializing_empty_lists(
|
19249 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19250 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19509 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19510 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19251 19511 | ::http::Method::POST,
|
19252 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19253 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19254 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19255 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("OmitsSerializingEmptyLists")),
|
19512 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19513 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19514 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19515 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("OmitsSerializingEmptyLists")),
|
19256 19516 | ]),
|
19257 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19517 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19258 19518 | ])
|
19259 19519 | )
|
19260 19520 | ),
|
19261 19521 | )
|
19262 19522 | }
|
19263 19523 | pub(super) fn operation_with_defaults(
|
19264 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19265 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19524 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19525 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19266 19526 | ::http::Method::POST,
|
19267 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19268 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19269 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19270 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("OperationWithDefaults")),
|
19527 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19528 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19529 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19530 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("OperationWithDefaults")),
|
19271 19531 | ]),
|
19272 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19532 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19273 19533 | ])
|
19274 19534 | )
|
19275 19535 | ),
|
19276 19536 | )
|
19277 19537 | }
|
19278 19538 | pub(super) fn operation_with_nested_structure(
|
19279 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19280 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19539 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19540 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19281 19541 | ::http::Method::POST,
|
19282 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19283 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19284 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19285 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("OperationWithNestedStructure")),
|
19542 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19543 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19544 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19545 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("OperationWithNestedStructure")),
|
19286 19546 | ]),
|
19287 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19547 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19288 19548 | ])
|
19289 19549 | )
|
19290 19550 | ),
|
19291 19551 | )
|
19292 19552 | }
|
19293 19553 | pub(super) fn post_player_action(
|
19294 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19295 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19554 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19555 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19296 19556 | ::http::Method::POST,
|
19297 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19298 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19299 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19300 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("PostPlayerAction")),
|
19557 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19558 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19559 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19560 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("PostPlayerAction")),
|
19301 19561 | ]),
|
19302 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19562 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19303 19563 | ])
|
19304 19564 | )
|
19305 19565 | ),
|
19306 19566 | )
|
19307 19567 | }
|
19308 19568 | pub(super) fn post_union_with_json_name(
|
19309 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19310 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19569 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19570 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19311 19571 | ::http::Method::POST,
|
19312 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19313 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19314 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19315 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("PostUnionWithJsonName")),
|
19572 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19573 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19574 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19575 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("PostUnionWithJsonName")),
|
19316 19576 | ]),
|
19317 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19577 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19318 19578 | ])
|
19319 19579 | )
|
19320 19580 | ),
|
19321 19581 | )
|
19322 19582 | }
|
19323 19583 | pub(super) fn put_with_content_encoding(
|
19324 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19325 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19584 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19585 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19326 19586 | ::http::Method::POST,
|
19327 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19328 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19329 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19330 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("requestcompression")),
|
19331 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("putcontentwithencoding")),
|
19587 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19588 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19589 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19590 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("requestcompression")),
|
19591 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("putcontentwithencoding")),
|
19332 19592 | ]),
|
19333 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19593 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19334 19594 | ])
|
19335 19595 | )
|
19336 19596 | ),
|
19337 19597 | )
|
19338 19598 | }
|
19339 19599 | pub(super) fn query_idempotency_token_auto_fill(
|
19340 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19341 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19600 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19601 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19342 19602 | ::http::Method::POST,
|
19343 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19344 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19345 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19346 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("QueryIdempotencyTokenAutoFill")),
|
19603 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19604 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19605 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19606 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("QueryIdempotencyTokenAutoFill")),
|
19347 19607 | ]),
|
19348 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19608 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19349 19609 | ])
|
19350 19610 | )
|
19351 19611 | ),
|
19352 19612 | )
|
19353 19613 | }
|
19354 19614 | pub(super) fn query_params_as_string_list_map(
|
19355 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19356 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19615 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19616 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19357 19617 | ::http::Method::POST,
|
19358 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19359 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19360 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19361 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("StringListMap")),
|
19618 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19619 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19620 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19621 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("StringListMap")),
|
19362 19622 | ]),
|
19363 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19623 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19364 19624 | ])
|
19365 19625 | )
|
19366 19626 | ),
|
19367 19627 | )
|
19368 19628 | }
|
19369 - | pub(super) fn query_precedence() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19370 - | {
|
19371 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19629 + | pub(super) fn query_precedence(
|
19630 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19631 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19372 19632 | ::http::Method::POST,
|
19373 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19374 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19375 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19376 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("Precedence")),
|
19633 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19634 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19635 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19636 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("Precedence")),
|
19377 19637 | ]),
|
19378 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19638 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19379 19639 | ])
|
19380 19640 | )
|
19381 19641 | ),
|
19382 19642 | )
|
19383 19643 | }
|
19384 - | pub(super) fn recursive_shapes() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19385 - | {
|
19386 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19644 + | pub(super) fn recursive_shapes(
|
19645 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19646 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19387 19647 | ::http::Method::PUT,
|
19388 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19389 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19390 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19391 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("RecursiveShapes")),
|
19648 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19649 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19650 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19651 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("RecursiveShapes")),
|
19392 19652 | ]),
|
19393 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19653 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19394 19654 | ])
|
19395 19655 | )
|
19396 19656 | ),
|
19397 19657 | )
|
19398 19658 | }
|
19399 19659 | pub(super) fn response_code_http_fallback(
|
19400 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19401 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19660 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19661 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19402 19662 | ::http::Method::GET,
|
19403 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19404 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19405 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19406 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("responseCodeHttpFallback")),
|
19663 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19664 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19665 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19666 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("responseCodeHttpFallback")),
|
19407 19667 | ]),
|
19408 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19668 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19409 19669 | ])
|
19410 19670 | )
|
19411 19671 | ),
|
19412 19672 | )
|
19413 19673 | }
|
19414 19674 | pub(super) fn response_code_required(
|
19415 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19416 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19675 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19676 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19417 19677 | ::http::Method::GET,
|
19418 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19419 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19420 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19421 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("responseCodeRequired")),
|
19678 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19679 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19680 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19681 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("responseCodeRequired")),
|
19422 19682 | ]),
|
19423 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19683 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19424 19684 | ])
|
19425 19685 | )
|
19426 19686 | ),
|
19427 19687 | )
|
19428 19688 | }
|
19429 19689 | pub(super) fn simple_scalar_properties(
|
19430 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19431 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19690 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19691 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19432 19692 | ::http::Method::PUT,
|
19433 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19434 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19435 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19436 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("SimpleScalarProperties")),
|
19693 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19694 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19695 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19696 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("SimpleScalarProperties")),
|
19437 19697 | ]),
|
19438 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19698 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19439 19699 | ])
|
19440 19700 | )
|
19441 19701 | ),
|
19442 19702 | )
|
19443 19703 | }
|
19444 - | pub(super) fn sparse_json_lists() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19445 - | {
|
19446 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19704 + | pub(super) fn sparse_json_lists(
|
19705 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19706 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19447 19707 | ::http::Method::PUT,
|
19448 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19449 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19450 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19451 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("SparseJsonLists")),
|
19708 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19709 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19710 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19711 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("SparseJsonLists")),
|
19452 19712 | ]),
|
19453 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19713 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19454 19714 | ])
|
19455 19715 | )
|
19456 19716 | ),
|
19457 19717 | )
|
19458 19718 | }
|
19459 - | pub(super) fn sparse_json_maps() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19460 - | {
|
19461 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19719 + | pub(super) fn sparse_json_maps(
|
19720 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19721 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19462 19722 | ::http::Method::POST,
|
19463 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19464 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19465 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19466 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("SparseJsonMaps")),
|
19723 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19724 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19725 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19726 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("SparseJsonMaps")),
|
19467 19727 | ]),
|
19468 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19728 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19469 19729 | ])
|
19470 19730 | )
|
19471 19731 | ),
|
19472 19732 | )
|
19473 19733 | }
|
19474 - | pub(super) fn streaming_traits() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19475 - | {
|
19476 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19734 + | pub(super) fn streaming_traits(
|
19735 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19736 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19477 19737 | ::http::Method::POST,
|
19478 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19479 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19480 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19481 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraits")),
|
19738 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19739 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19740 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19741 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraits")),
|
19482 19742 | ]),
|
19483 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19743 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19484 19744 | ])
|
19485 19745 | )
|
19486 19746 | ),
|
19487 19747 | )
|
19488 19748 | }
|
19489 19749 | pub(super) fn streaming_traits_require_length(
|
19490 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19491 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19750 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19751 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19492 19752 | ::http::Method::POST,
|
19493 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19494 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19495 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19496 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraitsRequireLength")),
|
19753 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19754 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19755 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19756 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraitsRequireLength")),
|
19497 19757 | ]),
|
19498 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19758 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19499 19759 | ])
|
19500 19760 | )
|
19501 19761 | ),
|
19502 19762 | )
|
19503 19763 | }
|
19504 19764 | pub(super) fn streaming_traits_with_media_type(
|
19505 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19506 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19765 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19766 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19507 19767 | ::http::Method::POST,
|
19508 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19509 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19510 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19511 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraitsWithMediaType")),
|
19768 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19769 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19770 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19771 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("StreamingTraitsWithMediaType")),
|
19512 19772 | ]),
|
19513 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19773 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19514 19774 | ])
|
19515 19775 | )
|
19516 19776 | ),
|
19517 19777 | )
|
19518 19778 | }
|
19519 19779 | pub(super) fn test_body_structure(
|
19520 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19521 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19780 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19781 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19522 19782 | ::http::Method::POST,
|
19523 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19524 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19525 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19526 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("body")),
|
19783 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19784 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19785 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19786 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("body")),
|
19527 19787 | ]),
|
19528 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19788 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19529 19789 | ])
|
19530 19790 | )
|
19531 19791 | ),
|
19532 19792 | )
|
19533 19793 | }
|
19534 19794 | pub(super) fn test_get_no_input_no_payload(
|
19535 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19536 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19795 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19796 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19537 19797 | ::http::Method::GET,
|
19538 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19539 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19540 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19541 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_input_no_payload")),
|
19798 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19799 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19800 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19801 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_input_no_payload")),
|
19542 19802 | ]),
|
19543 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19803 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19544 19804 | ])
|
19545 19805 | )
|
19546 19806 | ),
|
19547 19807 | )
|
19548 19808 | }
|
19549 19809 | pub(super) fn test_get_no_payload(
|
19550 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19551 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19810 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19811 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19552 19812 | ::http::Method::GET,
|
19553 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19554 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19555 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19556 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_payload")),
|
19813 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19814 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19815 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19816 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_payload")),
|
19557 19817 | ]),
|
19558 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19818 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19559 19819 | ])
|
19560 19820 | )
|
19561 19821 | ),
|
19562 19822 | )
|
19563 19823 | }
|
19564 - | pub(super) fn test_payload_blob() -> ::aws_smithy_http_server::routing::request_spec::RequestSpec
|
19565 - | {
|
19566 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19824 + | pub(super) fn test_payload_blob(
|
19825 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19826 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19567 19827 | ::http::Method::POST,
|
19568 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19569 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19570 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19571 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("blob_payload")),
|
19828 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19829 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19830 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19831 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("blob_payload")),
|
19572 19832 | ]),
|
19573 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19833 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19574 19834 | ])
|
19575 19835 | )
|
19576 19836 | ),
|
19577 19837 | )
|
19578 19838 | }
|
19579 19839 | pub(super) fn test_payload_structure(
|
19580 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19581 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19840 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19841 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19582 19842 | ::http::Method::POST,
|
19583 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19584 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19585 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19586 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("payload")),
|
19843 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19844 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19845 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19846 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("payload")),
|
19587 19847 | ]),
|
19588 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19848 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19589 19849 | ])
|
19590 19850 | )
|
19591 19851 | ),
|
19592 19852 | )
|
19593 19853 | }
|
19594 19854 | pub(super) fn test_post_no_input_no_payload(
|
19595 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19596 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19855 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19856 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19597 19857 | ::http::Method::POST,
|
19598 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19599 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19600 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19601 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_input_no_payload")),
|
19858 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19859 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19860 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19861 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_input_no_payload")),
|
19602 19862 | ]),
|
19603 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19863 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19604 19864 | ])
|
19605 19865 | )
|
19606 19866 | ),
|
19607 19867 | )
|
19608 19868 | }
|
19609 19869 | pub(super) fn test_post_no_payload(
|
19610 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19611 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19870 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19871 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19612 19872 | ::http::Method::POST,
|
19613 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19614 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19615 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19616 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_payload")),
|
19873 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19874 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19875 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19876 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("no_payload")),
|
19617 19877 | ]),
|
19618 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19878 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19619 19879 | ])
|
19620 19880 | )
|
19621 19881 | ),
|
19622 19882 | )
|
19623 19883 | }
|
19624 19884 | pub(super) fn timestamp_format_headers(
|
19625 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19626 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19885 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19886 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19627 19887 | ::http::Method::POST,
|
19628 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19629 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19630 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19631 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("TimestampFormatHeaders")),
|
19888 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19889 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19890 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19891 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("TimestampFormatHeaders")),
|
19632 19892 | ]),
|
19633 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19893 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19634 19894 | ])
|
19635 19895 | )
|
19636 19896 | ),
|
19637 19897 | )
|
19638 19898 | }
|
19639 19899 | pub(super) fn unit_input_and_output(
|
19640 - | ) -> ::aws_smithy_http_server::routing::request_spec::RequestSpec {
|
19641 - | ::aws_smithy_http_server::routing::request_spec::RequestSpec::new(
|
19900 + | ) -> ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec {
|
19901 + | ::aws_smithy_legacy_http_server::routing::request_spec::RequestSpec::new(
|
19642 19902 | ::http::Method::POST,
|
19643 - | ::aws_smithy_http_server::routing::request_spec::UriSpec::new(
|
19644 - | ::aws_smithy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19645 - | ::aws_smithy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19646 - | ::aws_smithy_http_server::routing::request_spec::PathSegment::Literal(String::from("UnitInputAndOutput")),
|
19903 + | ::aws_smithy_legacy_http_server::routing::request_spec::UriSpec::new(
|
19904 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathAndQuerySpec::new(
|
19905 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSpec::from_vector_unchecked(vec![
|
19906 + | ::aws_smithy_legacy_http_server::routing::request_spec::PathSegment::Literal(String::from("UnitInputAndOutput")),
|
19647 19907 | ]),
|
19648 - | ::aws_smithy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19908 + | ::aws_smithy_legacy_http_server::routing::request_spec::QuerySpec::from_vector_unchecked(vec![
|
19649 19909 | ])
|
19650 19910 | )
|
19651 19911 | ),
|
19652 19912 | )
|
19653 19913 | }
|
19654 19914 | }
|
19655 19915 |
|
19656 19916 | /// A REST JSON service that sends JSON requests and responses.
|
19657 19917 | ///
|
19658 19918 | /// See the [root](crate) documentation for more information.
|
19659 19919 | #[derive(Clone)]
|
19660 19920 | pub struct RestJson<
|
19661 - | S = ::aws_smithy_http_server::routing::RoutingService<
|
19662 - | ::aws_smithy_http_server::protocol::rest::router::RestRouter<
|
19663 - | ::aws_smithy_http_server::routing::Route<::aws_smithy_http_server::body::BoxBody>,
|
19921 + | S = ::aws_smithy_legacy_http_server::routing::RoutingService<
|
19922 + | ::aws_smithy_legacy_http_server::protocol::rest::router::RestRouter<
|
19923 + | ::aws_smithy_legacy_http_server::routing::Route<
|
19924 + | ::aws_smithy_legacy_http_server::body::BoxBody,
|
19925 + | >,
|
19664 19926 | >,
|
19665 - | ::aws_smithy_http_server::protocol::rest_json_1::RestJson1,
|
19927 + | ::aws_smithy_legacy_http_server::protocol::rest_json_1::RestJson1,
|
19666 19928 | >,
|
19667 19929 | > {
|
19668 19930 | // This is the router wrapped by layers.
|
19669 19931 | svc: S,
|
19670 19932 | }
|
19671 19933 |
|
19672 19934 | impl RestJson<()> {
|
19673 19935 | /// Constructs a builder for [`RestJson`].
|
19674 19936 | /// You must specify a configuration object holding any plugins and layers that should be applied
|
19675 19937 | /// to the operations in this service.
|
19676 19938 | pub fn builder<
|
19677 19939 | Body,
|
19678 19940 | L,
|
19679 - | HttpPl: ::aws_smithy_http_server::plugin::HttpMarker,
|
19680 - | ModelPl: ::aws_smithy_http_server::plugin::ModelMarker,
|
19941 + | HttpPl: ::aws_smithy_legacy_http_server::plugin::HttpMarker,
|
19942 + | ModelPl: ::aws_smithy_legacy_http_server::plugin::ModelMarker,
|
19681 19943 | >(
|
19682 19944 | config: RestJsonConfig<L, HttpPl, ModelPl>,
|
19683 19945 | ) -> RestJsonBuilder<Body, L, HttpPl, ModelPl> {
|
19684 19946 | RestJsonBuilder {
|
19685 19947 | all_query_string_types: None,
|
19686 19948 | constant_and_variable_query_string: None,
|
19687 19949 | constant_query_string: None,
|
19688 19950 | content_type_parameters: None,
|
19689 19951 | datetime_offsets: None,
|
19690 19952 | document_type: None,
|