102 payload->parkee = parkee_snapshot;
104 if (retriever_snapshot) {
105 ao2_ref(retriever_snapshot, +1);
106 payload->retriever = retriever_snapshot;
113 if (parker_dial_string) {
131 if (!
table || !
table->parking_park_bridge_channel) {
137 return table->parking_park_bridge_channel(parkee, parkee_uuid, parker_uuid, app_data);
140 return table->parking_park_bridge_channel(parkee, parkee_uuid, parker_uuid, app_data);
150 if (!
table || !
table->parking_blind_transfer_park) {
156 return table->parking_blind_transfer_park(parker, context, exten, parked_channel_cb, parked_channel_data);
159 return table->parking_blind_transfer_park(parker, context, exten, parked_channel_cb, parked_channel_data);
173 return table->parking_park_call(parker, exten, length);
176 return table->parking_park_call(parker, exten, length);
184 if (!
table || !
table->parking_is_exten_park) {
190 return table->parking_is_exten_park(context, exten);
193 return table->parking_is_exten_park(context, exten);
209 wrapper->module_name);
217 *wrapper = *fn_table;
232 if (strcmp(wrapper->module_name, module_name)) {
static char exten[AST_MAX_EXTENSION]
Asterisk main include file. File version handling, generic pbx functions.
static char parkinglot[AST_MAX_CONTEXT]
#define STASIS_MESSAGE_TYPE_INIT(name)
Boiler-plate messaging macro for initializing message types.
int ast_parking_unregister_bridge_features(const char *module_name)
Unregister the current parking provider.
struct stasis_message_type * ast_parked_call_type(void)
accessor for the parked call stasis message type
int ast_parking_register_bridge_features(struct ast_parking_bridge_feature_fn_table *fn_table)
Register a parking provider.
Structure representing a snapshot of channel state.
#define STASIS_MESSAGE_TYPE_CLEANUP(name)
Boiler-plate messaging macro for cleaning up message types.
#define ao2_global_obj_ref(holder)
A parked call message payload.
STASIS_MESSAGE_TYPE_DEFN(ast_parked_call_type)
Message type for parked calls.
enum ast_parked_call_event_type event_type
long unsigned int duration
A function table providing parking functionality to the Bridging API Bridging API and other consumers...
struct ast_channel_snapshot * parkee
General Asterisk PBX channel definitions.
int ast_register_cleanup(void(*func)(void))
Register a function to be executed before Asterisk gracefully exits.
#define RAII_VAR(vartype, varname, initval, dtor)
Declare a variable that will call a destructor function when it goes out of scope.
#define ast_string_field_init(x, size)
Initialize a field pool and fields.
int ast_parking_park_call(struct ast_bridge_channel *parker, char *exten, size_t length)
Park the bridge and/or callers that this channel is in.
#define ao2_ref(o, delta)
#define PARKING_MODULE_VERSION
struct stasis_topic * stasis_topic_create(const char *name)
Create a new topic.
Core PBX routines and definitions.
unsigned int module_version
The version of this function table. If the ABI for this table changes, the module version (/ref PARKI...
static AO2_GLOBAL_OBJ_STATIC(parking_provider)
The container for the parking provider.
unsigned int parkingspace
#define ao2_global_obj_release(holder)
struct ast_parking_bridge_feature_fn_table parking_provider
#define ao2_alloc(data_size, destructor_fn)
int ast_parking_blind_transfer_park(struct ast_bridge_channel *parker, const char *context, const char *exten, transfer_channel_cb parked_channel_cb, struct transfer_channel_data *parked_channel_data)
Perform a blind transfer to a parking extension.
struct ast_parked_call_payload * ast_parked_call_payload_create(enum ast_parked_call_event_type event_type, struct ast_channel_snapshot *parkee_snapshot, const char *parker_dial_string, struct ast_channel_snapshot *retriever_snapshot, const char *parkinglot, unsigned int parkingspace, unsigned long int timeout, unsigned long int duration)
Constructor for parked_call_payload objects.
ast_parked_call_event_type
Defines the type of parked call message being published.
int ast_parking_provider_registered(void)
Check whether a parking provider is registered.
Prototypes for public functions only of internal interest,.
#define SCOPED_MODULE_USE(module)
static struct stasis_topic * parking_topic
Topic for parking lots.
#define ao2_global_obj_replace_unref(holder, obj)
int ast_parking_is_exten_park(const char *context, const char *exten)
Determine if the context/exten is a "parking" extension.
struct stasis_topic * ast_parking_topic(void)
accessor for the parking stasis topic
Structure that contains information regarding a channel in a bridge.
static void parking_stasis_cleanup(void)
int ast_parking_stasis_init(void)
initializes the rtp engine arrays
AO2 object that wraps data for transfer_channel_cb.
const ast_string_field parker_dial_string
void(* transfer_channel_cb)(struct ast_channel *chan, struct transfer_channel_data *user_data, enum ast_transfer_type transfer_type)
Callback function type called during blind transfers.
int ast_parking_park_bridge_channel(struct ast_bridge_channel *parkee, const char *parkee_uuid, const char *parker_uuid, const char *app_data)
Perform a direct park on a channel in a bridge.
static char context[AST_MAX_CONTEXT]
struct ast_channel_snapshot * retriever
Asterisk module definitions.
static void parked_call_payload_destructor(void *obj)
Destructor for parked_call_payload objects.
#define ast_string_field_free_memory(x)
free all memory - to be called before destroying the object
#define ast_string_field_set(x, field, data)
Set a field to a simple string value.