[][src]Struct outils::tree::generic::error::TreeError

pub struct TreeError<Ix = DefaultIndexType> { /* fields omitted */ }

Error type that covers the error situations that commonly occur when manipulation tree or forest operations.

TreeError keeps a TreeErrorType describing the error as well as a String that can be used to store a description of the context in which the error has occured.

Implementations

impl<Ix> TreeError<Ix>[src]

pub fn invalid_node_index(context: &str, node: NodeIndex<Ix>) -> Self[src]

Construct a new TreeError of type TreeErrorType::InvalidNodeIndex referring to node

pub fn expected_root_node(context: &str, node: NodeIndex<Ix>) -> Self[src]

Construct a new TreeError of type TreeErrorType::ExpectedRootNode referring to node

pub fn expected_non_ancestor_node(
    context: &str,
    new_ancestor: NodeIndex<Ix>,
    new_descendant: NodeIndex<Ix>
) -> Self
[src]

Construct a new TreeError of type TreeErrorType::ExpectedNonAncestorNode referring to new_ancestor and new_descendant.

pub fn other_error(context: &str, msg: &str) -> Self[src]

Construct a new TreeError of type TreeErrorType::OtherType with a custom message msgdescribing the particular error situation.

Trait Implementations

impl<Ix: Clone> Clone for TreeError<Ix>[src]

impl<Ix: Debug> Debug for TreeError<Ix>[src]

impl Display for TreeError[src]

impl Error for TreeError[src]

Auto Trait Implementations

impl<Ix> RefUnwindSafe for TreeError<Ix> where
    Ix: RefUnwindSafe

impl<Ix> Send for TreeError<Ix> where
    Ix: Send

impl<Ix> Sync for TreeError<Ix> where
    Ix: Sync

impl<Ix> Unpin for TreeError<Ix> where
    Ix: Unpin

impl<Ix> UnwindSafe for TreeError<Ix> where
    Ix: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,