[][src]Trait conjure_http::server::AsyncResource

pub trait AsyncResource<I, O>: Sized + Sync + Send {
    const NAME: &'static str;

    fn endpoints<B, R>() -> Vec<AsyncEndpoint<Self, B, R>>
    where
        B: RequestBody<BinaryBody = I> + Send,
        B::BinaryBody: Send,
        R: AsyncVisitResponse<BinaryWriter = O> + Send
; }

An asynchronous HTTP resource.

The server-half of a Conjure service implements this trait.

Associated Constants

const NAME: &'static str

The resource's name.

Loading content...

Required methods

fn endpoints<B, R>() -> Vec<AsyncEndpoint<Self, B, R>> where
    B: RequestBody<BinaryBody = I> + Send,
    B::BinaryBody: Send,
    R: AsyncVisitResponse<BinaryWriter = O> + Send

Returns the resource's HTTP endpoints.

Loading content...

Implementors

Loading content...