/// Construct a new job registry from the provided job list.
Construct a new job registry from the provided job list.
Construct a new job registry from the provided job list .
pub fn new(jobs: &[&'static NamedJob]) -> Self {
        let mut job_map = HashMap::new();
        for &job in jobs {
            if job_map.insert(job.name(), job).is_some() {
                panic!("Duplicate job registered: {}", job.name());
            }
        }
        Self {
            error_handler: Arc::new(Self::default_error_handler),
            job_map,
            context: Map::new(),
        }
    }
pub fn new ( jobs : & [ & ' static NamedJob ] ) -> Self { let mut job_map = HashMap :: new ( ) ; for & job in jobs { if job_map . insert ( job . name ( ) , job ) . is_some ( ) { panic ! ( " " job name ( ) ) ; } } Self { error_handler : Arc :: new ( Self :: default_error_handler ) , job_map , context : Map :: new ( ) , } }
Construct a new job registry from the provided job list.
Construct a new job registry from the provided job list .
jobs
&[&'static NamedJob]