pub struct Confirmation {
pub title: String,
pub text: String,
pub verb: String,
pub danger: bool,
}Expand description
A question asked before an action’s command runs: a title, what happens, the verb of the button that goes on, and the danger style (the focus starts on Cancel).
Fields§
§title: String§text: String§verb: String§danger: boolImplementations§
Source§impl Confirmation
impl Confirmation
pub fn new(title: &str, text: &str, verb: &str) -> Confirmation
pub fn danger(self) -> Confirmation
Sourcepub fn filled(&self, values: &Values) -> Confirmation
pub fn filled(&self, values: &Values) -> Confirmation
Its texts with the values they name filled in.
Trait Implementations§
Source§impl Clone for Confirmation
impl Clone for Confirmation
Source§fn clone(&self) -> Confirmation
fn clone(&self) -> Confirmation
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 Confirmation
impl Debug for Confirmation
Source§impl Default for Confirmation
impl Default for Confirmation
Source§fn default() -> Confirmation
fn default() -> Confirmation
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for Confirmation
impl<'de> Deserialize<'de> for Confirmation
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
Source§impl PartialEq for Confirmation
impl PartialEq for Confirmation
Source§impl Serialize for Confirmation
impl Serialize for Confirmation
impl StructuralPartialEq for Confirmation
Auto Trait Implementations§
impl Freeze for Confirmation
impl RefUnwindSafe for Confirmation
impl Send for Confirmation
impl Sync for Confirmation
impl Unpin for Confirmation
impl UnsafeUnpin for Confirmation
impl UnwindSafe for Confirmation
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