1 1 | // Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
|
2 + | /* RustType.kt:516 */
|
2 3 | #[::napi_derive::napi(object)]
|
4 + | /* StructureGenerator.kt:197 */
|
3 5 | #[allow(missing_docs)] // documentation missing in model
|
6 + | /* RustType.kt:516 */
|
4 7 | #[derive(
|
5 8 | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
6 9 | )]
|
7 - | pub struct GetPokemonSpeciesOutput {
|
8 - | /// The name for this resource.
|
10 + | pub /* StructureGenerator.kt:201 */ struct GetPokemonSpeciesOutput {
|
11 + | /// /* StructureGenerator.kt:231 */The name for this resource.
|
9 12 | pub name: ::std::string::String,
|
10 - | /// A list of flavor text entries for this Pokémon species.
|
13 + | /// /* StructureGenerator.kt:231 */A list of flavor text entries for this Pokémon species.
|
11 14 | pub flavor_text_entries: ::std::vec::Vec<crate::model::FlavorText>,
|
15 + | /* StructureGenerator.kt:201 */
|
12 16 | }
|
17 + | /* StructureGenerator.kt:135 */
|
13 18 | impl GetPokemonSpeciesOutput {
|
14 - | /// The name for this resource.
|
19 + | /// /* StructureGenerator.kt:231 */The name for this resource.
|
20 + | /* StructureGenerator.kt:166 */
|
15 21 | pub fn name(&self) -> &str {
|
22 + | /* StructureGenerator.kt:171 */
|
16 23 | use std::ops::Deref;
|
17 24 | self.name.deref()
|
25 + | /* StructureGenerator.kt:166 */
|
18 26 | }
|
19 - | /// A list of flavor text entries for this Pokémon species.
|
27 + | /// /* StructureGenerator.kt:231 */A list of flavor text entries for this Pokémon species.
|
28 + | /* StructureGenerator.kt:166 */
|
20 29 | pub fn flavor_text_entries(&self) -> &[crate::model::FlavorText] {
|
30 + | /* StructureGenerator.kt:171 */
|
21 31 | use std::ops::Deref;
|
22 32 | self.flavor_text_entries.deref()
|
33 + | /* StructureGenerator.kt:166 */
|
23 34 | }
|
35 + | /* StructureGenerator.kt:135 */
|
24 36 | }
|
37 + | /* ServerCodegenVisitor.kt:370 */
|
25 38 | impl GetPokemonSpeciesOutput {
|
26 - | /// Creates a new builder-style object to manufacture [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
39 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:211 */Creates a new builder-style object to manufacture [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
40 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
27 41 | pub fn builder() -> crate::output::get_pokemon_species_output::Builder {
|
42 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:213 */
|
28 43 | crate::output::get_pokemon_species_output::Builder::default()
|
44 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
29 45 | }
|
46 + | /* ServerCodegenVisitor.kt:370 */
|
30 47 | }
|
31 48 |
|
49 + | /* RustType.kt:516 */
|
32 50 | #[::napi_derive::napi(object)]
|
51 + | /* StructureGenerator.kt:197 */
|
33 52 | #[allow(missing_docs)] // documentation missing in model
|
53 + | /* RustType.kt:516 */
|
34 54 | #[derive(
|
35 55 | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
36 56 | )]
|
37 - | pub struct CheckHealthOutput {}
|
57 + | pub /* StructureGenerator.kt:201 */ struct CheckHealthOutput {/* StructureGenerator.kt:201 */}
|
58 + | /* ServerCodegenVisitor.kt:370 */
|
38 59 | impl CheckHealthOutput {
|
39 - | /// Creates a new builder-style object to manufacture [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
60 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:211 */Creates a new builder-style object to manufacture [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
61 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
40 62 | pub fn builder() -> crate::output::check_health_output::Builder {
|
63 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:213 */
|
41 64 | crate::output::check_health_output::Builder::default()
|
65 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
42 66 | }
|
67 + | /* ServerCodegenVisitor.kt:370 */
|
43 68 | }
|
44 69 |
|
70 + | /* RustType.kt:516 */
|
45 71 | #[::napi_derive::napi(object)]
|
72 + | /* StructureGenerator.kt:197 */
|
46 73 | #[allow(missing_docs)] // documentation missing in model
|
74 + | /* RustType.kt:516 */
|
47 75 | #[derive(
|
48 76 | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
49 77 | )]
|
50 - | pub struct DoNothingOutput {}
|
78 + | pub /* StructureGenerator.kt:201 */ struct DoNothingOutput {/* StructureGenerator.kt:201 */}
|
79 + | /* ServerCodegenVisitor.kt:370 */
|
51 80 | impl DoNothingOutput {
|
52 - | /// Creates a new builder-style object to manufacture [`DoNothingOutput`](crate::output::DoNothingOutput).
|
81 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:211 */Creates a new builder-style object to manufacture [`DoNothingOutput`](crate::output::DoNothingOutput).
|
82 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
53 83 | pub fn builder() -> crate::output::do_nothing_output::Builder {
|
84 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:213 */
|
54 85 | crate::output::do_nothing_output::Builder::default()
|
86 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
55 87 | }
|
88 + | /* ServerCodegenVisitor.kt:370 */
|
56 89 | }
|
57 90 |
|
91 + | /* RustType.kt:516 */
|
58 92 | #[::napi_derive::napi(object)]
|
93 + | /* StructureGenerator.kt:197 */
|
59 94 | #[allow(missing_docs)] // documentation missing in model
|
95 + | /* RustType.kt:516 */
|
60 96 | #[derive(
|
61 97 | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
62 98 | )]
|
63 - | pub struct GetServerStatisticsOutput {
|
64 - | /// The number of calls executed by the server.
|
99 + | pub /* StructureGenerator.kt:201 */ struct GetServerStatisticsOutput {
|
100 + | /// /* StructureGenerator.kt:231 */The number of calls executed by the server.
|
65 101 | pub calls_count: i64,
|
102 + | /* StructureGenerator.kt:201 */
|
66 103 | }
|
104 + | /* StructureGenerator.kt:135 */
|
67 105 | impl GetServerStatisticsOutput {
|
68 - | /// The number of calls executed by the server.
|
106 + | /// /* StructureGenerator.kt:231 */The number of calls executed by the server.
|
107 + | /* StructureGenerator.kt:166 */
|
69 108 | pub fn calls_count(&self) -> i64 {
|
109 + | /* StructureGenerator.kt:168 */
|
70 110 | self.calls_count
|
111 + | /* StructureGenerator.kt:166 */
|
71 112 | }
|
113 + | /* StructureGenerator.kt:135 */
|
72 114 | }
|
115 + | /* ServerCodegenVisitor.kt:370 */
|
73 116 | impl GetServerStatisticsOutput {
|
74 - | /// Creates a new builder-style object to manufacture [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
117 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:211 */Creates a new builder-style object to manufacture [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
118 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
75 119 | pub fn builder() -> crate::output::get_server_statistics_output::Builder {
|
120 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:213 */
|
76 121 | crate::output::get_server_statistics_output::Builder::default()
|
122 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:212 */
|
77 123 | }
|
124 + | /* ServerCodegenVisitor.kt:370 */
|
78 125 | }
|
79 - | /// See [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
126 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:110 */See [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
80 127 | pub mod get_pokemon_species_output {
|
81 128 |
|
129 + | /* RustType.kt:516 */
|
82 130 | #[derive(::std::cmp::PartialEq, ::std::fmt::Debug)]
|
83 - | /// Holds one variant for each of the ways the builder can fail.
|
84 - |
|
131 + | /// /* ServerBuilderConstraintViolations.kt:72 */Holds one variant for each of the ways the builder can fail.
|
132 + | /* ServerBuilderConstraintViolations.kt:75 */
|
85 133 | #[allow(clippy::enum_variant_names)]
|
86 134 | pub enum ConstraintViolation {
|
87 - | /// `name` was not provided but it is required when building `GetPokemonSpeciesOutput`.
|
135 + | /// /* ServerBuilderConstraintViolations.kt:138 */`name` was not provided but it is required when building `GetPokemonSpeciesOutput`.
|
136 + | /* ServerBuilderConstraintViolations.kt:143 */
|
88 137 | MissingName,
|
89 - | /// `flavor_text_entries` was not provided but it is required when building `GetPokemonSpeciesOutput`.
|
138 + | /// /* ServerBuilderConstraintViolations.kt:138 */`flavor_text_entries` was not provided but it is required when building `GetPokemonSpeciesOutput`.
|
139 + | /* ServerBuilderConstraintViolations.kt:143 */
|
90 140 | MissingFlavorTextEntries,
|
141 + | /* ServerBuilderConstraintViolations.kt:75 */
|
91 142 | }
|
143 + | /* ServerBuilderConstraintViolations.kt:117 */
|
92 144 | impl ::std::fmt::Display for ConstraintViolation {
|
145 + | /* ServerBuilderConstraintViolations.kt:118 */
|
93 146 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
147 + | /* ServerBuilderConstraintViolations.kt:119 */
|
94 148 | match self {
|
95 - | ConstraintViolation::MissingName => write!(f, "`name` was not provided but it is required when building `GetPokemonSpeciesOutput`"),
|
96 - | ConstraintViolation::MissingFlavorTextEntries => write!(f, "`flavor_text_entries` was not provided but it is required when building `GetPokemonSpeciesOutput`"),
|
97 - | }
|
149 + | /* ServerBuilderConstraintViolations.kt:127 */ConstraintViolation::MissingName => write!(f, "`name` was not provided but it is required when building `GetPokemonSpeciesOutput`"),
|
150 + | /* ServerBuilderConstraintViolations.kt:127 */ConstraintViolation::MissingFlavorTextEntries => write!(f, "`flavor_text_entries` was not provided but it is required when building `GetPokemonSpeciesOutput`"),
|
151 + | /* ServerBuilderConstraintViolations.kt:119 */}
|
152 + | /* ServerBuilderConstraintViolations.kt:118 */
|
98 153 | }
|
154 + | /* ServerBuilderConstraintViolations.kt:117 */
|
99 155 | }
|
156 + | /* ServerBuilderConstraintViolations.kt:84 */
|
100 157 | impl ::std::error::Error for ConstraintViolation {}
|
158 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:254 */
|
101 159 | impl ::std::convert::TryFrom<Builder> for crate::output::GetPokemonSpeciesOutput {
|
102 160 | type Error = ConstraintViolation;
|
103 161 |
|
104 162 | fn try_from(builder: Builder) -> ::std::result::Result<Self, Self::Error> {
|
105 163 | builder.build()
|
106 164 | }
|
107 165 | }
|
108 - | /// A builder for [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
166 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:130 */A builder for [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
167 + | /* RustType.kt:516 */
|
109 168 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
169 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
110 170 | pub struct Builder {
|
171 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:225 */
|
111 172 | pub(crate) name: ::std::option::Option<::std::string::String>,
|
173 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:225 */
|
112 174 | pub(crate) flavor_text_entries:
|
113 175 | ::std::option::Option<::std::vec::Vec<crate::model::FlavorText>>,
|
176 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
114 177 | }
|
178 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
115 179 | impl Builder {
|
116 - | /// The name for this resource.
|
180 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:241 */The name for this resource.
|
181 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
117 182 | pub fn name(mut self, input: ::std::string::String) -> Self {
|
118 - | self.name = Some(input);
|
183 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */
|
184 + | self.name =
|
185 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */Some(
|
186 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:247 */input
|
187 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */)
|
188 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */;
|
119 189 | self
|
190 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
120 191 | }
|
121 - | /// A list of flavor text entries for this Pokémon species.
|
192 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:241 */A list of flavor text entries for this Pokémon species.
|
193 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
122 194 | pub fn flavor_text_entries(
|
123 195 | mut self,
|
124 196 | input: ::std::vec::Vec<crate::model::FlavorText>,
|
125 197 | ) -> Self {
|
126 - | self.flavor_text_entries = Some(input);
|
198 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */
|
199 + | self.flavor_text_entries =
|
200 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */Some(
|
201 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:247 */input
|
202 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */)
|
203 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */;
|
127 204 | self
|
205 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
128 206 | }
|
129 - | /// Consumes the builder and constructs a [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
130 - | ///
|
207 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:150 */Consumes the builder and constructs a [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput).
|
208 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:152 */
|
131 209 | /// The builder fails to construct a [`GetPokemonSpeciesOutput`](crate::output::GetPokemonSpeciesOutput) if you do not provide a value for all non-`Option`al members.
|
132 210 | ///
|
211 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:159 */
|
133 212 | pub fn build(self) -> Result<crate::output::GetPokemonSpeciesOutput, ConstraintViolation> {
|
134 213 | self.build_enforcing_required_and_enum_traits()
|
135 214 | }
|
215 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
136 216 | fn build_enforcing_required_and_enum_traits(
|
137 217 | self,
|
138 218 | ) -> Result<crate::output::GetPokemonSpeciesOutput, ConstraintViolation> {
|
139 - | Ok(crate::output::GetPokemonSpeciesOutput {
|
140 - | name: self.name.ok_or(ConstraintViolation::MissingName)?,
|
141 - | flavor_text_entries: self
|
142 - | .flavor_text_entries
|
143 - | .ok_or(ConstraintViolation::MissingFlavorTextEntries)?,
|
144 - | })
|
219 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:175 */
|
220 + | Ok(
|
221 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
222 + | crate::output::GetPokemonSpeciesOutput {
|
223 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:186 */
|
224 + | name: self
|
225 + | .name
|
226 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:202 */
|
227 + | .ok_or(ConstraintViolation::MissingName)?,
|
228 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:186 */
|
229 + | flavor_text_entries: self
|
230 + | .flavor_text_entries
|
231 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:202 */
|
232 + | .ok_or(ConstraintViolation::MissingFlavorTextEntries)?,
|
233 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
234 + | }, /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:175 */
|
235 + | )
|
236 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
145 237 | }
|
238 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
146 239 | }
|
240 + |
|
241 + | /* RustCrateInlineModuleComposingWriter.kt:299 */
|
147 242 | }
|
148 - | /// See [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
243 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:110 */See [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
149 244 | pub mod check_health_output {
|
150 245 |
|
246 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:269 */
|
151 247 | impl ::std::convert::From<Builder> for crate::output::CheckHealthOutput {
|
152 248 | fn from(builder: Builder) -> Self {
|
153 249 | builder.build()
|
154 250 | }
|
155 251 | }
|
156 - | /// A builder for [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
252 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:130 */A builder for [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
253 + | /* RustType.kt:516 */
|
157 254 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
158 - | pub struct Builder {}
|
255 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
256 + | pub struct Builder {/* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */}
|
257 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
159 258 | impl Builder {
|
160 - | /// Consumes the builder and constructs a [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
259 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:150 */Consumes the builder and constructs a [`CheckHealthOutput`](crate::output::CheckHealthOutput).
|
260 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:159 */
|
161 261 | pub fn build(self) -> crate::output::CheckHealthOutput {
|
162 262 | self.build_enforcing_required_and_enum_traits()
|
163 263 | }
|
264 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
164 265 | fn build_enforcing_required_and_enum_traits(self) -> crate::output::CheckHealthOutput {
|
165 - | crate::output::CheckHealthOutput {}
|
266 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
267 + | crate::output::CheckHealthOutput {
|
268 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */}
|
269 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
166 270 | }
|
271 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
167 272 | }
|
273 + |
|
274 + | /* RustCrateInlineModuleComposingWriter.kt:299 */
|
168 275 | }
|
169 - | /// See [`DoNothingOutput`](crate::output::DoNothingOutput).
|
276 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:110 */See [`DoNothingOutput`](crate::output::DoNothingOutput).
|
170 277 | pub mod do_nothing_output {
|
171 278 |
|
279 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:269 */
|
172 280 | impl ::std::convert::From<Builder> for crate::output::DoNothingOutput {
|
173 281 | fn from(builder: Builder) -> Self {
|
174 282 | builder.build()
|
175 283 | }
|
176 284 | }
|
177 - | /// A builder for [`DoNothingOutput`](crate::output::DoNothingOutput).
|
285 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:130 */A builder for [`DoNothingOutput`](crate::output::DoNothingOutput).
|
286 + | /* RustType.kt:516 */
|
178 287 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
179 - | pub struct Builder {}
|
288 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
289 + | pub struct Builder {/* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */}
|
290 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
180 291 | impl Builder {
|
181 - | /// Consumes the builder and constructs a [`DoNothingOutput`](crate::output::DoNothingOutput).
|
292 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:150 */Consumes the builder and constructs a [`DoNothingOutput`](crate::output::DoNothingOutput).
|
293 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:159 */
|
182 294 | pub fn build(self) -> crate::output::DoNothingOutput {
|
183 295 | self.build_enforcing_required_and_enum_traits()
|
184 296 | }
|
297 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
185 298 | fn build_enforcing_required_and_enum_traits(self) -> crate::output::DoNothingOutput {
|
186 - | crate::output::DoNothingOutput {}
|
299 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
300 + | crate::output::DoNothingOutput {
|
301 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */}
|
302 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
187 303 | }
|
304 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
188 305 | }
|
306 + |
|
307 + | /* RustCrateInlineModuleComposingWriter.kt:299 */
|
189 308 | }
|
190 - | /// See [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
309 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:110 */See [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
191 310 | pub mod get_server_statistics_output {
|
192 311 |
|
312 + | /* RustType.kt:516 */
|
193 313 | #[derive(::std::cmp::PartialEq, ::std::fmt::Debug)]
|
194 - | /// Holds one variant for each of the ways the builder can fail.
|
195 - |
|
314 + | /// /* ServerBuilderConstraintViolations.kt:72 */Holds one variant for each of the ways the builder can fail.
|
315 + | /* ServerBuilderConstraintViolations.kt:75 */
|
196 316 | #[allow(clippy::enum_variant_names)]
|
197 317 | pub enum ConstraintViolation {
|
198 - | /// `calls_count` was not provided but it is required when building `GetServerStatisticsOutput`.
|
318 + | /// /* ServerBuilderConstraintViolations.kt:138 */`calls_count` was not provided but it is required when building `GetServerStatisticsOutput`.
|
319 + | /* ServerBuilderConstraintViolations.kt:143 */
|
199 320 | MissingCallsCount,
|
321 + | /* ServerBuilderConstraintViolations.kt:75 */
|
200 322 | }
|
323 + | /* ServerBuilderConstraintViolations.kt:117 */
|
201 324 | impl ::std::fmt::Display for ConstraintViolation {
|
325 + | /* ServerBuilderConstraintViolations.kt:118 */
|
202 326 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
327 + | /* ServerBuilderConstraintViolations.kt:119 */
|
203 328 | match self {
|
204 - | ConstraintViolation::MissingCallsCount => write!(f, "`calls_count` was not provided but it is required when building `GetServerStatisticsOutput`"),
|
205 - | }
|
329 + | /* ServerBuilderConstraintViolations.kt:127 */ConstraintViolation::MissingCallsCount => write!(f, "`calls_count` was not provided but it is required when building `GetServerStatisticsOutput`"),
|
330 + | /* ServerBuilderConstraintViolations.kt:119 */}
|
331 + | /* ServerBuilderConstraintViolations.kt:118 */
|
206 332 | }
|
333 + | /* ServerBuilderConstraintViolations.kt:117 */
|
207 334 | }
|
335 + | /* ServerBuilderConstraintViolations.kt:84 */
|
208 336 | impl ::std::error::Error for ConstraintViolation {}
|
337 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:254 */
|
209 338 | impl ::std::convert::TryFrom<Builder> for crate::output::GetServerStatisticsOutput {
|
210 339 | type Error = ConstraintViolation;
|
211 340 |
|
212 341 | fn try_from(builder: Builder) -> ::std::result::Result<Self, Self::Error> {
|
213 342 | builder.build()
|
214 343 | }
|
215 344 | }
|
216 - | /// A builder for [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
345 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:130 */A builder for [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
346 + | /* RustType.kt:516 */
|
217 347 | #[derive(::std::clone::Clone, ::std::default::Default, ::std::fmt::Debug)]
|
348 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
218 349 | pub struct Builder {
|
350 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:225 */
|
219 351 | pub(crate) calls_count: ::std::option::Option<i64>,
|
352 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:137 */
|
220 353 | }
|
354 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
221 355 | impl Builder {
|
222 - | /// The number of calls executed by the server.
|
356 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:241 */The number of calls executed by the server.
|
357 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
223 358 | pub fn calls_count(mut self, input: i64) -> Self {
|
224 - | self.calls_count = Some(input);
|
359 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */
|
360 + | self.calls_count =
|
361 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */Some(
|
362 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:247 */input
|
363 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:246 */)
|
364 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:245 */;
|
225 365 | self
|
366 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:244 */
|
226 367 | }
|
227 - | /// Consumes the builder and constructs a [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
228 - | ///
|
368 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:150 */Consumes the builder and constructs a [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput).
|
369 + | /// /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:152 */
|
229 370 | /// The builder fails to construct a [`GetServerStatisticsOutput`](crate::output::GetServerStatisticsOutput) if you do not provide a value for all non-`Option`al members.
|
230 371 | ///
|
372 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:159 */
|
231 373 | pub fn build(
|
232 374 | self,
|
233 375 | ) -> Result<crate::output::GetServerStatisticsOutput, ConstraintViolation> {
|
234 376 | self.build_enforcing_required_and_enum_traits()
|
235 377 | }
|
378 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
236 379 | fn build_enforcing_required_and_enum_traits(
|
237 380 | self,
|
238 381 | ) -> Result<crate::output::GetServerStatisticsOutput, ConstraintViolation> {
|
239 - | Ok(crate::output::GetServerStatisticsOutput {
|
240 - | calls_count: self
|
241 - | .calls_count
|
242 - | .ok_or(ConstraintViolation::MissingCallsCount)?,
|
243 - | })
|
382 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:175 */
|
383 + | Ok(
|
384 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
385 + | crate::output::GetServerStatisticsOutput {
|
386 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:186 */
|
387 + | calls_count: self
|
388 + | .calls_count
|
389 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:202 */
|
390 + | .ok_or(ConstraintViolation::MissingCallsCount)?,
|
391 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:182 */
|
392 + | }, /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:175 */
|
393 + | )
|
394 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:171 */
|
244 395 | }
|
396 + | /* ServerBuilderGeneratorWithoutPublicConstrainedTypes.kt:141 */
|
245 397 | }
|
398 + |
|
399 + | /* RustCrateInlineModuleComposingWriter.kt:299 */
|
246 400 | }
|