Skip to main content

VersionExtractor

Trait VersionExtractor 

Source
pub trait VersionExtractor {
    type ConfigType: Default + for<'de> Deserialize<'de> + Clone;

    // Required method
    async fn get_last_version(
        &self,
        config: Self::ConfigType,
    ) -> Result<VersionInfo>;

    // Provided method
    async fn get_all_versions(
        &self,
        _config: Self::ConfigType,
    ) -> Result<Vec<VersionInfo>> { ... }
}

Required Associated Types§

Source

type ConfigType: Default + for<'de> Deserialize<'de> + Clone

Required Methods§

Source

async fn get_last_version( &self, config: Self::ConfigType, ) -> Result<VersionInfo>

Provided Methods§

Source

async fn get_all_versions( &self, _config: Self::ConfigType, ) -> Result<Vec<VersionInfo>>

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.

Implementors§