16 #ifndef NC_MESSAGES_CLIENT_H_
17 #define NC_MESSAGES_CLIENT_H_
366 struct nc_rpc *
nc_rpc_commit(
int confirmed, uint32_t confirm_timeout,
const char *persist,
const char *persist_id,
446 struct nc_rpc *
nc_rpc_subscribe(
const char *stream_name,
const char *filter,
const char *start_time,
470 struct nc_rpc *
nc_rpc_getdata(
const char *datastore,
const char *filter,
const char *config_filter,
char **origin_filter,
471 int origin_filter_count,
int neg_origin_filter, uint16_t max_depth,
int with_origin,
enum NC_REPLY NC_RPL
Enumeration of NETCONF (both server and client) rpc-reply types.
NETCONF client error rpc-reply object.
struct nc_rpc * nc_rpc_act_generic(const struct lyd_node *data, NC_PARAMTYPE paramtype)
Create a generic NETCONF RPC or action.
void nc_reply_free(struct nc_reply *reply)
Free the NETCONF RPC reply object.
uint16_t attr_count
Number of items in the attr array.
NC_RPC_EDIT_ERROPT
Enumeration of <edit-config> error option.
const char * message
<error-message>, Human-readable description of the error.
struct nc_rpc * nc_rpc_act_generic_xml(const char *xml_str, NC_PARAMTYPE paramtype)
Create a generic NETCONF RPC or action from an XML string.
struct nc_rpc * nc_rpc_delete(NC_DATASTORE target, const char *url, NC_PARAMTYPE paramtype)
Create NETCONF RPC <delete-config>
const char * severity
<error-severity>.
const char ** attr
<bad-attr>, array of the names of the data-model-specific XML attributes that caused the error...
NC_RPC_EDIT_TESTOPT
Enumeration of <edit-config> test option.
NC_RPC_TYPE nc_rpc_get_type(const struct nc_rpc *rpc)
Get the type of the RPC.
NC_RPC_TYPE
Enumeration of RPC types.
struct nc_rpc * nc_rpc_editdata(const char *datastore, NC_RPC_EDIT_DFLTOP default_op, const char *edit_content, NC_PARAMTYPE paramtype)
Create NETCONF RPC <get-data>
struct nc_rpc * nc_rpc_kill(uint32_t session_id)
Create NETCONF RPC <kill-session>
struct nc_rpc * nc_rpc_commit(int confirmed, uint32_t confirm_timeout, const char *persist, const char *persist_id, NC_PARAMTYPE paramtype)
Create NETCONF RPC <commit>
NETCONF error structure representation.
const char ** elem
<bad-element>, array of the names of the data-model-specific XML element that caused the error...
const char * type
<error-type>, error layer where the error occurred.
struct nc_rpc * nc_rpc_getconfig(NC_DATASTORE source, const char *filter, NC_WD_MODE wd_mode, NC_PARAMTYPE paramtype)
Create NETCONF RPC <get-config>
struct nc_rpc * nc_rpc_subscribe(const char *stream_name, const char *filter, const char *start_time, const char *stop_time, NC_PARAMTYPE paramtype)
Create NETCONF RPC <create-subscription>
void nc_notif_free(struct nc_notif *notif)
Free the NETCONF Notification object.
const char * message_lang
xml:lang attribute of the error-message.
struct nc_rpc * nc_rpc_lock(NC_DATASTORE target)
Create NETCONF RPC <lock>
struct nc_rpc * nc_rpc_cancel(const char *persist_id, NC_PARAMTYPE paramtype)
Create NETCONF RPC <cancel-commit>
NETCONF client notification object.
struct nc_rpc * nc_rpc_validate(NC_DATASTORE source, const char *url_or_config, NC_PARAMTYPE paramtype)
Create NETCONF RPC <validate>
enum NC_DATASTORE_TYPE NC_DATASTORE
Enumeration of the supported types of datastores defined by NETCONF.
struct nc_rpc * nc_rpc_unlock(NC_DATASTORE target)
Create NETCONF RPC <unlock>
const char ** ns
<bad-namespace>, array of the unexpected XML namespaces that caused the error. Part of <error-info>...
NC_PARAMTYPE
Enumeration of function parameter treatments.
struct nc_rpc * nc_rpc_edit(NC_DATASTORE target, NC_RPC_EDIT_DFLTOP default_op, NC_RPC_EDIT_TESTOPT test_opt, NC_RPC_EDIT_ERROPT error_opt, const char *edit_content, NC_PARAMTYPE paramtype)
Create NETCONF RPC <edit-config>
struct nc_rpc * nc_rpc_discard(void)
Create NETCONF RPC <discard-changes>
struct nc_rpc * nc_rpc_copy(NC_DATASTORE target, const char *url_trg, NC_DATASTORE source, const char *url_or_config_src, NC_WD_MODE wd_mode, NC_PARAMTYPE paramtype)
Create NETCONF RPC <copy-config>
uint16_t other_count
Number of items in the other array.
void nc_rpc_free(struct nc_rpc *rpc)
Free the NETCONF RPC object.
const char * sid
<session-id>, session ID of the session holding the requested lock. Part of <error-info>.
const char * tag
<error-tag>.
enum NC_WITHDEFAULTS_MODE NC_WD_MODE
Enumeration of NETCONF with-defaults capability modes.
uint16_t elem_count
Number of items in the elem array.
NETCONF client data rpc-reply object.
struct nc_rpc * nc_rpc_getdata(const char *datastore, const char *filter, const char *config_filter, char **origin_filter, int origin_filter_count, int neg_origin_filter, uint16_t max_depth, int with_origin, NC_WD_MODE wd_mode, NC_PARAMTYPE paramtype)
Create NETCONF RPC <get-data>
struct nc_rpc * nc_rpc_getschema(const char *identifier, const char *version, const char *format, NC_PARAMTYPE paramtype)
Create NETCONF RPC <get-schema>
struct lyxml_elem ** other
Array of the remaining non-standard elements.
uint16_t ns_count
Number of items in the ns array.
const char * path
<error-path>, XPATH expression identifying the element with the error.
NETCONF client rpc-reply object.
const char * apptag
<error-app-tag>, the data-model-specific or implementation-specific error condition, if one exists.
struct nc_rpc * nc_rpc_get(const char *filter, NC_WD_MODE wd_mode, NC_PARAMTYPE paramtype)
Create NETCONF RPC <get>
libnetconf2's general public functions and structures definitions.
NC_RPC_EDIT_DFLTOP
Enumeration of <edit-config> default operation.