pub struct Tree { /* private fields */ }
Expand description

A hierarchical structure that provides a root Node and subtrees of linked nodes that represent valid Request paths.

The Tree is created by the gotham::router::builder API and used internally by the Router to determine the valid Route instances for a request path before dispatch.

Implementations

Creates a new Tree and root Node.

Adds a direct child to the root of the Tree.

Adds a Route be evaluated by the Router when the root of the Tree is requested.

Borrow the root NodeBuilder as mutable.

Determines if a child Node representing the exact segment provided exists at the root of the Tree.

To be used in building a Tree structure only.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more