Queued processing of work items.
More...
|
typedef void(* | pw_work_func_t) (void *obj, void *data, int res, uint32_t id) |
|
Queued processing of work items.
typedef void(* pw_work_func_t) (void *obj, void *data, int res, uint32_t id) |
Create a new Work Queue.
- Parameters
-
- Returns
- a newly allocated work queue
Destroy a work queue.
- Parameters
-
queue | the work queue to destroy |
Add an item to the work queue.
- Parameters
-
queue | the work queue |
obj | the object owning the work item |
res | a result code |
func | a work function |
data | passed to func |
int pw_work_queue_cancel |
( |
struct pw_work_queue * |
queue, |
|
|
void * |
obj, |
|
|
uint32_t |
id |
|
) |
| |
Cancel a work item.
- Parameters
-
queue | the work queue |
obj | the owner object |
id | the wotk id to cancel |
int pw_work_queue_complete |
( |
struct pw_work_queue * |
queue, |
|
|
void * |
obj, |
|
|
uint32_t |
seq, |
|
|
int |
res |
|
) |
| |
Complete a work item.
- Parameters
-
queue | the work queue |
obj | the owner object |
seq | the sequence number that completed |
res | 0 if the item was found, < 0 on error |