mrcp_application.h File Reference

MRCP User Level Application Interface. More...

#include "mrcp_client_types.h"
#include "mpf_rtp_descriptor.h"
#include "mpf_stream.h"

Go to the source code of this file.

Data Structures

struct  mrcp_sig_message_t
struct  mrcp_app_message_t
struct  mrcp_app_message_dispatcher_t

Typedefs

typedef
typedefAPT_BEGIN_EXTERN_C
struct mrcp_app_message_t 
mrcp_app_message_t
typedef struct mrcp_sig_message_t mrcp_sig_message_t
typedef struct
mrcp_app_message_dispatcher_t 
mrcp_app_message_dispatcher_t
typedef apt_bool_t(* mrcp_app_message_handler_f )(const mrcp_app_message_t *app_message)

Enumerations

enum  mrcp_sig_message_type_e { MRCP_SIG_MESSAGE_TYPE_REQUEST, MRCP_SIG_MESSAGE_TYPE_RESPONSE, MRCP_SIG_MESSAGE_TYPE_EVENT }
enum  mrcp_sig_status_code_e { MRCP_SIG_STATUS_CODE_SUCCESS, MRCP_SIG_STATUS_CODE_FAILURE, MRCP_SIG_STATUS_CODE_TERMINATE, MRCP_SIG_STATUS_CODE_CANCEL }
enum  mrcp_sig_command_e {
  MRCP_SIG_COMMAND_SESSION_UPDATE, MRCP_SIG_COMMAND_SESSION_TERMINATE, MRCP_SIG_COMMAND_CHANNEL_ADD, MRCP_SIG_COMMAND_CHANNEL_REMOVE,
  MRCP_SIG_COMMAND_RESOURCE_DISCOVER
}
enum  mrcp_sig_event_e { MRCP_SIG_EVENT_TERMINATE }
enum  mrcp_app_message_type_e { MRCP_APP_MESSAGE_TYPE_SIGNALING, MRCP_APP_MESSAGE_TYPE_CONTROL }

Functions

mrcp_application_tmrcp_application_create (const mrcp_app_message_handler_f handler, void *obj, apr_pool_t *pool)
apt_bool_t mrcp_application_destroy (mrcp_application_t *application)
void * mrcp_application_object_get (const mrcp_application_t *application)
const apt_dir_layout_tmrcp_application_dir_layout_get (const mrcp_application_t *application)
mrcp_session_tmrcp_application_session_create (mrcp_application_t *application, const char *profile, void *obj)
apr_pool_t * mrcp_application_session_pool_get (const mrcp_session_t *session)
const apt_str_tmrcp_application_session_id_get (const mrcp_session_t *session)
int mrcp_application_session_response_code_get (const mrcp_session_t *session)
void * mrcp_application_session_object_get (const mrcp_session_t *session)
void mrcp_application_session_object_set (mrcp_session_t *session, void *obj)
void mrcp_application_session_name_set (mrcp_session_t *session, const char *name)
apt_bool_t mrcp_application_session_update (mrcp_session_t *session)
apt_bool_t mrcp_application_session_terminate (mrcp_session_t *session)
apt_bool_t mrcp_application_session_destroy (mrcp_session_t *session)
mrcp_channel_tmrcp_application_channel_create (mrcp_session_t *session, mrcp_resource_id resource_id, mpf_termination_t *termination, mpf_rtp_termination_descriptor_t *rtp_descriptor, void *obj)
void * mrcp_application_channel_object_get (const mrcp_channel_t *channel)
mpf_rtp_termination_descriptor_tmrcp_application_rtp_descriptor_get (const mrcp_channel_t *channel)
const mpf_codec_descriptor_tmrcp_application_source_descriptor_get (const mrcp_channel_t *channel)
const mpf_codec_descriptor_tmrcp_application_sink_descriptor_get (const mrcp_channel_t *channel)
const mpf_audio_stream_tmrcp_application_audio_stream_get (const mrcp_channel_t *channel)
apt_bool_t mrcp_application_channel_add (mrcp_session_t *session, mrcp_channel_t *channel)
mrcp_message_tmrcp_application_message_create (mrcp_session_t *session, mrcp_channel_t *channel, mrcp_method_id method_id)
apt_bool_t mrcp_application_message_send (mrcp_session_t *session, mrcp_channel_t *channel, mrcp_message_t *message)
apt_bool_t mrcp_application_channel_remove (mrcp_session_t *session, mrcp_channel_t *channel)
apt_bool_t mrcp_application_resource_discover (mrcp_session_t *session)
apt_bool_t mrcp_application_message_dispatch (const mrcp_app_message_dispatcher_t *dispatcher, const mrcp_app_message_t *app_message)
mpf_termination_tmrcp_application_audio_termination_create (mrcp_session_t *session, const mpf_audio_stream_vtable_t *stream_vtable, mpf_stream_capabilities_t *capabilities, void *obj)
mpf_termination_tmrcp_application_source_termination_create (mrcp_session_t *session, const mpf_audio_stream_vtable_t *stream_vtable, mpf_codec_descriptor_t *codec_descriptor, void *obj)
mpf_termination_tmrcp_application_sink_termination_create (mrcp_session_t *session, const mpf_audio_stream_vtable_t *stream_vtable, mpf_codec_descriptor_t *codec_descriptor, void *obj)

