Function actix_web::pred::Any
[−]
[src]
pub fn Any<S: 'static, P: Predicate<S> + 'static>(pred: P) -> AnyPredicate<S>
Return predicate that matches if any of supplied predicate matches.
use actix_web::pred; fn main() { Application::new() .resource("/index.html", |r| r.route() .p(pred::Any(pred::Get()).or(pred::Post())) .h(HTTPMethodNotAllowed)); }