pub struct App { /* private fields */ }Expand description
Builder for an application description.
Implementations§
Source§impl App
impl App
pub const fn new() -> Self
pub fn route(self, operation: OperationDescriptor) -> Self
pub fn routes( self, operations: impl IntoIterator<Item = OperationDescriptor>, ) -> Self
Sourcepub fn security_scheme(self, scheme: SecuritySchemeDescriptor) -> Self
pub fn security_scheme(self, scheme: SecuritySchemeDescriptor) -> Self
Registers a named security scheme referenced by operation contracts.
Sourcepub fn build(self) -> Result<AppDefinition, BuildError>
pub fn build(self) -> Result<AppDefinition, BuildError>
Validates and deterministically orders the application graph.
§Errors
Returns BuildError when an operation identity or HTTP binding is
registered more than once.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for App
impl RefUnwindSafe for App
impl Send for App
impl Sync for App
impl Unpin for App
impl UnsafeUnpin for App
impl UnwindSafe for App
Blanket Implementations§
Source§impl<T> BackgroundExt for T
impl<T> BackgroundExt for T
fn background(self, task: BackgroundTask) -> Background<Self>
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more