XML resource representation

A resource is represented in XML as an XML element, with an XML attribute "y:self" that contains the URI for the resource. Sub-resources are encoded as sub-elements to the resource element.

Single-valued resource properties are encoded as sub-elements to the resource element, with the value encoded as character data in the sub-element.

In the XML representation, every resource has an XML attribute: y:self="...". In the representation of a list resource, the keys are always present and encoded first. Leafs are properties of the resource.

The following example shows the XML representation of the "access-list" resource."

<mac xmlns="urn:brocade.com:mgmt:brocade-mac-access-list" 
xmlns:y="urn:brocade.com:mgmt:brocade-mac-access-list" y:self="/rest/config/mac">
   <access-list y:self="/rest/config/running/mac/access-list">
     <standard y:self="/rest/config/running/mac/access-list/standard/stdmac">
       <name>stdmac</name>
     </standard>
   </access-list>
</mac>