1 1 | // Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
|
2 - | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
3 - | /// :rtype None:
|
4 - | #[allow(missing_docs)] // documentation missing in model
|
5 - | #[derive(
|
6 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
7 - | )]
|
8 - | pub struct ExtraError {}
|
9 - | #[allow(clippy::new_without_default)]
|
10 - | #[allow(clippy::too_many_arguments)]
|
11 - | #[::pyo3::pymethods]
|
12 - | impl ExtraError {
|
13 - | #[new]
|
14 - | pub fn new() -> Self {
|
15 - | Self {}
|
16 - | }
|
17 - | fn __repr__(&self) -> String {
|
18 - | format!("{self:?}")
|
19 - | }
|
20 - | fn __str__(&self) -> String {
|
21 - | format!("{self:?}")
|
22 - | }
|
23 - | }
|
24 - | impl ExtraError {
|
25 - | #[doc(hidden)]
|
26 - | /// Returns the error name.
|
27 - | pub fn name(&self) -> &'static str {
|
28 - | "ExtraError"
|
29 - | }
|
30 - | }
|
31 - | impl ::std::fmt::Display for ExtraError {
|
32 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
33 - | ::std::write!(f, "ExtraError")?;
|
34 - | Ok(())
|
35 - | }
|
36 - | }
|
37 - | impl ::std::error::Error for ExtraError {}
|
38 - | impl ExtraError {
|
39 - | /// Creates a new builder-style object to manufacture [`ExtraError`](crate::error::ExtraError).
|
40 - | pub fn builder() -> crate::error::extra_error::Builder {
|
41 - | crate::error::extra_error::Builder::default()
|
42 - | }
|
43 - | }
|
44 - |
|
45 - | /// Error type for the `HttpQueryParamsOnlyOperation` operation.
|
46 - | /// Each variant represents an error that can occur for the `HttpQueryParamsOnlyOperation` operation.
|
2 + | /// Error type for the `StringPayload` operation.
|
3 + | /// Each variant represents an error that can occur for the `StringPayload` operation.
|
47 4 | #[derive(::std::fmt::Debug)]
|
48 - | pub enum HttpQueryParamsOnlyOperationError {
|
5 + | pub enum StringPayloadError {
|
49 6 | #[allow(missing_docs)] // documentation missing in model
|
50 7 | ExtraError(crate::error::ExtraError),
|
51 8 | #[allow(missing_docs)] // documentation missing in model
|
52 9 | InternalServerError(crate::error::InternalServerError),
|
53 10 | }
|
54 - | impl ::std::fmt::Display for HttpQueryParamsOnlyOperationError {
|
11 + | impl ::std::fmt::Display for StringPayloadError {
|
55 12 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
56 13 | match &self {
|
57 - | HttpQueryParamsOnlyOperationError::ExtraError(_inner) => _inner.fmt(f),
|
58 - | HttpQueryParamsOnlyOperationError::InternalServerError(_inner) => _inner.fmt(f),
|
14 + | StringPayloadError::ExtraError(_inner) => _inner.fmt(f),
|
15 + | StringPayloadError::InternalServerError(_inner) => _inner.fmt(f),
|
59 16 | }
|
60 17 | }
|
61 18 | }
|
62 - | impl HttpQueryParamsOnlyOperationError {
|
63 - | /// Returns `true` if the error kind is `HttpQueryParamsOnlyOperationError::ExtraError`.
|
19 + | impl StringPayloadError {
|
20 + | /// Returns `true` if the error kind is `StringPayloadError::ExtraError`.
|
64 21 | pub fn is_extra_error(&self) -> bool {
|
65 - | matches!(&self, HttpQueryParamsOnlyOperationError::ExtraError(_))
|
22 + | matches!(&self, StringPayloadError::ExtraError(_))
|
66 23 | }
|
67 - | /// Returns `true` if the error kind is `HttpQueryParamsOnlyOperationError::InternalServerError`.
|
24 + | /// Returns `true` if the error kind is `StringPayloadError::InternalServerError`.
|
68 25 | pub fn is_internal_server_error(&self) -> bool {
|
69 - | matches!(
|
70 - | &self,
|
71 - | HttpQueryParamsOnlyOperationError::InternalServerError(_)
|
72 - | )
|
26 + | matches!(&self, StringPayloadError::InternalServerError(_))
|
73 27 | }
|
74 28 | /// Returns the error name string by matching the correct variant.
|
75 29 | pub fn name(&self) -> &'static str {
|
76 30 | match &self {
|
77 - | HttpQueryParamsOnlyOperationError::ExtraError(_inner) => _inner.name(),
|
78 - | HttpQueryParamsOnlyOperationError::InternalServerError(_inner) => _inner.name(),
|
31 + | StringPayloadError::ExtraError(_inner) => _inner.name(),
|
32 + | StringPayloadError::InternalServerError(_inner) => _inner.name(),
|
79 33 | }
|
80 34 | }
|
81 35 | }
|
82 - | impl ::std::error::Error for HttpQueryParamsOnlyOperationError {
|
36 + | impl ::std::error::Error for StringPayloadError {
|
83 37 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
84 38 | match &self {
|
85 - | HttpQueryParamsOnlyOperationError::ExtraError(_inner) => Some(_inner),
|
86 - | HttpQueryParamsOnlyOperationError::InternalServerError(_inner) => Some(_inner),
|
39 + | StringPayloadError::ExtraError(_inner) => Some(_inner),
|
40 + | StringPayloadError::InternalServerError(_inner) => Some(_inner),
|
87 41 | }
|
88 42 | }
|
89 43 | }
|
90 - | impl ::std::convert::From<crate::error::ExtraError>
|
91 - | for crate::error::HttpQueryParamsOnlyOperationError
|
92 - | {
|
93 - | fn from(variant: crate::error::ExtraError) -> crate::error::HttpQueryParamsOnlyOperationError {
|
44 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::StringPayloadError {
|
45 + | fn from(variant: crate::error::ExtraError) -> crate::error::StringPayloadError {
|
94 46 | Self::ExtraError(variant)
|
95 47 | }
|
96 48 | }
|
97 - | impl ::std::convert::From<crate::error::InternalServerError>
|
98 - | for crate::error::HttpQueryParamsOnlyOperationError
|
99 - | {
|
100 - | fn from(
|
101 - | variant: crate::error::InternalServerError,
|
102 - | ) -> crate::error::HttpQueryParamsOnlyOperationError {
|
49 + | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::StringPayloadError {
|
50 + | fn from(variant: crate::error::InternalServerError) -> crate::error::StringPayloadError {
|
103 51 | Self::InternalServerError(variant)
|
104 52 | }
|
105 53 | }
|
106 54 |
|
107 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::HttpQueryParamsOnlyOperationError {
|
108 - | fn from(variant: ::pyo3::PyErr) -> crate::error::HttpQueryParamsOnlyOperationError {
|
55 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::StringPayloadError {
|
56 + | fn from(variant: ::pyo3::PyErr) -> crate::error::StringPayloadError {
|
109 57 | ::pyo3::Python::with_gil(|py| {
|
110 58 | let error = variant.value(py);
|
111 59 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
112 60 | return error.into();
|
113 61 | }
|
114 62 | crate::error::InternalServerError {
|
115 63 | message: error.to_string(),
|
116 64 | }
|
117 65 | .into()
|
118 66 | })
|
119 67 | }
|
120 68 | }
|
121 69 |
|
122 - | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
123 - | /// :param message str:
|
124 - | /// :rtype None:
|
125 - | #[allow(missing_docs)] // documentation missing in model
|
126 - | #[derive(
|
127 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
128 - | )]
|
129 - | pub struct InternalServerError {
|
130 - | #[pyo3(get, set)]
|
131 - | /// :type str:
|
132 - | #[allow(missing_docs)] // documentation missing in model
|
133 - | pub message: ::std::string::String,
|
134 - | }
|
135 - | #[allow(clippy::new_without_default)]
|
136 - | #[allow(clippy::too_many_arguments)]
|
137 - | #[::pyo3::pymethods]
|
138 - | impl InternalServerError {
|
139 - | #[new]
|
140 - | pub fn new(message: ::std::string::String) -> Self {
|
141 - | Self { message }
|
142 - | }
|
143 - | fn __repr__(&self) -> String {
|
144 - | format!("{self:?}")
|
145 - | }
|
146 - | fn __str__(&self) -> String {
|
147 - | format!("{self:?}")
|
148 - | }
|
149 - | }
|
150 - | impl InternalServerError {
|
151 - | /// Returns the error message.
|
152 - | pub fn message(&self) -> &str {
|
153 - | &self.message
|
154 - | }
|
155 - | #[doc(hidden)]
|
156 - | /// Returns the error name.
|
157 - | pub fn name(&self) -> &'static str {
|
158 - | "InternalServerError"
|
159 - | }
|
160 - | }
|
161 - | impl ::std::fmt::Display for InternalServerError {
|
162 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
163 - | ::std::write!(f, "InternalServerError")?;
|
164 - | {
|
165 - | ::std::write!(f, ": {}", &self.message)?;
|
166 - | }
|
167 - | Ok(())
|
168 - | }
|
169 - | }
|
170 - | impl ::std::error::Error for InternalServerError {}
|
171 - | impl InternalServerError {
|
172 - | /// Creates a new builder-style object to manufacture [`InternalServerError`](crate::error::InternalServerError).
|
173 - | pub fn builder() -> crate::error::internal_server_error::Builder {
|
174 - | crate::error::internal_server_error::Builder::default()
|
175 - | }
|
176 - | }
|
177 - |
|
178 - | /// Error type for the `QueryPrecedence` operation.
|
179 - | /// Each variant represents an error that can occur for the `QueryPrecedence` operation.
|
70 + | /// Error type for the `PrimitiveIntHeader` operation.
|
71 + | /// Each variant represents an error that can occur for the `PrimitiveIntHeader` operation.
|
180 72 | #[derive(::std::fmt::Debug)]
|
181 - | pub enum QueryPrecedenceError {
|
73 + | pub enum PrimitiveIntHeaderError {
|
74 + | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
75 + | ValidationException(crate::error::ValidationException),
|
182 76 | #[allow(missing_docs)] // documentation missing in model
|
183 77 | ExtraError(crate::error::ExtraError),
|
184 78 | #[allow(missing_docs)] // documentation missing in model
|
185 79 | InternalServerError(crate::error::InternalServerError),
|
186 80 | }
|
187 - | impl ::std::fmt::Display for QueryPrecedenceError {
|
81 + | impl ::std::fmt::Display for PrimitiveIntHeaderError {
|
188 82 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
189 83 | match &self {
|
190 - | QueryPrecedenceError::ExtraError(_inner) => _inner.fmt(f),
|
191 - | QueryPrecedenceError::InternalServerError(_inner) => _inner.fmt(f),
|
84 + | PrimitiveIntHeaderError::ValidationException(_inner) => _inner.fmt(f),
|
85 + | PrimitiveIntHeaderError::ExtraError(_inner) => _inner.fmt(f),
|
86 + | PrimitiveIntHeaderError::InternalServerError(_inner) => _inner.fmt(f),
|
192 87 | }
|
193 88 | }
|
194 89 | }
|
195 - | impl QueryPrecedenceError {
|
196 - | /// Returns `true` if the error kind is `QueryPrecedenceError::ExtraError`.
|
90 + | impl PrimitiveIntHeaderError {
|
91 + | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::ValidationException`.
|
92 + | pub fn is_validation_exception(&self) -> bool {
|
93 + | matches!(&self, PrimitiveIntHeaderError::ValidationException(_))
|
94 + | }
|
95 + | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::ExtraError`.
|
197 96 | pub fn is_extra_error(&self) -> bool {
|
198 - | matches!(&self, QueryPrecedenceError::ExtraError(_))
|
97 + | matches!(&self, PrimitiveIntHeaderError::ExtraError(_))
|
199 98 | }
|
200 - | /// Returns `true` if the error kind is `QueryPrecedenceError::InternalServerError`.
|
99 + | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::InternalServerError`.
|
201 100 | pub fn is_internal_server_error(&self) -> bool {
|
202 - | matches!(&self, QueryPrecedenceError::InternalServerError(_))
|
101 + | matches!(&self, PrimitiveIntHeaderError::InternalServerError(_))
|
203 102 | }
|
204 103 | /// Returns the error name string by matching the correct variant.
|
205 104 | pub fn name(&self) -> &'static str {
|
206 105 | match &self {
|
207 - | QueryPrecedenceError::ExtraError(_inner) => _inner.name(),
|
208 - | QueryPrecedenceError::InternalServerError(_inner) => _inner.name(),
|
106 + | PrimitiveIntHeaderError::ValidationException(_inner) => _inner.name(),
|
107 + | PrimitiveIntHeaderError::ExtraError(_inner) => _inner.name(),
|
108 + | PrimitiveIntHeaderError::InternalServerError(_inner) => _inner.name(),
|
209 109 | }
|
210 110 | }
|
211 111 | }
|
212 - | impl ::std::error::Error for QueryPrecedenceError {
|
112 + | impl ::std::error::Error for PrimitiveIntHeaderError {
|
213 113 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
214 114 | match &self {
|
215 - | QueryPrecedenceError::ExtraError(_inner) => Some(_inner),
|
216 - | QueryPrecedenceError::InternalServerError(_inner) => Some(_inner),
|
115 + | PrimitiveIntHeaderError::ValidationException(_inner) => Some(_inner),
|
116 + | PrimitiveIntHeaderError::ExtraError(_inner) => Some(_inner),
|
117 + | PrimitiveIntHeaderError::InternalServerError(_inner) => Some(_inner),
|
217 118 | }
|
218 119 | }
|
219 120 | }
|
220 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::QueryPrecedenceError {
|
221 - | fn from(variant: crate::error::ExtraError) -> crate::error::QueryPrecedenceError {
|
121 + | impl ::std::convert::From<crate::error::ValidationException>
|
122 + | for crate::error::PrimitiveIntHeaderError
|
123 + | {
|
124 + | fn from(variant: crate::error::ValidationException) -> crate::error::PrimitiveIntHeaderError {
|
125 + | Self::ValidationException(variant)
|
126 + | }
|
127 + | }
|
128 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::PrimitiveIntHeaderError {
|
129 + | fn from(variant: crate::error::ExtraError) -> crate::error::PrimitiveIntHeaderError {
|
222 130 | Self::ExtraError(variant)
|
223 131 | }
|
224 132 | }
|
225 133 | impl ::std::convert::From<crate::error::InternalServerError>
|
226 - | for crate::error::QueryPrecedenceError
|
134 + | for crate::error::PrimitiveIntHeaderError
|
227 135 | {
|
228 - | fn from(variant: crate::error::InternalServerError) -> crate::error::QueryPrecedenceError {
|
136 + | fn from(variant: crate::error::InternalServerError) -> crate::error::PrimitiveIntHeaderError {
|
229 137 | Self::InternalServerError(variant)
|
230 138 | }
|
231 139 | }
|
232 140 |
|
233 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::QueryPrecedenceError {
|
234 - | fn from(variant: ::pyo3::PyErr) -> crate::error::QueryPrecedenceError {
|
141 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::PrimitiveIntHeaderError {
|
142 + | fn from(variant: ::pyo3::PyErr) -> crate::error::PrimitiveIntHeaderError {
|
235 143 | ::pyo3::Python::with_gil(|py| {
|
236 144 | let error = variant.value(py);
|
145 + | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
146 + | return error.into();
|
147 + | }
|
237 148 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
238 149 | return error.into();
|
239 150 | }
|
240 151 | crate::error::InternalServerError {
|
241 152 | message: error.to_string(),
|
242 153 | }
|
243 154 | .into()
|
244 155 | })
|
245 156 | }
|
246 157 | }
|
247 158 |
|
248 - | /// Error type for the `EmptyStructWithContentOnWireOp` operation.
|
249 - | /// Each variant represents an error that can occur for the `EmptyStructWithContentOnWireOp` operation.
|
159 + | /// Error type for the `EnumQuery` operation.
|
160 + | /// Each variant represents an error that can occur for the `EnumQuery` operation.
|
250 161 | #[derive(::std::fmt::Debug)]
|
251 - | pub enum EmptyStructWithContentOnWireOpError {
|
162 + | pub enum EnumQueryError {
|
163 + | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
164 + | ValidationException(crate::error::ValidationException),
|
252 165 | #[allow(missing_docs)] // documentation missing in model
|
253 166 | ExtraError(crate::error::ExtraError),
|
254 167 | #[allow(missing_docs)] // documentation missing in model
|
255 168 | InternalServerError(crate::error::InternalServerError),
|
256 169 | }
|
257 - | impl ::std::fmt::Display for EmptyStructWithContentOnWireOpError {
|
170 + | impl ::std::fmt::Display for EnumQueryError {
|
258 171 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
259 172 | match &self {
|
260 - | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => _inner.fmt(f),
|
261 - | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => _inner.fmt(f),
|
173 + | EnumQueryError::ValidationException(_inner) => _inner.fmt(f),
|
174 + | EnumQueryError::ExtraError(_inner) => _inner.fmt(f),
|
175 + | EnumQueryError::InternalServerError(_inner) => _inner.fmt(f),
|
262 176 | }
|
263 177 | }
|
264 178 | }
|
265 - | impl EmptyStructWithContentOnWireOpError {
|
266 - | /// Returns `true` if the error kind is `EmptyStructWithContentOnWireOpError::ExtraError`.
|
179 + | impl EnumQueryError {
|
180 + | /// Returns `true` if the error kind is `EnumQueryError::ValidationException`.
|
181 + | pub fn is_validation_exception(&self) -> bool {
|
182 + | matches!(&self, EnumQueryError::ValidationException(_))
|
183 + | }
|
184 + | /// Returns `true` if the error kind is `EnumQueryError::ExtraError`.
|
267 185 | pub fn is_extra_error(&self) -> bool {
|
268 - | matches!(&self, EmptyStructWithContentOnWireOpError::ExtraError(_))
|
186 + | matches!(&self, EnumQueryError::ExtraError(_))
|
269 187 | }
|
270 - | /// Returns `true` if the error kind is `EmptyStructWithContentOnWireOpError::InternalServerError`.
|
188 + | /// Returns `true` if the error kind is `EnumQueryError::InternalServerError`.
|
271 189 | pub fn is_internal_server_error(&self) -> bool {
|
272 - | matches!(
|
273 - | &self,
|
274 - | EmptyStructWithContentOnWireOpError::InternalServerError(_)
|
275 - | )
|
190 + | matches!(&self, EnumQueryError::InternalServerError(_))
|
276 191 | }
|
277 192 | /// Returns the error name string by matching the correct variant.
|
278 193 | pub fn name(&self) -> &'static str {
|
279 194 | match &self {
|
280 - | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => _inner.name(),
|
281 - | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => _inner.name(),
|
195 + | EnumQueryError::ValidationException(_inner) => _inner.name(),
|
196 + | EnumQueryError::ExtraError(_inner) => _inner.name(),
|
197 + | EnumQueryError::InternalServerError(_inner) => _inner.name(),
|
282 198 | }
|
283 199 | }
|
284 200 | }
|
285 - | impl ::std::error::Error for EmptyStructWithContentOnWireOpError {
|
201 + | impl ::std::error::Error for EnumQueryError {
|
286 202 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
287 203 | match &self {
|
288 - | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => Some(_inner),
|
289 - | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => Some(_inner),
|
204 + | EnumQueryError::ValidationException(_inner) => Some(_inner),
|
205 + | EnumQueryError::ExtraError(_inner) => Some(_inner),
|
206 + | EnumQueryError::InternalServerError(_inner) => Some(_inner),
|
290 207 | }
|
291 208 | }
|
292 209 | }
|
293 - | impl ::std::convert::From<crate::error::ExtraError>
|
294 - | for crate::error::EmptyStructWithContentOnWireOpError
|
295 - | {
|
296 - | fn from(
|
297 - | variant: crate::error::ExtraError,
|
298 - | ) -> crate::error::EmptyStructWithContentOnWireOpError {
|
210 + | impl ::std::convert::From<crate::error::ValidationException> for crate::error::EnumQueryError {
|
211 + | fn from(variant: crate::error::ValidationException) -> crate::error::EnumQueryError {
|
212 + | Self::ValidationException(variant)
|
213 + | }
|
214 + | }
|
215 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::EnumQueryError {
|
216 + | fn from(variant: crate::error::ExtraError) -> crate::error::EnumQueryError {
|
299 217 | Self::ExtraError(variant)
|
300 218 | }
|
301 219 | }
|
302 - | impl ::std::convert::From<crate::error::InternalServerError>
|
303 - | for crate::error::EmptyStructWithContentOnWireOpError
|
304 - | {
|
305 - | fn from(
|
306 - | variant: crate::error::InternalServerError,
|
307 - | ) -> crate::error::EmptyStructWithContentOnWireOpError {
|
220 + | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::EnumQueryError {
|
221 + | fn from(variant: crate::error::InternalServerError) -> crate::error::EnumQueryError {
|
308 222 | Self::InternalServerError(variant)
|
309 223 | }
|
310 224 | }
|
311 225 |
|
312 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::EmptyStructWithContentOnWireOpError {
|
313 - | fn from(variant: ::pyo3::PyErr) -> crate::error::EmptyStructWithContentOnWireOpError {
|
226 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::EnumQueryError {
|
227 + | fn from(variant: ::pyo3::PyErr) -> crate::error::EnumQueryError {
|
314 228 | ::pyo3::Python::with_gil(|py| {
|
315 229 | let error = variant.value(py);
|
230 + | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
231 + | return error.into();
|
232 + | }
|
316 233 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
317 234 | return error.into();
|
318 235 | }
|
319 236 | crate::error::InternalServerError {
|
320 237 | message: error.to_string(),
|
321 238 | }
|
322 239 | .into()
|
323 240 | })
|
324 241 | }
|
325 242 | }
|
326 243 |
|
327 - | /// Error type for the `CaseInsensitiveErrorOperation` operation.
|
328 - | /// Each variant represents an error that can occur for the `CaseInsensitiveErrorOperation` operation.
|
244 + | /// Error type for the `StatusResponse` operation.
|
245 + | /// Each variant represents an error that can occur for the `StatusResponse` operation.
|
329 246 | #[derive(::std::fmt::Debug)]
|
330 - | pub enum CaseInsensitiveErrorOperationError {
|
331 - | #[allow(missing_docs)] // documentation missing in model
|
332 - | CaseInsensitiveError(crate::error::CaseInsensitiveError),
|
247 + | pub enum StatusResponseError {
|
333 248 | #[allow(missing_docs)] // documentation missing in model
|
334 249 | ExtraError(crate::error::ExtraError),
|
335 250 | #[allow(missing_docs)] // documentation missing in model
|
336 251 | InternalServerError(crate::error::InternalServerError),
|
337 252 | }
|
338 - | impl ::std::fmt::Display for CaseInsensitiveErrorOperationError {
|
253 + | impl ::std::fmt::Display for StatusResponseError {
|
339 254 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
340 255 | match &self {
|
341 - | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => _inner.fmt(f),
|
342 - | CaseInsensitiveErrorOperationError::ExtraError(_inner) => _inner.fmt(f),
|
343 - | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => _inner.fmt(f),
|
256 + | StatusResponseError::ExtraError(_inner) => _inner.fmt(f),
|
257 + | StatusResponseError::InternalServerError(_inner) => _inner.fmt(f),
|
344 258 | }
|
345 259 | }
|
346 260 | }
|
347 - | impl CaseInsensitiveErrorOperationError {
|
348 - | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::CaseInsensitiveError`.
|
349 - | pub fn is_case_insensitive_error(&self) -> bool {
|
350 - | matches!(
|
351 - | &self,
|
352 - | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_)
|
353 - | )
|
354 - | }
|
355 - | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::ExtraError`.
|
261 + | impl StatusResponseError {
|
262 + | /// Returns `true` if the error kind is `StatusResponseError::ExtraError`.
|
356 263 | pub fn is_extra_error(&self) -> bool {
|
357 - | matches!(&self, CaseInsensitiveErrorOperationError::ExtraError(_))
|
264 + | matches!(&self, StatusResponseError::ExtraError(_))
|
358 265 | }
|
359 - | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::InternalServerError`.
|
266 + | /// Returns `true` if the error kind is `StatusResponseError::InternalServerError`.
|
360 267 | pub fn is_internal_server_error(&self) -> bool {
|
361 - | matches!(
|
362 - | &self,
|
363 - | CaseInsensitiveErrorOperationError::InternalServerError(_)
|
364 - | )
|
268 + | matches!(&self, StatusResponseError::InternalServerError(_))
|
365 269 | }
|
366 270 | /// Returns the error name string by matching the correct variant.
|
367 271 | pub fn name(&self) -> &'static str {
|
368 272 | match &self {
|
369 - | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => _inner.name(),
|
370 - | CaseInsensitiveErrorOperationError::ExtraError(_inner) => _inner.name(),
|
371 - | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => _inner.name(),
|
273 + | StatusResponseError::ExtraError(_inner) => _inner.name(),
|
274 + | StatusResponseError::InternalServerError(_inner) => _inner.name(),
|
372 275 | }
|
373 276 | }
|
374 277 | }
|
375 - | impl ::std::error::Error for CaseInsensitiveErrorOperationError {
|
278 + | impl ::std::error::Error for StatusResponseError {
|
376 279 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
377 280 | match &self {
|
378 - | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => Some(_inner),
|
379 - | CaseInsensitiveErrorOperationError::ExtraError(_inner) => Some(_inner),
|
380 - | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => Some(_inner),
|
381 - | }
|
281 + | StatusResponseError::ExtraError(_inner) => Some(_inner),
|
282 + | StatusResponseError::InternalServerError(_inner) => Some(_inner),
|
382 283 | }
|
383 - | }
|
384 - | impl ::std::convert::From<crate::error::CaseInsensitiveError>
|
385 - | for crate::error::CaseInsensitiveErrorOperationError
|
386 - | {
|
387 - | fn from(
|
388 - | variant: crate::error::CaseInsensitiveError,
|
389 - | ) -> crate::error::CaseInsensitiveErrorOperationError {
|
390 - | Self::CaseInsensitiveError(variant)
|
391 284 | }
|
392 285 | }
|
393 - | impl ::std::convert::From<crate::error::ExtraError>
|
394 - | for crate::error::CaseInsensitiveErrorOperationError
|
395 - | {
|
396 - | fn from(variant: crate::error::ExtraError) -> crate::error::CaseInsensitiveErrorOperationError {
|
286 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::StatusResponseError {
|
287 + | fn from(variant: crate::error::ExtraError) -> crate::error::StatusResponseError {
|
397 288 | Self::ExtraError(variant)
|
398 289 | }
|
399 290 | }
|
400 - | impl ::std::convert::From<crate::error::InternalServerError>
|
401 - | for crate::error::CaseInsensitiveErrorOperationError
|
402 - | {
|
403 - | fn from(
|
404 - | variant: crate::error::InternalServerError,
|
405 - | ) -> crate::error::CaseInsensitiveErrorOperationError {
|
291 + | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::StatusResponseError {
|
292 + | fn from(variant: crate::error::InternalServerError) -> crate::error::StatusResponseError {
|
406 293 | Self::InternalServerError(variant)
|
407 294 | }
|
408 295 | }
|
409 296 |
|
410 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::CaseInsensitiveErrorOperationError {
|
411 - | fn from(variant: ::pyo3::PyErr) -> crate::error::CaseInsensitiveErrorOperationError {
|
297 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::StatusResponseError {
|
298 + | fn from(variant: ::pyo3::PyErr) -> crate::error::StatusResponseError {
|
412 299 | ::pyo3::Python::with_gil(|py| {
|
413 300 | let error = variant.value(py);
|
414 - | if let Ok(error) = error.extract::<crate::error::CaseInsensitiveError>() {
|
415 - | return error.into();
|
416 - | }
|
417 301 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
418 302 | return error.into();
|
419 303 | }
|
420 304 | crate::error::InternalServerError {
|
421 305 | message: error.to_string(),
|
422 306 | }
|
423 307 | .into()
|
424 308 | })
|
425 309 | }
|
426 310 | }
|
427 311 |
|
428 - | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
429 - | /// :param message typing.Optional\[str\]:
|
430 - | /// :rtype None:
|
431 - | #[allow(missing_docs)] // documentation missing in model
|
432 - | #[derive(
|
433 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
434 - | )]
|
435 - | pub struct CaseInsensitiveError {
|
436 - | #[pyo3(get, set)]
|
437 - | /// :type typing.Optional\[str\]:
|
312 + | /// Error type for the `MapWithEnumKeyOp` operation.
|
313 + | /// Each variant represents an error that can occur for the `MapWithEnumKeyOp` operation.
|
314 + | #[derive(::std::fmt::Debug)]
|
315 + | pub enum MapWithEnumKeyOpError {
|
316 + | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
317 + | ValidationException(crate::error::ValidationException),
|
438 318 | #[allow(missing_docs)] // documentation missing in model
|
439 - | pub message: ::std::option::Option<::std::string::String>,
|
319 + | ExtraError(crate::error::ExtraError),
|
320 + | #[allow(missing_docs)] // documentation missing in model
|
321 + | InternalServerError(crate::error::InternalServerError),
|
440 322 | }
|
441 - | #[allow(clippy::new_without_default)]
|
442 - | #[allow(clippy::too_many_arguments)]
|
443 - | #[::pyo3::pymethods]
|
444 - | impl CaseInsensitiveError {
|
445 - | #[new]
|
446 - | pub fn new(message: ::std::option::Option<::std::string::String>) -> Self {
|
447 - | Self { message }
|
448 - | }
|
449 - | fn __repr__(&self) -> String {
|
450 - | format!("{self:?}")
|
323 + | impl ::std::fmt::Display for MapWithEnumKeyOpError {
|
324 + | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
325 + | match &self {
|
326 + | MapWithEnumKeyOpError::ValidationException(_inner) => _inner.fmt(f),
|
327 + | MapWithEnumKeyOpError::ExtraError(_inner) => _inner.fmt(f),
|
328 + | MapWithEnumKeyOpError::InternalServerError(_inner) => _inner.fmt(f),
|
451 329 | }
|
452 - | fn __str__(&self) -> String {
|
453 - | format!("{self:?}")
|
454 330 | }
|
455 331 | }
|
456 - | impl CaseInsensitiveError {
|
457 - | /// Returns the error message.
|
458 - | pub fn message(&self) -> ::std::option::Option<&str> {
|
459 - | self.message.as_deref()
|
332 + | impl MapWithEnumKeyOpError {
|
333 + | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::ValidationException`.
|
334 + | pub fn is_validation_exception(&self) -> bool {
|
335 + | matches!(&self, MapWithEnumKeyOpError::ValidationException(_))
|
460 336 | }
|
461 - | #[doc(hidden)]
|
462 - | /// Returns the error name.
|
337 + | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::ExtraError`.
|
338 + | pub fn is_extra_error(&self) -> bool {
|
339 + | matches!(&self, MapWithEnumKeyOpError::ExtraError(_))
|
340 + | }
|
341 + | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::InternalServerError`.
|
342 + | pub fn is_internal_server_error(&self) -> bool {
|
343 + | matches!(&self, MapWithEnumKeyOpError::InternalServerError(_))
|
344 + | }
|
345 + | /// Returns the error name string by matching the correct variant.
|
463 346 | pub fn name(&self) -> &'static str {
|
464 - | "CaseInsensitiveError"
|
347 + | match &self {
|
348 + | MapWithEnumKeyOpError::ValidationException(_inner) => _inner.name(),
|
349 + | MapWithEnumKeyOpError::ExtraError(_inner) => _inner.name(),
|
350 + | MapWithEnumKeyOpError::InternalServerError(_inner) => _inner.name(),
|
351 + | }
|
465 352 | }
|
466 353 | }
|
467 - | impl ::std::fmt::Display for CaseInsensitiveError {
|
468 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
469 - | ::std::write!(f, "CaseInsensitiveError")?;
|
470 - | if let ::std::option::Option::Some(inner_1) = &self.message {
|
471 - | {
|
472 - | ::std::write!(f, ": {inner_1}")?;
|
354 + | impl ::std::error::Error for MapWithEnumKeyOpError {
|
355 + | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
356 + | match &self {
|
357 + | MapWithEnumKeyOpError::ValidationException(_inner) => Some(_inner),
|
358 + | MapWithEnumKeyOpError::ExtraError(_inner) => Some(_inner),
|
359 + | MapWithEnumKeyOpError::InternalServerError(_inner) => Some(_inner),
|
473 360 | }
|
474 361 | }
|
475 - | Ok(())
|
362 + | }
|
363 + | impl ::std::convert::From<crate::error::ValidationException>
|
364 + | for crate::error::MapWithEnumKeyOpError
|
365 + | {
|
366 + | fn from(variant: crate::error::ValidationException) -> crate::error::MapWithEnumKeyOpError {
|
367 + | Self::ValidationException(variant)
|
476 368 | }
|
477 369 | }
|
478 - | impl ::std::error::Error for CaseInsensitiveError {}
|
479 - | impl CaseInsensitiveError {
|
480 - | /// Creates a new builder-style object to manufacture [`CaseInsensitiveError`](crate::error::CaseInsensitiveError).
|
481 - | pub fn builder() -> crate::error::case_insensitive_error::Builder {
|
482 - | crate::error::case_insensitive_error::Builder::default()
|
370 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::MapWithEnumKeyOpError {
|
371 + | fn from(variant: crate::error::ExtraError) -> crate::error::MapWithEnumKeyOpError {
|
372 + | Self::ExtraError(variant)
|
373 + | }
|
374 + | }
|
375 + | impl ::std::convert::From<crate::error::InternalServerError>
|
376 + | for crate::error::MapWithEnumKeyOpError
|
377 + | {
|
378 + | fn from(variant: crate::error::InternalServerError) -> crate::error::MapWithEnumKeyOpError {
|
379 + | Self::InternalServerError(variant)
|
483 380 | }
|
484 381 | }
|
485 382 |
|
486 - | /// Error type for the `NullInNonSparse` operation.
|
487 - | /// Each variant represents an error that can occur for the `NullInNonSparse` operation.
|
383 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::MapWithEnumKeyOpError {
|
384 + | fn from(variant: ::pyo3::PyErr) -> crate::error::MapWithEnumKeyOpError {
|
385 + | ::pyo3::Python::with_gil(|py| {
|
386 + | let error = variant.value(py);
|
387 + | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
388 + | return error.into();
|
389 + | }
|
390 + | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
391 + | return error.into();
|
392 + | }
|
393 + | crate::error::InternalServerError {
|
394 + | message: error.to_string(),
|
395 + | }
|
396 + | .into()
|
397 + | })
|
398 + | }
|
399 + | }
|
400 + |
|
401 + | /// Error type for the `PrimitiveIntOp` operation.
|
402 + | /// Each variant represents an error that can occur for the `PrimitiveIntOp` operation.
|
488 403 | #[derive(::std::fmt::Debug)]
|
489 - | pub enum NullInNonSparseError {
|
404 + | pub enum PrimitiveIntOpError {
|
490 405 | #[allow(missing_docs)] // documentation missing in model
|
491 406 | ExtraError(crate::error::ExtraError),
|
492 407 | #[allow(missing_docs)] // documentation missing in model
|
493 408 | InternalServerError(crate::error::InternalServerError),
|
494 409 | }
|
495 - | impl ::std::fmt::Display for NullInNonSparseError {
|
410 + | impl ::std::fmt::Display for PrimitiveIntOpError {
|
496 411 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
497 412 | match &self {
|
498 - | NullInNonSparseError::ExtraError(_inner) => _inner.fmt(f),
|
499 - | NullInNonSparseError::InternalServerError(_inner) => _inner.fmt(f),
|
413 + | PrimitiveIntOpError::ExtraError(_inner) => _inner.fmt(f),
|
414 + | PrimitiveIntOpError::InternalServerError(_inner) => _inner.fmt(f),
|
500 415 | }
|
501 416 | }
|
502 417 | }
|
503 - | impl NullInNonSparseError {
|
504 - | /// Returns `true` if the error kind is `NullInNonSparseError::ExtraError`.
|
418 + | impl PrimitiveIntOpError {
|
419 + | /// Returns `true` if the error kind is `PrimitiveIntOpError::ExtraError`.
|
505 420 | pub fn is_extra_error(&self) -> bool {
|
506 - | matches!(&self, NullInNonSparseError::ExtraError(_))
|
421 + | matches!(&self, PrimitiveIntOpError::ExtraError(_))
|
507 422 | }
|
508 - | /// Returns `true` if the error kind is `NullInNonSparseError::InternalServerError`.
|
423 + | /// Returns `true` if the error kind is `PrimitiveIntOpError::InternalServerError`.
|
509 424 | pub fn is_internal_server_error(&self) -> bool {
|
510 - | matches!(&self, NullInNonSparseError::InternalServerError(_))
|
425 + | matches!(&self, PrimitiveIntOpError::InternalServerError(_))
|
511 426 | }
|
512 427 | /// Returns the error name string by matching the correct variant.
|
513 428 | pub fn name(&self) -> &'static str {
|
514 429 | match &self {
|
515 - | NullInNonSparseError::ExtraError(_inner) => _inner.name(),
|
516 - | NullInNonSparseError::InternalServerError(_inner) => _inner.name(),
|
430 + | PrimitiveIntOpError::ExtraError(_inner) => _inner.name(),
|
431 + | PrimitiveIntOpError::InternalServerError(_inner) => _inner.name(),
|
517 432 | }
|
518 433 | }
|
519 434 | }
|
520 - | impl ::std::error::Error for NullInNonSparseError {
|
435 + | impl ::std::error::Error for PrimitiveIntOpError {
|
521 436 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
522 437 | match &self {
|
523 - | NullInNonSparseError::ExtraError(_inner) => Some(_inner),
|
524 - | NullInNonSparseError::InternalServerError(_inner) => Some(_inner),
|
438 + | PrimitiveIntOpError::ExtraError(_inner) => Some(_inner),
|
439 + | PrimitiveIntOpError::InternalServerError(_inner) => Some(_inner),
|
525 440 | }
|
526 441 | }
|
527 442 | }
|
528 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::NullInNonSparseError {
|
529 - | fn from(variant: crate::error::ExtraError) -> crate::error::NullInNonSparseError {
|
443 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::PrimitiveIntOpError {
|
444 + | fn from(variant: crate::error::ExtraError) -> crate::error::PrimitiveIntOpError {
|
530 445 | Self::ExtraError(variant)
|
531 446 | }
|
532 447 | }
|
533 - | impl ::std::convert::From<crate::error::InternalServerError>
|
534 - | for crate::error::NullInNonSparseError
|
535 - | {
|
536 - | fn from(variant: crate::error::InternalServerError) -> crate::error::NullInNonSparseError {
|
448 + | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::PrimitiveIntOpError {
|
449 + | fn from(variant: crate::error::InternalServerError) -> crate::error::PrimitiveIntOpError {
|
537 450 | Self::InternalServerError(variant)
|
538 451 | }
|
539 452 | }
|
540 453 |
|
541 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::NullInNonSparseError {
|
542 - | fn from(variant: ::pyo3::PyErr) -> crate::error::NullInNonSparseError {
|
454 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::PrimitiveIntOpError {
|
455 + | fn from(variant: ::pyo3::PyErr) -> crate::error::PrimitiveIntOpError {
|
543 456 | ::pyo3::Python::with_gil(|py| {
|
544 457 | let error = variant.value(py);
|
545 458 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
546 459 | return error.into();
|
547 460 | }
|
548 461 | crate::error::InternalServerError {
|
549 462 | message: error.to_string(),
|
550 463 | }
|
551 464 | .into()
|
552 465 | })
|
635 548 | return error.into();
|
636 549 | }
|
637 550 | crate::error::InternalServerError {
|
638 551 | message: error.to_string(),
|
639 552 | }
|
640 553 | .into()
|
641 554 | })
|
642 555 | }
|
643 556 | }
|
644 557 |
|
645 - | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
646 - | /// :param message str:
|
647 - | /// :param field_list typing.Optional\[typing.List\[rest_json_extras.model.ValidationExceptionField\]\]:
|
648 - | /// :rtype None:
|
649 - | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
650 - | #[derive(
|
651 - | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
652 - | )]
|
653 - | pub struct ValidationException {
|
654 - | #[pyo3(get, set)]
|
655 - | /// :type str:
|
656 - | /// A summary of the validation failure.
|
657 - | pub message: ::std::string::String,
|
658 - | #[pyo3(get, set)]
|
659 - | /// :type typing.Optional\[typing.List\[rest_json_extras.model.ValidationExceptionField\]\]:
|
660 - | /// A list of specific failures encountered while validating the input. A member can appear in this list more than once if it failed to satisfy multiple constraints.
|
661 - | pub field_list: ::std::option::Option<::std::vec::Vec<crate::model::ValidationExceptionField>>,
|
662 - | }
|
663 - | impl ValidationException {
|
664 - | /// A list of specific failures encountered while validating the input. A member can appear in this list more than once if it failed to satisfy multiple constraints.
|
665 - | pub fn field_list(&self) -> ::std::option::Option<&[crate::model::ValidationExceptionField]> {
|
666 - | self.field_list.as_deref()
|
667 - | }
|
668 - | }
|
669 - | #[allow(clippy::new_without_default)]
|
670 - | #[allow(clippy::too_many_arguments)]
|
671 - | #[::pyo3::pymethods]
|
672 - | impl ValidationException {
|
673 - | #[new]
|
674 - | pub fn new(
|
675 - | message: ::std::string::String,
|
676 - | field_list: ::std::option::Option<::std::vec::Vec<crate::model::ValidationExceptionField>>,
|
677 - | ) -> Self {
|
678 - | Self {
|
679 - | message,
|
680 - | field_list,
|
681 - | }
|
682 - | }
|
683 - | fn __repr__(&self) -> String {
|
684 - | format!("{self:?}")
|
685 - | }
|
686 - | fn __str__(&self) -> String {
|
687 - | format!("{self:?}")
|
688 - | }
|
689 - | }
|
690 - | impl ValidationException {
|
691 - | /// Returns the error message.
|
692 - | pub fn message(&self) -> &str {
|
693 - | &self.message
|
694 - | }
|
695 - | #[doc(hidden)]
|
696 - | /// Returns the error name.
|
697 - | pub fn name(&self) -> &'static str {
|
698 - | "ValidationException"
|
699 - | }
|
700 - | }
|
701 - | impl ::std::fmt::Display for ValidationException {
|
702 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
703 - | ::std::write!(f, "ValidationException")?;
|
704 - | {
|
705 - | ::std::write!(f, ": {}", &self.message)?;
|
706 - | }
|
707 - | Ok(())
|
708 - | }
|
709 - | }
|
710 - | impl ::std::error::Error for ValidationException {}
|
711 - | impl ValidationException {
|
712 - | /// Creates a new builder-style object to manufacture [`ValidationException`](crate::error::ValidationException).
|
713 - | pub fn builder() -> crate::error::validation_exception::Builder {
|
714 - | crate::error::validation_exception::Builder::default()
|
715 - | }
|
716 - | }
|
717 - |
|
718 - | /// Error type for the `PrimitiveIntOp` operation.
|
719 - | /// Each variant represents an error that can occur for the `PrimitiveIntOp` operation.
|
558 + | /// Error type for the `NullInNonSparse` operation.
|
559 + | /// Each variant represents an error that can occur for the `NullInNonSparse` operation.
|
720 560 | #[derive(::std::fmt::Debug)]
|
721 - | pub enum PrimitiveIntOpError {
|
561 + | pub enum NullInNonSparseError {
|
722 562 | #[allow(missing_docs)] // documentation missing in model
|
723 563 | ExtraError(crate::error::ExtraError),
|
724 564 | #[allow(missing_docs)] // documentation missing in model
|
725 565 | InternalServerError(crate::error::InternalServerError),
|
726 566 | }
|
727 - | impl ::std::fmt::Display for PrimitiveIntOpError {
|
567 + | impl ::std::fmt::Display for NullInNonSparseError {
|
728 568 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
729 569 | match &self {
|
730 - | PrimitiveIntOpError::ExtraError(_inner) => _inner.fmt(f),
|
731 - | PrimitiveIntOpError::InternalServerError(_inner) => _inner.fmt(f),
|
570 + | NullInNonSparseError::ExtraError(_inner) => _inner.fmt(f),
|
571 + | NullInNonSparseError::InternalServerError(_inner) => _inner.fmt(f),
|
732 572 | }
|
733 573 | }
|
734 574 | }
|
735 - | impl PrimitiveIntOpError {
|
736 - | /// Returns `true` if the error kind is `PrimitiveIntOpError::ExtraError`.
|
575 + | impl NullInNonSparseError {
|
576 + | /// Returns `true` if the error kind is `NullInNonSparseError::ExtraError`.
|
737 577 | pub fn is_extra_error(&self) -> bool {
|
738 - | matches!(&self, PrimitiveIntOpError::ExtraError(_))
|
578 + | matches!(&self, NullInNonSparseError::ExtraError(_))
|
739 579 | }
|
740 - | /// Returns `true` if the error kind is `PrimitiveIntOpError::InternalServerError`.
|
580 + | /// Returns `true` if the error kind is `NullInNonSparseError::InternalServerError`.
|
741 581 | pub fn is_internal_server_error(&self) -> bool {
|
742 - | matches!(&self, PrimitiveIntOpError::InternalServerError(_))
|
582 + | matches!(&self, NullInNonSparseError::InternalServerError(_))
|
743 583 | }
|
744 584 | /// Returns the error name string by matching the correct variant.
|
745 585 | pub fn name(&self) -> &'static str {
|
746 586 | match &self {
|
747 - | PrimitiveIntOpError::ExtraError(_inner) => _inner.name(),
|
748 - | PrimitiveIntOpError::InternalServerError(_inner) => _inner.name(),
|
587 + | NullInNonSparseError::ExtraError(_inner) => _inner.name(),
|
588 + | NullInNonSparseError::InternalServerError(_inner) => _inner.name(),
|
749 589 | }
|
750 590 | }
|
751 591 | }
|
752 - | impl ::std::error::Error for PrimitiveIntOpError {
|
592 + | impl ::std::error::Error for NullInNonSparseError {
|
753 593 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
754 594 | match &self {
|
755 - | PrimitiveIntOpError::ExtraError(_inner) => Some(_inner),
|
756 - | PrimitiveIntOpError::InternalServerError(_inner) => Some(_inner),
|
595 + | NullInNonSparseError::ExtraError(_inner) => Some(_inner),
|
596 + | NullInNonSparseError::InternalServerError(_inner) => Some(_inner),
|
757 597 | }
|
758 598 | }
|
759 599 | }
|
760 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::PrimitiveIntOpError {
|
761 - | fn from(variant: crate::error::ExtraError) -> crate::error::PrimitiveIntOpError {
|
600 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::NullInNonSparseError {
|
601 + | fn from(variant: crate::error::ExtraError) -> crate::error::NullInNonSparseError {
|
762 602 | Self::ExtraError(variant)
|
763 603 | }
|
764 604 | }
|
765 - | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::PrimitiveIntOpError {
|
766 - | fn from(variant: crate::error::InternalServerError) -> crate::error::PrimitiveIntOpError {
|
605 + | impl ::std::convert::From<crate::error::InternalServerError>
|
606 + | for crate::error::NullInNonSparseError
|
607 + | {
|
608 + | fn from(variant: crate::error::InternalServerError) -> crate::error::NullInNonSparseError {
|
767 609 | Self::InternalServerError(variant)
|
768 610 | }
|
769 611 | }
|
770 612 |
|
771 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::PrimitiveIntOpError {
|
772 - | fn from(variant: ::pyo3::PyErr) -> crate::error::PrimitiveIntOpError {
|
613 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::NullInNonSparseError {
|
614 + | fn from(variant: ::pyo3::PyErr) -> crate::error::NullInNonSparseError {
|
773 615 | ::pyo3::Python::with_gil(|py| {
|
774 616 | let error = variant.value(py);
|
775 617 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
776 618 | return error.into();
|
777 619 | }
|
778 620 | crate::error::InternalServerError {
|
779 621 | message: error.to_string(),
|
780 622 | }
|
781 623 | .into()
|
782 624 | })
|
783 625 | }
|
784 626 | }
|
785 627 |
|
786 - | /// Error type for the `MapWithEnumKeyOp` operation.
|
787 - | /// Each variant represents an error that can occur for the `MapWithEnumKeyOp` operation.
|
628 + | /// Error type for the `CaseInsensitiveErrorOperation` operation.
|
629 + | /// Each variant represents an error that can occur for the `CaseInsensitiveErrorOperation` operation.
|
788 630 | #[derive(::std::fmt::Debug)]
|
789 - | pub enum MapWithEnumKeyOpError {
|
790 - | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
791 - | ValidationException(crate::error::ValidationException),
|
631 + | pub enum CaseInsensitiveErrorOperationError {
|
632 + | #[allow(missing_docs)] // documentation missing in model
|
633 + | CaseInsensitiveError(crate::error::CaseInsensitiveError),
|
792 634 | #[allow(missing_docs)] // documentation missing in model
|
793 635 | ExtraError(crate::error::ExtraError),
|
794 636 | #[allow(missing_docs)] // documentation missing in model
|
795 637 | InternalServerError(crate::error::InternalServerError),
|
796 638 | }
|
797 - | impl ::std::fmt::Display for MapWithEnumKeyOpError {
|
639 + | impl ::std::fmt::Display for CaseInsensitiveErrorOperationError {
|
798 640 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
799 641 | match &self {
|
800 - | MapWithEnumKeyOpError::ValidationException(_inner) => _inner.fmt(f),
|
801 - | MapWithEnumKeyOpError::ExtraError(_inner) => _inner.fmt(f),
|
802 - | MapWithEnumKeyOpError::InternalServerError(_inner) => _inner.fmt(f),
|
642 + | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => _inner.fmt(f),
|
643 + | CaseInsensitiveErrorOperationError::ExtraError(_inner) => _inner.fmt(f),
|
644 + | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => _inner.fmt(f),
|
803 645 | }
|
804 646 | }
|
805 647 | }
|
806 - | impl MapWithEnumKeyOpError {
|
807 - | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::ValidationException`.
|
808 - | pub fn is_validation_exception(&self) -> bool {
|
809 - | matches!(&self, MapWithEnumKeyOpError::ValidationException(_))
|
648 + | impl CaseInsensitiveErrorOperationError {
|
649 + | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::CaseInsensitiveError`.
|
650 + | pub fn is_case_insensitive_error(&self) -> bool {
|
651 + | matches!(
|
652 + | &self,
|
653 + | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_)
|
654 + | )
|
810 655 | }
|
811 - | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::ExtraError`.
|
656 + | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::ExtraError`.
|
812 657 | pub fn is_extra_error(&self) -> bool {
|
813 - | matches!(&self, MapWithEnumKeyOpError::ExtraError(_))
|
658 + | matches!(&self, CaseInsensitiveErrorOperationError::ExtraError(_))
|
814 659 | }
|
815 - | /// Returns `true` if the error kind is `MapWithEnumKeyOpError::InternalServerError`.
|
660 + | /// Returns `true` if the error kind is `CaseInsensitiveErrorOperationError::InternalServerError`.
|
816 661 | pub fn is_internal_server_error(&self) -> bool {
|
817 - | matches!(&self, MapWithEnumKeyOpError::InternalServerError(_))
|
662 + | matches!(
|
663 + | &self,
|
664 + | CaseInsensitiveErrorOperationError::InternalServerError(_)
|
665 + | )
|
818 666 | }
|
819 667 | /// Returns the error name string by matching the correct variant.
|
820 668 | pub fn name(&self) -> &'static str {
|
821 669 | match &self {
|
822 - | MapWithEnumKeyOpError::ValidationException(_inner) => _inner.name(),
|
823 - | MapWithEnumKeyOpError::ExtraError(_inner) => _inner.name(),
|
824 - | MapWithEnumKeyOpError::InternalServerError(_inner) => _inner.name(),
|
670 + | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => _inner.name(),
|
671 + | CaseInsensitiveErrorOperationError::ExtraError(_inner) => _inner.name(),
|
672 + | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => _inner.name(),
|
825 673 | }
|
826 674 | }
|
827 675 | }
|
828 - | impl ::std::error::Error for MapWithEnumKeyOpError {
|
676 + | impl ::std::error::Error for CaseInsensitiveErrorOperationError {
|
829 677 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
830 678 | match &self {
|
831 - | MapWithEnumKeyOpError::ValidationException(_inner) => Some(_inner),
|
832 - | MapWithEnumKeyOpError::ExtraError(_inner) => Some(_inner),
|
833 - | MapWithEnumKeyOpError::InternalServerError(_inner) => Some(_inner),
|
679 + | CaseInsensitiveErrorOperationError::CaseInsensitiveError(_inner) => Some(_inner),
|
680 + | CaseInsensitiveErrorOperationError::ExtraError(_inner) => Some(_inner),
|
681 + | CaseInsensitiveErrorOperationError::InternalServerError(_inner) => Some(_inner),
|
834 682 | }
|
835 683 | }
|
836 684 | }
|
837 - | impl ::std::convert::From<crate::error::ValidationException>
|
838 - | for crate::error::MapWithEnumKeyOpError
|
685 + | impl ::std::convert::From<crate::error::CaseInsensitiveError>
|
686 + | for crate::error::CaseInsensitiveErrorOperationError
|
839 687 | {
|
840 - | fn from(variant: crate::error::ValidationException) -> crate::error::MapWithEnumKeyOpError {
|
841 - | Self::ValidationException(variant)
|
688 + | fn from(
|
689 + | variant: crate::error::CaseInsensitiveError,
|
690 + | ) -> crate::error::CaseInsensitiveErrorOperationError {
|
691 + | Self::CaseInsensitiveError(variant)
|
842 692 | }
|
843 693 | }
|
844 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::MapWithEnumKeyOpError {
|
845 - | fn from(variant: crate::error::ExtraError) -> crate::error::MapWithEnumKeyOpError {
|
694 + | impl ::std::convert::From<crate::error::ExtraError>
|
695 + | for crate::error::CaseInsensitiveErrorOperationError
|
696 + | {
|
697 + | fn from(variant: crate::error::ExtraError) -> crate::error::CaseInsensitiveErrorOperationError {
|
846 698 | Self::ExtraError(variant)
|
847 699 | }
|
848 700 | }
|
849 701 | impl ::std::convert::From<crate::error::InternalServerError>
|
850 - | for crate::error::MapWithEnumKeyOpError
|
702 + | for crate::error::CaseInsensitiveErrorOperationError
|
851 703 | {
|
852 - | fn from(variant: crate::error::InternalServerError) -> crate::error::MapWithEnumKeyOpError {
|
704 + | fn from(
|
705 + | variant: crate::error::InternalServerError,
|
706 + | ) -> crate::error::CaseInsensitiveErrorOperationError {
|
853 707 | Self::InternalServerError(variant)
|
854 708 | }
|
855 709 | }
|
856 710 |
|
857 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::MapWithEnumKeyOpError {
|
858 - | fn from(variant: ::pyo3::PyErr) -> crate::error::MapWithEnumKeyOpError {
|
711 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::CaseInsensitiveErrorOperationError {
|
712 + | fn from(variant: ::pyo3::PyErr) -> crate::error::CaseInsensitiveErrorOperationError {
|
859 713 | ::pyo3::Python::with_gil(|py| {
|
860 714 | let error = variant.value(py);
|
861 - | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
715 + | if let Ok(error) = error.extract::<crate::error::CaseInsensitiveError>() {
|
862 716 | return error.into();
|
863 717 | }
|
864 718 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
865 719 | return error.into();
|
866 720 | }
|
867 721 | crate::error::InternalServerError {
|
868 722 | message: error.to_string(),
|
869 723 | }
|
870 724 | .into()
|
871 725 | })
|
872 726 | }
|
873 727 | }
|
874 728 |
|
875 - | /// Error type for the `StatusResponse` operation.
|
876 - | /// Each variant represents an error that can occur for the `StatusResponse` operation.
|
729 + | /// Error type for the `EmptyStructWithContentOnWireOp` operation.
|
730 + | /// Each variant represents an error that can occur for the `EmptyStructWithContentOnWireOp` operation.
|
877 731 | #[derive(::std::fmt::Debug)]
|
878 - | pub enum StatusResponseError {
|
732 + | pub enum EmptyStructWithContentOnWireOpError {
|
879 733 | #[allow(missing_docs)] // documentation missing in model
|
880 734 | ExtraError(crate::error::ExtraError),
|
881 735 | #[allow(missing_docs)] // documentation missing in model
|
882 736 | InternalServerError(crate::error::InternalServerError),
|
883 737 | }
|
884 - | impl ::std::fmt::Display for StatusResponseError {
|
738 + | impl ::std::fmt::Display for EmptyStructWithContentOnWireOpError {
|
885 739 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
886 740 | match &self {
|
887 - | StatusResponseError::ExtraError(_inner) => _inner.fmt(f),
|
888 - | StatusResponseError::InternalServerError(_inner) => _inner.fmt(f),
|
741 + | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => _inner.fmt(f),
|
742 + | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => _inner.fmt(f),
|
889 743 | }
|
890 744 | }
|
891 745 | }
|
892 - | impl StatusResponseError {
|
893 - | /// Returns `true` if the error kind is `StatusResponseError::ExtraError`.
|
746 + | impl EmptyStructWithContentOnWireOpError {
|
747 + | /// Returns `true` if the error kind is `EmptyStructWithContentOnWireOpError::ExtraError`.
|
894 748 | pub fn is_extra_error(&self) -> bool {
|
895 - | matches!(&self, StatusResponseError::ExtraError(_))
|
749 + | matches!(&self, EmptyStructWithContentOnWireOpError::ExtraError(_))
|
896 750 | }
|
897 - | /// Returns `true` if the error kind is `StatusResponseError::InternalServerError`.
|
751 + | /// Returns `true` if the error kind is `EmptyStructWithContentOnWireOpError::InternalServerError`.
|
898 752 | pub fn is_internal_server_error(&self) -> bool {
|
899 - | matches!(&self, StatusResponseError::InternalServerError(_))
|
753 + | matches!(
|
754 + | &self,
|
755 + | EmptyStructWithContentOnWireOpError::InternalServerError(_)
|
756 + | )
|
900 757 | }
|
901 758 | /// Returns the error name string by matching the correct variant.
|
902 759 | pub fn name(&self) -> &'static str {
|
903 760 | match &self {
|
904 - | StatusResponseError::ExtraError(_inner) => _inner.name(),
|
905 - | StatusResponseError::InternalServerError(_inner) => _inner.name(),
|
761 + | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => _inner.name(),
|
762 + | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => _inner.name(),
|
906 763 | }
|
907 764 | }
|
908 765 | }
|
909 - | impl ::std::error::Error for StatusResponseError {
|
766 + | impl ::std::error::Error for EmptyStructWithContentOnWireOpError {
|
910 767 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
911 768 | match &self {
|
912 - | StatusResponseError::ExtraError(_inner) => Some(_inner),
|
913 - | StatusResponseError::InternalServerError(_inner) => Some(_inner),
|
769 + | EmptyStructWithContentOnWireOpError::ExtraError(_inner) => Some(_inner),
|
770 + | EmptyStructWithContentOnWireOpError::InternalServerError(_inner) => Some(_inner),
|
914 771 | }
|
915 772 | }
|
916 773 | }
|
917 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::StatusResponseError {
|
918 - | fn from(variant: crate::error::ExtraError) -> crate::error::StatusResponseError {
|
774 + | impl ::std::convert::From<crate::error::ExtraError>
|
775 + | for crate::error::EmptyStructWithContentOnWireOpError
|
776 + | {
|
777 + | fn from(
|
778 + | variant: crate::error::ExtraError,
|
779 + | ) -> crate::error::EmptyStructWithContentOnWireOpError {
|
919 780 | Self::ExtraError(variant)
|
920 781 | }
|
921 782 | }
|
922 - | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::StatusResponseError {
|
923 - | fn from(variant: crate::error::InternalServerError) -> crate::error::StatusResponseError {
|
783 + | impl ::std::convert::From<crate::error::InternalServerError>
|
784 + | for crate::error::EmptyStructWithContentOnWireOpError
|
785 + | {
|
786 + | fn from(
|
787 + | variant: crate::error::InternalServerError,
|
788 + | ) -> crate::error::EmptyStructWithContentOnWireOpError {
|
924 789 | Self::InternalServerError(variant)
|
925 790 | }
|
926 791 | }
|
927 792 |
|
928 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::StatusResponseError {
|
929 - | fn from(variant: ::pyo3::PyErr) -> crate::error::StatusResponseError {
|
793 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::EmptyStructWithContentOnWireOpError {
|
794 + | fn from(variant: ::pyo3::PyErr) -> crate::error::EmptyStructWithContentOnWireOpError {
|
930 795 | ::pyo3::Python::with_gil(|py| {
|
931 796 | let error = variant.value(py);
|
932 797 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
933 798 | return error.into();
|
934 799 | }
|
935 800 | crate::error::InternalServerError {
|
936 801 | message: error.to_string(),
|
937 802 | }
|
938 803 | .into()
|
939 804 | })
|
940 805 | }
|
941 806 | }
|
942 807 |
|
943 - | /// Error type for the `EnumQuery` operation.
|
944 - | /// Each variant represents an error that can occur for the `EnumQuery` operation.
|
808 + | /// Error type for the `QueryPrecedence` operation.
|
809 + | /// Each variant represents an error that can occur for the `QueryPrecedence` operation.
|
945 810 | #[derive(::std::fmt::Debug)]
|
946 - | pub enum EnumQueryError {
|
947 - | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
948 - | ValidationException(crate::error::ValidationException),
|
811 + | pub enum QueryPrecedenceError {
|
949 812 | #[allow(missing_docs)] // documentation missing in model
|
950 813 | ExtraError(crate::error::ExtraError),
|
951 814 | #[allow(missing_docs)] // documentation missing in model
|
952 815 | InternalServerError(crate::error::InternalServerError),
|
953 816 | }
|
954 - | impl ::std::fmt::Display for EnumQueryError {
|
817 + | impl ::std::fmt::Display for QueryPrecedenceError {
|
955 818 | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
956 819 | match &self {
|
957 - | EnumQueryError::ValidationException(_inner) => _inner.fmt(f),
|
958 - | EnumQueryError::ExtraError(_inner) => _inner.fmt(f),
|
959 - | EnumQueryError::InternalServerError(_inner) => _inner.fmt(f),
|
820 + | QueryPrecedenceError::ExtraError(_inner) => _inner.fmt(f),
|
821 + | QueryPrecedenceError::InternalServerError(_inner) => _inner.fmt(f),
|
960 822 | }
|
961 823 | }
|
962 824 | }
|
963 - | impl EnumQueryError {
|
964 - | /// Returns `true` if the error kind is `EnumQueryError::ValidationException`.
|
965 - | pub fn is_validation_exception(&self) -> bool {
|
966 - | matches!(&self, EnumQueryError::ValidationException(_))
|
967 - | }
|
968 - | /// Returns `true` if the error kind is `EnumQueryError::ExtraError`.
|
825 + | impl QueryPrecedenceError {
|
826 + | /// Returns `true` if the error kind is `QueryPrecedenceError::ExtraError`.
|
969 827 | pub fn is_extra_error(&self) -> bool {
|
970 - | matches!(&self, EnumQueryError::ExtraError(_))
|
828 + | matches!(&self, QueryPrecedenceError::ExtraError(_))
|
971 829 | }
|
972 - | /// Returns `true` if the error kind is `EnumQueryError::InternalServerError`.
|
830 + | /// Returns `true` if the error kind is `QueryPrecedenceError::InternalServerError`.
|
973 831 | pub fn is_internal_server_error(&self) -> bool {
|
974 - | matches!(&self, EnumQueryError::InternalServerError(_))
|
832 + | matches!(&self, QueryPrecedenceError::InternalServerError(_))
|
975 833 | }
|
976 834 | /// Returns the error name string by matching the correct variant.
|
977 835 | pub fn name(&self) -> &'static str {
|
978 836 | match &self {
|
979 - | EnumQueryError::ValidationException(_inner) => _inner.name(),
|
980 - | EnumQueryError::ExtraError(_inner) => _inner.name(),
|
981 - | EnumQueryError::InternalServerError(_inner) => _inner.name(),
|
837 + | QueryPrecedenceError::ExtraError(_inner) => _inner.name(),
|
838 + | QueryPrecedenceError::InternalServerError(_inner) => _inner.name(),
|
982 839 | }
|
983 840 | }
|
984 841 | }
|
985 - | impl ::std::error::Error for EnumQueryError {
|
842 + | impl ::std::error::Error for QueryPrecedenceError {
|
986 843 | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
987 844 | match &self {
|
988 - | EnumQueryError::ValidationException(_inner) => Some(_inner),
|
989 - | EnumQueryError::ExtraError(_inner) => Some(_inner),
|
990 - | EnumQueryError::InternalServerError(_inner) => Some(_inner),
|
845 + | QueryPrecedenceError::ExtraError(_inner) => Some(_inner),
|
846 + | QueryPrecedenceError::InternalServerError(_inner) => Some(_inner),
|
991 847 | }
|
992 848 | }
|
993 849 | }
|
994 - | impl ::std::convert::From<crate::error::ValidationException> for crate::error::EnumQueryError {
|
995 - | fn from(variant: crate::error::ValidationException) -> crate::error::EnumQueryError {
|
996 - | Self::ValidationException(variant)
|
997 - | }
|
998 - | }
|
999 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::EnumQueryError {
|
1000 - | fn from(variant: crate::error::ExtraError) -> crate::error::EnumQueryError {
|
850 + | impl ::std::convert::From<crate::error::ExtraError> for crate::error::QueryPrecedenceError {
|
851 + | fn from(variant: crate::error::ExtraError) -> crate::error::QueryPrecedenceError {
|
1001 852 | Self::ExtraError(variant)
|
1002 853 | }
|
1003 854 | }
|
1004 - | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::EnumQueryError {
|
1005 - | fn from(variant: crate::error::InternalServerError) -> crate::error::EnumQueryError {
|
855 + | impl ::std::convert::From<crate::error::InternalServerError>
|
856 + | for crate::error::QueryPrecedenceError
|
857 + | {
|
858 + | fn from(variant: crate::error::InternalServerError) -> crate::error::QueryPrecedenceError {
|
1006 859 | Self::InternalServerError(variant)
|
1007 860 | }
|
1008 861 | }
|
1009 862 |
|
1010 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::EnumQueryError {
|
1011 - | fn from(variant: ::pyo3::PyErr) -> crate::error::EnumQueryError {
|
863 + | impl ::std::convert::From<::pyo3::PyErr> for crate::error::QueryPrecedenceError {
|
864 + | fn from(variant: ::pyo3::PyErr) -> crate::error::QueryPrecedenceError {
|
1012 865 | ::pyo3::Python::with_gil(|py| {
|
1013 866 | let error = variant.value(py);
|
1014 - | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
1015 - | return error.into();
|
1016 - | }
|
1017 867 | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
1018 868 | return error.into();
|
1019 869 | }
|
1020 870 | crate::error::InternalServerError {
|
1021 871 | message: error.to_string(),
|
1022 872 | }
|
1023 873 | .into()
|
1024 874 | })
|
1025 875 | }
|
1026 876 | }
|
1027 877 |
|
1028 - | /// Error type for the `PrimitiveIntHeader` operation.
|
1029 - | /// Each variant represents an error that can occur for the `PrimitiveIntHeader` operation.
|
1030 - | #[derive(::std::fmt::Debug)]
|
1031 - | pub enum PrimitiveIntHeaderError {
|
1032 - | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
1033 - | ValidationException(crate::error::ValidationException),
|
1034 - | #[allow(missing_docs)] // documentation missing in model
|
1035 - | ExtraError(crate::error::ExtraError),
|
878 + | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
879 + | /// :rtype None:
|
880 + | #[allow(missing_docs)] // documentation missing in model
|
881 + | #[derive(
|
882 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
883 + | )]
|
884 + | pub struct ExtraError {}
|
885 + | #[allow(clippy::new_without_default)]
|
886 + | #[allow(clippy::too_many_arguments)]
|
887 + | #[::pyo3::pymethods]
|
888 + | impl ExtraError {
|
889 + | #[new]
|
890 + | pub fn new() -> Self {
|
891 + | Self {}
|
892 + | }
|
893 + | fn __repr__(&self) -> String {
|
894 + | format!("{self:?}")
|
895 + | }
|
896 + | fn __str__(&self) -> String {
|
897 + | format!("{self:?}")
|
898 + | }
|
899 + | }
|
900 + | impl ExtraError {
|
901 + | #[doc(hidden)]
|
902 + | /// Returns the error name.
|
903 + | pub fn name(&self) -> &'static str {
|
904 + | "ExtraError"
|
905 + | }
|
906 + | }
|
907 + | impl ::std::fmt::Display for ExtraError {
|
908 + | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
909 + | ::std::write!(f, "ExtraError")?;
|
910 + | Ok(())
|
911 + | }
|
912 + | }
|
913 + | impl ::std::error::Error for ExtraError {}
|
914 + | impl ExtraError {
|
915 + | /// Creates a new builder-style object to manufacture [`ExtraError`](crate::error::ExtraError).
|
916 + | pub fn builder() -> crate::error::extra_error::Builder {
|
917 + | crate::error::extra_error::Builder::default()
|
918 + | }
|
919 + | }
|
920 + |
|
921 + | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
922 + | /// :param message str:
|
923 + | /// :rtype None:
|
924 + | #[allow(missing_docs)] // documentation missing in model
|
925 + | #[derive(
|
926 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
927 + | )]
|
928 + | pub struct InternalServerError {
|
929 + | #[pyo3(get, set)]
|
930 + | /// :type str:
|
1036 931 | #[allow(missing_docs)] // documentation missing in model
|
1037 - | InternalServerError(crate::error::InternalServerError),
|
932 + | pub message: ::std::string::String,
|
933 + | }
|
934 + | #[allow(clippy::new_without_default)]
|
935 + | #[allow(clippy::too_many_arguments)]
|
936 + | #[::pyo3::pymethods]
|
937 + | impl InternalServerError {
|
938 + | #[new]
|
939 + | pub fn new(message: ::std::string::String) -> Self {
|
940 + | Self { message }
|
941 + | }
|
942 + | fn __repr__(&self) -> String {
|
943 + | format!("{self:?}")
|
944 + | }
|
945 + | fn __str__(&self) -> String {
|
946 + | format!("{self:?}")
|
947 + | }
|
948 + | }
|
949 + | impl InternalServerError {
|
950 + | /// Returns the error message.
|
951 + | pub fn message(&self) -> &str {
|
952 + | &self.message
|
953 + | }
|
954 + | #[doc(hidden)]
|
955 + | /// Returns the error name.
|
956 + | pub fn name(&self) -> &'static str {
|
957 + | "InternalServerError"
|
958 + | }
|
959 + | }
|
960 + | impl ::std::fmt::Display for InternalServerError {
|
961 + | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
962 + | ::std::write!(f, "InternalServerError")?;
|
963 + | {
|
964 + | ::std::write!(f, ": {}", &self.message)?;
|
965 + | }
|
966 + | Ok(())
|
967 + | }
|
968 + | }
|
969 + | impl ::std::error::Error for InternalServerError {}
|
970 + | impl InternalServerError {
|
971 + | /// Creates a new builder-style object to manufacture [`InternalServerError`](crate::error::InternalServerError).
|
972 + | pub fn builder() -> crate::error::internal_server_error::Builder {
|
973 + | crate::error::internal_server_error::Builder::default()
|
974 + | }
|
975 + | }
|
976 + |
|
977 + | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
978 + | /// :param message str:
|
979 + | /// :param field_list typing.Optional\[typing.List\[rest_json_extras.model.ValidationExceptionField\]\]:
|
980 + | /// :rtype None:
|
981 + | /// A standard error for input validation failures. This should be thrown by services when a member of the input structure falls outside of the modeled or documented constraints.
|
982 + | #[derive(
|
983 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
984 + | )]
|
985 + | pub struct ValidationException {
|
986 + | #[pyo3(get, set)]
|
987 + | /// :type str:
|
988 + | /// A summary of the validation failure.
|
989 + | pub message: ::std::string::String,
|
990 + | #[pyo3(get, set)]
|
991 + | /// :type typing.Optional\[typing.List\[rest_json_extras.model.ValidationExceptionField\]\]:
|
992 + | /// A list of specific failures encountered while validating the input. A member can appear in this list more than once if it failed to satisfy multiple constraints.
|
993 + | pub field_list: ::std::option::Option<::std::vec::Vec<crate::model::ValidationExceptionField>>,
|
1038 994 | }
|
1039 - | impl ::std::fmt::Display for PrimitiveIntHeaderError {
|
1040 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
1041 - | match &self {
|
1042 - | PrimitiveIntHeaderError::ValidationException(_inner) => _inner.fmt(f),
|
1043 - | PrimitiveIntHeaderError::ExtraError(_inner) => _inner.fmt(f),
|
1044 - | PrimitiveIntHeaderError::InternalServerError(_inner) => _inner.fmt(f),
|
1045 - | }
|
995 + | impl ValidationException {
|
996 + | /// A list of specific failures encountered while validating the input. A member can appear in this list more than once if it failed to satisfy multiple constraints.
|
997 + | pub fn field_list(&self) -> ::std::option::Option<&[crate::model::ValidationExceptionField]> {
|
998 + | self.field_list.as_deref()
|
1046 999 | }
|
1047 1000 | }
|
1048 - | impl PrimitiveIntHeaderError {
|
1049 - | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::ValidationException`.
|
1050 - | pub fn is_validation_exception(&self) -> bool {
|
1051 - | matches!(&self, PrimitiveIntHeaderError::ValidationException(_))
|
1052 - | }
|
1053 - | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::ExtraError`.
|
1054 - | pub fn is_extra_error(&self) -> bool {
|
1055 - | matches!(&self, PrimitiveIntHeaderError::ExtraError(_))
|
1001 + | #[allow(clippy::new_without_default)]
|
1002 + | #[allow(clippy::too_many_arguments)]
|
1003 + | #[::pyo3::pymethods]
|
1004 + | impl ValidationException {
|
1005 + | #[new]
|
1006 + | pub fn new(
|
1007 + | message: ::std::string::String,
|
1008 + | field_list: ::std::option::Option<::std::vec::Vec<crate::model::ValidationExceptionField>>,
|
1009 + | ) -> Self {
|
1010 + | Self {
|
1011 + | message,
|
1012 + | field_list,
|
1056 1013 | }
|
1057 - | /// Returns `true` if the error kind is `PrimitiveIntHeaderError::InternalServerError`.
|
1058 - | pub fn is_internal_server_error(&self) -> bool {
|
1059 - | matches!(&self, PrimitiveIntHeaderError::InternalServerError(_))
|
1060 1014 | }
|
1061 - | /// Returns the error name string by matching the correct variant.
|
1062 - | pub fn name(&self) -> &'static str {
|
1063 - | match &self {
|
1064 - | PrimitiveIntHeaderError::ValidationException(_inner) => _inner.name(),
|
1065 - | PrimitiveIntHeaderError::ExtraError(_inner) => _inner.name(),
|
1066 - | PrimitiveIntHeaderError::InternalServerError(_inner) => _inner.name(),
|
1015 + | fn __repr__(&self) -> String {
|
1016 + | format!("{self:?}")
|
1067 1017 | }
|
1018 + | fn __str__(&self) -> String {
|
1019 + | format!("{self:?}")
|
1068 1020 | }
|
1069 1021 | }
|
1070 - | impl ::std::error::Error for PrimitiveIntHeaderError {
|
1071 - | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
1072 - | match &self {
|
1073 - | PrimitiveIntHeaderError::ValidationException(_inner) => Some(_inner),
|
1074 - | PrimitiveIntHeaderError::ExtraError(_inner) => Some(_inner),
|
1075 - | PrimitiveIntHeaderError::InternalServerError(_inner) => Some(_inner),
|
1076 - | }
|
1022 + | impl ValidationException {
|
1023 + | /// Returns the error message.
|
1024 + | pub fn message(&self) -> &str {
|
1025 + | &self.message
|
1077 1026 | }
|
1078 - | }
|
1079 - | impl ::std::convert::From<crate::error::ValidationException>
|
1080 - | for crate::error::PrimitiveIntHeaderError
|
1081 - | {
|
1082 - | fn from(variant: crate::error::ValidationException) -> crate::error::PrimitiveIntHeaderError {
|
1083 - | Self::ValidationException(variant)
|
1027 + | #[doc(hidden)]
|
1028 + | /// Returns the error name.
|
1029 + | pub fn name(&self) -> &'static str {
|
1030 + | "ValidationException"
|
1084 1031 | }
|
1085 1032 | }
|
1086 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::PrimitiveIntHeaderError {
|
1087 - | fn from(variant: crate::error::ExtraError) -> crate::error::PrimitiveIntHeaderError {
|
1088 - | Self::ExtraError(variant)
|
1033 + | impl ::std::fmt::Display for ValidationException {
|
1034 + | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
1035 + | ::std::write!(f, "ValidationException")?;
|
1036 + | {
|
1037 + | ::std::write!(f, ": {}", &self.message)?;
|
1089 1038 | }
|
1090 - | }
|
1091 - | impl ::std::convert::From<crate::error::InternalServerError>
|
1092 - | for crate::error::PrimitiveIntHeaderError
|
1093 - | {
|
1094 - | fn from(variant: crate::error::InternalServerError) -> crate::error::PrimitiveIntHeaderError {
|
1095 - | Self::InternalServerError(variant)
|
1039 + | Ok(())
|
1096 1040 | }
|
1097 1041 | }
|
1098 - |
|
1099 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::PrimitiveIntHeaderError {
|
1100 - | fn from(variant: ::pyo3::PyErr) -> crate::error::PrimitiveIntHeaderError {
|
1101 - | ::pyo3::Python::with_gil(|py| {
|
1102 - | let error = variant.value(py);
|
1103 - | if let Ok(error) = error.extract::<crate::error::ValidationException>() {
|
1104 - | return error.into();
|
1105 - | }
|
1106 - | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
1107 - | return error.into();
|
1108 - | }
|
1109 - | crate::error::InternalServerError {
|
1110 - | message: error.to_string(),
|
1111 - | }
|
1112 - | .into()
|
1113 - | })
|
1042 + | impl ::std::error::Error for ValidationException {}
|
1043 + | impl ValidationException {
|
1044 + | /// Creates a new builder-style object to manufacture [`ValidationException`](crate::error::ValidationException).
|
1045 + | pub fn builder() -> crate::error::validation_exception::Builder {
|
1046 + | crate::error::validation_exception::Builder::default()
|
1114 1047 | }
|
1115 1048 | }
|
1116 1049 |
|
1117 - | /// Error type for the `StringPayload` operation.
|
1118 - | /// Each variant represents an error that can occur for the `StringPayload` operation.
|
1119 - | #[derive(::std::fmt::Debug)]
|
1120 - | pub enum StringPayloadError {
|
1121 - | #[allow(missing_docs)] // documentation missing in model
|
1122 - | ExtraError(crate::error::ExtraError),
|
1050 + | #[::pyo3::pyclass(extends = ::pyo3::exceptions::PyException)]
|
1051 + | /// :param message typing.Optional\[str\]:
|
1052 + | /// :rtype None:
|
1053 + | #[allow(missing_docs)] // documentation missing in model
|
1054 + | #[derive(
|
1055 + | ::std::clone::Clone, ::std::cmp::Eq, ::std::cmp::PartialEq, ::std::fmt::Debug, ::std::hash::Hash,
|
1056 + | )]
|
1057 + | pub struct CaseInsensitiveError {
|
1058 + | #[pyo3(get, set)]
|
1059 + | /// :type typing.Optional\[str\]:
|
1123 1060 | #[allow(missing_docs)] // documentation missing in model
|
1124 - | InternalServerError(crate::error::InternalServerError),
|
1061 + | pub message: ::std::option::Option<::std::string::String>,
|
1125 1062 | }
|
1126 - | impl ::std::fmt::Display for StringPayloadError {
|
1127 - | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
1128 - | match &self {
|
1129 - | StringPayloadError::ExtraError(_inner) => _inner.fmt(f),
|
1130 - | StringPayloadError::InternalServerError(_inner) => _inner.fmt(f),
|
1063 + | #[allow(clippy::new_without_default)]
|
1064 + | #[allow(clippy::too_many_arguments)]
|
1065 + | #[::pyo3::pymethods]
|
1066 + | impl CaseInsensitiveError {
|
1067 + | #[new]
|
1068 + | pub fn new(message: ::std::option::Option<::std::string::String>) -> Self {
|
1069 + | Self { message }
|
1131 1070 | }
|
1071 + | fn __repr__(&self) -> String {
|
1072 + | format!("{self:?}")
|
1132 1073 | }
|
1133 - | }
|
1134 - | impl StringPayloadError {
|
1135 - | /// Returns `true` if the error kind is `StringPayloadError::ExtraError`.
|
1136 - | pub fn is_extra_error(&self) -> bool {
|
1137 - | matches!(&self, StringPayloadError::ExtraError(_))
|
1074 + | fn __str__(&self) -> String {
|
1075 + | format!("{self:?}")
|
1138 1076 | }
|
1139 - | /// Returns `true` if the error kind is `StringPayloadError::InternalServerError`.
|
1140 - | pub fn is_internal_server_error(&self) -> bool {
|
1141 - | matches!(&self, StringPayloadError::InternalServerError(_))
|
1077 + | }
|
1078 + | impl CaseInsensitiveError {
|
1079 + | /// Returns the error message.
|
1080 + | pub fn message(&self) -> ::std::option::Option<&str> {
|
1081 + | self.message.as_deref()
|
1142 1082 | }
|
1143 - | /// Returns the error name string by matching the correct variant.
|
1083 + | #[doc(hidden)]
|
1084 + | /// Returns the error name.
|
1144 1085 | pub fn name(&self) -> &'static str {
|
1145 - | match &self {
|
1146 - | StringPayloadError::ExtraError(_inner) => _inner.name(),
|
1147 - | StringPayloadError::InternalServerError(_inner) => _inner.name(),
|
1148 - | }
|
1086 + | "CaseInsensitiveError"
|
1149 1087 | }
|
1150 1088 | }
|
1151 - | impl ::std::error::Error for StringPayloadError {
|
1152 - | fn source(&self) -> std::option::Option<&(dyn ::std::error::Error + 'static)> {
|
1153 - | match &self {
|
1154 - | StringPayloadError::ExtraError(_inner) => Some(_inner),
|
1155 - | StringPayloadError::InternalServerError(_inner) => Some(_inner),
|
1156 - | }
|
1089 + | impl ::std::fmt::Display for CaseInsensitiveError {
|
1090 + | fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
1091 + | ::std::write!(f, "CaseInsensitiveError")?;
|
1092 + | if let ::std::option::Option::Some(inner_1) = &self.message {
|
1093 + | {
|
1094 + | ::std::write!(f, ": {inner_1}")?;
|
1157 1095 | }
|
1158 - | }
|
1159 - | impl ::std::convert::From<crate::error::ExtraError> for crate::error::StringPayloadError {
|
1160 - | fn from(variant: crate::error::ExtraError) -> crate::error::StringPayloadError {
|
1161 - | Self::ExtraError(variant)
|
1162 1096 | }
|
1163 - | }
|
1164 - | impl ::std::convert::From<crate::error::InternalServerError> for crate::error::StringPayloadError {
|
1165 - | fn from(variant: crate::error::InternalServerError) -> crate::error::StringPayloadError {
|
1166 - | Self::InternalServerError(variant)
|
1097 + | Ok(())
|
1167 1098 | }
|
1168 1099 | }
|
1169 - |
|
1170 - | impl ::std::convert::From<::pyo3::PyErr> for crate::error::StringPayloadError {
|
1171 - | fn from(variant: ::pyo3::PyErr) -> crate::error::StringPayloadError {
|
1172 - | ::pyo3::Python::with_gil(|py| {
|
1173 - | let error = variant.value(py);
|
1174 - | if let Ok(error) = error.extract::<crate::error::ExtraError>() {
|
1175 - | return error.into();
|
1176 - | }
|
1177 - | crate::error::InternalServerError {
|
1178 - | message: error.to_string(),
|
1179 - | }
|
1180 - | .into()
|
1181 - | })
|
1100 + | impl ::std::error::Error for CaseInsensitiveError {}
|
1101 + | impl CaseInsensitiveError {
|
1102 + | /// Creates a new builder-style object to manufacture [`CaseInsensitiveError`](crate::error::CaseInsensitiveError).
|
1103 + | pub fn builder() -> crate::error::case_insensitive_error::Builder {
|
1104 + | crate::error::case_insensitive_error::Builder::default()
|
1182 1105 | }
|
1183 1106 | }
|
1184 1107 | /// See [`ExtraError`](crate::error::ExtraError).
|
1185 1108 | pub mod extra_error {
|
1186 1109 |
|
1187 1110 | impl ::std::convert::From<Builder> for crate::error::ExtraError {
|
1188 1111 | fn from(builder: Builder) -> Self {
|
1189 1112 | builder.build()
|
1190 1113 | }
|
1191 1114 | }
|