Skip to main content

VersionMatcher

Trait VersionMatcher 

Source
pub trait VersionMatcher: Send + Sync {
    // Required method
    fn matches(&self, version: &ApiVersion) -> bool;

    // Provided method
    fn priority(&self) -> i32 { ... }
}
Expand description

Matcher for version selection

Required Methods§

Source

fn matches(&self, version: &ApiVersion) -> bool

Check if a version matches

Provided Methods§

Source

fn priority(&self) -> i32

Get the priority (higher = preferred)

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§