Asterisk - The Open Source Telephony Project  18.5.0
Data Fields
ast_taskprocessor_listener_callbacks Struct Reference

#include <taskprocessor.h>

Data Fields

void(* dtor )(struct ast_taskprocessor_listener *listener)
 
void(* emptied )(struct ast_taskprocessor_listener *listener)
 Indicates the task processor has become empty. More...
 
void(* shutdown )(struct ast_taskprocessor_listener *listener)
 Indicates the taskprocessor wishes to die. More...
 
int(* start )(struct ast_taskprocessor_listener *listener)
 The taskprocessor has started completely. More...
 
void(* task_pushed )(struct ast_taskprocessor_listener *listener, int was_empty)
 Indicates a task was pushed to the processor. More...
 

Detailed Description

Definition at line 82 of file taskprocessor.h.

Field Documentation

◆ dtor

void(* dtor) (struct ast_taskprocessor_listener *listener)

Definition at line 118 of file taskprocessor.h.

Referenced by taskprocessor_listener_dtor().

◆ emptied

void(* emptied) (struct ast_taskprocessor_listener *listener)

Indicates the task processor has become empty.

Parameters
listenerThe listener

Definition at line 104 of file taskprocessor.h.

Referenced by ast_taskprocessor_execute().

◆ shutdown

void(* shutdown) (struct ast_taskprocessor_listener *listener)

Indicates the taskprocessor wishes to die.

All operations on the task processor must to be stopped in this callback. This is an opportune time to free the listener's user data if it is not going to be used anywhere else.

After this callback returns, it is NOT safe to operate on the listener's reference to the taskprocessor.

Parameters
listenerThe listener

Definition at line 117 of file taskprocessor.h.

Referenced by listener_shutdown().

◆ start

int(* start) (struct ast_taskprocessor_listener *listener)

The taskprocessor has started completely.

This indicates that the taskprocessor is fully set up and the listener can now start interacting with it.

Parameters
listenerThe listener to start

Definition at line 91 of file taskprocessor.h.

Referenced by __start_taskprocessor().

◆ task_pushed

void(* task_pushed) (struct ast_taskprocessor_listener *listener, int was_empty)

Indicates a task was pushed to the processor.

Parameters
listenerThe listener
was_emptyIf non-zero, the taskprocessor was empty prior to the task being pushed

Definition at line 98 of file taskprocessor.h.

Referenced by taskprocessor_push().


The documentation for this struct was generated from the following file: