Trait poem_openapi::API [−][src]
pub trait API: Sized {
fn meta() -> Vec<MetaAPI>;
fn register(registry: &mut Registry);
fn add_routes(self, route: Route) -> Route;
fn combine<T: API>(self, other: T) -> CombinedAPI<Self, T> { ... }
}
Expand description
Represents a OpenAPI object.
Required methods
fn add_routes(self, route: Route) -> Route
fn add_routes(self, route: Route) -> Route
Adds all API endpoints to the routing object.
Provided methods
fn combine<T: API>(self, other: T) -> CombinedAPI<Self, T>
fn combine<T: API>(self, other: T) -> CombinedAPI<Self, T>
Combine two API objects into one.