pub fn create(task: &Arc<dyn Task>) -> Arc<Self> {
        task.suspend();
        Arc::new(SuspendToken {
            base: KObjectBase::new(),
            task: Arc::downgrade(task),
        })
    }
/// Create a `SuspendToken` which can suspend the given task.
Create a `SuspendToken` which can suspend the given task.
Create a ` SuspendToken ` which can suspend the given task .
pub fn create(task: &Arc<dyn Task>) -> Arc<Self> {
        task.suspend();
        Arc::new(SuspendToken {
            base: KObjectBase::new(),
            task: Arc::downgrade(task),
        })
    }
pub fn create ( task : & Arc < dyn Task > ) -> Arc < Self > { task . suspend ( ) ; Arc :: new ( SuspendToken { base : KObjectBase :: new ( ) , task : Arc :: downgrade ( task ) , } ) }
Create a `SuspendToken` which can suspend the given task.
Create a ` SuspendToken ` which can suspend the given task .
task
&Arc<dyn Task>
task
&Arc<dyn Task>