pub trait Artifact: Send + Sync {
// Required methods
fn classifier(&self) -> Option<String>;
fn extension(&self) -> String;
fn name(&self) -> String;
fn artifact_type(&self) -> String;
// Provided methods
fn date(&self) -> Option<Date> { ... }
fn file(&self) -> PathBuf { ... }
fn buildable(&self) -> Option<Box<dyn Buildable>> { ... }
}
Expand description
Represents the artifact output of some task
Required Methods§
Sourcefn classifier(&self) -> Option<String>
fn classifier(&self) -> Option<String>
The classifier of the artifact, if any
Sourcefn artifact_type(&self) -> String
fn artifact_type(&self) -> String
The type of the artifact.
By default, this value is the name as the extension but can have a different value.
Provided Methods§
Sourcefn date(&self) -> Option<Date>
fn date(&self) -> Option<Date>
The date that should be used when publishing the artifact.
By default, nothing is returned
Sourcefn file(&self) -> PathBuf
fn file(&self) -> PathBuf
Gets the file for this artifact.
By default, this value is [name][-[classifier]].[extension]
fn buildable(&self) -> Option<Box<dyn Buildable>>
Trait Implementations§
Source§impl Artifact for Box<dyn Artifact>
impl Artifact for Box<dyn Artifact>
Source§fn classifier(&self) -> Option<String>
fn classifier(&self) -> Option<String>
The classifier of the artifact, if any
Source§fn date(&self) -> Option<Date>
fn date(&self) -> Option<Date>
The date that should be used when publishing the artifact. Read more
Source§fn artifact_type(&self) -> String
fn artifact_type(&self) -> String
The type of the artifact. Read more