pub trait RemoveStep {
// Required methods
fn describe(&self, tense: Tense) -> String;
fn perform(&mut self) -> Result<(), RemoveError>;
// Provided method
fn describe_detailed(&self, tense: Tense) -> String { ... }
}Expand description
One step in the remove process. Can be executed or described.
Required Methods§
Sourcefn describe(&self, tense: Tense) -> String
fn describe(&self, tense: Tense) -> String
A short (one line) description of what this step will do to the system. Pass in the tense you want for the description (past, present or future)
Sourcefn perform(&mut self) -> Result<(), RemoveError>
fn perform(&mut self) -> Result<(), RemoveError>
Executes this remove step. This can be used when building an uninstall/remove wizard. For example to ask the user confirmation before each step.
§Errors
The system can change between preparing to remove and actually removing the install. For example a file could have been removed by the user of the system. Or the removal could run into an error that was not checked for while preparing. If you find this happens please make an issue.
Provided Methods§
Sourcefn describe_detailed(&self, tense: Tense) -> String
fn describe_detailed(&self, tense: Tense) -> String
A verbose description of what this step will do to the system. Includes as many details as possible. Pass in the tense you want for the description (past, present or future)