paperclip_actix

Trait Mountable

source
pub trait Mountable {
    // Required methods
    fn path(&self) -> &str;
    fn operations(&mut self) -> BTreeMap<HttpMethod, DefaultOperationRaw>;
    fn definitions(&mut self) -> BTreeMap<String, DefaultSchemaRaw>;
    fn security_definitions(&mut self) -> BTreeMap<String, SecurityScheme>;

    // Provided method
    fn update_operations(
        &mut self,
        map: &mut BTreeMap<String, DefaultPathItemRaw>,
    ) { ... }
}
Expand description

Indicates that this thingmabob has a path and a bunch of definitions and operations.

Required Methods§

source

fn path(&self) -> &str

Where this thing gets mounted.

source

fn operations(&mut self) -> BTreeMap<HttpMethod, DefaultOperationRaw>

Map of HTTP methods and the associated API operations.

source

fn definitions(&mut self) -> BTreeMap<String, DefaultSchemaRaw>

The definitions recorded by this object.

source

fn security_definitions(&mut self) -> BTreeMap<String, SecurityScheme>

The security definitions recorded by this object.

Provided Methods§

source

fn update_operations(&mut self, map: &mut BTreeMap<String, DefaultPathItemRaw>)

Updates the given map of operations with operations tracked by this object.

NOTE: Overriding implementations must ensure that the PathItem is normalized before updating the input map.

Implementors§