[][src]Struct ketos::trace::Trace

pub struct Trace { /* fields omitted */ }

Represents a series of items, beginning with the outermost context and culminating with the context in which an error was generated.

Methods

impl Trace[src]

pub fn new(items: Vec<TraceItem>, expr: Option<Value>) -> Trace[src]

Creates a new Trace from a series of items.

pub fn single(item: TraceItem, expr: Option<Value>) -> Trace[src]

Creates a new Trace from a single item.

pub fn items(&self) -> &[TraceItem][src]

Returns the series of traced items.

pub fn expr(&self) -> Option<&Value>[src]

Returns a borrowed reference to the optional contained expression.

pub fn take_expr(&mut self) -> Option<Value>[src]

Takes the optional contained expression and returns it.

Trait Implementations

impl NameDisplay for Trace[src]

impl Clone for Trace[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl !Send for Trace

impl !Sync for Trace

Blanket Implementations

impl<T> AnyValue for T where
    T: Any
[src]

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

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

type Owned = T

impl<T> From for T[src]

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

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

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

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

The type returned in the event of a conversion error.