Detailed Description

MRCP User Level Application Interface.


Typedef Documentation

MRCP application message dispatcher declaration

MRCP application message handler

typedef typedefAPT_BEGIN_EXTERN_C struct mrcp_app_message_t mrcp_app_message_t

MRCP application message declaration

MRCP signaling message declaration


Enumeration Type Documentation

Enumeration of MRCP application message types

Enumerator:
MRCP_APP_MESSAGE_TYPE_SIGNALING 

signaling message type

MRCP_APP_MESSAGE_TYPE_CONTROL 

control message type

Enumeration of MRCP signaling commands (requests/responses)

Enumeration of MRCP signaling events

Enumeration of MRCP signaling message types

Enumerator:
MRCP_SIG_MESSAGE_TYPE_REQUEST 

request message

MRCP_SIG_MESSAGE_TYPE_RESPONSE 

response message

MRCP_SIG_MESSAGE_TYPE_EVENT 

event message

Enumeration of MRCP signaling status codes

Enumerator:
MRCP_SIG_STATUS_CODE_SUCCESS 

indicates success

MRCP_SIG_STATUS_CODE_FAILURE 

request failed

MRCP_SIG_STATUS_CODE_TERMINATE 

request failed, session/channel/connection unexpectedly terminated

MRCP_SIG_STATUS_CODE_CANCEL 

request cancelled


Function Documentation

const mpf_audio_stream_t* mrcp_application_audio_stream_get ( const mrcp_channel_t channel  ) 

Get associated audio stream.

Parameters:
channel the channel to get associated stream from
mpf_termination_t* mrcp_application_audio_termination_create ( mrcp_session_t session,
const mpf_audio_stream_vtable_t stream_vtable,
mpf_stream_capabilities_t capabilities,
void *  obj 
)

Create audio termination

Parameters:
session the session to create termination for
stream_vtable the virtual table of audio stream
capabilities the capabilities of the stream
obj the external object
apt_bool_t mrcp_application_channel_add ( mrcp_session_t session,
mrcp_channel_t channel 
)

Send channel add request.

Parameters:
session the session to create channel for
channel the control channel
mrcp_channel_t* mrcp_application_channel_create ( mrcp_session_t session,
mrcp_resource_id  resource_id,
mpf_termination_t termination,
mpf_rtp_termination_descriptor_t rtp_descriptor,
void *  obj 
)

Create control channel.

Parameters:
session the session to create channel for
resource_id the resource identifier of the channel
termination the media termination
rtp_descriptor the RTP termination descriptor (NULL by default)
obj the external object
void* mrcp_application_channel_object_get ( const mrcp_channel_t channel  ) 

Get external object associated with the channel.

Parameters:
channel the channel to get object from
apt_bool_t mrcp_application_channel_remove ( mrcp_session_t session,
mrcp_channel_t channel 
)

Remove channel.

Parameters:
session the session to remove channel from
channel the control channel to remove
mrcp_application_t* mrcp_application_create ( const mrcp_app_message_handler_f  handler,
void *  obj,
apr_pool_t *  pool 
)

Create application instance.

Parameters:
handler the event handler
obj the external object
pool the pool to allocate memory from
apt_bool_t mrcp_application_destroy ( mrcp_application_t application  ) 

Destroy application instance.

Parameters:
application the application to destroy
const apt_dir_layout_t* mrcp_application_dir_layout_get ( const mrcp_application_t application  ) 

Get dir layout structure.

