#[non_exhaustive]pub enum ConfigError {
NoRoots,
EmptyRoot,
CacheCapacityTooLarge {
value: usize,
max: usize,
},
InvalidEnvironment,
NotUnicode(&'static str),
NotANumber(&'static str),
}Expand description
An invalid Sword configuration. Messages never include variable values.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NoRoots
No template root was configured.
EmptyRoot
A template root is an empty path.
CacheCapacityTooLarge
The cache capacity is above MAX_CACHE_CAPACITY.
InvalidEnvironment
The environment name is not 1 to 64 letters, digits, _, - or ..
NotUnicode(&'static str)
An environment variable (named here) is not valid unicode.
NotANumber(&'static str)
An environment variable (named here) is not a non-negative whole number.
Trait Implementations§
Source§impl Clone for ConfigError
impl Clone for ConfigError
Source§impl Debug for ConfigError
impl Debug for ConfigError
Source§impl Display for ConfigError
impl Display for ConfigError
impl Eq for ConfigError
Source§impl Error for ConfigError
impl Error for ConfigError
1.30.0 · 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 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for ConfigError
impl PartialEq for ConfigError
impl StructuralPartialEq for ConfigError
Auto Trait Implementations§
impl Forget for ConfigError
impl Freeze for ConfigError
impl Move for ConfigError
impl RefUnwindSafe for ConfigError
impl Send for ConfigError
impl Sync for ConfigError
impl Unpin for ConfigError
impl UnsafeUnpin for ConfigErrorwhere
&'static str: UnsafeUnpin,
impl UnwindSafe for ConfigErrorwhere
&'static str: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.