pub struct ArtifactRef { /* private fields */ }Expand description
A handle on an artifact produced by an earlier step of the run.
Only the producing step hands one out: StepOutput::artifact
for a file a shell step declared with ShellConfig::output,
WorkflowContext::put_artifact
for bytes stored by hand. Pass it to ShellConfig::input
or WorkflowContext::get_artifact:
the producer’s name is never copied by hand.
§Examples
use ironflow_engine::config::ShellConfig;
use ironflow_engine::context::WorkflowContext;
use ironflow_engine::error::EngineError;
let build = ctx
.shell("build", ShellConfig::new("./gen-report").output("target/report.html"))
.await?;
let report = build.artifact("report.html")?;
assert_eq!(report.step(), "build");
ctx.shell("publish", ShellConfig::new("./publish report.html").input(&report))
.await?;Implementations§
Trait Implementations§
Source§impl Clone for ArtifactRef
impl Clone for ArtifactRef
Source§impl Debug for ArtifactRef
impl Debug for ArtifactRef
impl Eq for ArtifactRef
Source§impl From<&ArtifactRef> for ArtifactInput
impl From<&ArtifactRef> for ArtifactInput
Source§fn from(artifact: &ArtifactRef) -> Self
fn from(artifact: &ArtifactRef) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ArtifactRef
impl PartialEq for ArtifactRef
impl StructuralPartialEq for ArtifactRef
Auto Trait Implementations§
impl Freeze for ArtifactRef
impl RefUnwindSafe for ArtifactRef
impl Send for ArtifactRef
impl Sync for ArtifactRef
impl Unpin for ArtifactRef
impl UnsafeUnpin for ArtifactRef
impl UnwindSafe for ArtifactRef
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.