pub enum ExtensionTypeError {
InvalidName(InvalidTypeName),
InvalidAnyTypeVariable {
id: u32,
nullability: bool,
},
InvalidParameter(TypeParamError),
InvalidFieldType(String),
DuplicateFieldName {
field_name: String,
},
InvalidParameterCount {
type_name: String,
expected: usize,
actual: usize,
},
InvalidParameterKind {
type_name: String,
index: usize,
expected: &'static str,
},
InvalidParameterValue {
type_name: String,
index: usize,
value: i64,
expected: &'static str,
},
InvalidParameterRange {
type_name: String,
index: usize,
value: i64,
expected: RangeInclusive<i32>,
},
StructureCannotBeNullable {
type_string: String,
},
ParseType(TypeParseError),
}Available on crate feature
parse only.Expand description
Error types for extension type validation
Variants§
InvalidName(InvalidTypeName)
Extension type name is invalid
InvalidAnyTypeVariable
Any type variable is invalid for concrete types
InvalidParameter(TypeParamError)
Parameter validation failed
InvalidFieldType(String)
Field type is invalid
DuplicateFieldName
Duplicate struct field name
InvalidParameterCount
Type parameter count is invalid for the given type name
Fields
InvalidParameterKind
Type parameter is of the wrong kind for the given position
Fields
InvalidParameterValue
Provided parameter value does not fit within the expected bounds
Fields
InvalidParameterRange
Provided parameter value does not fit within the expected bounds
Fields
§
expected: RangeInclusive<i32>Description of the expected range or type
StructureCannotBeNullable
Structure representation cannot be nullable
ParseType(TypeParseError)
Error parsing type
Trait Implementations§
Source§impl Debug for ExtensionTypeError
impl Debug for ExtensionTypeError
Source§impl Display for ExtensionTypeError
impl Display for ExtensionTypeError
Source§impl Error for ExtensionTypeError
impl Error for ExtensionTypeError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<ExtensionTypeError> for SimpleExtensionsError
impl From<ExtensionTypeError> for SimpleExtensionsError
Source§fn from(source: ExtensionTypeError) -> Self
fn from(source: ExtensionTypeError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ExtensionTypeError
impl PartialEq for ExtensionTypeError
impl StructuralPartialEq for ExtensionTypeError
Auto Trait Implementations§
impl Freeze for ExtensionTypeError
impl RefUnwindSafe for ExtensionTypeError
impl Send for ExtensionTypeError
impl Sync for ExtensionTypeError
impl Unpin for ExtensionTypeError
impl UnwindSafe for ExtensionTypeError
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more