[][src]Struct tide_fluent_routes::RouteSegment

pub struct RouteSegment<State> { /* fields omitted */ }

A Builder for Tide routes. RouteBuilders can be composed into a tree that represents the tree of path segments, middleware and endpoints that defines the routes in a Tide application. This tree can then be returned as a list of routes to each of the endpoints.

Trait Implementations

impl<State: Debug> Debug for RouteSegment<State>[src]

impl<State: Clone + Send + Sync + 'static> RouteBuilder<State> for RouteSegment<State>[src]

fn method(self, method: Method, endpoint: impl Endpoint<State>) -> Self[src]

Add an endpoint

fn at<R: Fn(Self) -> Self>(self, path: &str, routes: R) -> Self[src]

Add sub-routes for a path segment

fn with<M: Middleware<State>, R: Fn(Self) -> Self>(
    self,
    middleware: M,
    routes: R
) -> Self
[src]

Add sub-routes for a middleware

Auto Trait Implementations

impl<State> !RefUnwindSafe for RouteSegment<State>

impl<State> Send for RouteSegment<State>

impl<State> Sync for RouteSegment<State>

impl<State> Unpin for RouteSegment<State>

impl<State> !UnwindSafe for RouteSegment<State>

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<State, R> RouteBuilderExt<State> for R where
    R: RouteBuilder<State>,
    State: 'static + Clone + Send + Sync
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

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>,