diff --git a/SDT/schema/test/dal-core.xml b/SDT/schema/test/dal-core.xml new file mode 100644 index 0000000000000000000000000000000000000000..9372c9dde324957a2be71871dd8c0181c8fe13e6 --- /dev/null +++ b/SDT/schema/test/dal-core.xml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="iso-8859-1"?> + +<Domain xmlns="http://hgi.org/xml/dal/1.0" + id="hgi.dal.core"> + + <Modules> + <ModuleClass name="BooleanState"> + <Doc> + <tt>BooleanState</tt> is the preferred module for modelling a + functionality corresponding to an underlying binary state. This + module should be used to abstract away from the actual datatype + and values in question. Note that the module does not define whether + the execution mode is blocking or non-blocking. + </Doc> + <Actions> + <Action name="get" type="boolean"> + <Doc> + Obtain the current associated state. + </Doc> + </Action> + <Action name="setTarget"> + <Doc> + Set the associated state to the specified value. + </Doc> + <Arg name="value" type="boolean"> + <Doc> + The desired value of the associated state. + </Doc> + </Arg> + </Action> + </Actions> + </ModuleClass> + </Modules> + +</Domain> diff --git a/SDT/schema/test/dal-eg.xml b/SDT/schema/test/dal-eg.xml new file mode 100644 index 0000000000000000000000000000000000000000..81603e8d5951c2adfcdca1341ccf2cbf6ae613b8 --- /dev/null +++ b/SDT/schema/test/dal-eg.xml @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="iso-8859-1"?> + +<Domain xmlns:xi="http://www.w3.org/2001/XInclude" + xmlns="http://hgi.org/xml/dal/1.0" + id="com.telekom"> + + <Imports> + <xi:include href="./dal-core.xml" parse="xml" /> + </Imports> + + <Modules> + </Modules> + + <Devices> + + <Device id="switch.power"> + <DeviceInfo> + <Name>PowerSwitch</Name> + <!-- The Vendor field should probably be part of the domain --> + <Vendor>Telekom Innovation Laboratories</Vendor> + </DeviceInfo> + + <Doc> + This device is intended as a demonstration of how to use the + abstract modules defined in the <em>HGI Core</em> domain. The + vendor has provided a proprietry module with two operations + <tt>on</tt> and <tt>off</tt>. This is clearly a candidate for the + module class <tt>BooleanState</tt>. + </Doc> + + <Modules> + <Module name="proprietaryPower"> + <Doc> + The proprietry interface for turning the switch on and off. + Actions for setting the state to <tt>on</tt> or <tt>off</tt> + and for querying the state. + </Doc> + + <Actions> + <Action name="on"> + <Doc> + Turn the switch on. + </Doc> + </Action> + <Action name="off"> + <Doc> + Turn the switch off. + </Doc> + </Action> + <Action name="state" type="string"> + <Doc> + Query the state of the switch. Returns the string "<tt>on</tt>" + or "<tt>off</tt>". + </Doc> + </Action> + </Actions> + </Module> + + <Module name="power"> + <extends domain="hgi.dal.core" class="BooleanState"/> + </Module> + </Modules> + </Device> + </Devices> +</Domain>