pub struct BoxLocalAsyncEndpoint<'a, I, O> { /* private fields */ }Expand description
A boxed LocalAsyncEndpoint trait object.
Implementations§
Source§impl<'a, I, O> BoxLocalAsyncEndpoint<'a, I, O>
impl<'a, I, O> BoxLocalAsyncEndpoint<'a, I, O>
Sourcepub fn new<T>(v: T) -> Selfwhere
T: LocalAsyncEndpoint<I, O> + 'a,
pub fn new<T>(v: T) -> Selfwhere
T: LocalAsyncEndpoint<I, O> + 'a,
Creates a new BoxLocalAsyncEndpoint.
Trait Implementations§
Source§impl<I, O> EndpointMetadata for BoxLocalAsyncEndpoint<'_, I, O>
impl<I, O> EndpointMetadata for BoxLocalAsyncEndpoint<'_, I, O>
Source§fn path(&self) -> &[PathSegment]
fn path(&self) -> &[PathSegment]
The endpoint’s parsed HTTP URI path. Read more
Source§fn service_name(&self) -> &str
fn service_name(&self) -> &str
The name of the service defining this endpoint.
Source§fn deprecated(&self) -> Option<&str>
fn deprecated(&self) -> Option<&str>
If the endpoint is deprecated, returns the deprecation documentation.
Source§impl<I, O> LocalAsyncEndpoint<I, O> for BoxLocalAsyncEndpoint<'_, I, O>
impl<I, O> LocalAsyncEndpoint<I, O> for BoxLocalAsyncEndpoint<'_, I, O>
Source§async fn handle(
&self,
req: Request<I>,
response_extensions: &mut Extensions,
) -> Result<Response<LocalAsyncResponseBody<O>>, Error>
async fn handle( &self, req: Request<I>, response_extensions: &mut Extensions, ) -> Result<Response<LocalAsyncResponseBody<O>>, Error>
Handles a request to the endpoint. Read more