pub trait ExecutableTask:
HasTaskId
+ Send
+ Sync {
// Required methods
fn options_declarations(&self) -> Option<OptionDeclarations>;
fn try_set_from_decoder(
&mut self,
decoder: &OptionsDecoder<'_>,
) -> Result<(), PayloadError<ProjectError>>;
fn execute(
&mut self,
project: &Project,
) -> Result<(), PayloadError<BuildException>>;
fn did_work(&self) -> bool;
fn task_up_to_date(&self) -> bool;
fn group(&self) -> String;
fn description(&self) -> String;
}
Expand description
A object safe generic trait for executing tasks
Required Methods§
Sourcefn options_declarations(&self) -> Option<OptionDeclarations>
fn options_declarations(&self) -> Option<OptionDeclarations>
Get the options declaration for this task
Sourcefn try_set_from_decoder(
&mut self,
decoder: &OptionsDecoder<'_>,
) -> Result<(), PayloadError<ProjectError>>
fn try_set_from_decoder( &mut self, decoder: &OptionsDecoder<'_>, ) -> Result<(), PayloadError<ProjectError>>
Try to set values from a decoder
Sourcefn execute(
&mut self,
project: &Project,
) -> Result<(), PayloadError<BuildException>>
fn execute( &mut self, project: &Project, ) -> Result<(), PayloadError<BuildException>>
Executes the task, with a given project
Sourcefn task_up_to_date(&self) -> bool
fn task_up_to_date(&self) -> bool
Check if this task marked itself as up to date
Sourcefn description(&self) -> String
fn description(&self) -> String
Gets the description of the task