Lines Matching refs:xml

13 #include "xml-utils.h"
84 locuri = get_node(ctx->xml, node, "Item/Target/LocURI");
88 uri = xml_node_get_text(ctx->xml, locuri);
91 xml_node_get_text_free(ctx->xml, uri);
101 node = xml_node_create(ctx->xml, parent, NULL, element);
104 xml_node_create_text(ctx->xml, node, NULL, "LocURI", uri);
116 "DevId from devinfo.xml is not available - cannot use OMA DM");
120 syncml = xml_node_create_root(ctx->xml, "SYNCML:SYNCML1.2", NULL, &ns,
123 synchdr = xml_node_create(ctx->xml, syncml, NULL, "SyncHdr");
124 xml_node_create_text(ctx->xml, synchdr, NULL, "VerDTD", "1.2");
125 xml_node_create_text(ctx->xml, synchdr, NULL, "VerProto", "DM/1.2");
126 xml_node_create_text(ctx->xml, synchdr, NULL, "SessionID", "1");
127 xml_node_create_text(ctx->xml, synchdr, NULL, "MsgID", int2str(msgid));
139 xml_node_create_text(ctx->xml, parent, NULL, "CmdID", int2str(cmdid));
148 node = xml_node_create(ctx->xml, parent, NULL, "Alert");
152 xml_node_create_text(ctx->xml, node, NULL, "Data", int2str(data));
164 node = xml_node_create(ctx->xml, parent, NULL, "Status");
168 xml_node_create_text(ctx->xml, node, NULL, "MsgRef", int2str(msgref));
170 xml_node_create_text(ctx->xml, node, NULL, "CmdRef",
172 xml_node_create_text(ctx->xml, node, NULL, "Cmd", cmd);
173 xml_node_create_text(ctx->xml, node, NULL, "Data", int2str(data));
175 xml_node_create_text(ctx->xml, node, NULL, "TargetRef",
189 node = xml_node_create(ctx->xml, parent, NULL, "Results");
194 xml_node_create_text(ctx->xml, node, NULL, "MsgRef", int2str(msgref));
195 xml_node_create_text(ctx->xml, node, NULL, "CmdRef", int2str(cmdref));
208 fnode = node_from_file(ctx->xml, fname);
211 tnds = mo_to_tnds(ctx->xml, fnode, 0, urn, "syncml:dmddf1.2");
212 xml_node_free(ctx->xml, fnode);
216 str = xml_node_to_str(ctx->xml, tnds);
217 xml_node_free(ctx->xml, tnds);
231 item = xml_node_create(ctx->xml, parent, NULL, "Item");
233 node = xml_node_create(ctx->xml, item, NULL, "Meta");
234 xml_node_create_text_ns(ctx->xml, node, "syncml:metinf", "Format",
236 xml_node_create_text_ns(ctx->xml, node, "syncml:metinf", "Type",
238 xml_node_create_text(ctx->xml, item, NULL, "Data", data);
249 info = node_from_file(ctx->xml, "devinfo.xml");
251 wpa_printf(MSG_INFO, "Could not read devinfo.xml");
255 replace = xml_node_create(ctx->xml, parent, NULL, "Replace");
257 xml_node_free(ctx->xml, info);
262 xml_node_for_each_child(ctx->xml, child, info) {
263 xml_node_for_each_check(ctx->xml, child);
264 name = xml_node_get_localname(ctx->xml, child);
266 txt = xml_node_get_text(ctx->xml, child);
269 xml_node_get_text_free(ctx->xml, txt);
273 xml_node_free(ctx->xml, info);
287 item = xml_node_create(ctx->xml, node, NULL, "Item");
289 node = xml_node_create(ctx->xml, item, NULL, "Meta");
291 xml_node_create_text_ns(ctx->xml, node, "syncml:metinf", "Type", buf);
292 xml_node_create_text_ns(ctx->xml, node, "syncml:metinf", "Format",
293 "xml");
294 xml_node_create_text(ctx->xml, item, NULL, "Data", data);
309 syncbody = xml_node_create(ctx->xml, syncml, NULL, "SyncBody");
311 xml_node_free(ctx->xml, syncml);
318 str = mo_str(ctx, NULL, "devdetail.xml");
320 xml_node_free(ctx->xml, syncml);
330 xml_node_create(ctx->xml, syncbody, NULL, "Final");
396 node = get_node(ctx->xml, exec, "Item/Data");
402 data = xml_node_get_text(ctx->xml, node);
411 xml_node_get_text_free(ctx->xml, data);
434 node = get_node(ctx->xml, exec, "Item/Data");
440 data = xml_node_get_text(ctx->xml, node);
446 getcert = xml_node_from_buf(ctx->xml, data);
447 xml_node_get_text_free(ctx->xml, data);
456 name = xml_node_get_localname(ctx->xml, getcert);
465 xml_node_free(ctx->xml, getcert);
540 pps_node = get_node(ctx->xml, pps, pos);
554 pps_node = get_node(ctx->xml, pps, uri);
579 pps_node = xml_node_create(ctx->xml, pps_node, NULL, upos);
589 node = get_node(ctx->xml, add, "Item/Meta/Type");
592 type = xml_node_get_text(ctx->xml, node);
599 os_strstr(type, "application/vnd.syncml.dmtnds+xml");
602 node = get_node(ctx->xml, add, "Item/Data");
609 data = xml_node_get_text(ctx->xml, node);
619 tnds = xml_node_from_buf(ctx->xml, data);
620 xml_node_get_text_free(ctx->xml, data);
628 unode = tnds_to_mo(ctx->xml, tnds);
629 xml_node_free(ctx->xml, tnds);
638 xml_node_add_child(ctx->xml, pps_node, unode);
664 node = get_node(ctx->xml, add, "Item/Target/LocURI");
669 locuri = xml_node_get_text(ctx->xml, node);
677 xml_node_get_text_free(ctx->xml, locuri);
681 node = get_node(ctx->xml, add, "Item/Data");
684 xml_node_get_text_free(ctx->xml, locuri);
691 xml_node_get_text_free(ctx->xml, locuri);
698 xml_node_get_text_free(ctx->xml, locuri);
770 pps_node = get_node(ctx->xml, pps, pos);
777 node = get_node(ctx->xml, replace, "Item/Meta/Type");
780 type = xml_node_get_text(ctx->xml, node);
787 os_strstr(type, "application/vnd.syncml.dmtnds+xml");
790 node = get_node(ctx->xml, replace, "Item/Data");
797 data = xml_node_get_text(ctx->xml, node);
807 tnds = xml_node_from_buf(ctx->xml, data);
808 xml_node_get_text_free(ctx->xml, data);
816 unode = tnds_to_mo(ctx->xml, tnds);
817 xml_node_free(ctx->xml, tnds);
826 parent = xml_node_get_parent(ctx->xml, pps_node);
827 xml_node_detach(ctx->xml, pps_node);
828 xml_node_add_child(ctx->xml, parent, unode);
830 xml_node_set_text(ctx->xml, pps_node, data);
831 xml_node_get_text_free(ctx->xml, data);
890 pps_node = get_node(ctx->xml, pps, pos);
897 name = xml_node_get_localname(ctx->xml, pps_node);
911 *value = xml_node_get_text(ctx->xml, pps_node);
925 cnode = get_node(ctx->xml, node, "CmdID");
929 str = xml_node_get_text(ctx->xml, cnode);
933 xml_node_get_text_free(ctx->xml, str);
949 str = xml_node_to_str(ctx->xml, syncml);
950 xml_node_free(ctx->xml, syncml);
958 res = http_post(ctx->http, url, str, "application/vnd.syncml.dm+xml",
979 resp = xml_node_from_buf(ctx->xml, res);
1010 name = xml_node_get_localname(ctx->xml, resp);
1016 hdr = get_node(ctx->xml, resp, "SyncHdr");
1017 body = get_node(ctx->xml, resp, "SyncBody");
1023 xml_node_for_each_child(ctx->xml, child, hdr) {
1024 xml_node_for_each_check(ctx->xml, child);
1025 name = xml_node_get_localname(ctx->xml, child);
1028 tmp = xml_node_get_text(ctx->xml, child);
1031 xml_node_get_text_free(ctx->xml, tmp);
1033 tmp = xml_node_get_text(ctx->xml, child);
1036 xml_node_get_text_free(ctx->xml, tmp);
1050 syncbody = xml_node_create(ctx->xml, syncml, NULL, "SyncBody");
1055 xml_node_for_each_child(ctx->xml, child, body) {
1056 xml_node_for_each_check(ctx->xml, child);
1058 name = xml_node_get_localname(ctx->xml, child);
1110 xml_node_get_text_free(ctx->xml, value);
1133 xml_node_free(ctx->xml, syncml);
1140 xml_node_free(ctx->xml, syncml);
1145 xml_node_create(ctx->xml, syncbody, NULL, "Final");
1182 xml_node_free(ctx->xml, resp);
1227 xml_node_free(ctx->xml, resp);
1277 xml_node_free(ctx->xml, resp);
1324 xml_node_free(ctx->xml, resp);
1347 pps = node_from_file(ctx->xml, pps_fname);
1354 add = node_from_file(ctx->xml, add_fname);
1358 xml_node_free(ctx->xml, pps);
1365 xml_node_free(ctx->xml, pps);
1366 xml_node_free(ctx->xml, add);
1378 pps = node_from_file(ctx->xml, pps_fname);
1385 replace = node_from_file(ctx->xml, replace_fname);
1389 xml_node_free(ctx->xml, pps);
1396 xml_node_free(ctx->xml, pps);
1397 xml_node_free(ctx->xml, replace);