Parameters:
application the application to get dir layout from
mrcp_message_t* mrcp_application_message_create ( mrcp_session_t session,
mrcp_channel_t channel,
mrcp_method_id  method_id 
)

Create MRCP message.

Parameters:
session the session
channel the control channel
method_id the method identifier of MRCP message
apt_bool_t mrcp_application_message_dispatch ( const mrcp_app_message_dispatcher_t dispatcher,
const mrcp_app_message_t app_message 
)

Dispatch application message.

Parameters:
dispatcher the dispatcher inteface
app_message the message to dispatch
apt_bool_t mrcp_application_message_send ( mrcp_session_t session,
mrcp_channel_t channel,
mrcp_message_t message 
)

Send MRCP message.

Parameters:
session the session
channel the control channel
message the MRCP message to send
void* mrcp_application_object_get ( const mrcp_application_t application  ) 

Get external object associated with the application.

Parameters:
application the application to get object from
apt_bool_t mrcp_application_resource_discover ( mrcp_session_t session  ) 

Discover resources.

Parameters:
session the session to use as communication object
mpf_rtp_termination_descriptor_t* mrcp_application_rtp_descriptor_get ( const mrcp_channel_t channel  ) 

Get RTP termination descriptor.

Parameters:
channel the channel to get descriptor from
mrcp_session_t* mrcp_application_session_create ( mrcp_application_t application,
const char *  profile,
void *  obj 
)

Create session.

Parameters:
application the entire application
profile the name of the profile to use
obj the external object
Returns:
the created session instance
apt_bool_t mrcp_application_session_destroy ( mrcp_session_t session  ) 

Destroy client session (session must be terminated prior to destroy).

Parameters:
session the session to destroy
const apt_str_t* mrcp_application_session_id_get ( const mrcp_session_t session  ) 

Get session identifier.

Parameters:
session the session to get identifier of
void mrcp_application_session_name_set ( mrcp_session_t session,
const char *  name 
)

Set name of the session (informative only used for debugging).

Parameters:
session the session to set name for
name the name to set
void* mrcp_application_session_object_get ( const mrcp_session_t session  ) 

Get external object associated with the session.

Parameters:
session the session to get object from
void mrcp_application_session_object_set ( mrcp_session_t session,
void *  obj 
)

Set (associate) external object to the session.

Parameters:
session the session to set object for
obj the object to set
apr_pool_t* mrcp_application_session_pool_get ( const mrcp_session_t session  ) 

Get memory pool the session object is created out of.

Parameters:
session the session to get pool from
int mrcp_application_session_response_code_get ( const mrcp_session_t session  ) 

Get SIP or RTSP response code.

Parameters:
session the session to use
apt_bool_t mrcp_application_session_terminate ( mrcp_session_t session  ) 

Send session termination request.

Parameters:
session the session to terminate
apt_bool_t mrcp_application_session_update ( mrcp_session_t session  ) 

Send session update request.

Parameters:
session the session to update
const mpf_codec_descriptor_t* mrcp_application_sink_descriptor_get ( const mrcp_channel_t channel  ) 

Get codec descriptor of sink stream.

Parameters:
channel the channel to get descriptor from
mpf_termination_t* mrcp_application_sink_termination_create ( mrcp_session_t session,
const mpf_audio_stream_vtable_t stream_vtable,
mpf_codec_descriptor_t codec_descriptor,
void *  obj 
)

Create sink media termination

Parameters:
session the session to create termination for
stream_vtable the virtual table of audio stream
codec_descriptor the descriptor of audio stream (NULL by default)
obj the external object
Deprecated:
See also:
mrcp_application_audio_termination_create()
const mpf_codec_descriptor_t* mrcp_application_source_descriptor_get ( const mrcp_channel_t channel  ) 

Get codec descriptor of source stream.

Parameters:
channel the channel to get descriptor from
mpf_termination_t* mrcp_application_source_termination_create ( mrcp_session_t session,
const mpf_audio_stream_vtable_t stream_vtable,
mpf_codec_descriptor_t codec_descriptor,
void *  obj 
)

Create source media termination

Parameters:
session the session to create termination for
stream_vtable the virtual table of audio stream
codec_descriptor the descriptor of audio stream (NULL by default)
obj the external object
Deprecated:
See also:
mrcp_application_audio_termination_create()
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Generated on 25 Mar 2013 for UniMRCP by  doxygen 1.6.1