pub enum Error {
Show 16 variants
UnsupportedOperation {
operation: String,
actual_type: ValueType,
},
ValueConversion {
src_type: ValueType,
dst_type: ValueType,
},
RangeTooLarge {
length: usize,
},
ValueType {
actual_type: ValueType,
expected_type: ValueType,
},
Index {
key: String,
},
InvalidTypeForKey(ValueType),
InvalidRegexFlag(String),
UnrecognizedType(String),
Overflow,
ParseDecimalError(ParseDecimalError),
ParseFloatError(ParseFloatError),
ParseIntError(ParseIntError),
InvalidRange,
DecimalError(DecimalError),
RegexError(Error),
TryReserveError(TryReserveError),
}
Expand description
This type is used for all errors that can be returned by Polyvalue
Variants§
UnsupportedOperation
An error caused by attempting to use a value of the wrong type in a calculation
Fields
ValueConversion
An error caused by attempting to convert a value to a different type
Fields
RangeTooLarge
An error caused by attempting to convert a value to a different type
ValueType
An error caused by attempting to use a value of the wrong type in a calculation
Fields
Index
An error caused by attempting to use an invalid object or array key
InvalidTypeForKey(ValueType)
An error caused by attempting to use an type as an object key
InvalidRegexFlag(String)
An error caused by attempting to use an invalid regex flag
UnrecognizedType(String)
An error caused by attempting to use an unsupported type
Overflow
An error caused by a calculation that resulted in an overflow
ParseDecimalError(ParseDecimalError)
An error caused by parsing a value from a string
ParseFloatError(ParseFloatError)
An error caused by parsing a value from a string
ParseIntError(ParseIntError)
An error caused by parsing a value from a string
InvalidRange
An error caused by parsing a value from a string
DecimalError(DecimalError)
An error caused by parsing a Decimal
RegexError(Error)
An error caused by parsing a regex
TryReserveError(TryReserveError)
An error caused by large allocations