libnetconf  0.10.0-146_trunk
NETCONF Library
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
messages_xml.h
Go to the documentation of this file.
1 
40 #ifndef NC_MESSAGES_XML_H_
41 #define NC_MESSAGES_XML_H_
42 
43 #include <time.h>
44 
45 #include <libxml/tree.h>
46 
47 #include "netconf.h"
48 #include "error.h"
49 
50 #ifdef __cplusplus
51 extern "C" {
52 #endif
53 
67 struct nc_filter* ncxml_filter_new(NC_FILTER_TYPE type, ...);
68 
76 xmlDocPtr ncxml_reply_dump(const nc_reply *reply);
77 
88 nc_reply* ncxml_reply_build(xmlDocPtr reply_dump);
89 
97 xmlDocPtr ncxml_rpc_dump(const nc_rpc *rpc);
98 
111 nc_rpc* ncxml_rpc_build(xmlDocPtr rpc_dump, const struct nc_session* session);
112 
120 xmlNodePtr ncxml_rpc_get_op_content(const nc_rpc *rpc);
121 
133 xmlNodePtr ncxml_rpc_get_config(const nc_rpc *rpc);
134 
144 xmlNodePtr ncxml_reply_get_data(const nc_reply *reply);
145 
153 nc_reply* ncxml_reply_data(const xmlNodePtr data);
154 
163 nc_reply* ncxml_reply_data_ns(const xmlNodePtr data, const char* ns);
164 
194 
222 nc_rpc* ncxml_rpc_editconfig(NC_DATASTORE target, NC_DATASTORE source, NC_EDIT_DEFOP_TYPE default_operation, NC_EDIT_ERROPT_TYPE error_option, NC_EDIT_TESTOPT_TYPE test_option, ...);
223 
234 nc_rpc* ncxml_rpc_generic(const xmlNodePtr data);
235 
236 #ifdef __cplusplus
237 }
238 #endif
239 
240 #endif /* NC_MESSAGES_XML_H_ */
NC_EDIT_ERROPT_TYPE
Enumeration of edit-config's <error-option> element values.
Definition: netconf.h:308
NC_EDIT_DEFOP_TYPE
Enumeration of edit-config's <default-operation> element values.
Definition: netconf.h:296
struct nc_filter * ncxml_filter_new(NC_FILTER_TYPE type,...)
Create a new NETCONF filter of the specified type.
xmlNodePtr ncxml_rpc_get_op_content(const nc_rpc *rpc)
Get the content of the operation specification from the given rpc.
xmlNodePtr ncxml_rpc_get_config(const nc_rpc *rpc)
Get <config> element from the RPC operation including its content. This function is valid only for <c...
xmlNodePtr ncxml_reply_get_data(const nc_reply *reply)
Get <data> element in <rpc-reply> including its content.
NC_DATASTORE
Enumeration of the supported types of datastores defined by NETCONF.
Definition: netconf.h:260
nc_rpc * ncxml_rpc_editconfig(NC_DATASTORE target, NC_DATASTORE source, NC_EDIT_DEFOP_TYPE default_operation, NC_EDIT_ERROPT_TYPE error_option, NC_EDIT_TESTOPT_TYPE test_option,...)
Create <edit-config> NETCONF rpc message.
struct nc_msg nc_reply
reply message.
Definition: netconf.h:62
nc_reply * ncxml_reply_data(const xmlNodePtr data)
Create rpc-reply response with <data> content.
nc_rpc * ncxml_rpc_generic(const xmlNodePtr data)
Create a generic NETCONF rpc message with the specified content.
NETCONF error handling functions.
struct nc_msg nc_rpc
rpc message.
Definition: netconf.h:56
nc_rpc * ncxml_rpc_build(xmlDocPtr rpc_dump, const struct nc_session *session)
Build <rpc> message from the libxml2 document structure. This is the reverse function of the ncxml_rp...
NC_EDIT_TESTOPT_TYPE
Enumeration of edit-config's <test-option> element values.
Definition: netconf.h:322
nc_reply * ncxml_reply_data_ns(const xmlNodePtr data, const char *ns)
Create rpc-reply response with <data> content in the specified namespace.
nc_rpc * ncxml_rpc_copyconfig(NC_DATASTORE source, NC_DATASTORE target,...)
Create <copy-config> NETCONF rpc message.
nc_reply * ncxml_reply_build(xmlDocPtr reply_dump)
Build <rpc-reply> message from the libxml2 document structure. This is the reverse function of the nc...
NC_FILTER_TYPE
Enumeration of supported NETCONF filter types.
Definition: netconf.h:273
libnetconf's general public functions and structures definitions.
xmlDocPtr ncxml_reply_dump(const nc_reply *reply)
Dump the rpc-reply message into a libxml2 document structure.
xmlDocPtr ncxml_rpc_dump(const nc_rpc *rpc)
Dump the rpc message into a libxml2 document structure.