#[non_exhaustive]pub enum NestedSetError {
NodeNotFound {
model: &'static str,
key: String,
},
MoveIntoOwnSubtree {
model: &'static str,
key: String,
target: String,
},
OutsideScope {
model: &'static str,
},
DuplicateKey {
model: &'static str,
key: String,
},
ScopeMismatch {
model: &'static str,
key: String,
target: String,
},
}Expand description
An operation on a tree that can’t be done.
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.
NodeNotFound
The node an operation starts from is no longer in the table.
MoveIntoOwnSubtree
A move would put a node inside its own subtree.
Fields
OutsideScope
A node made by create_root_in isn’t in the scope it was given: the scope doesn’t name
the model’s scope columns.
DuplicateKey
An arrangement lists the same node twice.
ScopeMismatch
A move would take a node into another tree of the table.
Trait Implementations§
Source§impl Clone for NestedSetError
impl Clone for NestedSetError
Source§impl Debug for NestedSetError
impl Debug for NestedSetError
Source§impl Display for NestedSetError
impl Display for NestedSetError
impl Eq for NestedSetError
Source§impl Error for NestedSetError
impl Error for NestedSetError
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 NestedSetError
impl PartialEq for NestedSetError
impl StructuralPartialEq for NestedSetError
Auto Trait Implementations§
impl Forget for NestedSetError
impl Freeze for NestedSetError
impl Move for NestedSetError
impl RefUnwindSafe for NestedSetError
impl Send for NestedSetError
impl Sync for NestedSetErrorwhere
RawVecInner: Sync,
impl Unpin for NestedSetError
impl UnsafeUnpin for NestedSetError
impl UnwindSafe for NestedSetError
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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.impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<K> ForeignKey<K> for K
impl<K> ForeignKey<K> for K
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more