UniMRCP  1.3.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
mrcp_sig_agent.h
Go to the documentation of this file.
1 /*
2  * Copyright 2008-2014 Arsen Chaloyan
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  * $Id: mrcp_sig_agent.h 2253 2014-11-21 02:57:19Z achaloyan@gmail.com $
17  */
18 
19 #ifndef MRCP_SIG_AGENT_H
20 #define MRCP_SIG_AGENT_H
21 
22 /**
23  * @file mrcp_sig_agent.h
24  * @brief Abstract MRCP Signaling Agent
25  */
26 
27 #include <apr_network_io.h>
28 #include <apr_tables.h>
29 #include "mrcp_sig_types.h"
30 #include "apt_task.h"
31 
33 
34 /** Signaling settings */
36  /** Server IP address */
37  char *server_ip;
38  /** Server port */
39  apr_port_t server_port;
40  /** Server SIP user name (v2 only) */
41  char *user_name;
42  /** Resource location (v1 only) */
44  /** Map of the MRCP resource names (v1 only) */
45  apr_table_t *resource_map;
46  /** Force destination IP address. Should be used only in case
47  SDP contains incorrect connection address (local IP address behind NAT) */
49  /** Optional feature tags */
50  char *feature_tags;
51 };
52 
53 /** MRCP signaling agent */
55  /** Agent identifier */
56  const char *id;
57  /** Memory pool to allocate memory from */
58  apr_pool_t *pool;
59  /** External object associated with agent */
60  void *obj;
61  /** Parent object (client/server) */
62  void *parent;
63  /** MRCP resource factory */
65  /** Task interface */
67  /** Task message pool used to allocate signaling agent messages */
69 
70  /** Virtual create_server_session */
71  mrcp_session_t* (*create_server_session)(mrcp_sig_agent_t *signaling_agent);
72  /** Virtual create_client_session */
74 };
75 
76 /** Create signaling agent. */
77 MRCP_DECLARE(mrcp_sig_agent_t*) mrcp_signaling_agent_create(const char *id, void *obj, apr_pool_t *pool);
78 
79 /** Create factory of signaling agents. */
81 
82 /** Add signaling agent to factory. */
84 
85 /** Determine whether factory is empty. */
87 
88 /** Select next available signaling agent. */
90 
91 /** Allocate MRCP signaling settings. */
93 
94 
96 
97 #endif /* MRCP_SIG_AGENT_H */