UniMRCP  1.5.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Data Structures | Typedefs | Functions
rtsp_client.h File Reference

RTSP Client. More...

#include "apt_task.h"
#include "rtsp_message.h"

Go to the source code of this file.

Data Structures

struct  rtsp_client_vtable_t
 

Typedefs

typedef
typedefAPT_BEGIN_EXTERN_C
struct rtsp_client_t 
rtsp_client_t
 
typedef struct
rtsp_client_session_t 
rtsp_client_session_t
 
typedef struct rtsp_client_vtable_t rtsp_client_vtable_t
 

Functions

rtsp_client_trtsp_client_create (const char *id, apr_size_t max_connection_count, apr_size_t request_timeout, void *obj, const rtsp_client_vtable_t *handler, apr_pool_t *pool)
 
apt_bool_t rtsp_client_destroy (rtsp_client_t *client)
 
apt_bool_t rtsp_client_start (rtsp_client_t *client)
 
apt_bool_t rtsp_client_terminate (rtsp_client_t *client)
 
apt_task_trtsp_client_task_get (const rtsp_client_t *client)
 
void * rtsp_client_object_get (const rtsp_client_t *client)
 
rtsp_client_session_trtsp_client_session_create (rtsp_client_t *client, const char *server_ip, apr_port_t server_port, const char *resource_location)
 
void rtsp_client_session_destroy (rtsp_client_session_t *session)
 
apt_bool_t rtsp_client_session_terminate (rtsp_client_t *client, rtsp_client_session_t *session)
 
apt_bool_t rtsp_client_session_request (rtsp_client_t *client, rtsp_client_session_t *session, rtsp_message_t *message)
 
void * rtsp_client_session_object_get (const rtsp_client_session_t *session)
 
void rtsp_client_session_object_set (rtsp_client_session_t *session, void *obj)
 
const apt_str_trtsp_client_session_id_get (const rtsp_client_session_t *session)
 

Detailed Description

RTSP Client.

Typedef Documentation

Opaque RTSP client session declaration

typedef typedefAPT_BEGIN_EXTERN_C struct rtsp_client_t rtsp_client_t

Opaque RTSP client declaration

RTSP client vtable declaration

Function Documentation

rtsp_client_t* rtsp_client_create ( const char *  id,
apr_size_t  max_connection_count,
apr_size_t  request_timeout,
void *  obj,
const rtsp_client_vtable_t handler,
apr_pool_t *  pool 
)

Create RTSP client.

Parameters
idthe identifier of the client
max_connection_countthe number of max RTSP connections
request_timeoutthe request timeout to set
objthe external object to send event to
handlerthe response/event handler
poolthe pool to allocate memory from
apt_bool_t rtsp_client_destroy ( rtsp_client_t client)

Destroy RTSP client.

Parameters
clientthe client to destroy
void* rtsp_client_object_get ( const rtsp_client_t client)

Get external object.

Parameters
clientthe client to get object from
rtsp_client_session_t* rtsp_client_session_create ( rtsp_client_t client,
const char *  server_ip,
apr_port_t  server_port,
const char *  resource_location 
)

Create RTSP session.

Parameters
clientthe client to create session for
server_ipthe IP address of RTSP server
server_portthe port of RTSP server
resource_locationthe location of RTSP resource (path in RTSP URI)
void rtsp_client_session_destroy ( rtsp_client_session_t session)

Destroy RTSP session.

Parameters
sessionthe session to destroy
const apt_str_t* rtsp_client_session_id_get ( const rtsp_client_session_t session)

Get the session identifier.

Parameters
sessionthe session to get identifier from
void* rtsp_client_session_object_get ( const rtsp_client_session_t session)

Get object associated with the session.

Parameters
sessionthe session to get object from
void rtsp_client_session_object_set ( rtsp_client_session_t session,
void *  obj 
)

Set object associated with the session.

Parameters
sessionthe session to set object for
objthe object to set
apt_bool_t rtsp_client_session_request ( rtsp_client_t client,
rtsp_client_session_t session,
rtsp_message_t message 
)

Send RTSP message.

Parameters
clientthe client to use
sessionthe session to send RTSP request for
messagethe RTSP request to send
apt_bool_t rtsp_client_session_terminate ( rtsp_client_t client,
rtsp_client_session_t session 
)

Terminate RTSP session.

Parameters
clientthe client to use
sessionthe session to terminate
apt_bool_t rtsp_client_start ( rtsp_client_t client)

Start client and wait for incoming requests.

Parameters
clientthe client to start
apt_task_t* rtsp_client_task_get ( const rtsp_client_t client)

Get task.

Parameters
clientthe client to get task from
apt_bool_t rtsp_client_terminate ( rtsp_client_t client)

Terminate client.

Parameters
clientthe client to terminate