Loading...
Searching...
No Matches
executor.h File Reference

Go to the source code of this file.

## Data Structures

struct | AVTask
struct | AVTaskCallbacks

## Typedefs

typedef struct AVExecutor | AVExecutor

## Functions

AVExecutor * | av_executor_alloc (const AVTaskCallbacks *callbacks, int thread_count)
| Alloc executor.
void | av_executor_free (AVExecutor **e)
| Free executor.
void | av_executor_execute (AVExecutor *e, AVTask *t)
| Add task to executor.

## Typedef Documentation

## AVExecutor

typedef struct AVExecutor AVExecutor

Definition at line 24 of file executor.h.

## Function Documentation

## av_executor_alloc()

AVExecutor * av_executor_alloc | ( | const AVTaskCallbacks * | callbacks,
|  | int | thread_count )

Alloc executor.

Parameters

  callbacks | callback structure for executor
  thread_count | worker thread number, 0 for run on caller's thread directly

Returns
  return the executor

## av_executor_free()

void av_executor_free | ( | AVExecutor ** | e | ) |

Free executor.

Parameters

  e | pointer to executor

## av_executor_execute()

void av_executor_execute | ( | AVExecutor * | e,
|  | AVTask * | t )

Add task to executor.

Parameters

  e | pointer to executor
  t | pointer to task. If NULL, it will wakeup one work thread