pub struct SetupContext {
pub config: Config,
pub user_input: HashMap<String, String>,
pub flags: HashMap<String, bool>,
pub step_results: HashMap<String, String>,
}Expand description
Context for setup wizard steps
Fields§
§config: Config§user_input: HashMap<String, String>§flags: HashMap<String, bool>§step_results: HashMap<String, String>Implementations§
Source§impl SetupContext
impl SetupContext
pub fn new() -> Self
pub fn set_input(&mut self, key: &str, value: &str)
pub fn get_input(&self, key: &str) -> Option<&String>
pub fn set_flag(&mut self, key: &str, value: bool)
pub fn get_flag(&self, key: &str) -> bool
pub fn set_result(&mut self, step: &str, result: &str)
pub fn get_result(&self, step: &str) -> Option<&String>
Trait Implementations§
Source§impl Debug for SetupContext
impl Debug for SetupContext
Source§impl Default for SetupContext
impl Default for SetupContext
Source§fn default() -> SetupContext
fn default() -> SetupContext
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for SetupContext
impl RefUnwindSafe for SetupContext
impl Send for SetupContext
impl Sync for SetupContext
impl Unpin for SetupContext
impl UnwindSafe for SetupContext
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