TANDBERG D14172.01 Example, NTP Status, Server item=2, Domain item=1, DNS IP Configuration

Models: D14172.01

1 84
Download 84 pages 8.98 Kb
Page 5
Image 5
<Status>

TANDBERG Gatekeeper/Border Controller API User Guide

Example 1.3

If we now look at the NTP element once NTP has been correctly configured we see that it now contains more sub-structure:

<Status>

<NTP item="1" status="Active"> <Address item="1">10.0.0.2</Address> <Port item="1">123</Port>

<LastUpdate item="1">2008-01-01 12:00:00</LastUpdate> <LastCorrection item="1">1</LastCorrection>

</NTP>

</Status>

In this example, the attributes are used to provide valuable information in addition to establishing a dependency to the underlying sub-structure of the element.

Example 1.4

In the above examples, all elements have an attribute named item. This attribute specifies the instance number of the element. If we examine the DNS configuration for a system which has two DNS servers configured then the XML structure would look like this:

<Configuration> <IP item="1">

<DNS item="1"> <Server item="1">

<Address item="1">10.0.0.3</Address> </Server>

<Server item="2">

<Address item="1">10.0.0.4</Address> </Server>

<Domain item="1">

<Name item="1">example.com</Name> </Domain>

</DNS>

</IP>

</Configuration>

D14172.01

page 5 of 84

Page 5
Image 5
TANDBERG D14172.01 manual Example, NTP Status, Server item=2, Domain item=1, DNS IP Configuration