Trait finchers_core::Endpoint [] [src]

pub trait Endpoint: Send + Sync {
    type Output;
    type Task: Task<Output = Self::Output>;
    fn apply(&self, cx: &mut Context) -> Option<Self::Task>;

    fn apply_request(
        &self,
        input: &Input,
        body: RequestBody
    ) -> ApplyRequest<Self::Task> { ... } }

Trait representing an endpoint.

Associated Types

The inner type associated with this endpoint.

The type of value which will be returned from apply.

Required Methods

Perform checking the incoming HTTP request and returns an instance of the associated task if matched.

Provided Methods

Create an asyncrhonous computation from a request.

Implementations on Foreign Types

impl<'a, E: Endpoint> Endpoint for &'a E
[src]

[src]

[src]

impl<E: Endpoint> Endpoint for Box<E>
[src]

[src]

[src]

impl<E: Endpoint> Endpoint for Arc<E>
[src]

[src]

[src]

Implementors