The following example describes the APIs used in zonemgr ADR Interface Description Language. This is only an example.
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <api xmlns="http://xmlns.oracle.com/radadr" name="com.oracle.solaris.rad.zonemgr"> <version major="1" minor="0"/> <enum name="ErrorCode"> <value name="NONE" value="0"/> <value name="FRAMEWORK_ERROR"/> <value name="SNAPSHOT_ERROR"/> <value name="COMMAND_ERROR"/> <value name="RESOURCE_ALREADY_EXISTS"/> <value name="RESOURCE_NOT_FOUND"/> <value name="RESOURCE_TOO_MANY"/> <value name="RESOURCE_UNKNOWN"/> <value name="ALREADY_EDITING"/> <value name="PROPERTY_UNKNOWN"/> <value name="NOT_EDITING"/> <value name="SYSTEM_ERROR"/> <value name="INVALID_ARGUMENT"/> <value name="INVALID_ZONE_STATE"/> </enum> <struct name="Result" stability="private"> <field typeref="ErrorCode" name="code" nullable="true"/> <field type="string" name="str" nullable="true"/> <field type="string" name="stdout" nullable="true"/> <field type="string" name="stderr" nullable="true"/> </struct> <struct name="ConfigChange"> <field type="string" name="zone"/> </struct> <struct name="StateChange"> <field type="string" name="zone"/> <field type="string" name="oldstate"/> <field type="string" name="newstate"/> </struct> <enum name="PropertyValueType"> <value name="PROP_SIMPLE"/> <value name="PROP_LIST"/> <value name="PROP_COMPLEX"/> </enum> <struct name="Property"> <field name="name" type="string"/> <field name="value" type="string" nullable="true"/> <field name="type" typeref="PropertyValueType" nullable="true"/> <field name="listvalue" nullable="true"> <list type="string"/> </field> <field name="complexvalue" nullable="true"> <list type="string"/> </field> </struct> <struct name="Resource"> <field type="string" name="type"/> <field name="properties" nullable="true"> <list typeref="Property"/> </field> <field name="parent" type="string" nullable="true"/> </struct> <interface name="ZoneManager"> <method name="create"> <result typeref="Result"/> <error typeref="Result"/> <argument name="name" type="string"/> <argument name="path" type="string" nullable="true"/> <argument name="template" type="string" nullable="true"/> </method> <method name="delete"> <result typeref="Result"/> <error typeref="Result"/> <argument name="name" type="string"/> </method> <method name="importConfig"> <result typeref="Result"/> <error typeref="Result"/> <argument name="noexecute" type="boolean"/> <argument name="name" type="string"/> <argument name="configuration"> <list type="string"/> </argument> </method> <event typeref="StateChange" name="stateChange"/> </interface> <interface name="ZoneInfo"> <property name="brand" access="ro" type="string"/> <property name="id" access="ro" type="integer"/> <property name="uuid" access="ro" type="string" nullable="true"> <error typeref="Result"/> </property> <property name="name" access="ro" type="string"/> <property name="isGlobal" access="ro" type="boolean"/> </interface> <interface name="Zone"> <name key="name" primary="true"/> <name key="id"/> <property name="auxstate" access="ro" nullable="true"> <list type="string"/> <error typeref="Result"/> </property> <property name="brand" access="ro" type="string"/> <property name="id" access="ro" type="integer"/> <property name="uuid" access="ro" type="string" nullable="true"> <error typeref="Result"/> </property> <property name="name" access="ro" type="string"/> <property name="state" access="ro" type="string"/> <method name="cancelConfig"> <error typeref="Result"/> </method> <method name="exportConfig"> <result type="string"/> <error typeref="Result"/> <argument name="includeEdits" type="boolean" nullable="true"/> <argument type="boolean" name="liveMode" nullable="true"/> </method> <method name="update"> <error typeref="Result"/> <argument name="noexecute" type="boolean"/> <argument name="commands"> <list type="string"/> </argument> </method> <method name="editConfig"> <error typeref="Result"/> <argument type="boolean" name="liveMode" nullable="true"/> </method> <method name="commitConfig"> <error typeref="Result"/> </method> <method name="configIsLive"> <result type="boolean"/> </method> <method name="configIsStale"> <result type="boolean"/> <error typeref="Result"/> </method> <method name="addResource"> <error typeref="Result"/> <argument name="resource" typeref="Resource"/> <argument name="scope" typeref="Resource" nullable="true"/> </method> <method name="reloadConfig"> <error typeref="Result"/> <argument type="boolean" name="liveMode" nullable="true"/> </method> <method name="removeResources"> <error typeref="Result"/> <argument name="filter" typeref="Resource" nullable="false"/> <argument name="scope" typeref="Resource" nullable="true"/> </method> <method name="getResources"> <result> <list typeref="Resource"/> </result> <error typeref="Result"/> <argument name="filter" typeref="Resource" nullable="true"/> <argument name="scope" typeref="Resource" nullable="true"/> </method> <method name="getResourceProperties"> <result> <list typeref="Property"/> </result> <error typeref="Result"/> <argument name="filter" typeref="Resource" nullable="false"/> <argument name="properties" nullable="true"> <list type="string"/> </argument> </method> <method name="setResourceProperties"> <error typeref="Result"/> <argument name="filter" typeref="Resource" nullable="false"/> <argument name="properties" nullable="false"> <list typeref="Property"/> </argument> </method> <method name="clearResourceProperties"> <error typeref="Result"/> <argument name="filter" typeref="Resource" nullable="false"/> <argument name="properties" nullable="false"> <list type="string"/> </argument> </method> <method name="apply"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="attach"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="boot"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="clone"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="detach"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="halt"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="install"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="mark"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="move"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="rename"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="ready"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="reboot"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="savecore"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="shutdown"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="suspend"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="uninstall"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <method name="verify"> <result typeref="Result"/> <error typeref="Result"/> <argument name="options" nullable="true"> <list type="string"/> </argument> </method> <event typeref="ConfigChange" name="configChange"/> </interface> </api>