]> sjero.net Git - linphone/blob - tools/xml2lpc.h
Aac-eld add missing header according to RFC3640 3.3.6
[linphone] / tools / xml2lpc.h
1 /*
2 linphone
3 Copyright (C) 2012 Belledonne Communications SARL
4
5 This program is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License
7 as published by the Free Software Foundation; either version 2
8 of the License, or (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
18 */
19
20 #ifndef XML2LPC_H_
21 #define XML2LPC_H_
22
23 #include "lpconfig.h"
24
25 typedef struct _xml2lpc_context xml2lpc_context;
26
27 typedef enum _xml2lpc_log_level {
28         XML2LPC_DEBUG = 0,
29         XML2LPC_MESSAGE,
30         XML2LPC_WARNING,
31         XML2LPC_ERROR
32 } xml2lpc_log_level;
33
34 typedef void(*xml2lpc_function)(void *ctx, xml2lpc_log_level level, const char *fmt, va_list list);
35
36 xml2lpc_context* xml2lpc_context_new(xml2lpc_function cbf, void *ctx);
37 void xml2lpc_context_destroy(xml2lpc_context*);
38
39 int xml2lpc_set_xml_file(xml2lpc_context* context, const char *filename);
40 int xml2lpc_set_xml_fd(xml2lpc_context* context, int fd);
41 int xml2lpc_set_xml_string(xml2lpc_context* context, const char *content);
42
43 int xml2lpc_set_xsd_file(xml2lpc_context* context, const char *filename);
44 int xml2lpc_set_xsd_fd(xml2lpc_context* context, int fd);
45 int xml2lpc_set_xsd_string(xml2lpc_context* context, const char *content);
46
47 int xml2lpc_validate(xml2lpc_context *context);
48 int xml2lpc_convert(xml2lpc_context *context, LpConfig *lpc);
49
50
51
52 #endif //XML2LPC_H_