JobBuilderTrait

Trait JobBuilderTrait 

Source
pub trait JobBuilderTrait {
    // Required methods
    fn validate(self) -> Self;
    fn step(self, step: SyncStep) -> Self;
    fn multi_threaded(self, max_threads: usize) -> Self;
    fn get(name: String) -> Self;
    fn build(self) -> Job;
}
Expand description

A trait for building synchronous jobs.

Required Methods§

Source

fn validate(self) -> Self

Validates the builder configuration.

§Returns

Returns a modified builder instance if validation succeeds.

Source

fn step(self, step: SyncStep) -> Self

Adds a step to the job.

§Arguments
  • step - The synchronous step to add.
§Returns Self

Returns a modified builder instance.

Source

fn multi_threaded(self, max_threads: usize) -> Self

Configures the job to run in multithreaded mode.

§Arguments
  • max_threads - The maximum number of threads allowed for multithreaded execution.
§Returns Self

Returns a modified builder instance.

Source

fn get(name: String) -> Self

Initializes a new builder instance with the given name.

§Arguments
  • name - The name of the job.
§Returns Self

Returns a new builder instance.

Source

fn build(self) -> Job

Builds and returns the configured synchronous job.

§Returns Job

Returns the configured synchronous job.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§