Struct warp::filters::BoxedFilter[][src]

pub struct BoxedFilter<T: Tuple> { /* fields omitted */ }

A type representing a boxed Filter trait object.

The filter inside is a dynamic trait object. The purpose of this type is to ease returning Filters from other functions.

To create one, call Filter::boxed on any filter.

Examples

use warp::{Filter, filters::BoxedFilter, Reply};
 
pub fn assets_filter() -> BoxedFilter<(impl Reply,)> {
    warp::path("assets")
        .and(warp::fs::dir("./assets"))
        .boxed()
}

Trait Implementations

impl<T: Tuple> Clone for BoxedFilter<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<T: Tuple> Debug for BoxedFilter<T>
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<T> Send for BoxedFilter<T>

impl<T> Sync for BoxedFilter<T>