pub trait Apiv2Operation {
// Required methods
fn operation() -> DefaultOperationRaw;
fn security_definitions() -> BTreeMap<String, SecurityScheme>;
fn definitions() -> BTreeMap<String, DefaultSchemaRaw>;
// Provided method
fn is_visible() -> bool { ... }
}
Expand description
Represents a OpenAPI v2 operation convertible. This is auto-implemented by framework-specific macros:
NOTE: The type parameters specified here aren’t used by the trait itself, but can be used for constraining stuff in framework-related impls.
Required Methods§
sourcefn operation() -> DefaultOperationRaw
fn operation() -> DefaultOperationRaw
Returns the definition for this operation.
sourcefn security_definitions() -> BTreeMap<String, SecurityScheme>
fn security_definitions() -> BTreeMap<String, SecurityScheme>
Returns a map of security definitions that will be merged globally.
sourcefn definitions() -> BTreeMap<String, DefaultSchemaRaw>
fn definitions() -> BTreeMap<String, DefaultSchemaRaw>
Returns the definitions used by this operation.
Provided Methods§
fn is_visible() -> bool
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.