pub trait Api<C: Send + Sync> {
// Required methods
fn get_task_list<'life0, 'life1, 'async_trait>(
&'life0 self,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskListResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_task_log_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
get_task_log_request: GetTaskLogRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskLogByIdResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn pause_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<PauseTaskByIdResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn resume_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<ResumeTaskByIdResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn start_task<'life0, 'life1, 'async_trait>(
&'life0 self,
start_task_request: StartTaskRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StartTaskResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn stop_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StopTaskByIdResponse, ApiError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
// Provided method
fn poll_ready(
&self,
_cx: &mut Context<'_>,
) -> Poll<Result<(), Box<dyn Error + Send + Sync + 'static>>> { ... }
}
Expand description
API
Required Methods§
Sourcefn get_task_list<'life0, 'life1, 'async_trait>(
&'life0 self,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskListResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_task_list<'life0, 'life1, 'async_trait>(
&'life0 self,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskListResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Get list of running tasks
Sourcefn get_task_log_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
get_task_log_request: GetTaskLogRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskLogByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_task_log_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
get_task_log_request: GetTaskLogRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<GetTaskLogByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
get log
Sourcefn pause_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<PauseTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn pause_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<PauseTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Pause a task by id
Sourcefn resume_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<ResumeTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn resume_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<ResumeTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Resume a task by id
Sourcefn start_task<'life0, 'life1, 'async_trait>(
&'life0 self,
start_task_request: StartTaskRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StartTaskResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn start_task<'life0, 'life1, 'async_trait>(
&'life0 self,
start_task_request: StartTaskRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StartTaskResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Start a new task
Sourcefn stop_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StopTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn stop_task_by_id<'life0, 'life1, 'async_trait>(
&'life0 self,
simple_id_request: SimpleIdRequest,
context: &'life1 C,
) -> Pin<Box<dyn Future<Output = Result<StopTaskByIdResponse, ApiError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Stop a task by id