mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-07-24 05:02:10 +00:00
part 3 of 3 standardizing typedefed types to end in _t.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@1300 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
@@ -1390,7 +1390,7 @@ typedef apr_thread_mutex_t switch_mutex_t;
|
||||
* most optimial mutex based on a given platform's performance charateristics,
|
||||
* it will behave as either a nested or an unnested lock.
|
||||
*
|
||||
SWITCH_DECLARE(switch_status) switch_mutex_init(switch_mutex_t **lock,
|
||||
SWITCH_DECLARE(switch_status_t) switch_mutex_init(switch_mutex_t **lock,
|
||||
switch_lock_flag flags,
|
||||
switch_memory_pool_t *pool);
|
||||
*/
|
||||
@@ -1399,7 +1399,7 @@ SWITCH_DECLARE(switch_status) switch_mutex_init(switch_mutex_t **lock,
|
||||
* Destroy the mutex and free the memory associated with the lock.
|
||||
* @param lock the mutex to destroy.
|
||||
*/
|
||||
//SWITCH_DECLARE(switch_status) switch_mutex_destroy(switch_mutex_t *lock);
|
||||
//SWITCH_DECLARE(switch_status_t) switch_mutex_destroy(switch_mutex_t *lock);
|
||||
#define switch_mutex_destroy apr_thread_mutex_destroy
|
||||
|
||||
/**
|
||||
@@ -1407,14 +1407,14 @@ SWITCH_DECLARE(switch_status) switch_mutex_init(switch_mutex_t **lock,
|
||||
* the current thread will be put to sleep until the lock becomes available.
|
||||
* @param lock the mutex on which to acquire the lock.
|
||||
*/
|
||||
//SWITCH_DECLARE(switch_status) switch_mutex_lock(switch_mutex_t *lock);
|
||||
//SWITCH_DECLARE(switch_status_t) switch_mutex_lock(switch_mutex_t *lock);
|
||||
#define switch_mutex_lock apr_thread_mutex_lock
|
||||
|
||||
/**
|
||||
* Release the lock for the given mutex.
|
||||
* @param lock the mutex from which to release the lock.
|
||||
*/
|
||||
//SWITCH_DECLARE(switch_status) switch_mutex_unlock(switch_mutex_t *lock);
|
||||
//SWITCH_DECLARE(switch_status_t) switch_mutex_unlock(switch_mutex_t *lock);
|
||||
#define switch_mutex_unlock apr_thread_mutex_unlock
|
||||
|
||||
/**
|
||||
@@ -1424,7 +1424,7 @@ SWITCH_DECLARE(switch_status) switch_mutex_init(switch_mutex_t **lock,
|
||||
* if the return value was APR_EBUSY, for portability reasons.
|
||||
* @param lock the mutex on which to attempt the lock acquiring.
|
||||
*/
|
||||
//SWITCH_DECLARE(switch_status) switch_mutex_trylock(switch_mutex_t *lock);
|
||||
//SWITCH_DECLARE(switch_status_t) switch_mutex_trylock(switch_mutex_t *lock);
|
||||
#define switch_mutex_trylock apr_thread_mutex_trylock
|
||||
|
||||
/** @} */
|
||||
|
||||
@@ -60,7 +60,7 @@ struct switch_buffer;
|
||||
* \param max_len length required by the buffer
|
||||
* \return status
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_buffer_create(switch_memory_pool_t *pool, switch_buffer_t **buffer, switch_size_t max_len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_buffer_create(switch_memory_pool_t *pool, switch_buffer_t **buffer, switch_size_t max_len);
|
||||
|
||||
/*! \brief Get the length of a switch_buffer_t
|
||||
* \param buffer any buffer of type switch_buffer_t
|
||||
|
||||
@@ -94,7 +94,7 @@ struct switch_caller_application {
|
||||
/*! An optional argument string to pass to the application */
|
||||
char *application_data;
|
||||
/*! A function pointer to the application */
|
||||
switch_application_function application_function;
|
||||
switch_application_function_t application_function;
|
||||
struct switch_caller_application *next;
|
||||
};
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ typedef struct switch_channel_timetable switch_channel_timetable_t;
|
||||
\param channel channel to retrieve state from
|
||||
\return current state of channel
|
||||
*/
|
||||
SWITCH_DECLARE(switch_channel_state) switch_channel_get_state(switch_channel_t *channel);
|
||||
SWITCH_DECLARE(switch_channel_state_t) switch_channel_get_state(switch_channel_t *channel);
|
||||
|
||||
/*!
|
||||
\brief Determine if a channel is ready for io
|
||||
@@ -74,11 +74,11 @@ SWITCH_DECLARE(switch_channel_state) switch_channel_get_state(switch_channel_t *
|
||||
SWITCH_DECLARE(unsigned int) switch_channel_ready(switch_channel_t *channel);
|
||||
|
||||
|
||||
SWITCH_DECLARE(switch_channel_state) switch_channel_perform_set_state(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(switch_channel_state_t) switch_channel_perform_set_state(switch_channel_t *channel,
|
||||
const char *file,
|
||||
const char *func,
|
||||
int line,
|
||||
switch_channel_state state);
|
||||
switch_channel_state_t state);
|
||||
|
||||
/*!
|
||||
\brief Set the current state of a channel
|
||||
@@ -122,7 +122,7 @@ SWITCH_DECLARE(switch_channel_timetable_t *) switch_channel_get_timetable(switch
|
||||
\param pool memory_pool to use for allocation
|
||||
\return SWITCH_STATUS_SUCCESS if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_alloc(switch_channel_t **channel, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_alloc(switch_channel_t **channel, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Connect a newly allocated channel to a session object and setup it's initial state
|
||||
@@ -131,9 +131,9 @@ SWITCH_DECLARE(switch_status) switch_channel_alloc(switch_channel_t **channel, s
|
||||
\param state the initial state of the channel
|
||||
\param flags the initial channel flags
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_init(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_init(switch_channel_t *channel,
|
||||
switch_core_session_t *session,
|
||||
switch_channel_state state,
|
||||
switch_channel_state_t state,
|
||||
uint32_t flags);
|
||||
|
||||
/*!
|
||||
@@ -193,7 +193,7 @@ SWITCH_DECLARE(char *) switch_channel_get_uuid(switch_channel_t *channel);
|
||||
\param value the vaule of the variable
|
||||
\returns SWITCH_STATUS_SUCCESS if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_set_variable(switch_channel_t *channel, char *varname, char *value);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_set_variable(switch_channel_t *channel, char *varname, char *value);
|
||||
|
||||
/*!
|
||||
\brief Retrieve a variable from a given channel
|
||||
@@ -223,23 +223,23 @@ SWITCH_DECLARE(switch_caller_extension_t *) switch_channel_get_caller_extension(
|
||||
\param flags or'd list of channel flags to test
|
||||
\return TRUE if flags were present
|
||||
*/
|
||||
SWITCH_DECLARE(int) switch_channel_test_flag(switch_channel_t *channel, switch_channel_flag flags);
|
||||
SWITCH_DECLARE(int) switch_channel_test_flag(switch_channel_t *channel, switch_channel_flag_t flags);
|
||||
|
||||
/*!
|
||||
\brief Set given flag(s) on a given channel
|
||||
\param channel channel on which to set flag(s)
|
||||
\param flags or'd list of flags to set
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_channel_set_flag(switch_channel_t *channel, switch_channel_flag flags);
|
||||
SWITCH_DECLARE(void) switch_channel_set_flag(switch_channel_t *channel, switch_channel_flag_t flags);
|
||||
|
||||
/*!
|
||||
\brief Clear given flag(s) from a channel
|
||||
\param channel channel to clear flags from
|
||||
\param flags or'd list of flags to clear
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_channel_clear_flag(switch_channel_t *channel, switch_channel_flag flags);
|
||||
SWITCH_DECLARE(void) switch_channel_clear_flag(switch_channel_t *channel, switch_channel_flag_t flags);
|
||||
|
||||
SWITCH_DECLARE(switch_status) switch_channel_perform_answer(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_perform_answer(switch_channel_t *channel,
|
||||
const char *file,
|
||||
const char *func,
|
||||
int line);
|
||||
@@ -252,7 +252,7 @@ SWITCH_DECLARE(switch_status) switch_channel_perform_answer(switch_channel_t *ch
|
||||
|
||||
|
||||
|
||||
SWITCH_DECLARE(switch_status) switch_channel_perform_pre_answer(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_perform_pre_answer(switch_channel_t *channel,
|
||||
const char *file,
|
||||
const char *func,
|
||||
int line);
|
||||
@@ -292,7 +292,7 @@ SWITCH_DECLARE(const switch_state_handler_table_t *) switch_channel_get_state_ha
|
||||
\param private_info void pointer to private data
|
||||
\return SWITCH_STATUS_SUCCESS if data was set
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_set_private(switch_channel_t *channel, void *private_info);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_set_private(switch_channel_t *channel, void *private_info);
|
||||
|
||||
/*!
|
||||
\brief Retrieve private from a given channel
|
||||
@@ -307,7 +307,7 @@ SWITCH_DECLARE(void *) switch_channel_get_private(switch_channel_t *channel);
|
||||
\param name name to assign
|
||||
\return SWITCH_STATUS_SUCCESS if name was assigned
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_set_name(switch_channel_t *channel, char *name);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_set_name(switch_channel_t *channel, char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the name of a given channel
|
||||
@@ -317,7 +317,7 @@ SWITCH_DECLARE(switch_status) switch_channel_set_name(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(char *) switch_channel_get_name(switch_channel_t *channel);
|
||||
|
||||
|
||||
SWITCH_DECLARE(switch_channel_state) switch_channel_perform_hangup(switch_channel_t *channel,
|
||||
SWITCH_DECLARE(switch_channel_state_t) switch_channel_perform_hangup(switch_channel_t *channel,
|
||||
const char *file,
|
||||
const char *func,
|
||||
int line,
|
||||
@@ -344,7 +344,7 @@ SWITCH_DECLARE(switch_size_t) switch_channel_has_dtmf(switch_channel_t *channel)
|
||||
\param dtmf string of digits to queue
|
||||
\return SWITCH_STATUS_SUCCESS if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_channel_queue_dtmf(switch_channel_t *channel, char *dtmf);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_queue_dtmf(switch_channel_t *channel, char *dtmf);
|
||||
|
||||
/*!
|
||||
\brief Retrieve DTMF digits from a given channel
|
||||
@@ -360,7 +360,7 @@ SWITCH_DECLARE(switch_size_t) switch_channel_dequeue_dtmf(switch_channel_t *chan
|
||||
\param state state to get name of
|
||||
\return the string representation of the state
|
||||
*/
|
||||
SWITCH_DECLARE(const char *) switch_channel_state_name(switch_channel_state state);
|
||||
SWITCH_DECLARE(const char *) switch_channel_state_name(switch_channel_state_t state);
|
||||
|
||||
/*!
|
||||
\brief Add information about a given channel to an event object
|
||||
@@ -371,8 +371,8 @@ SWITCH_DECLARE(void) switch_channel_event_set_data(switch_channel_t *channel, sw
|
||||
|
||||
|
||||
// These may go away
|
||||
SWITCH_DECLARE(switch_status) switch_channel_set_raw_mode (switch_channel_t *channel, int freq, int bits, int channels, int ms, int kbps);
|
||||
SWITCH_DECLARE(switch_status) switch_channel_get_raw_mode (switch_channel_t *channel, int *freq, int *bits, int *channels, int *ms, int *kbps);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_set_raw_mode (switch_channel_t *channel, int freq, int bits, int channels, int ms, int kbps);
|
||||
SWITCH_DECLARE(switch_status_t) switch_channel_get_raw_mode (switch_channel_t *channel, int *freq, int *bits, int *channels, int *ms, int *kbps);
|
||||
/** @} */
|
||||
|
||||
END_EXTERN_C
|
||||
|
||||
@@ -51,7 +51,7 @@ SWITCH_DECLARE(void) switch_console_loop(void);
|
||||
/*!
|
||||
\brief A method akin to printf that allows you to redirect output to a specific console "channel"
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_console_printf(switch_text_channel channel, char *file, const char *func, int line, char *fmt, ...);
|
||||
SWITCH_DECLARE(void) switch_console_printf(switch_text_channel_t channel, char *file, const char *func, int line, char *fmt, ...);
|
||||
|
||||
END_EXTERN_C
|
||||
|
||||
|
||||
+62
-62
@@ -103,13 +103,13 @@ struct switch_core_runtime;
|
||||
\param console optional FILE stream for output
|
||||
\note to be called at application startup
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_init(char *console);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_init(char *console);
|
||||
|
||||
/*!
|
||||
\brief Destroy the core
|
||||
\note to be called at application shutdown
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_destroy(void);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_destroy(void);
|
||||
///\}
|
||||
|
||||
|
||||
@@ -121,7 +121,7 @@ SWITCH_DECLARE(switch_status) switch_core_destroy(void);
|
||||
\param session the session to acquire from
|
||||
\return success if it is safe to read from the session
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_read_lock(switch_core_session_t *session);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_read_lock(switch_core_session_t *session);
|
||||
|
||||
/*!
|
||||
\brief Acquire a write lock on the session
|
||||
@@ -162,13 +162,13 @@ SWITCH_DECLARE(const switch_state_handler_table_t *) switch_core_get_state_handl
|
||||
\brief Create a new sub memory pool from the core's master pool
|
||||
\return SWITCH_STATUS_SUCCESS on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_new_memory_pool(switch_memory_pool_t **pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_new_memory_pool(switch_memory_pool_t **pool);
|
||||
|
||||
/*!
|
||||
\brief Returns a subpool back to the main pool
|
||||
\return SWITCH_STATUS_SUCCESS on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_destroy_memory_pool(switch_memory_pool_t **pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_destroy_memory_pool(switch_memory_pool_t **pool);
|
||||
|
||||
/*!
|
||||
\brief Start the session's state machine
|
||||
@@ -248,7 +248,7 @@ SWITCH_DECLARE(switch_memory_pool_t *) switch_core_session_get_pool(switch_core_
|
||||
\param pool the pool to use for the allocation (a new one will be used if NULL)
|
||||
\return the newly created session
|
||||
*/
|
||||
SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request(const switch_endpoint_interface *endpoint_interface, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_core_session_t *) switch_core_session_request(const switch_endpoint_interface_t *endpoint_interface, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Destroy a session and return the memory pool to the core
|
||||
@@ -304,7 +304,7 @@ SWITCH_DECLARE(switch_core_session_t *) switch_core_session_locate(char *uuid_st
|
||||
\param message the switch_core_session_message_t object to send
|
||||
\return the status returned by the message handler
|
||||
*/
|
||||
SWITCH_DECLARE (switch_status) switch_core_session_message_send(char *uuid_str, switch_core_session_message_t *message);
|
||||
SWITCH_DECLARE (switch_status_t) switch_core_session_message_send(char *uuid_str, switch_core_session_message_t *message);
|
||||
|
||||
/*!
|
||||
\brief Queue an event on another session using its uuid
|
||||
@@ -312,7 +312,7 @@ SWITCH_DECLARE (switch_status) switch_core_session_message_send(char *uuid_str,
|
||||
\param event the event to send
|
||||
\return the status returned by the message handler
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_event_send(char *uuid_str, switch_event_t *event);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_event_send(char *uuid_str, switch_event_t *event);
|
||||
|
||||
/*!
|
||||
\brief Retrieve private user data from a session
|
||||
@@ -327,7 +327,7 @@ SWITCH_DECLARE(void *) switch_core_session_get_private(switch_core_session_t *se
|
||||
\param private_info the used data to add
|
||||
\return SWITCH_STATUS_SUCCESS if data is added
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_set_private(switch_core_session_t *session, void *private_info);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_set_private(switch_core_session_t *session, void *private_info);
|
||||
|
||||
/*!
|
||||
\brief Add a logical stream to a session
|
||||
@@ -383,7 +383,7 @@ SWITCH_DECLARE(void) switch_core_service_session(switch_core_session_t *session,
|
||||
\param pool optional existing memory pool to donate to the session
|
||||
\return SWITCH_STATUS_SUCCESS if the session was created
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_outgoing_channel(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_outgoing_channel(switch_core_session_t *session,
|
||||
char *endpoint_name,
|
||||
switch_caller_profile_t *caller_profile,
|
||||
switch_core_session_t **new_session,
|
||||
@@ -394,7 +394,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_outgoing_channel(switch_core_s
|
||||
\param session the session to answer the channel of
|
||||
\return SWITCH_STATUS_SUCCESS if the channel was answered
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_answer_channel(switch_core_session_t *session);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_answer_channel(switch_core_session_t *session);
|
||||
|
||||
/*!
|
||||
\brief Receive a message on a given session
|
||||
@@ -402,7 +402,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_answer_channel(switch_core_ses
|
||||
\param message the message to recieve
|
||||
\return the status returned by the message handler
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_receive_message(switch_core_session_t *session, switch_core_session_message_t *message);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_receive_message(switch_core_session_t *session, switch_core_session_message_t *message);
|
||||
|
||||
/*!
|
||||
\brief Queue an event on a given session
|
||||
@@ -410,7 +410,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_receive_message(switch_core_se
|
||||
\param event the event to queue
|
||||
\return the status returned by the message handler
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_queue_event(switch_core_session_t *session, switch_event_t *event);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_queue_event(switch_core_session_t *session, switch_event_t *event);
|
||||
|
||||
/*!
|
||||
\brief Read a frame from a session
|
||||
@@ -420,7 +420,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_queue_event(switch_core_sessio
|
||||
\param stream_id which logical media channel to use
|
||||
\return SWITCH_STATUS_SUCCESS a the frame was read
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_read_frame(switch_core_session_t *session, switch_frame_t **frame, int timeout, int stream_id);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_read_frame(switch_core_session_t *session, switch_frame_t **frame, int timeout, int stream_id);
|
||||
|
||||
/*!
|
||||
\brief Write a frame to a session
|
||||
@@ -430,14 +430,14 @@ SWITCH_DECLARE(switch_status) switch_core_session_read_frame(switch_core_session
|
||||
\param stream_id which logical media channel to use
|
||||
\return SWITCH_STATUS_SUCCESS a the frame was written
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_write_frame(switch_core_session_t *session, switch_frame_t *frame, int timeout, int stream_id);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_write_frame(switch_core_session_t *session, switch_frame_t *frame, int timeout, int stream_id);
|
||||
|
||||
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_perform_kill_channel(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_perform_kill_channel(switch_core_session_t *session,
|
||||
const char *file,
|
||||
const char *func,
|
||||
int line,
|
||||
switch_signal sig);
|
||||
switch_signal_t sig);
|
||||
/*!
|
||||
\brief Send a signal to a channel
|
||||
\param session session to send signal to
|
||||
@@ -453,7 +453,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_perform_kill_channel(switch_co
|
||||
\param stream_id which logical media channel to use
|
||||
\return SWITCH_STATUS_SUCCESS if data is available for read within timeframe specified
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_waitfor_read(switch_core_session_t *session, int timeout, int stream_id);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_waitfor_read(switch_core_session_t *session, int timeout, int stream_id);
|
||||
|
||||
/*!
|
||||
\brief Wait for a session to be ready for output
|
||||
@@ -462,7 +462,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_waitfor_read(switch_core_sessi
|
||||
\param stream_id which logical media channel to use
|
||||
\return SWITCH_STATUS_SUCCESS if the session is available for write within timeframe specified
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_waitfor_write(switch_core_session_t *session, int timeout, int stream_id);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_waitfor_write(switch_core_session_t *session, int timeout, int stream_id);
|
||||
|
||||
/*!
|
||||
\brief Send DTMF to a session
|
||||
@@ -470,7 +470,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_waitfor_write(switch_core_sess
|
||||
\param dtmf string to send to the session
|
||||
\return SWITCH_STATUS_SUCCESS if the dtmf was written
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_send_dtmf(switch_core_session_t *session, char *dtmf);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_send_dtmf(switch_core_session_t *session, char *dtmf);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session requests an outgoing extension
|
||||
@@ -478,7 +478,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_send_dtmf(switch_core_session_
|
||||
\param outgoing_channel hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_outgoing(switch_core_session_t *session, switch_outgoing_channel_hook outgoing_channel);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_outgoing(switch_core_session_t *session, switch_outgoing_channel_hook_t outgoing_channel);
|
||||
///\}
|
||||
|
||||
///\defgroup shooks Session Hook Callbacks
|
||||
@@ -490,7 +490,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_outgoing(switch
|
||||
\param answer_channel hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_answer_channel(switch_core_session_t *session, switch_answer_channel_hook answer_channel);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_answer_channel(switch_core_session_t *session, switch_answer_channel_hook_t answer_channel);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session sends a message
|
||||
@@ -498,7 +498,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_answer_channel(
|
||||
\param receive_message hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_receive_message(switch_core_session_t *session, switch_receive_message_hook receive_message);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_receive_message(switch_core_session_t *session, switch_receive_message_hook_t receive_message);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session reads a frame
|
||||
@@ -506,7 +506,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_receive_message
|
||||
\param read_frame hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_read_frame(switch_core_session_t *session, switch_read_frame_hook read_frame);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_read_frame(switch_core_session_t *session, switch_read_frame_hook_t read_frame);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session writes a frame
|
||||
@@ -514,7 +514,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_read_frame(swit
|
||||
\param write_frame hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_write_frame(switch_core_session_t *session, switch_write_frame_hook write_frame);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_write_frame(switch_core_session_t *session, switch_write_frame_hook_t write_frame);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session kills a channel
|
||||
@@ -522,7 +522,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_write_frame(swi
|
||||
\param kill_channel hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_kill_channel(switch_core_session_t *session, switch_kill_channel_hook kill_channel);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_kill_channel(switch_core_session_t *session, switch_kill_channel_hook_t kill_channel);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session waits for a read event
|
||||
@@ -530,7 +530,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_kill_channel(sw
|
||||
\param waitfor_read hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_waitfor_read(switch_core_session_t *session, switch_waitfor_read_hook waitfor_read);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_waitfor_read(switch_core_session_t *session, switch_waitfor_read_hook_t waitfor_read);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session waits for a write event
|
||||
@@ -538,7 +538,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_waitfor_read(sw
|
||||
\param waitfor_write hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_waitfor_write(switch_core_session_t *session, switch_waitfor_write_hook waitfor_write);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_waitfor_write(switch_core_session_t *session, switch_waitfor_write_hook_t waitfor_write);
|
||||
|
||||
/*!
|
||||
\brief Add an event hook to be executed when a session sends dtmf
|
||||
@@ -546,7 +546,7 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_waitfor_write(s
|
||||
\param send_dtmf hook to bind
|
||||
\return SWITCH_STATUS_SUCCESS on suceess
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_send_dtmf(switch_core_session_t *session, switch_send_dtmf_hook send_dtmf);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_add_event_hook_send_dtmf(switch_core_session_t *session, switch_send_dtmf_hook_t send_dtmf);
|
||||
///\}
|
||||
|
||||
///\defgroup hashf Hash Functions
|
||||
@@ -558,14 +558,14 @@ SWITCH_DECLARE(switch_status) switch_core_session_add_event_hook_send_dtmf(switc
|
||||
\param pool the pool to use for the new hash
|
||||
\return SWITCH_STATUS_SUCCESS if the hash is created
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_hash_init(switch_hash_t **hash, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_hash_init(switch_hash_t **hash, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Destroy an existing hash table
|
||||
\param hash the hash to destroy
|
||||
\return SWITCH_STATUS_SUCCESS if the hash is destroyed
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_hash_destroy(switch_hash_t *hash);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_hash_destroy(switch_hash_t *hash);
|
||||
|
||||
/*!
|
||||
\brief Insert data into a hash
|
||||
@@ -575,7 +575,7 @@ SWITCH_DECLARE(switch_status) switch_core_hash_destroy(switch_hash_t *hash);
|
||||
\return SWITCH_STATUS_SUCCESS if the data is added
|
||||
\note the string key must be a constant or a dynamic string
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_hash_insert(switch_hash_t *hash, char *key, void *data);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_hash_insert(switch_hash_t *hash, char *key, void *data);
|
||||
|
||||
/*!
|
||||
\brief Insert data into a hash with dynamicly allocated key name
|
||||
@@ -584,7 +584,7 @@ SWITCH_DECLARE(switch_status) switch_core_hash_insert(switch_hash_t *hash, char
|
||||
\param data the data to add
|
||||
\return SWITCH_STATUS_SUCCESS if the data is added
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_hash_insert_dup(switch_hash_t *hash, char *key, void *data);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_hash_insert_dup(switch_hash_t *hash, char *key, void *data);
|
||||
|
||||
/*!
|
||||
\brief Delete data from a hash based on desired key
|
||||
@@ -592,7 +592,7 @@ SWITCH_DECLARE(switch_status) switch_core_hash_insert_dup(switch_hash_t *hash, c
|
||||
\param key the key from which to delete the data
|
||||
\return SWITCH_STATUS_SUCCESS if the data is deleted
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_hash_delete(switch_hash_t *hash, char *key);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_hash_delete(switch_hash_t *hash, char *key);
|
||||
|
||||
/*!
|
||||
\brief Retrieve data from a given hash
|
||||
@@ -615,7 +615,7 @@ SWITCH_DECLARE(void *) switch_core_hash_find(switch_hash_t *hash, char *key);
|
||||
\param pool the memory pool to use for allocation
|
||||
\return
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_timer_init(switch_timer_t *timer, char *timer_name, int interval, int samples, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_timer_init(switch_timer_t *timer, char *timer_name, int interval, int samples, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Wait for one cycle on an existing timer
|
||||
@@ -629,7 +629,7 @@ SWITCH_DECLARE(int) switch_core_timer_next(switch_timer_t *timer);
|
||||
\param timer timer to destroy
|
||||
\return SWITCH_STATUS_SUCCESS after destruction
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_timer_destroy(switch_timer_t *timer);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_timer_destroy(switch_timer_t *timer);
|
||||
///\}
|
||||
|
||||
///\defgroup codecs Codec Functions
|
||||
@@ -647,7 +647,7 @@ SWITCH_DECLARE(switch_status) switch_core_timer_destroy(switch_timer_t *timer);
|
||||
\param pool the memory pool to use
|
||||
\return SWITCH_STATUS_SUCCESS if the handle is allocated
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_codec_init(switch_codec_t *codec,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_codec_init(switch_codec_t *codec,
|
||||
char *codec_name,
|
||||
uint32_t rate,
|
||||
int ms,
|
||||
@@ -670,7 +670,7 @@ SWITCH_DECLARE(switch_status) switch_core_codec_init(switch_codec_t *codec,
|
||||
\return SWITCH_STATUS_SUCCESS if the data was encoded
|
||||
\note encoded_data_len will be rewritten to the in-use size of encoded_data
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_codec_encode(switch_codec_t *codec,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_codec_encode(switch_codec_t *codec,
|
||||
switch_codec_t *other_codec,
|
||||
void *decoded_data,
|
||||
uint32_t decoded_data_len,
|
||||
@@ -694,7 +694,7 @@ SWITCH_DECLARE(switch_status) switch_core_codec_encode(switch_codec_t *codec,
|
||||
\return SWITCH_STATUS_SUCCESS if the data was decoded
|
||||
\note decoded_data_len will be rewritten to the in-use size of decoded_data
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_codec_decode(switch_codec_t *codec,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_codec_decode(switch_codec_t *codec,
|
||||
switch_codec_t *other_codec,
|
||||
void *encoded_data,
|
||||
uint32_t encoded_data_len,
|
||||
@@ -709,7 +709,7 @@ SWITCH_DECLARE(switch_status) switch_core_codec_decode(switch_codec_t *codec,
|
||||
\param codec the codec handle to destroy
|
||||
\return SWITCH_STATUS_SUCCESS if the codec was destroyed
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_codec_destroy(switch_codec_t *codec);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_codec_destroy(switch_codec_t *codec);
|
||||
|
||||
/*!
|
||||
\brief Assign the read codec to a given session
|
||||
@@ -717,7 +717,7 @@ SWITCH_DECLARE(switch_status) switch_core_codec_destroy(switch_codec_t *codec);
|
||||
\param codec the codec to add
|
||||
\return SWITCH_STATUS_SUCCESS if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_set_read_codec(switch_core_session_t *session, switch_codec_t *codec);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_set_read_codec(switch_core_session_t *session, switch_codec_t *codec);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the read codec from a given session
|
||||
@@ -732,7 +732,7 @@ SWITCH_DECLARE(switch_codec_t *) switch_core_session_get_read_codec(switch_core_
|
||||
\param codec the codec to add
|
||||
\return SWITCH_STATUS_SUCCESS if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_session_set_write_codec(switch_core_session_t *session, switch_codec_t *codec);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_session_set_write_codec(switch_core_session_t *session, switch_codec_t *codec);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the write codec from a given session
|
||||
@@ -772,7 +772,7 @@ SWITCH_DECLARE(switch_core_db *) switch_core_db_open_file(char *filename);
|
||||
\return SWITCH_STATUS_SUCCESS if the file is opened
|
||||
\note the loadable module used is chosen based on the file extension
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_file_open(switch_file_handle_t *fh, char *file_path, unsigned int flags, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_file_open(switch_file_handle_t *fh, char *file_path, unsigned int flags, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Read media from a file handle
|
||||
@@ -781,7 +781,7 @@ SWITCH_DECLARE(switch_status) switch_core_file_open(switch_file_handle_t *fh, ch
|
||||
\param len the max size of the buffer
|
||||
\return SWITCH_STATUS_SUCCESS with len adjusted to the bytes read if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_file_read(switch_file_handle_t *fh, void *data, switch_size_t *len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_file_read(switch_file_handle_t *fh, void *data, switch_size_t *len);
|
||||
|
||||
/*!
|
||||
\brief Write media to a file handle
|
||||
@@ -790,7 +790,7 @@ SWITCH_DECLARE(switch_status) switch_core_file_read(switch_file_handle_t *fh, vo
|
||||
\param len the amount of data to write from the buffer
|
||||
\return SWITCH_STATUS_SUCCESS with len adjusted to the bytes written if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_file_write(switch_file_handle_t *fh, void *data, switch_size_t *len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_file_write(switch_file_handle_t *fh, void *data, switch_size_t *len);
|
||||
|
||||
/*!
|
||||
\brief Seek a position in a file
|
||||
@@ -800,14 +800,14 @@ SWITCH_DECLARE(switch_status) switch_core_file_write(switch_file_handle_t *fh, v
|
||||
\param whence the indicator (see traditional seek)
|
||||
\return SWITCH_STATUS_SUCCESS with cur_pos adjusted to new position
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_file_seek(switch_file_handle_t *fh, unsigned int *cur_pos, int64_t samples, int whence);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_file_seek(switch_file_handle_t *fh, unsigned int *cur_pos, int64_t samples, int whence);
|
||||
|
||||
/*!
|
||||
\brief Close an open file handle
|
||||
\param fh the file handle to close
|
||||
\return SWITCH_STATUS_SUCCESS if the file handle was closed
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_file_close(switch_file_handle_t *fh);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_file_close(switch_file_handle_t *fh);
|
||||
///\}
|
||||
|
||||
///\defgroup speech ASR/TTS Functions
|
||||
@@ -823,11 +823,11 @@ SWITCH_DECLARE(switch_status) switch_core_file_close(switch_file_handle_t *fh);
|
||||
\param pool the pool to use (NULL for new pool)
|
||||
\return SWITCH_STATUS_SUCCESS if the handle is opened
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_open(switch_speech_handle *sh,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_open(switch_speech_handle_t *sh,
|
||||
char *module_name,
|
||||
char *voice_name,
|
||||
unsigned int rate,
|
||||
switch_speech_flag *flags,
|
||||
switch_speech_flag_t *flags,
|
||||
switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
@@ -839,7 +839,7 @@ SWITCH_DECLARE(switch_status) switch_core_speech_open(switch_speech_handle *sh,
|
||||
\param flags flags in/out for fine tuning
|
||||
\return SWITCH_STATUS_SUCCESS with possible new flags on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_feed_asr(switch_speech_handle *sh, void *data, unsigned int *len, int rate, switch_speech_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_feed_asr(switch_speech_handle_t *sh, void *data, unsigned int *len, int rate, switch_speech_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Get text back from the ASR module
|
||||
@@ -849,7 +849,7 @@ SWITCH_DECLARE(switch_status) switch_core_speech_feed_asr(switch_speech_handle *
|
||||
\param flags flags in/out for fine tuning
|
||||
\return SWITCH_STATUS_SUCCESS with possible new flags on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_interpret_asr(switch_speech_handle *sh, char *buf, unsigned int buflen, switch_speech_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_interpret_asr(switch_speech_handle_t *sh, char *buf, unsigned int buflen, switch_speech_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Feed text to the TTS module
|
||||
@@ -858,7 +858,7 @@ SWITCH_DECLARE(switch_status) switch_core_speech_interpret_asr(switch_speech_han
|
||||
\param flags flags in/out for fine tuning
|
||||
\return SWITCH_STATUS_SUCCESS with len adjusted to the bytes written if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_feed_tts(switch_speech_handle *sh, char *text, switch_speech_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_feed_tts(switch_speech_handle_t *sh, char *text, switch_speech_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Read rendered audio from the TTS module
|
||||
@@ -869,18 +869,18 @@ SWITCH_DECLARE(switch_status) switch_core_speech_feed_tts(switch_speech_handle *
|
||||
\param flags flags in/out for fine tuning
|
||||
\return SWITCH_STATUS_SUCCESS with len adjusted to the bytes written if successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_read_tts(switch_speech_handle *sh,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_read_tts(switch_speech_handle_t *sh,
|
||||
void *data,
|
||||
switch_size_t *datalen,
|
||||
uint32_t *rate,
|
||||
switch_speech_flag *flags);
|
||||
switch_speech_flag_t *flags);
|
||||
/*!
|
||||
\brief Close an open speech handle
|
||||
\param sh the speech handle to close
|
||||
\param flags flags in/out for fine tuning
|
||||
\return SWITCH_STATUS_SUCCESS if the file handle was closed
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_speech_close(switch_speech_handle *sh, switch_speech_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_speech_close(switch_speech_handle_t *sh, switch_speech_flag_t *flags);
|
||||
///\}
|
||||
|
||||
|
||||
@@ -897,7 +897,7 @@ SWITCH_DECLARE(switch_status) switch_core_speech_close(switch_speech_handle *sh,
|
||||
\param pool the pool to use (NULL for new pool)
|
||||
\return SWITCH_STATUS_SUCCESS if the handle is opened
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_directory_open(switch_directory_handle *dh,
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_directory_open(switch_directory_handle_t *dh,
|
||||
char *module_name,
|
||||
char *source,
|
||||
char *dsn,
|
||||
@@ -911,14 +911,14 @@ SWITCH_DECLARE(switch_status) switch_core_directory_open(switch_directory_handle
|
||||
\param query a string of filters or query data
|
||||
\return SWITCH_STATUS_SUCCESS if the query is successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_directory_query(switch_directory_handle *dh, char *base, char *query);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_directory_query(switch_directory_handle_t *dh, char *base, char *query);
|
||||
|
||||
/*!
|
||||
\brief Obtain the next record in a lookup
|
||||
\param dh a direcotry handle to use
|
||||
\return SWITCH_STATUS_SUCCESS if another record exists
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_directory_next(switch_directory_handle *dh);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_directory_next(switch_directory_handle_t *dh);
|
||||
|
||||
/*!
|
||||
\brief Obtain the next name/value pair in the current record
|
||||
@@ -927,14 +927,14 @@ SWITCH_DECLARE(switch_status) switch_core_directory_next(switch_directory_handle
|
||||
\param val a pointer to poinbter of the value to fill in
|
||||
\return SWITCH_STATUS_SUCCESS if an item exists
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_directory_next_pair(switch_directory_handle *dh, char **var, char **val);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_directory_next_pair(switch_directory_handle_t *dh, char **var, char **val);
|
||||
|
||||
/*!
|
||||
\brief Close an open directory handle
|
||||
\param dh a direcotry handle to close
|
||||
\return SWITCH_STATUS_SUCCESS if handle was closed
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_directory_close(switch_directory_handle *dh);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_directory_close(switch_directory_handle_t *dh);
|
||||
///\}
|
||||
|
||||
|
||||
@@ -946,13 +946,13 @@ SWITCH_DECLARE(switch_status) switch_core_directory_close(switch_directory_handl
|
||||
\param channel text channel enumeration
|
||||
\return a FILE stream
|
||||
*/
|
||||
SWITCH_DECLARE(FILE *) switch_core_data_channel(switch_text_channel channel);
|
||||
SWITCH_DECLARE(FILE *) switch_core_data_channel(switch_text_channel_t channel);
|
||||
|
||||
/*!
|
||||
\brief Set the output console to the desired file
|
||||
\param console the file path
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_core_set_console(char *console);
|
||||
SWITCH_DECLARE(switch_status_t) switch_core_set_console(char *console);
|
||||
|
||||
/*!
|
||||
\brief Get the output console
|
||||
|
||||
+12
-12
@@ -122,13 +122,13 @@ struct switch_event_node {
|
||||
\param pool the memory pool to use for the event system (creates a new one if NULL)
|
||||
\return SWITCH_STATUS_SUCCESS when complete
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_init(switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_init(switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Stop the eventing system
|
||||
\return SWITCH_STATUS_SUCCESS when complete
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_shutdown(void);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_shutdown(void);
|
||||
|
||||
/*!
|
||||
\brief Create an event
|
||||
@@ -137,7 +137,7 @@ SWITCH_DECLARE(switch_status) switch_event_shutdown(void);
|
||||
\param subclass_name the subclass name for custom event (only valid when event_id is SWITCH_EVENT_CUSTOM)
|
||||
\return SWITCH_STATUS_SUCCESS on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_create_subclass(switch_event_t **event, switch_event_types_t event_id, char *subclass_name);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_create_subclass(switch_event_t **event, switch_event_types_t event_id, char *subclass_name);
|
||||
|
||||
/*!
|
||||
\brief Set the priority of an event
|
||||
@@ -145,7 +145,7 @@ SWITCH_DECLARE(switch_status) switch_event_create_subclass(switch_event_t **even
|
||||
\param priority the event priority
|
||||
\return SWITCH_STATUS_SUCCESS
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_set_priority(switch_event_t *event, switch_priority_t priority);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_set_priority(switch_event_t *event, switch_priority_t priority);
|
||||
|
||||
/*!
|
||||
\brief Retrieve a header value from an event
|
||||
@@ -163,7 +163,7 @@ SWITCH_DECLARE(char *) switch_event_get_header(switch_event_t *event, char *head
|
||||
\param fmt the value of the header (varargs see standard sprintf family)
|
||||
\return SWITCH_STATUS_SUCCESS if the header was added
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_add_header(switch_event_t *event, switch_stack_t stack, char *header_name, char *fmt, ...);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_add_header(switch_event_t *event, switch_stack_t stack, char *header_name, char *fmt, ...);
|
||||
|
||||
/*!
|
||||
\brief Destroy an event
|
||||
@@ -177,7 +177,7 @@ SWITCH_DECLARE(void) switch_event_destroy(switch_event_t **event);
|
||||
\param todup an event to duplicate
|
||||
\return SWITCH_STATUS_SUCCESS if the event was duplicated
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_dup(switch_event_t **event, switch_event_t *todup);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_dup(switch_event_t **event, switch_event_t *todup);
|
||||
|
||||
/*!
|
||||
\brief Fire an event with full arguement list
|
||||
@@ -188,7 +188,7 @@ SWITCH_DECLARE(switch_status) switch_event_dup(switch_event_t **event, switch_ev
|
||||
\param user_data optional private data to pass to the event handlers
|
||||
\return
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_fire_detailed(char *file, char *func, int line, switch_event_t **event, void *user_data);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_fire_detailed(char *file, char *func, int line, switch_event_t **event, void *user_data);
|
||||
|
||||
/*!
|
||||
\brief Bind an event callback to a specific event
|
||||
@@ -199,7 +199,7 @@ SWITCH_DECLARE(switch_status) switch_event_fire_detailed(char *file, char *func,
|
||||
\param user_data optional user specific data to pass whenever the callback is invoked
|
||||
\return SWITCH_STATUS_SUCCESS if the event was binded
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_bind(char *id, switch_event_types_t event, char *subclass_name, switch_event_callback_t callback, void *user_data);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_bind(char *id, switch_event_types_t event, char *subclass_name, switch_event_callback_t callback, void *user_data);
|
||||
|
||||
/*!
|
||||
\brief Render the name of an event id enumeration
|
||||
@@ -216,7 +216,7 @@ SWITCH_DECLARE(char *) switch_event_name(switch_event_types_t event);
|
||||
\note There is nothing to enforce this but I reccommend using module::event_name for the subclass names
|
||||
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_reserve_subclass_detailed(char *owner, char *subclass_name);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_reserve_subclass_detailed(char *owner, char *subclass_name);
|
||||
|
||||
/*!
|
||||
\brief Render a string representation of an event sutable for printing or network transport
|
||||
@@ -227,13 +227,13 @@ SWITCH_DECLARE(switch_status) switch_event_reserve_subclass_detailed(char *owner
|
||||
\return SWITCH_STATUS_SUCCESS if the operation was successful
|
||||
\note the body supplied by this function will supersede an existing body the event may have
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_serialize(switch_event_t *event, char *buf, switch_size_t buflen, char *fmt, ...);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_serialize(switch_event_t *event, char *buf, switch_size_t buflen, char *fmt, ...);
|
||||
|
||||
/*!
|
||||
\brief Determine if the event system has been initilized
|
||||
\return SWITCH_STATUS_SUCCESS if the system is running
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_running(void);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_running(void);
|
||||
|
||||
/*!
|
||||
\brief Add a body to an event
|
||||
@@ -242,7 +242,7 @@ SWITCH_DECLARE(switch_status) switch_event_running(void);
|
||||
\return SWITCH_STATUS_SUCCESS if the body was added to the event
|
||||
\note the body parameter can be shadowed by the switch_event_reserve_subclass_detailed function
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_event_add_body(switch_event_t *event, char *fmt, ...);
|
||||
SWITCH_DECLARE(switch_status_t) switch_event_add_body(switch_event_t *event, char *fmt, ...);
|
||||
|
||||
|
||||
/*!
|
||||
|
||||
@@ -65,7 +65,7 @@ struct switch_frame {
|
||||
/*! the timestamp of the frame */
|
||||
uint32_t timestamp;
|
||||
/*! frame flags */
|
||||
switch_frame_flag flags;
|
||||
switch_frame_flag_t flags;
|
||||
};
|
||||
|
||||
END_EXTERN_C
|
||||
|
||||
+12
-12
@@ -58,8 +58,8 @@ BEGIN_EXTERN_C
|
||||
\param buflen the size of buf
|
||||
\return SWITCH_STATUS_SUCCESS to keep the collection moving.
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_collect_digits_callback(switch_core_session_t *session,
|
||||
switch_dtmf_callback_function dtmf_callback,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_collect_digits_callback(switch_core_session_t *session,
|
||||
switch_dtmf_callback_function_t dtmf_callback,
|
||||
void *buf,
|
||||
unsigned int buflen);
|
||||
|
||||
@@ -75,7 +75,7 @@ SWITCH_DECLARE(switch_status) switch_ivr_collect_digits_callback(switch_core_ses
|
||||
\param poll_channel flag to specify if you want the function to poll the channel while running
|
||||
\return SWITCH_STATUS_SUCCESS to keep the collection moving.
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_collect_digits_count(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_collect_digits_count(switch_core_session_t *session,
|
||||
char *buf,
|
||||
unsigned int buflen,
|
||||
unsigned int maxdigits,
|
||||
@@ -96,11 +96,11 @@ SWITCH_DECLARE(switch_status) switch_ivr_collect_digits_count(switch_core_sessio
|
||||
\return SWITCH_STATUS_SUCCESS if all is well
|
||||
\note passing a NULL dtmf_callback nad a not NULL buf indicates to copy any dtmf to buf and stop playback.
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_play_file(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_play_file(switch_core_session_t *session,
|
||||
switch_file_handle_t *fh,
|
||||
char *file,
|
||||
char *timer_name,
|
||||
switch_dtmf_callback_function dtmf_callback,
|
||||
switch_dtmf_callback_function_t dtmf_callback,
|
||||
void *buf,
|
||||
unsigned int buflen);
|
||||
|
||||
@@ -117,10 +117,10 @@ SWITCH_DECLARE(switch_status) switch_ivr_play_file(switch_core_session_t *sessio
|
||||
\return SWITCH_STATUS_SUCCESS if all is well
|
||||
\note passing a NULL dtmf_callback nad a not NULL buf indicates to copy any dtmf to buf and stop recording.
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_record_file(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_record_file(switch_core_session_t *session,
|
||||
switch_file_handle_t *fh,
|
||||
char *file,
|
||||
switch_dtmf_callback_function dtmf_callback,
|
||||
switch_dtmf_callback_function_t dtmf_callback,
|
||||
void *buf,
|
||||
unsigned int buflen);
|
||||
|
||||
@@ -138,12 +138,12 @@ SWITCH_DECLARE(switch_status) switch_ivr_record_file(switch_core_session_t *sess
|
||||
\param buflen the len of buf
|
||||
\return SWITCH_STATUS_SUCCESS if all is well
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_speak_text(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_speak_text(switch_core_session_t *session,
|
||||
char *tts_name,
|
||||
char *voice_name,
|
||||
char *timer_name,
|
||||
uint32_t rate,
|
||||
switch_dtmf_callback_function dtmf_callback,
|
||||
switch_dtmf_callback_function_t dtmf_callback,
|
||||
char *text,
|
||||
void *buf,
|
||||
unsigned int buflen);
|
||||
@@ -158,10 +158,10 @@ SWITCH_DECLARE(switch_status) switch_ivr_speak_text(switch_core_session_t *sessi
|
||||
\param peer_session_data data to pass to the DTMF callback for peer_session
|
||||
\return SWITCH_STATUS_SUCCESS if all is well
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_multi_threaded_bridge(switch_core_session_t *session,
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_multi_threaded_bridge(switch_core_session_t *session,
|
||||
switch_core_session_t *peer_session,
|
||||
unsigned int timelimit,
|
||||
switch_dtmf_callback_function dtmf_callback,
|
||||
switch_dtmf_callback_function_t dtmf_callback,
|
||||
void *session_data,
|
||||
void *peer_session_data);
|
||||
|
||||
@@ -173,7 +173,7 @@ SWITCH_DECLARE(switch_status) switch_ivr_multi_threaded_bridge(switch_core_sessi
|
||||
\param dialplan the new dialplan (OPTIONAL, may be NULL)
|
||||
\param context the new context (OPTIONAL, may be NULL)
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_ivr_session_transfer(switch_core_session_t *session, char *extension, char *dialplan, char *context);
|
||||
SWITCH_DECLARE(switch_status_t) switch_ivr_session_transfer(switch_core_session_t *session, char *extension, char *dialplan, char *context);
|
||||
|
||||
/** @} */
|
||||
|
||||
|
||||
@@ -56,30 +56,30 @@ struct switch_loadable_module_interface {
|
||||
/*! the name of the module */
|
||||
const char *module_name;
|
||||
/*! the table of endpoints the module has implmented */
|
||||
const switch_endpoint_interface *endpoint_interface;
|
||||
const switch_endpoint_interface_t *endpoint_interface;
|
||||
/*! the table of timers the module has implmented */
|
||||
const switch_timer_interface *timer_interface;
|
||||
const switch_timer_interface_t *timer_interface;
|
||||
/*! the table of dialplans the module has implmented */
|
||||
const switch_dialplan_interface *dialplan_interface;
|
||||
const switch_dialplan_interface_t *dialplan_interface;
|
||||
/*! the table of codecs the module has implmented */
|
||||
const switch_codec_interface *codec_interface;
|
||||
const switch_codec_interface_t *codec_interface;
|
||||
/*! the table of applications the module has implmented */
|
||||
const switch_application_interface *application_interface;
|
||||
const switch_application_interface_t *application_interface;
|
||||
/*! the table of api functions the module has implmented */
|
||||
const switch_api_interface *api_interface;
|
||||
const switch_api_interface_t *api_interface;
|
||||
/*! the table of file formats the module has implmented */
|
||||
const switch_file_interface *file_interface;
|
||||
const switch_file_interface_t *file_interface;
|
||||
/*! the table of speech interfaces the module has implmented */
|
||||
const switch_speech_interface *speech_interface;
|
||||
const switch_speech_interface_t *speech_interface;
|
||||
/*! the table of directory interfaces the module has implmented */
|
||||
const switch_directory_interface *directory_interface;
|
||||
const switch_directory_interface_t *directory_interface;
|
||||
};
|
||||
|
||||
/*!
|
||||
\brief Initilize the module backend and load all the modules
|
||||
\return SWITCH_STATUS_SUCCESS when complete
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_loadable_module_init(void);
|
||||
SWITCH_DECLARE(switch_status_t) switch_loadable_module_init(void);
|
||||
|
||||
/*!
|
||||
\brief Shutdown the module backend and call the shutdown routine in all loaded modules
|
||||
@@ -91,21 +91,21 @@ SWITCH_DECLARE(void) switch_loadable_module_shutdown(void);
|
||||
\param name the name of the endpoint
|
||||
\return the desired endpoint interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_endpoint_interface *) switch_loadable_module_get_endpoint_interface(char *name);
|
||||
SWITCH_DECLARE(switch_endpoint_interface_t *) switch_loadable_module_get_endpoint_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the codec interface by it's registered name
|
||||
\param name the name of the codec
|
||||
\return the desired codec interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_codec_interface *) switch_loadable_module_get_codec_interface(char *name);
|
||||
SWITCH_DECLARE(switch_codec_interface_t *) switch_loadable_module_get_codec_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the dialplan interface by it's registered name
|
||||
\param name the name of the dialplan
|
||||
\return the desired dialplan interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_dialplan_interface *) switch_loadable_module_get_dialplan_interface(char *name);
|
||||
SWITCH_DECLARE(switch_dialplan_interface_t *) switch_loadable_module_get_dialplan_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief build a dynamic module object and register it (for use in double embeded modules)
|
||||
@@ -116,7 +116,7 @@ SWITCH_DECLARE(switch_dialplan_interface *) switch_loadable_module_get_dialplan_
|
||||
\return the resulting status
|
||||
\note only use this function if you are making a module that in turn gateways module loading to another technology
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_loadable_module_build_dynamic(char *filename,
|
||||
SWITCH_DECLARE(switch_status_t) switch_loadable_module_build_dynamic(char *filename,
|
||||
switch_module_load_t switch_module_load,
|
||||
switch_module_runtime_t switch_module_runtime,
|
||||
switch_module_shutdown_t switch_module_shutdown);
|
||||
@@ -126,42 +126,42 @@ SWITCH_DECLARE(switch_status) switch_loadable_module_build_dynamic(char *filenam
|
||||
\param name the name of the timer
|
||||
\return the desired timer interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_timer_interface *) switch_loadable_module_get_timer_interface(char *name);
|
||||
SWITCH_DECLARE(switch_timer_interface_t *) switch_loadable_module_get_timer_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the application interface by it's registered name
|
||||
\param name the name of the application
|
||||
\return the desired application interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_application_interface *) switch_loadable_module_get_application_interface(char *name);
|
||||
SWITCH_DECLARE(switch_application_interface_t *) switch_loadable_module_get_application_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the API interface by it's registered name
|
||||
\param name the name of the API
|
||||
\return the desired API interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_api_interface *) switch_loadable_module_get_api_interface(char *name);
|
||||
SWITCH_DECLARE(switch_api_interface_t *) switch_loadable_module_get_api_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the file format interface by it's registered name
|
||||
\param name the name of the file format
|
||||
\return the desired file format interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_file_interface *) switch_loadable_module_get_file_interface(char *name);
|
||||
SWITCH_DECLARE(switch_file_interface_t *) switch_loadable_module_get_file_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the speech interface by it's registered name
|
||||
\param name the name of the speech interface
|
||||
\return the desired speech interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_speech_interface *) switch_loadable_module_get_speech_interface(char *name);
|
||||
SWITCH_DECLARE(switch_speech_interface_t *) switch_loadable_module_get_speech_interface(char *name);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the directory interface by it's registered name
|
||||
\param name the name of the directory interface
|
||||
\return the desired directory interface
|
||||
*/
|
||||
SWITCH_DECLARE(switch_directory_interface *) switch_loadable_module_get_directory_interface(char *name);
|
||||
SWITCH_DECLARE(switch_directory_interface_t *) switch_loadable_module_get_directory_interface(char *name);
|
||||
|
||||
|
||||
/*!
|
||||
@@ -172,7 +172,7 @@ SWITCH_DECLARE(switch_directory_interface *) switch_loadable_module_get_director
|
||||
\return the number of elements added to the array
|
||||
*/
|
||||
SWITCH_DECLARE(int) switch_loadable_module_get_codecs(switch_memory_pool_t *pool,
|
||||
switch_codec_interface **array,
|
||||
switch_codec_interface_t **array,
|
||||
int arraylen);
|
||||
|
||||
/*!
|
||||
@@ -184,7 +184,7 @@ SWITCH_DECLARE(int) switch_loadable_module_get_codecs(switch_memory_pool_t *pool
|
||||
\return the number of elements added to the array
|
||||
\note this function only considers codecs that are listed in the "prefs" array and ignores the rest.
|
||||
*/
|
||||
SWITCH_DECLARE(int) switch_loadable_module_get_codecs_sorted(switch_codec_interface **array,
|
||||
SWITCH_DECLARE(int) switch_loadable_module_get_codecs_sorted(switch_codec_interface_t **array,
|
||||
int arraylen,
|
||||
char **prefs,
|
||||
int preflen);
|
||||
@@ -197,7 +197,7 @@ SWITCH_DECLARE(int) switch_loadable_module_get_codecs_sorted(switch_codec_interf
|
||||
\param len the length in bytes of retbuf
|
||||
\return the status returned by the API call
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_api_execute(char *cmd, char *arg, char *retbuf, switch_size_t len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_api_execute(char *cmd, char *arg, char *retbuf, switch_size_t len);
|
||||
|
||||
|
||||
/*!
|
||||
@@ -206,7 +206,7 @@ SWITCH_DECLARE(switch_status) switch_api_execute(char *cmd, char *arg, char *ret
|
||||
\param fname the file name of the module
|
||||
\return the status
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_loadable_module_load_module(char *dir, char *fname);
|
||||
SWITCH_DECLARE(switch_status_t) switch_loadable_module_load_module(char *dir, char *fname);
|
||||
|
||||
/* Prototypes of module interface functions */
|
||||
|
||||
@@ -216,19 +216,19 @@ SWITCH_DECLARE(switch_status) switch_loadable_module_load_module(char *dir, char
|
||||
\param filename the path to the module's dll or so file
|
||||
\return SWITCH_STATUS_SUCCESS on a successful load
|
||||
*/
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_load(const switch_loadable_module_interface **interface, char *filename);
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_reload(void);
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_pause(void);
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_resume(void);
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_status(void);
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_runtime(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_load(const switch_loadable_module_interface_t **interface, char *filename);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_reload(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_pause(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_resume(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_status(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_runtime(void);
|
||||
|
||||
|
||||
/*!
|
||||
\brief Shutdown a module
|
||||
\return SWITCH_STATUS_SUCCESS on a successful shutdown
|
||||
*/
|
||||
SWITCH_MOD_DECLARE(switch_status) switch_module_shutdown(void);
|
||||
SWITCH_MOD_DECLARE(switch_status_t) switch_module_shutdown(void);
|
||||
///\}
|
||||
|
||||
END_EXTERN_C
|
||||
|
||||
@@ -59,14 +59,14 @@ typedef struct {
|
||||
/*! The function where the message originated */
|
||||
char *func;
|
||||
/*! The log level of the message */
|
||||
switch_log_level level;
|
||||
switch_log_level_t level;
|
||||
/*! The time when the log line was sent */
|
||||
switch_time_t timestamp;
|
||||
/*! A pointer to where the actual content of the message starts (skipping past the preformatted portion) */
|
||||
char *content;
|
||||
} switch_log_node;
|
||||
} switch_log_node_t;
|
||||
|
||||
typedef switch_status (*switch_log_function)(const switch_log_node *node, switch_log_level level);
|
||||
typedef switch_status_t (*switch_log_function_t)(const switch_log_node_t *node, switch_log_level_t level);
|
||||
|
||||
|
||||
/*!
|
||||
@@ -74,13 +74,13 @@ typedef switch_status (*switch_log_function)(const switch_log_node *node, switch
|
||||
\param pool the memory pool to use
|
||||
\note to be called at application startup by the core
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_log_init(switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_log_init(switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Shut down the logging engine
|
||||
\note to be called at application termination by the core
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_log_shutdown(void);
|
||||
SWITCH_DECLARE(switch_status_t) switch_log_shutdown(void);
|
||||
|
||||
|
||||
/*!
|
||||
@@ -94,27 +94,27 @@ SWITCH_DECLARE(switch_status) switch_log_shutdown(void);
|
||||
\param ... variable args
|
||||
\note there are channel macros to supply the first 4 parameters
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel channel, char *file, const char *func, int line, switch_log_level level, char *fmt, ...);
|
||||
SWITCH_DECLARE(void) switch_log_printf(switch_text_channel_t channel, char *file, const char *func, int line, switch_log_level_t level, char *fmt, ...);
|
||||
|
||||
/*!
|
||||
\brief Shut down the logging engine
|
||||
\note to be called at application termination by the core
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_log_bind_logger(switch_log_function function, switch_log_level level);
|
||||
SWITCH_DECLARE(switch_status_t) switch_log_bind_logger(switch_log_function_t function, switch_log_level_t level);
|
||||
|
||||
/*!
|
||||
\brief Return the name of the specified log level
|
||||
\param level the level
|
||||
\return the name of the log level
|
||||
*/
|
||||
SWITCH_DECLARE(const char *) switch_log_level2str(switch_log_level level);
|
||||
SWITCH_DECLARE(const char *) switch_log_level2str(switch_log_level_t level);
|
||||
|
||||
/*!
|
||||
\brief Return the level number of the specified log level name
|
||||
\param str the name of the level
|
||||
\return the log level
|
||||
*/
|
||||
SWITCH_DECLARE(switch_log_level) switch_log_str2level(const char *str);
|
||||
SWITCH_DECLARE(switch_log_level_t) switch_log_str2level(const char *str);
|
||||
|
||||
///\}
|
||||
END_EXTERN_C
|
||||
|
||||
@@ -47,137 +47,137 @@ BEGIN_EXTERN_C
|
||||
*/
|
||||
struct switch_state_handler_table {
|
||||
/*! executed when the state changes to init */
|
||||
switch_state_handler on_init;
|
||||
switch_state_handler_t on_init;
|
||||
/*! executed when the state changes to ring */
|
||||
switch_state_handler on_ring;
|
||||
switch_state_handler_t on_ring;
|
||||
/*! executed when the state changes to execute */
|
||||
switch_state_handler on_execute;
|
||||
switch_state_handler_t on_execute;
|
||||
/*! executed when the state changes to hangup */
|
||||
switch_state_handler on_hangup;
|
||||
switch_state_handler_t on_hangup;
|
||||
/*! executed when the state changes to loopback*/
|
||||
switch_state_handler on_loopback;
|
||||
switch_state_handler_t on_loopback;
|
||||
/*! executed when the state changes to transmit*/
|
||||
switch_state_handler on_transmit;
|
||||
switch_state_handler_t on_transmit;
|
||||
/*! executed when the state changes to hold*/
|
||||
switch_state_handler on_hold;
|
||||
switch_state_handler_t on_hold;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom outgoing channel callback hooks */
|
||||
struct switch_io_event_hook_outgoing_channel {
|
||||
/*! the outgoing channel callback hook*/
|
||||
switch_outgoing_channel_hook outgoing_channel;
|
||||
switch_outgoing_channel_hook_t outgoing_channel;
|
||||
struct switch_io_event_hook_outgoing_channel *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom answer channel callback hooks */
|
||||
struct switch_io_event_hook_answer_channel {
|
||||
/*! the answer channel callback hook*/
|
||||
switch_answer_channel_hook answer_channel;
|
||||
switch_answer_channel_hook_t answer_channel;
|
||||
struct switch_io_event_hook_answer_channel *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom receive message callback hooks */
|
||||
struct switch_io_event_hook_receive_message {
|
||||
/*! the answer channel callback hook*/
|
||||
switch_receive_message_hook receive_message;
|
||||
switch_receive_message_hook_t receive_message;
|
||||
struct switch_io_event_hook_receive_message *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom receive message callback hooks */
|
||||
struct switch_io_event_hook_queue_event {
|
||||
/*! the answer channel callback hook*/
|
||||
switch_queue_event_hook queue_event;
|
||||
switch_queue_event_hook_t queue_event;
|
||||
struct switch_io_event_hook_queue_event *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom read frame channel callback hooks */
|
||||
struct switch_io_event_hook_read_frame {
|
||||
/*! the read frame channel callback hook*/
|
||||
switch_read_frame_hook read_frame;
|
||||
switch_read_frame_hook_t read_frame;
|
||||
struct switch_io_event_hook_read_frame *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom write_frame channel callback hooks */
|
||||
struct switch_io_event_hook_write_frame {
|
||||
/*! the write_frame channel callback hook*/
|
||||
switch_write_frame_hook write_frame;
|
||||
switch_write_frame_hook_t write_frame;
|
||||
struct switch_io_event_hook_write_frame *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom kill channel callback hooks */
|
||||
struct switch_io_event_hook_kill_channel {
|
||||
/*! the kill channel callback hook*/
|
||||
switch_kill_channel_hook kill_channel;
|
||||
switch_kill_channel_hook_t kill_channel;
|
||||
struct switch_io_event_hook_kill_channel *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom waitfor read channel callback hooks */
|
||||
struct switch_io_event_hook_waitfor_read {
|
||||
/*! the waitfor read channel callback hook*/
|
||||
switch_waitfor_read_hook waitfor_read;
|
||||
switch_waitfor_read_hook_t waitfor_read;
|
||||
struct switch_io_event_hook_waitfor_read *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom waitfor write channel callback hooks */
|
||||
struct switch_io_event_hook_waitfor_write {
|
||||
/*! the waitfor write channel callback hook*/
|
||||
switch_waitfor_write_hook waitfor_write;
|
||||
switch_waitfor_write_hook_t waitfor_write;
|
||||
struct switch_io_event_hook_waitfor_write *next;
|
||||
};
|
||||
|
||||
/*! \brief Node in which to store custom send dtmf channel callback hooks */
|
||||
struct switch_io_event_hook_send_dtmf {
|
||||
/*! the send dtmf channel callback hook*/
|
||||
switch_send_dtmf_hook send_dtmf;
|
||||
switch_send_dtmf_hook_t send_dtmf;
|
||||
struct switch_io_event_hook_send_dtmf *next;
|
||||
};
|
||||
|
||||
/*! \brief A table of lists of io_event_hooks to store the event hooks associated with a session */
|
||||
struct switch_io_event_hooks {
|
||||
/*! a list of outgoing channel hooks */
|
||||
struct switch_io_event_hook_outgoing_channel *outgoing_channel;
|
||||
switch_io_event_hook_outgoing_channel_t *outgoing_channel;
|
||||
/*! a list of answer channel hooks */
|
||||
struct switch_io_event_hook_answer_channel *answer_channel;
|
||||
switch_io_event_hook_answer_channel_t *answer_channel;
|
||||
/*! a list of receive message hooks */
|
||||
struct switch_io_event_hook_receive_message *receive_message;
|
||||
switch_io_event_hook_receive_message_t *receive_message;
|
||||
/*! a list of queue message hooks */
|
||||
struct switch_io_event_hook_queue_event *queue_event;
|
||||
switch_io_event_hook_queue_event_t *queue_event;
|
||||
/*! a list of read frame hooks */
|
||||
struct switch_io_event_hook_read_frame *read_frame;
|
||||
switch_io_event_hook_read_frame_t *read_frame;
|
||||
/*! a list of write frame hooks */
|
||||
struct switch_io_event_hook_write_frame *write_frame;
|
||||
switch_io_event_hook_write_frame_t *write_frame;
|
||||
/*! a list of kill channel hooks */
|
||||
struct switch_io_event_hook_kill_channel *kill_channel;
|
||||
switch_io_event_hook_kill_channel_t *kill_channel;
|
||||
/*! a list of wait for read hooks */
|
||||
struct switch_io_event_hook_waitfor_read *waitfor_read;
|
||||
switch_io_event_hook_waitfor_read_t *waitfor_read;
|
||||
/*! a list of wait for write hooks */
|
||||
struct switch_io_event_hook_waitfor_write *waitfor_write;
|
||||
switch_io_event_hook_waitfor_write_t *waitfor_write;
|
||||
/*! a list of send dtmf hooks */
|
||||
struct switch_io_event_hook_send_dtmf *send_dtmf;
|
||||
switch_io_event_hook_send_dtmf_t *send_dtmf;
|
||||
};
|
||||
|
||||
/*! \brief A table of i/o routines that an endpoint interface can implement */
|
||||
struct switch_io_routines {
|
||||
/*! creates an outgoing session from given session, caller profile */
|
||||
switch_status (*outgoing_channel)(switch_core_session_t *, switch_caller_profile_t *, switch_core_session_t **, switch_memory_pool_t *);
|
||||
switch_status_t (*outgoing_channel)(switch_core_session_t *, switch_caller_profile_t *, switch_core_session_t **, switch_memory_pool_t *);
|
||||
/*! answers the given session's channel */
|
||||
switch_status (*answer_channel)(switch_core_session_t *);
|
||||
switch_status_t (*answer_channel)(switch_core_session_t *);
|
||||
/*! read a frame from a session */
|
||||
switch_status (*read_frame)(switch_core_session_t *, switch_frame_t **, int, switch_io_flag, int);
|
||||
switch_status_t (*read_frame)(switch_core_session_t *, switch_frame_t **, int, switch_io_flag_t, int);
|
||||
/*! write a frame to a session */
|
||||
switch_status (*write_frame)(switch_core_session_t *, switch_frame_t *, int, switch_io_flag, int);
|
||||
switch_status_t (*write_frame)(switch_core_session_t *, switch_frame_t *, int, switch_io_flag_t, int);
|
||||
/*! send a kill signal to the session's channel */
|
||||
switch_status (*kill_channel)(switch_core_session_t *, int);
|
||||
switch_status_t (*kill_channel)(switch_core_session_t *, int);
|
||||
/*! wait for the session's channel to be ready to read audio */
|
||||
switch_status (*waitfor_read)(switch_core_session_t *, int, int);
|
||||
switch_status_t (*waitfor_read)(switch_core_session_t *, int, int);
|
||||
/*! wait for the session's channel to be ready to write audio */
|
||||
switch_status (*waitfor_write)(switch_core_session_t *, int, int);
|
||||
switch_status_t (*waitfor_write)(switch_core_session_t *, int, int);
|
||||
/*! send a string of DTMF digits to a session's channel */
|
||||
switch_status (*send_dtmf)(switch_core_session_t *, char *);
|
||||
switch_status_t (*send_dtmf)(switch_core_session_t *, char *);
|
||||
/*! receive a message from another session*/
|
||||
switch_status (*receive_message)(switch_core_session_t *, switch_core_session_message_t *);
|
||||
switch_status_t (*receive_message)(switch_core_session_t *, switch_core_session_message_t *);
|
||||
/*! queue a message for another session*/
|
||||
switch_status (*queue_event)(switch_core_session_t *, switch_event_t *);
|
||||
switch_status_t (*queue_event)(switch_core_session_t *, switch_event_t *);
|
||||
};
|
||||
|
||||
/*! \brief Abstraction of an module endpoint interface
|
||||
@@ -191,7 +191,7 @@ struct switch_endpoint_interface {
|
||||
const char *interface_name;
|
||||
|
||||
/*! channel abstraction methods */
|
||||
const switch_io_routines *io_routines;
|
||||
const switch_io_routines_t *io_routines;
|
||||
|
||||
/*! state machine methods */
|
||||
const switch_state_handler_table_t *state_handler;
|
||||
@@ -214,7 +214,7 @@ struct switch_timer {
|
||||
/*! current sample count based on samples parameter */
|
||||
unsigned int samplecount;
|
||||
/*! the timer interface provided from a loadable module */
|
||||
struct switch_timer_interface *timer_interface;
|
||||
switch_timer_interface_t *timer_interface;
|
||||
/*! the timer's memory pool */
|
||||
switch_memory_pool_t *memory_pool;
|
||||
/*! private data for loadable modules to store information */
|
||||
@@ -226,11 +226,11 @@ struct switch_timer_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! function to allocate the timer */
|
||||
switch_status (*timer_init)(switch_timer_t *);
|
||||
switch_status_t (*timer_init)(switch_timer_t *);
|
||||
/*! function to wait for one cycle to pass */
|
||||
switch_status (*timer_next)(switch_timer_t *);
|
||||
switch_status_t (*timer_next)(switch_timer_t *);
|
||||
/*! function to deallocate the timer */
|
||||
switch_status (*timer_destroy)(switch_timer_t *);
|
||||
switch_status_t (*timer_destroy)(switch_timer_t *);
|
||||
const struct switch_timer_interface *next;
|
||||
};
|
||||
|
||||
@@ -239,7 +239,7 @@ struct switch_dialplan_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! the function to read an extension and set a channels dialpan */
|
||||
switch_dialplan_hunt_function hunt_function;
|
||||
switch_dialplan_hunt_function_t hunt_function;
|
||||
const struct switch_dialplan_interface *next;
|
||||
};
|
||||
|
||||
@@ -248,15 +248,15 @@ struct switch_file_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! function to open the file */
|
||||
switch_status (*file_open)(switch_file_handle_t *, char *file_path);
|
||||
switch_status_t (*file_open)(switch_file_handle_t *, char *file_path);
|
||||
/*! function to close the file */
|
||||
switch_status (*file_close)(switch_file_handle_t *);
|
||||
switch_status_t (*file_close)(switch_file_handle_t *);
|
||||
/*! function to read from the file */
|
||||
switch_status (*file_read)(switch_file_handle_t *, void *data, switch_size_t *len);
|
||||
switch_status_t (*file_read)(switch_file_handle_t *, void *data, switch_size_t *len);
|
||||
/*! function to write from the file */
|
||||
switch_status (*file_write)(switch_file_handle_t *, void *data, switch_size_t *len);
|
||||
switch_status_t (*file_write)(switch_file_handle_t *, void *data, switch_size_t *len);
|
||||
/*! function to seek to a certian position in the file */
|
||||
switch_status (*file_seek)(switch_file_handle_t *, unsigned int *cur_pos, int64_t samples, int whence);
|
||||
switch_status_t (*file_seek)(switch_file_handle_t *, unsigned int *cur_pos, int64_t samples, int whence);
|
||||
/*! list of supported file extensions */
|
||||
char **extens;
|
||||
const struct switch_file_interface *next;
|
||||
@@ -265,7 +265,7 @@ struct switch_file_interface {
|
||||
/*! an abstract representation of a file handle (some parameters based on compat with libsndfile) */
|
||||
struct switch_file_handle {
|
||||
/*! the interface of the module that implemented the current file type */
|
||||
const struct switch_file_interface *file_interface;
|
||||
const switch_file_interface_t *file_interface;
|
||||
/*! flags to control behaviour */
|
||||
uint32_t flags;
|
||||
/*! a file descriptor if neceessary */
|
||||
@@ -300,24 +300,24 @@ struct switch_speech_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! function to open the speech interface */
|
||||
switch_status (*speech_open)(switch_speech_handle *sh,
|
||||
switch_status_t (*speech_open)(switch_speech_handle_t *sh,
|
||||
char *voice_name,
|
||||
int rate,
|
||||
switch_speech_flag *flags);
|
||||
switch_speech_flag_t *flags);
|
||||
/*! function to close the speech interface */
|
||||
switch_status (*speech_close)(switch_speech_handle *, switch_speech_flag *flags);
|
||||
switch_status_t (*speech_close)(switch_speech_handle_t *, switch_speech_flag_t *flags);
|
||||
/*! function to feed audio to the ASR*/
|
||||
switch_status (*speech_feed_asr)(switch_speech_handle *sh, void *data, unsigned int *len, int rate, switch_speech_flag *flags);
|
||||
switch_status_t (*speech_feed_asr)(switch_speech_handle_t *sh, void *data, unsigned int *len, int rate, switch_speech_flag_t *flags);
|
||||
/*! function to read text from the ASR*/
|
||||
switch_status (*speech_interpret_asr)(switch_speech_handle *sh, char *buf, unsigned int buflen, switch_speech_flag *flags);
|
||||
switch_status_t (*speech_interpret_asr)(switch_speech_handle_t *sh, char *buf, unsigned int buflen, switch_speech_flag_t *flags);
|
||||
/*! function to feed text to the TTS*/
|
||||
switch_status (*speech_feed_tts)(switch_speech_handle *sh, char *text, switch_speech_flag *flags);
|
||||
switch_status_t (*speech_feed_tts)(switch_speech_handle_t *sh, char *text, switch_speech_flag_t *flags);
|
||||
/*! function to read audio from the TTS*/
|
||||
switch_status (*speech_read_tts)(switch_speech_handle *sh,
|
||||
switch_status_t (*speech_read_tts)(switch_speech_handle_t *sh,
|
||||
void *data,
|
||||
switch_size_t *datalen,
|
||||
uint32_t *rate,
|
||||
switch_speech_flag *flags);
|
||||
switch_speech_flag_t *flags);
|
||||
|
||||
const struct switch_speech_interface *next;
|
||||
};
|
||||
@@ -326,7 +326,7 @@ struct switch_speech_interface {
|
||||
/*! an abstract representation of a asr/tts speech interface. */
|
||||
struct switch_speech_handle {
|
||||
/*! the interface of the module that implemented the current speech interface */
|
||||
const struct switch_speech_interface *speech_interface;
|
||||
const switch_speech_interface_t *speech_interface;
|
||||
/*! flags to control behaviour */
|
||||
uint32_t flags;
|
||||
|
||||
@@ -343,15 +343,15 @@ struct switch_directory_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! function to open the directory interface */
|
||||
switch_status (*directory_open)(switch_directory_handle *dh, char *source, char *dsn, char *passwd);
|
||||
switch_status_t (*directory_open)(switch_directory_handle_t *dh, char *source, char *dsn, char *passwd);
|
||||
/*! function to close the directory interface */
|
||||
switch_status (*directory_close)(switch_directory_handle *dh);
|
||||
switch_status_t (*directory_close)(switch_directory_handle_t *dh);
|
||||
/*! function to query the directory interface */
|
||||
switch_status (*directory_query)(switch_directory_handle *dh, char *base, char *query);
|
||||
switch_status_t (*directory_query)(switch_directory_handle_t *dh, char *base, char *query);
|
||||
/*! function to advance to the next record */
|
||||
switch_status (*directory_next)(switch_directory_handle *dh);
|
||||
switch_status_t (*directory_next)(switch_directory_handle_t *dh);
|
||||
/*! function to advance to the next name/value pair in the current record */
|
||||
switch_status (*directory_next_pair)(switch_directory_handle *dh, char **var, char **val);
|
||||
switch_status_t (*directory_next_pair)(switch_directory_handle_t *dh, char **var, char **val);
|
||||
|
||||
const struct switch_directory_interface *next;
|
||||
};
|
||||
@@ -359,7 +359,7 @@ struct switch_directory_interface {
|
||||
/*! an abstract representation of a directory interface. */
|
||||
struct switch_directory_handle {
|
||||
/*! the interface of the module that implemented the current directory interface */
|
||||
const struct switch_directory_interface *directory_interface;
|
||||
const switch_directory_interface_t *directory_interface;
|
||||
/*! flags to control behaviour */
|
||||
uint32_t flags;
|
||||
|
||||
@@ -410,7 +410,7 @@ struct switch_codec_settings {
|
||||
/*! an abstract handle to a codec module */
|
||||
struct switch_codec {
|
||||
/*! the codec interface table this handle uses */
|
||||
const struct switch_codec_interface *codec_interface;
|
||||
const switch_codec_interface_t *codec_interface;
|
||||
/*! the specific implementation of the above codec */
|
||||
const switch_codec_implementation_t *implementation;
|
||||
/*! codec settings for this handle */
|
||||
@@ -444,9 +444,9 @@ struct switch_codec_implementation {
|
||||
/*! max number of frames to send in one network packet */
|
||||
int max_frames_per_packet;
|
||||
/*! function to initialize a codec handle using this implementation */
|
||||
switch_status (*init)(switch_codec_t *, switch_codec_flag, const switch_codec_settings_t *codec_settings);
|
||||
switch_status_t (*init)(switch_codec_t *, switch_codec_flag_t, const switch_codec_settings_t *codec_settings);
|
||||
/*! function to encode raw data into encoded data */
|
||||
switch_status (*encode)(switch_codec_t *codec,
|
||||
switch_status_t (*encode)(switch_codec_t *codec,
|
||||
switch_codec_t *other_codec,
|
||||
void *decoded_data,
|
||||
uint32_t decoded_data_len,
|
||||
@@ -456,7 +456,7 @@ struct switch_codec_implementation {
|
||||
uint32_t *encoded_rate,
|
||||
unsigned int *flag);
|
||||
/*! function to decode encoded data into raw data */
|
||||
switch_status (*decode)(switch_codec_t *codec,
|
||||
switch_status_t (*decode)(switch_codec_t *codec,
|
||||
switch_codec_t *other_codec,
|
||||
void *encoded_data,
|
||||
uint32_t encoded_data_len,
|
||||
@@ -466,7 +466,7 @@ struct switch_codec_implementation {
|
||||
uint32_t *decoded_rate,
|
||||
unsigned int *flag);
|
||||
/*! deinitalize a codec handle using this implementation */
|
||||
switch_status (*destroy)(switch_codec_t *);
|
||||
switch_status_t (*destroy)(switch_codec_t *);
|
||||
const struct switch_codec_implementation *next;
|
||||
};
|
||||
|
||||
@@ -475,7 +475,7 @@ struct switch_codec_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! enumeration defining the type of the codec */
|
||||
const switch_codec_type codec_type;
|
||||
const switch_codec_type_t codec_type;
|
||||
/*! the IANA code number */
|
||||
switch_payload_t ianacode;
|
||||
/*! the IANA code name */
|
||||
@@ -490,7 +490,7 @@ struct switch_application_interface {
|
||||
/*! the name of the interface */
|
||||
const char *interface_name;
|
||||
/*! function the application implements */
|
||||
switch_application_function application_function;
|
||||
switch_application_function_t application_function;
|
||||
/*! the long winded description of the application */
|
||||
const char *long_desc;
|
||||
/*! the short and sweet description of the application */
|
||||
@@ -507,7 +507,7 @@ struct switch_api_interface {
|
||||
/*! a description of the api function */
|
||||
const char *desc;
|
||||
/*! function the api call uses */
|
||||
switch_api_function function;
|
||||
switch_api_function_t function;
|
||||
const struct switch_api_interface *next;
|
||||
};
|
||||
|
||||
|
||||
@@ -86,7 +86,7 @@ typedef struct {
|
||||
\param pool the memory pool to use for buffer allocation
|
||||
\return SWITCH_STATUS_SUCCESS if the handle was created
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_resample_create(switch_audio_resampler_t **new_resampler,
|
||||
SWITCH_DECLARE(switch_status_t) switch_resample_create(switch_audio_resampler_t **new_resampler,
|
||||
int from_rate,
|
||||
switch_size_t from_size,
|
||||
int to_rate,
|
||||
|
||||
+13
-13
@@ -45,7 +45,7 @@ BEGIN_EXTERN_C
|
||||
///\defgroup rtp RTP (RealTime Transport Protocol)
|
||||
///\ingroup core1
|
||||
///\{
|
||||
typedef void (*switch_rtp_invalid_handler)(switch_rtp_t *rtp_session,
|
||||
typedef void (*switch_rtp_invalid_handler_t)(switch_rtp_t *rtp_session,
|
||||
switch_socket_t *sock,
|
||||
void *data,
|
||||
switch_size_t datalen,
|
||||
@@ -76,7 +76,7 @@ SWITCH_DECLARE(switch_port_t) switch_rtp_request_port(void);
|
||||
\param pool a memory pool to use for the session
|
||||
\return the new RTP session or NULL on failure
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status)switch_rtp_create(switch_rtp_t **new_rtp_session,
|
||||
SWITCH_DECLARE(switch_status_t)switch_rtp_create(switch_rtp_t **new_rtp_session,
|
||||
switch_payload_t payload,
|
||||
uint32_t packet_size,
|
||||
uint32_t ms_per_packet,
|
||||
@@ -121,7 +121,7 @@ SWITCH_DECLARE(switch_rtp_t *)switch_rtp_new(char *rx_host,
|
||||
\param port the remote port
|
||||
\param err pointer for error messages
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_set_remote_address(switch_rtp_t *rtp_session, char *host, switch_port_t port, const char **err);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_set_remote_address(switch_rtp_t *rtp_session, char *host, switch_port_t port, const char **err);
|
||||
|
||||
/*!
|
||||
\brief Assign a local address to the RTP session
|
||||
@@ -131,7 +131,7 @@ SWITCH_DECLARE(switch_status) switch_rtp_set_remote_address(switch_rtp_t *rtp_se
|
||||
\param err pointer for error messages
|
||||
\note this call also binds the RTP session's socket to the new address
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_set_local_address(switch_rtp_t *rtp_session, char *host, switch_port_t port, const char **err);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_set_local_address(switch_rtp_t *rtp_session, char *host, switch_port_t port, const char **err);
|
||||
|
||||
/*!
|
||||
\brief Kill the socket on an existing RTP session
|
||||
@@ -149,7 +149,7 @@ SWITCH_DECLARE(void) switch_rtp_destroy(switch_rtp_t **rtp_session);
|
||||
\brief Acvite ICE on an RTP session
|
||||
\return SWITCH_STATUS_SUCCESS
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_activate_ice(switch_rtp_t *rtp_session, char *login, char *rlogin);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_activate_ice(switch_rtp_t *rtp_session, char *login, char *rlogin);
|
||||
|
||||
/*!
|
||||
\brief Set an RTP Flag
|
||||
@@ -215,7 +215,7 @@ SWITCH_DECLARE(uint32_t) switch_rtp_get_default_payload(switch_rtp_t *rtp_sessio
|
||||
\param on_invalid the function to set
|
||||
\return
|
||||
*/
|
||||
SWITCH_DECLARE(void) switch_rtp_set_invald_handler(switch_rtp_t *rtp_session, switch_rtp_invalid_handler on_invalid);
|
||||
SWITCH_DECLARE(void) switch_rtp_set_invald_handler(switch_rtp_t *rtp_session, switch_rtp_invalid_handler_t on_invalid);
|
||||
|
||||
/*!
|
||||
\brief Read data from a given RTP session
|
||||
@@ -226,7 +226,7 @@ SWITCH_DECLARE(void) switch_rtp_set_invald_handler(switch_rtp_t *rtp_session, sw
|
||||
\param flags flags
|
||||
\return the number of bytes read
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_read(switch_rtp_t *rtp_session, void *data, uint32_t *datalen, switch_payload_t *payload_type, switch_frame_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_read(switch_rtp_t *rtp_session, void *data, uint32_t *datalen, switch_payload_t *payload_type, switch_frame_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Read data from a given RTP session without copying
|
||||
@@ -237,7 +237,7 @@ SWITCH_DECLARE(switch_status) switch_rtp_read(switch_rtp_t *rtp_session, void *d
|
||||
\param flags flags
|
||||
\return the number of bytes read
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_zerocopy_read(switch_rtp_t *rtp_session, void **data, uint32_t *datalen, switch_payload_t *payload_type, switch_frame_flag *flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_zerocopy_read(switch_rtp_t *rtp_session, void **data, uint32_t *datalen, switch_payload_t *payload_type, switch_frame_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Read data from a given RTP session without copying
|
||||
@@ -245,7 +245,7 @@ SWITCH_DECLARE(switch_status) switch_rtp_zerocopy_read(switch_rtp_t *rtp_session
|
||||
\param frame a frame to populate with information
|
||||
\return the number of bytes read
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_zerocopy_read_frame(switch_rtp_t *rtp_session, switch_frame_t *frame);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_zerocopy_read_frame(switch_rtp_t *rtp_session, switch_frame_t *frame);
|
||||
|
||||
/*!
|
||||
\brief Write data to a given RTP session
|
||||
@@ -256,7 +256,7 @@ SWITCH_DECLARE(switch_status) switch_rtp_zerocopy_read_frame(switch_rtp_t *rtp_s
|
||||
\param flags frame flags
|
||||
\return the number of bytes written
|
||||
*/
|
||||
SWITCH_DECLARE(int) switch_rtp_write(switch_rtp_t *rtp_session, void *data, uint32_t datalen, uint32_t ts, switch_frame_flag *flags);
|
||||
SWITCH_DECLARE(int) switch_rtp_write(switch_rtp_t *rtp_session, void *data, uint32_t datalen, uint32_t ts, switch_frame_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Enable VAD on an RTP Session
|
||||
@@ -266,14 +266,14 @@ SWITCH_DECLARE(int) switch_rtp_write(switch_rtp_t *rtp_session, void *data, uint
|
||||
\param flags flags for control
|
||||
\return SWITCH_STAUTS_SUCCESS on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_enable_vad(switch_rtp_t *rtp_session, switch_core_session_t *session, switch_codec_t *codec, switch_vad_flag_t flags);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_enable_vad(switch_rtp_t *rtp_session, switch_core_session_t *session, switch_codec_t *codec, switch_vad_flag_t flags);
|
||||
|
||||
/*!
|
||||
\brief Disable VAD on an RTP Session
|
||||
\param rtp_session the RTP session
|
||||
\return SWITCH_STAUTS_SUCCESS on success
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_rtp_disable_vad(switch_rtp_t *rtp_session);
|
||||
SWITCH_DECLARE(switch_status_t) switch_rtp_disable_vad(switch_rtp_t *rtp_session);
|
||||
|
||||
/*!
|
||||
\brief Write data to a given RTP session
|
||||
@@ -296,7 +296,7 @@ SWITCH_DECLARE(int) switch_rtp_write_frame(switch_rtp_t *rtp_session, switch_fra
|
||||
\param flags frame flags
|
||||
\return the number of bytes written
|
||||
*/
|
||||
SWITCH_DECLARE(int) switch_rtp_write_manual(switch_rtp_t *rtp_session, void *data, uint16_t datalen, uint8_t m, switch_payload_t payload, uint32_t ts, uint16_t mseq, switch_frame_flag *flags);
|
||||
SWITCH_DECLARE(int) switch_rtp_write_manual(switch_rtp_t *rtp_session, void *data, uint16_t datalen, uint8_t m, switch_payload_t payload, uint32_t ts, uint16_t mseq, switch_frame_flag_t *flags);
|
||||
|
||||
/*!
|
||||
\brief Retrieve the SSRC from a given RTP session
|
||||
|
||||
@@ -209,7 +209,7 @@ SWITCH_DECLARE(uint8_t) switch_stun_packet_attribute_add_binded_address(switch_s
|
||||
\param pool the memory pool to use
|
||||
\return SUCCESS or FAIL
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_stun_lookup (char **ip,
|
||||
SWITCH_DECLARE(switch_status_t) switch_stun_lookup (char **ip,
|
||||
switch_port_t *port,
|
||||
char *stunip,
|
||||
switch_port_t stunport,
|
||||
|
||||
+74
-74
@@ -197,7 +197,7 @@ typedef enum {
|
||||
} switch_stack_t;
|
||||
|
||||
/*!
|
||||
\enum switch_status
|
||||
\enum switch_status_t
|
||||
\brief Common return values
|
||||
<pre>
|
||||
SWITCH_STATUS_SUCCESS - General Success (common return value for most functions)
|
||||
@@ -229,12 +229,12 @@ typedef enum {
|
||||
SWITCH_STATUS_INUSE,
|
||||
SWITCH_STATUS_BREAK,
|
||||
SWITCH_STATUS_SOCKERR
|
||||
} switch_status;
|
||||
} switch_status_t;
|
||||
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_log_level
|
||||
\enum switch_log_level_t
|
||||
\brief Log Level Enumeration
|
||||
<pre>
|
||||
SWITCH_LOG_CONSOLE - Console
|
||||
@@ -258,11 +258,11 @@ typedef enum {
|
||||
SWITCH_LOG_CRIT = 2,
|
||||
SWITCH_LOG_ALERT = 1,
|
||||
SWITCH_LOG_EMERG = 0
|
||||
} switch_log_level;
|
||||
} switch_log_level_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_text_channel
|
||||
\enum switch_text_channel_t
|
||||
\brief A target to write log/debug info to
|
||||
<pre>
|
||||
SWITCH_CHANNEL_ID_LOG - Write to the currently defined log
|
||||
@@ -274,7 +274,7 @@ typedef enum {
|
||||
SWITCH_CHANNEL_ID_LOG,
|
||||
SWITCH_CHANNEL_ID_LOG_CLEAN,
|
||||
SWITCH_CHANNEL_ID_EVENT
|
||||
} switch_text_channel;
|
||||
} switch_text_channel_t;
|
||||
|
||||
#define SWITCH_UUID_FORMATTED_LENGTH APR_UUID_FORMATTED_LENGTH
|
||||
#define SWITCH_CHANNEL_LOG SWITCH_CHANNEL_ID_LOG, __FILE__, __FUNCTION__, __LINE__
|
||||
@@ -282,7 +282,7 @@ typedef enum {
|
||||
#define SWITCH_CHANNEL_EVENT SWITCH_CHANNEL_ID_EVENT, __FILE__, __FUNCTION__, __LINE__
|
||||
|
||||
/*!
|
||||
\enum switch_channel_state
|
||||
\enum switch_channel_state_t
|
||||
\brief Channel States
|
||||
<pre>
|
||||
CS_NEW - Channel is newly created
|
||||
@@ -306,11 +306,11 @@ typedef enum {
|
||||
CS_HOLD,
|
||||
CS_HANGUP,
|
||||
CS_DONE
|
||||
} switch_channel_state;
|
||||
} switch_channel_state_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_channel_flag
|
||||
\enum switch_channel_flag_t
|
||||
\brief Channel Flags
|
||||
|
||||
<pre>
|
||||
@@ -336,11 +336,11 @@ typedef enum {
|
||||
CF_LOCK_THREAD = (1 << 6),
|
||||
CF_BRIDGED = (1 << 7),
|
||||
CF_HOLD = (1 << 8)
|
||||
} switch_channel_flag;
|
||||
} switch_channel_flag_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_frame_flag
|
||||
\enum switch_frame_flag_t
|
||||
\brief Frame Flags
|
||||
|
||||
<pre>
|
||||
@@ -351,11 +351,11 @@ SFF_RAW_RTP = (1 << 1) - Frame has raw rtp accessible
|
||||
typedef enum {
|
||||
SFF_CNG = (1 << 0),
|
||||
SFF_RAW_RTP = (1 << 1)
|
||||
} switch_frame_flag;
|
||||
} switch_frame_flag_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_signal
|
||||
\enum switch_signal_t
|
||||
\brief Signals to send to channels
|
||||
<pre>
|
||||
SWITCH_SIG_KILL - Kill the channel
|
||||
@@ -367,10 +367,10 @@ typedef enum {
|
||||
SWITCH_SIG_NONE,
|
||||
SWITCH_SIG_KILL,
|
||||
SWITCH_SIG_XFER
|
||||
} switch_signal;
|
||||
} switch_signal_t;
|
||||
|
||||
/*!
|
||||
\enum switch_codec_flag
|
||||
\enum switch_codec_flag_t
|
||||
\brief Codec related flags
|
||||
<pre>
|
||||
SWITCH_CODEC_FLAG_ENCODE = (1 << 0) - Codec can encode
|
||||
@@ -389,11 +389,11 @@ typedef enum {
|
||||
SWITCH_CODEC_FLAG_SILENCE = (1 << 4),
|
||||
SWITCH_CODEC_FLAG_FREE_POOL = (1 << 5),
|
||||
|
||||
} switch_codec_flag;
|
||||
} switch_codec_flag_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_speech_flag
|
||||
\enum switch_speech_flag_t
|
||||
\brief Speech related flags
|
||||
<pre>
|
||||
SWITCH_SPEECH_FLAG_TTS = (1 << 0) - Interface can/should convert text to speech.
|
||||
@@ -412,11 +412,11 @@ typedef enum {
|
||||
SWITCH_SPEECH_FLAG_FREE_POOL = (1 << 4),
|
||||
SWITCH_SPEECH_FLAG_BLOCKING = (1 << 5),
|
||||
|
||||
} switch_speech_flag;
|
||||
} switch_speech_flag_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_directory_flag
|
||||
\enum switch_directory_flag_t
|
||||
\brief Directory Handle related flags
|
||||
<pre>
|
||||
SWITCH_DIRECTORY_FLAG_FREE_POOL = (1 << 0) - Free interface's pool on destruction.
|
||||
@@ -425,10 +425,10 @@ SWITCH_DIRECTORY_FLAG_FREE_POOL = (1 << 0) - Free interface's pool on destruct
|
||||
typedef enum {
|
||||
SWITCH_DIRECTORY_FLAG_FREE_POOL = (1 << 0),
|
||||
|
||||
} switch_directory_flag;
|
||||
} switch_directory_flag_t;
|
||||
|
||||
/*!
|
||||
\enum switch_codec_type
|
||||
\enum switch_codec_type_t
|
||||
\brief Codec types
|
||||
<pre>
|
||||
SWITCH_CODEC_TYPE_AUDIO - Audio Codec
|
||||
@@ -442,11 +442,11 @@ typedef enum {
|
||||
SWITCH_CODEC_TYPE_VIDEO,
|
||||
SWITCH_CODEC_TYPE_T38,
|
||||
SWITCH_CODEC_TYPE_APP
|
||||
} switch_codec_type;
|
||||
} switch_codec_type_t;
|
||||
|
||||
|
||||
/*!
|
||||
\enum switch_timer_flag
|
||||
\enum switch_timer_flag_t
|
||||
\brief Timer related flags
|
||||
<pre>
|
||||
SWITCH_TIMER_FLAG_FREE_POOL = (1 << 0) - Free timer's pool on destruction
|
||||
@@ -454,10 +454,10 @@ SWITCH_TIMER_FLAG_FREE_POOL = (1 << 0) - Free timer's pool on destruction
|
||||
*/
|
||||
typedef enum {
|
||||
SWITCH_TIMER_FLAG_FREE_POOL = (1 << 0),
|
||||
} switch_timer_flag;
|
||||
} switch_timer_flag_t;
|
||||
|
||||
/*!
|
||||
\enum switch_file_flag
|
||||
\enum switch_file_flag_t
|
||||
\brief File flags
|
||||
<pre>
|
||||
SWITCH_FILE_FLAG_READ = (1 << 0) - Open for read
|
||||
@@ -481,11 +481,11 @@ typedef enum {
|
||||
SWITCH_FILE_DATA_DOUBLE = (1 << 6),
|
||||
SWITCH_FILE_DATA_RAW = (1 << 7),
|
||||
SWITCH_FILE_PAUSE = (1 << 8)
|
||||
} switch_file_flag;
|
||||
} switch_file_flag_t;
|
||||
|
||||
typedef enum {
|
||||
SWITCH_IO_FLAG_NOOP = 0,
|
||||
} switch_io_flag;
|
||||
} switch_io_flag_t;
|
||||
|
||||
/* make sure this is synced with the EVENT_NAMES array in switch_event.c
|
||||
also never put any new ones before EVENT_ALL
|
||||
@@ -617,57 +617,57 @@ typedef struct switch_buffer switch_buffer_t;
|
||||
typedef struct switch_codec_settings switch_codec_settings_t;
|
||||
typedef struct switch_config switch_config_t;
|
||||
|
||||
typedef struct switch_io_event_hook_outgoing_channel switch_io_event_hook_outgoing_channel;
|
||||
typedef struct switch_io_event_hook_answer_channel switch_io_event_hook_answer_channel;
|
||||
typedef struct switch_io_event_hook_receive_message switch_io_event_hook_receive_message;
|
||||
typedef struct switch_io_event_hook_queue_event switch_io_event_hook_queue_event;
|
||||
typedef struct switch_io_event_hook_read_frame switch_io_event_hook_read_frame;
|
||||
typedef struct switch_io_event_hook_write_frame switch_io_event_hook_write_frame;
|
||||
typedef struct switch_io_event_hook_kill_channel switch_io_event_hook_kill_channel;
|
||||
typedef struct switch_io_event_hook_waitfor_read switch_io_event_hook_waitfor_read;
|
||||
typedef struct switch_io_event_hook_waitfor_write switch_io_event_hook_waitfor_write;
|
||||
typedef struct switch_io_event_hook_send_dtmf switch_io_event_hook_send_dtmf;
|
||||
typedef struct switch_io_routines switch_io_routines;
|
||||
typedef struct switch_io_event_hooks switch_io_event_hooks;
|
||||
typedef struct switch_io_event_hook_outgoing_channel switch_io_event_hook_outgoing_channel_t;
|
||||
typedef struct switch_io_event_hook_answer_channel switch_io_event_hook_answer_channel_t;
|
||||
typedef struct switch_io_event_hook_receive_message switch_io_event_hook_receive_message_t;
|
||||
typedef struct switch_io_event_hook_queue_event switch_io_event_hook_queue_event_t;
|
||||
typedef struct switch_io_event_hook_read_frame switch_io_event_hook_read_frame_t;
|
||||
typedef struct switch_io_event_hook_write_frame switch_io_event_hook_write_frame_t;
|
||||
typedef struct switch_io_event_hook_kill_channel switch_io_event_hook_kill_channel_t;
|
||||
typedef struct switch_io_event_hook_waitfor_read switch_io_event_hook_waitfor_read_t;
|
||||
typedef struct switch_io_event_hook_waitfor_write switch_io_event_hook_waitfor_write_t;
|
||||
typedef struct switch_io_event_hook_send_dtmf switch_io_event_hook_send_dtmf_t;
|
||||
typedef struct switch_io_routines switch_io_routines_t;
|
||||
typedef struct switch_io_event_hooks switch_io_event_hooks_t;
|
||||
|
||||
typedef struct switch_speech_handle switch_speech_handle;
|
||||
typedef struct switch_directory_handle switch_directory_handle;
|
||||
typedef struct switch_speech_handle switch_speech_handle_t;
|
||||
typedef struct switch_directory_handle switch_directory_handle_t;
|
||||
|
||||
typedef struct switch_loadable_module_interface switch_loadable_module_interface;
|
||||
typedef struct switch_endpoint_interface switch_endpoint_interface;
|
||||
typedef struct switch_timer_interface switch_timer_interface;
|
||||
typedef struct switch_dialplan_interface switch_dialplan_interface;
|
||||
typedef struct switch_codec_interface switch_codec_interface;
|
||||
typedef struct switch_application_interface switch_application_interface;
|
||||
typedef struct switch_api_interface switch_api_interface;
|
||||
typedef struct switch_file_interface switch_file_interface;
|
||||
typedef struct switch_speech_interface switch_speech_interface;
|
||||
typedef struct switch_directory_interface switch_directory_interface;
|
||||
typedef struct switch_loadable_module_interface switch_loadable_module_interface_t;
|
||||
typedef struct switch_endpoint_interface switch_endpoint_interface_t;
|
||||
typedef struct switch_timer_interface switch_timer_interface_t;
|
||||
typedef struct switch_dialplan_interface switch_dialplan_interface_t;
|
||||
typedef struct switch_codec_interface switch_codec_interface_t;
|
||||
typedef struct switch_application_interface switch_application_interface_t;
|
||||
typedef struct switch_api_interface switch_api_interface_t;
|
||||
typedef struct switch_file_interface switch_file_interface_t;
|
||||
typedef struct switch_speech_interface switch_speech_interface_t;
|
||||
typedef struct switch_directory_interface switch_directory_interface_t;
|
||||
|
||||
typedef void (*switch_application_function)(switch_core_session_t *, char *);
|
||||
typedef void (*switch_application_function_t)(switch_core_session_t *, char *);
|
||||
typedef void (*switch_event_callback_t)(switch_event_t *);
|
||||
typedef switch_caller_extension_t *(*switch_dialplan_hunt_function)(switch_core_session_t *);
|
||||
typedef switch_status (*switch_state_handler)(switch_core_session_t *);
|
||||
typedef switch_status (*switch_outgoing_channel_hook)(switch_core_session_t *, switch_caller_profile_t *, switch_core_session_t *);
|
||||
typedef switch_status (*switch_answer_channel_hook)(switch_core_session_t *);
|
||||
typedef switch_status (*switch_receive_message_hook)(switch_core_session_t *, switch_core_session_message_t *);
|
||||
typedef switch_status (*switch_queue_event_hook)(switch_core_session_t *, switch_event_t *);
|
||||
typedef switch_status (*switch_read_frame_hook)(switch_core_session_t *, switch_frame_t **, int, switch_io_flag, int);
|
||||
typedef switch_status (*switch_write_frame_hook)(switch_core_session_t *, switch_frame_t *, int, switch_io_flag, int);
|
||||
typedef switch_status (*switch_kill_channel_hook)(switch_core_session_t *, int);
|
||||
typedef switch_status (*switch_waitfor_read_hook)(switch_core_session_t *, int, int);
|
||||
typedef switch_status (*switch_waitfor_write_hook)(switch_core_session_t *, int, int);
|
||||
typedef switch_status (*switch_send_dtmf_hook)(switch_core_session_t *, char *);
|
||||
typedef switch_status (*switch_api_function)(char *in, char *out, switch_size_t outlen);
|
||||
typedef switch_status (*switch_dtmf_callback_function)(switch_core_session_t *session, char *dtmf, void *buf, unsigned int buflen);
|
||||
typedef int (*switch_core_db_callback_func)(void *pArg, int argc, char **argv, char **columnNames);
|
||||
typedef switch_status (*switch_module_load_t) (switch_loadable_module_interface **, char *);
|
||||
typedef switch_status (*switch_module_reload_t) (void);
|
||||
typedef switch_status (*switch_module_pause_t) (void);
|
||||
typedef switch_status (*switch_module_resume_t) (void);
|
||||
typedef switch_status (*switch_module_status_t) (void);
|
||||
typedef switch_status (*switch_module_runtime_t) (void);
|
||||
typedef switch_status (*switch_module_shutdown_t) (void);
|
||||
typedef switch_caller_extension_t *(*switch_dialplan_hunt_function_t)(switch_core_session_t *);
|
||||
typedef switch_status_t (*switch_state_handler_t)(switch_core_session_t *);
|
||||
typedef switch_status_t (*switch_outgoing_channel_hook_t)(switch_core_session_t *, switch_caller_profile_t *, switch_core_session_t *);
|
||||
typedef switch_status_t (*switch_answer_channel_hook_t)(switch_core_session_t *);
|
||||
typedef switch_status_t (*switch_receive_message_hook_t)(switch_core_session_t *, switch_core_session_message_t *);
|
||||
typedef switch_status_t (*switch_queue_event_hook_t)(switch_core_session_t *, switch_event_t *);
|
||||
typedef switch_status_t (*switch_read_frame_hook_t)(switch_core_session_t *, switch_frame_t **, int, switch_io_flag_t, int);
|
||||
typedef switch_status_t (*switch_write_frame_hook_t)(switch_core_session_t *, switch_frame_t *, int, switch_io_flag_t, int);
|
||||
typedef switch_status_t (*switch_kill_channel_hook_t)(switch_core_session_t *, int);
|
||||
typedef switch_status_t (*switch_waitfor_read_hook_t)(switch_core_session_t *, int, int);
|
||||
typedef switch_status_t (*switch_waitfor_write_hook_t)(switch_core_session_t *, int, int);
|
||||
typedef switch_status_t (*switch_send_dtmf_hook_t)(switch_core_session_t *, char *);
|
||||
typedef switch_status_t (*switch_api_function_t)(char *in, char *out, switch_size_t outlen);
|
||||
typedef switch_status_t (*switch_dtmf_callback_function_t)(switch_core_session_t *session, char *dtmf, void *buf, unsigned int buflen);
|
||||
typedef int (*switch_core_db_callback_func_t)(void *pArg, int argc, char **argv, char **columnNames);
|
||||
typedef switch_status_t (*switch_module_load_t) (switch_loadable_module_interface_t **, char *);
|
||||
typedef switch_status_t (*switch_module_reload_t) (void);
|
||||
typedef switch_status_t (*switch_module_pause_t) (void);
|
||||
typedef switch_status_t (*switch_module_resume_t) (void);
|
||||
typedef switch_status_t (*switch_module_status_t) (void);
|
||||
typedef switch_status_t (*switch_module_runtime_t) (void);
|
||||
typedef switch_status_t (*switch_module_shutdown_t) (void);
|
||||
|
||||
|
||||
/* things we don't deserve to know about */
|
||||
|
||||
@@ -62,7 +62,7 @@ BEGIN_EXTERN_C
|
||||
atoi(expr))) ? SWITCH_TRUE : SWITCH_FALSE
|
||||
|
||||
|
||||
SWITCH_DECLARE(switch_status) switch_socket_recvfrom(switch_sockaddr_t *from, switch_socket_t *sock, int32_t flags, char *buf, switch_size_t *len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_socket_recvfrom(switch_sockaddr_t *from, switch_socket_t *sock, int32_t flags, char *buf, switch_size_t *len);
|
||||
|
||||
/*!
|
||||
\brief Return a printable name of a switch_priority_t
|
||||
@@ -157,7 +157,7 @@ SWITCH_DECLARE(unsigned int) switch_separate_string(char *buf, char delim, char
|
||||
\param pool the memory pool to use
|
||||
\return SWITCH_STATUS_SUCCESS when successful
|
||||
*/
|
||||
SWITCH_DECLARE(switch_status) switch_socket_create_pollfd(switch_pollfd_t *poll, switch_socket_t *sock, switch_int16_t flags, switch_memory_pool_t *pool);
|
||||
SWITCH_DECLARE(switch_status_t) switch_socket_create_pollfd(switch_pollfd_t *poll, switch_socket_t *sock, switch_int16_t flags, switch_memory_pool_t *pool);
|
||||
|
||||
/*!
|
||||
\brief Wait for a socket
|
||||
@@ -174,7 +174,7 @@ SWITCH_DECLARE(int) switch_socket_waitfor(switch_pollfd_t *poll, int ms);
|
||||
SWITCH_DECLARE(char *) switch_cut_path(char *in);
|
||||
|
||||
SWITCH_DECLARE(char *) switch_string_replace(const char *string, const char *search, const char *replace);
|
||||
SWITCH_DECLARE(switch_status) switch_string_match(const char *string, size_t string_len, const char *search, size_t search_len);
|
||||
SWITCH_DECLARE(switch_status_t) switch_string_match(const char *string, size_t string_len, const char *search, size_t search_len);
|
||||
|
||||
#define SWITCH_READ_ACCEPTABLE(status) status == SWITCH_STATUS_SUCCESS || status == SWITCH_STATUS_BREAK
|
||||
|
||||
|
||||
Reference in New Issue
Block a user