pub trait Source {
// Required methods
fn update(&mut self) -> Result<()>;
fn versions(&mut self) -> Result<&BTreeSet<Version>>;
fn set_current_version(&mut self, version: Version);
fn dir(&mut self) -> Result<&Path>;
}Expand description
A source trait.
The source allows to access a package diractory. The package is automatically updated, downaloded, and extracted by the source if it is necessery. Also, the packege source allows to manually update the package versions. The package updating is called the updating of package versions.
Required Methods§
Sourcefn set_current_version(&mut self, version: Version)
fn set_current_version(&mut self, version: Version)
Sets the current package version.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".