Browse code

jansson: Add en-/decode to/from xavp

Nested objects/arrays are not supported with the exception of decoding a
root array with only objects as items to multiple xavps.

Alex Hermann authored on 03/03/2017 14:39:42
Showing 1 changed files
... ...
@@ -33,5 +33,7 @@ int janssonmod_array_size(struct sip_msg* msg, char* json_in,
33 33
 		char* path_in, char* dst);
34 34
 int janssonmod_get_helper(sip_msg_t* msg, str *path_s, str *src_s,
35 35
 		pv_spec_t *dst_pv);
36
+int jansson_xdecode(struct sip_msg* msg, char* src_in, char* xavp_in);
37
+int jansson_xencode(struct sip_msg* msg, char* xavp, char* dst);
36 38
 
37 39
 #endif
Browse code

jansson: exported jansson_get(...) to kemi framework

- jansson.get(...)

Daniel-Constantin Mierla authored on 22/08/2018 14:49:32
Showing 1 changed files
... ...
@@ -31,5 +31,7 @@ int janssonmod_set(unsigned int append, struct sip_msg* msg, char* type_in,
31 31
 		char* path_in, char* value_in, char* result);
32 32
 int janssonmod_array_size(struct sip_msg* msg, char* json_in,
33 33
 		char* path_in, char* dst);
34
+int janssonmod_get_helper(sip_msg_t* msg, str *path_s, str *src_s,
35
+		pv_spec_t *dst_pv);
34 36
 
35 37
 #endif
Browse code

core, lib, modules: updated include paths for header files

Daniel-Constantin Mierla authored on 07/12/2016 11:07:22
Showing 1 changed files
... ...
@@ -23,7 +23,7 @@
23 23
 #ifndef _JANSSON_FUNCS_H_
24 24
 #define _JANSSON_FUNCS_H_
25 25
 
26
-#include "../../parser/msg_parser.h"
26
+#include "../../core/parser/msg_parser.h"
27 27
 
28 28
 int janssonmod_get(struct sip_msg* msg, char* path_in, char* json_in,
29 29
 		char* result);
Browse code

core, lib, modules: restructured source code tree

- new folder src/ to hold the source code for main project applications
- main.c is in src/
- all core files are subfolder are in src/core/
- modules are in src/modules/
- libs are in src/lib/
- application Makefiles are in src/
- application binary is built in src/ (src/kamailio)

Daniel-Constantin Mierla authored on 07/12/2016 11:03:51
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,35 @@
1
+/**
2
+ * Copyright (C) 2011 Flowroute LLC (flowroute.com)
3
+ *
4
+ * This file is part of Kamailio, a free SIP server.
5
+ *
6
+ * This file is free software; you can redistribute it and/or modify
7
+ * it under the terms of the GNU General Public License as published by
8
+ * the Free Software Foundation; either version 2 of the License, or
9
+ * (at your option) any later version
10
+ *
11
+ *
12
+ * This file is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
+ * GNU General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU General Public License
18
+ * along with this program; if not, write to the Free Software
19
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
20
+ *
21
+ */
22
+
23
+#ifndef _JANSSON_FUNCS_H_
24
+#define _JANSSON_FUNCS_H_
25
+
26
+#include "../../parser/msg_parser.h"
27
+
28
+int janssonmod_get(struct sip_msg* msg, char* path_in, char* json_in,
29
+		char* result);
30
+int janssonmod_set(unsigned int append, struct sip_msg* msg, char* type_in,
31
+		char* path_in, char* value_in, char* result);
32
+int janssonmod_array_size(struct sip_msg* msg, char* json_in,
33
+		char* path_in, char* dst);
34
+
35
+#endif