pub struct Parameter { /* private fields */ }
Expand description
Command parameter
Implementations§
source§impl Parameter
impl Parameter
sourcepub fn set_required(self, required: bool) -> Result<Self>
pub fn set_required(self, required: bool) -> Result<Self>
Set whether the parameter is required, default is not required. Note that you cannot have a required parameter after a non-required one
sourcepub fn set_default(self, default: &str) -> Result<Self>
pub fn set_default(self, default: &str) -> Result<Self>
Set a default for an optional parameter. Note that you can’t have a default for a required parameter
Trait Implementations§
source§impl PartialEq<Parameter> for Parameter
impl PartialEq<Parameter> for Parameter
impl StructuralPartialEq for Parameter
Auto Trait Implementations§
impl RefUnwindSafe for Parameter
impl Send for Parameter
impl Sync for Parameter
impl Unpin for Parameter
impl UnwindSafe for Parameter
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