[][src]Struct paperclip::actix::App

pub struct App<T, B> { /* fields omitted */ }

Wrapper for actix_web::App.

Methods

impl<T, B> App<T, B> where
    B: MessageBody,
    T: ServiceFactory<Config = (), Request = ServiceRequest, Response = ServiceResponse<B>, Error = Error, InitError = ()>, 
[src]

pub fn data<U>(self, data: U) -> App<T, B> where
    U: 'static, 
[src]

Proxy for actix_web::App::data.

NOTE: This doesn't affect spec generation.

pub fn data_factory<F, Out, D, E>(self, data: F) -> App<T, B> where
    D: 'static,
    E: Debug,
    F: Fn() -> Out + 'static,
    Out: Future<Output = Result<D, E>> + 'static, 
[src]

Proxy for actix_web::App::data_factory.

NOTE: This doesn't affect spec generation.

pub fn app_data<U>(self, data: U) -> App<T, B> where
    U: 'static, 
[src]

Proxy for actix_web::App::app_data.

NOTE: This doesn't affect spec generation.

pub fn configure<F>(self, f: F) -> App<T, B> where
    F: FnOnce(&mut ServiceConfig<Scope<ScopeEndpoint>>), 
[src]

pub fn route(self, path: &str, route: Route) -> App<T, B>[src]

Wrapper for actix_web::App::route.

pub fn service<F>(self, factory: F) -> App<T, B> where
    F: Mountable + HttpServiceFactory + 'static, 
[src]

pub fn default_service<F, U>(self, f: F) -> App<T, B> where
    F: IntoServiceFactory<U>,
    U: ServiceFactory<Config = (), Request = ServiceRequest, Response = ServiceResponse<Body>, Error = Error, InitError = ()> + 'static,
    <U as ServiceFactory>::InitError: Debug
[src]

Proxy for actix_web::App::default_service.

NOTE: This doesn't affect spec generation.

pub fn external_resource<N, U>(self, name: N, url: U) -> App<T, B> where
    N: AsRef<str>,
    U: AsRef<str>, 
[src]

Proxy for actix_web::App::external_resource.

NOTE: This doesn't affect spec generation.

pub fn wrap<M, B1>(
    self,
    mw: M
) -> App<impl ServiceFactory<Config = (), Request = ServiceRequest, Response = ServiceResponse<B1>, Error = Error, InitError = ()>, B1> where
    B1: MessageBody,
    M: Transform<<T as ServiceFactory>::Service, Request = ServiceRequest, Response = ServiceResponse<B1>, Error = Error, InitError = ()>, 
[src]

Proxy for actix_web::web::App::wrap.

NOTE: This doesn't affect spec generation.

pub fn wrap_fn<B1, F, R>(
    self,
    mw: F
) -> App<impl ServiceFactory<Config = (), Request = ServiceRequest, Response = ServiceResponse<B1>, Error = Error, InitError = ()>, B1> where
    B1: MessageBody,
    F: FnMut(ServiceRequest, &mut <T as ServiceFactory>::Service) -> R + Clone,
    R: Future<Output = Result<ServiceResponse<B1>, Error>>, 
[src]

Proxy for actix_web::web::App::wrap_fn.

NOTE: This doesn't affect spec generation.

pub fn with_json_spec_at(self, path: &str) -> App<T, B>[src]

Mounts the specification for all operations and definitions recorded by the wrapper and serves them in the given path as a JSON.

pub fn with_raw_json_spec<F>(self, call: F) -> App<T, B> where
    F: FnMut(App<T, B>, Value) -> App<T, B>, 
[src]

Calls the given function with App and JSON Value representing your API specification built until now.

NOTE: Unlike with_json_spec_at, this only has the API spec built until this function call. Any route handler added after this call won't affect the spec. So, it's important to call this function after adding all route handlers.

pub fn build(self) -> App<T, B>[src]

Builds and returns the actix_web::App.

Auto Trait Implementations

impl<T, B> !RefUnwindSafe for App<T, B>

impl<T, B> !Send for App<T, B>

impl<T, B> !Sync for App<T, B>

impl<T, B> Unpin for App<T, B> where
    B: Unpin,
    T: Unpin

impl<T, B> !UnwindSafe for App<T, B>

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<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<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

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

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,