#[non_exhaustive]pub struct SpecFlagSet {
pub name: String,
pub flags: Vec<SpecFlag>,
pub uses: Vec<SpecUse>,
/* private fields */
}Expand description
A named, reusable set of flag declarations.
Declared at the root of a spec, never inside a command: a set that one command can see and its sibling cannot is a scoping rule to explain for no benefit.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: String§flags: Vec<SpecFlag>Flags declared directly in the set.
uses: Vec<SpecUse>Sets this one composes, so a big set can be assembled from small ones.
Emptied while the file is read, like a command’s: what it named becomes part of
Self::flags, so a file that includes this one inherits a set with nothing left to
resolve.
Trait Implementations§
Source§impl Clone for SpecFlagSet
impl Clone for SpecFlagSet
Source§fn clone(&self) -> SpecFlagSet
fn clone(&self) -> SpecFlagSet
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SpecFlagSet
impl Debug for SpecFlagSet
Source§impl Default for SpecFlagSet
impl Default for SpecFlagSet
Auto Trait Implementations§
impl Freeze for SpecFlagSet
impl RefUnwindSafe for SpecFlagSet
impl Send for SpecFlagSet
impl Sync for SpecFlagSet
impl Unpin for SpecFlagSet
impl UnsafeUnpin for SpecFlagSet
impl UnwindSafe for SpecFlagSet
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more