RUGGEDCOM NETCONF
Reference Guide
Section 4.4
Getting Information for a Specific Object
To retrieve information for a specific object, such as a user, an interface, or other identified object, specify the
identification for the item item in the XML element hierarchy or XPath.
CONTENTS
•
Section 4.4.1, "Specifying Objects with Hierarchical XML Elements"
•
Section 4.4.2, "Specifying Objects with XPaths"
Section 4.4.1
Specifying Objects with Hierarchical XML Elements
When using hierarchical XML elements, enclose the identifying data within its element. For example:
{element}
...
{element}{data}{/element}
...
{/element}
Where:
• {element} is an element in the data model.
• ... represents multiple elements in the data model to the target element.
• {data} is the identifying data for the object whose information you want to retrieve.
For example, to return the role for a specific user, send an rpc-message similar to the following:
<rpc message-id="3030"
xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
<get>
<filter type="subtree">
<admin xmlns="http://ruggedcom.com/ns/rmf_admin">
<users>
<userid>
<name>oper</name>
<role />
</userid>
</users>
</admin>
</filter>
</get>
</rpc>]]>]]>
The device returns the following rpc-reply:
<?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="3020">
<data>
<admin xmlns="http://ruggedcom.com/ns/rmf_admin">
<users>
<userid>
<name>oper</name>
<role>operator</role>
</userid>
Getting Information for a Specific Object
Chapter 4
Getting Data
33