pub struct Flags(/* private fields */);Expand description
The resolved boolean parameters of a single run.
Implementations§
Source§impl Flags
impl Flags
Sourcepub fn new(values: BTreeMap<String, bool>) -> Self
pub fn new(values: BTreeMap<String, bool>) -> Self
Builds a flag set directly, for tests and for triggers that declare no pipeline.
Sourcepub fn get(&self, name: &str) -> Option<bool>
pub fn get(&self, name: &str) -> Option<bool>
Returns the value of name, or None when the flag was never declared.
An undeclared flag is deliberately distinct from one that is declared and false: a prompt referring to a flag nobody declared is a mistake, not a false condition.
Trait Implementations§
impl Eq for Flags
impl StructuralPartialEq for Flags
Auto Trait Implementations§
impl Freeze for Flags
impl RefUnwindSafe for Flags
impl Send for Flags
impl Sync for Flags
impl Unpin for Flags
impl UnsafeUnpin for Flags
impl UnwindSafe for Flags
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