TANDBERG Gatekeeper/Border Controller API User Guide
D14172.01
page 25 of 84
2.2.1 Format
Status information is presented by a mark-up notation, similar to XML. The main differences are:
•
all braces are removed in the XACLI format
•
XACLI does not use end-tags, except for a tag to mark end of the top element
•
XACLI does not use indent spaces to present the data structure
•
XACLI hides the instance number (
item
number in XML) of an element if only one instance of a
given element exists
•
A status top level element starts with “
*s
"
Example 2.5 shows XML formatting and XACLI formatting for the same status element,
NTP
.
Example 2.5
XML:
<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>
XACLI:
*s NTP (status=Active):
Address: "10.0.0.2"
Port: 123
LastUpdate: "2008-01-01 12:00:00"
LastCorrection: 1
*s/end
NOTE!
To write a parser for the XACLI format, the parser must keep track of the levels by counting
white spaces. The indent is increased by two whitespaces for each level.