pub struct OptionSpec {
pub ty: String,
pub description: Option<String>,
pub default: Option<Value>,
pub choices: Option<Vec<Value>>,
pub short: Option<String>,
pub env: Option<String>,
pub completer: Option<String>,
}Expand description
A flag option, --name / -x.
Fields§
§ty: String§description: Option<String>§default: Option<Value>§choices: Option<Vec<Value>>§short: Option<String>Single-letter short alias.
env: Option<String>§completer: Option<String>Shell snippet producing completion values.
Consumed by fdl completions <shell> (follow-up rollout task).
Trait Implementations§
Source§impl Clone for OptionSpec
impl Clone for OptionSpec
Source§fn clone(&self) -> OptionSpec
fn clone(&self) -> OptionSpec
Returns a duplicate of the value. Read more
1.0.0 · 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 OptionSpec
impl Debug for OptionSpec
Source§impl<'de> Deserialize<'de> for OptionSpec
impl<'de> Deserialize<'de> for OptionSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for OptionSpec
impl RefUnwindSafe for OptionSpec
impl Send for OptionSpec
impl Sync for OptionSpec
impl Unpin for OptionSpec
impl UnsafeUnpin for OptionSpec
impl UnwindSafe for OptionSpec
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