pub trait TaskFactory: 'static + Send + Sync {
    fn get_task_type(&self) -> TaskType;
    fn create<'life0, 'life1, 'async_trait>(
        &'life0 self,
        params: &'life1 [u8]
    ) -> Pin<Box<dyn Future<Output = BuckyResult<Box<dyn Task>>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        Self: 'async_trait
; fn restore<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        task_status: TaskStatus,
        params: &'life1 [u8],
        data: &'life2 [u8]
    ) -> Pin<Box<dyn Future<Output = BuckyResult<Box<dyn Task>>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        'life2: 'async_trait,
        Self: 'async_trait
; }

Required Methods

Implementors