Commit f61b218f authored by Andreas Kraft's avatar Andreas Kraft
Browse files

Fixed ModuleClass hierarchy. Much simpler know.

parent 9cf47b09
...@@ -2,6 +2,11 @@ ...@@ -2,6 +2,11 @@
In this document an overview about the SDT 2.0 ødefinitions and component hierarchy is given. In this document an overview about the SDT 2.0 ødefinitions and component hierarchy is given.
[Domain](#Domain)
[RootDevice](#RootDevice)
[Device](#Device)
[DeviceInfo](#DeviceInfo)
## SDT Overview ## SDT Overview
The followng UML diagram presents an overview about the SDT components. The followng UML diagram presents an overview about the SDT components.
...@@ -14,15 +19,23 @@ The syntax used in the diagram to model an XML Schema Definition (XSD) as an UML ...@@ -14,15 +19,23 @@ The syntax used in the diagram to model an XML Schema Definition (XSD) as an UML
## Components ## Components
-TBD
---
<a name="Domain"></a>
### Domain ### Domain
The *Domain* is the top-level component that defines all modules and devices of a domain. A *Domain* can import definitions of other domains. The *Domain* is the top-level component that defines all modules and devices of a domain. A *Domain* can import definitions of other domains.
A *Domain* can define *ModuleClasses* or *RootDevices* only, or may choose to provide both.
![](images/Domain.png) ![](images/Domain.png)
#### Attributes
- **id** : The identifier for that *Domain*. Required.
#### Elements
- **Imports** : XML import/include of other XML files. Optional.
- **Modules** : A list of *Module* components that are global to the whole domain. Optional.
- **RootDevices** : a List *RootDevice* components. Optional.
#### Example #### Example
<Domain xmlns:xi="http://www.w3.org/2001/XInclude" <Domain xmlns:xi="http://www.w3.org/2001/XInclude"
...@@ -32,23 +45,127 @@ The *Domain* is the top-level component that defines all modules and devices of ...@@ -32,23 +45,127 @@ The *Domain* is the top-level component that defines all modules and devices of
<xi:include href="./dal-core.xml" parse="xml" /> <xi:include href="./dal-core.xml" parse="xml" />
</Imports> </Imports>
<Modules> <Modules>
<!-- Modules go here --> <!-- List of Domain global Modules go here -->
</Modules> </Modules>
<RootDevices> <RootDevices>
<!-- RootDevices go here --> <!-- List of RootDevices go here -->
</RootDevices> </RootDevices>
</Domain> </Domain>
--- ---
<a name="RootDevice"/></a>
### RootDevice ### RootDevice
#### DeviceInfo A *RootDevice* is the description of a (physical) device that may contain optional sub-devices. It represents the idea an appliance that is addressable on a Home Area Network where one or more sub-*Devices* provide certain functionalities.
An example is a connected power-strip where each of the sockets can be switched on and off individually. The power-strip itself can provide functions such as "all sockets off" and "overall power consumption".
If the *RootDevice* includes sub-*Devices* then each sub-device may be of the same type or of different types. The functionality (*Actions*) of the *RootDevice* may be different from the functionality of its sub-*Devices*.
If the *RootDevice* does not include sub-devices then the *RootDevice* is the actual adressable device that provides all the functionality of the connected appliance.
*RootDevices* may define their own *ModuleClasses* or refer to predefined ModulesClasses of its or another *Domain*.
![](images/RootDevice.png)
#### Attributes
- **id** : The identifier for that *RootDevice*. Required.
#### Elements
- **Doc** : Documentation for the *RootDevice*. Optional.
- **Modules** : A list of *Module* components that are local to the *RootDevice*. Optional.
- **DeviceInfo** : Further meta-data about the *RootDevice*. Optional.
- **Devices** : A list *Device* components. Optional.
#### Example
<RootDevice id="aRootDevice">
<Doc>Some documentation</Doc>
<Modules>
<!-- List of Modules local to the RootDevice go here-->
</Modules>
<DeviceInfo>
<!-- The DeviceInfos for the RootDevice goes here-->
</DeviceInfo>
<Devices>
<!-- List of Sub-Devices of the RootDevice go here-->
</Devices>
</RootDevice>
---
### Device ### Device
*Devices* are optional components of a *RootDevice*. They represent physical sub-devices inside another device (the *RootDevice*).
*Devices* may define their own *ModuleClasses* or refer to predefined ModulesClasses of its or another *Domain*.
![](images/Device.png)
#### Attributes
- **id** : The identifier for that *Device*. Required.
#### Elements
- **Doc** : Documentation for the *Device*. Optional.
- **Modules** : A list of *Module* components that are local to the *RootDevice*. Optional.
- **DeviceInfo** : A list *Device* components. Optional.
#### Example
<Device id="aDevice">
<Doc>Some documentation</Doc>
<Modules>
<!-- Modules local to the Device go here-->
</Modules>
<DeviceInfo>
<!-- The DeviceInfo for the Device goes here-->
</DeviceInfo>
</RootDevice>
---
### Module, ModuleClass, ModuleDef ### Module, ModuleClass, ModuleDef
![](images/Domain.png)
#### Attributes
#### Sub-Components
#### Example
---
<a name="DeviceInfo"/></a>
### DeviceInfo
The *DeviceInfo* is an element of *RootDevice* or *Device* where a device vendor can provide metadata for a device that may be presented to an end-user.
![](images/DeviceInfo.png)
#### Attributes
None.
#### Elements
- **Name** : Vendor-specific name of a device. Required.
- **Vendor** : Name of the vendor for the device. Required.
- **FirmwareVersion** : Current version number of the firmware or other version information. Optional.
- **VendorURL** : A URL that points to further information for that device. This might be the product page on the web or an URL to the device manual. Optional.
- **SerialNumber** : The serial number or serial string. Optional.
#### Example
<DeviceInfo>
<Name>SomeDeviceName</Name>
<Vendor>ACME</Vendor>
<FirmwareVersion>1.0</FirmwareVersion>
<VendorURL>http://www.example.com/</VendorURL>
<SerialNumber>1234.5</SerialNumber>
</DeviceInfo>
---
---
### Action ### Action
### Data ### Data
...@@ -59,3 +176,14 @@ The *Domain* is the top-level component that defines all modules and devices of ...@@ -59,3 +176,14 @@ The *Domain* is the top-level component that defines all modules and devices of
# DOC TBD
Explain. Describe content elements
...@@ -4,12 +4,12 @@ ...@@ -4,12 +4,12 @@
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>270</x> <x>330</x>
<y>70</y> <y>120</y>
<w>150</w> <w>150</w>
<h>130</h> <h>130</h>
</coordinates> </coordinates>
<panel_attributes>ModuleDef <panel_attributes>ModuleClass
-- --
*@ name : text* *@ name : text*
/- extends: Extends/ /- extends: Extends/
...@@ -17,14 +17,15 @@ ...@@ -17,14 +17,15 @@
/- Actions : Actions/ /- Actions : Actions/
/- Data : Data/ /- Data : Data/
/- Events : Events/ /- Events : Events/
fg=blue
</panel_attributes> </panel_attributes>
<additional_attributes/> <additional_attributes/>
</element> </element>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>520</x> <x>580</x>
<y>160</y> <y>190</y>
<w>140</w> <w>140</w>
<h>100</h> <h>100</h>
</coordinates> </coordinates>
...@@ -40,21 +41,21 @@ fg=blue</panel_attributes> ...@@ -40,21 +41,21 @@ fg=blue</panel_attributes>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>410</x> <x>470</x>
<y>70</y> <y>100</y>
<w>130</w> <w>130</w>
<h>70</h> <h>90</h>
</coordinates> </coordinates>
<panel_attributes>lt=&lt;- <panel_attributes>lt=&lt;-
m1=0,1 m1=0,1
</panel_attributes> </panel_attributes>
<additional_attributes>110.0;10.0;40.0;10.0;40.0;50.0;10.0;50.0</additional_attributes> <additional_attributes>110.0;10.0;40.0;10.0;40.0;70.0;10.0;70.0</additional_attributes>
</element> </element>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>740</x> <x>800</x>
<y>230</y> <y>260</y>
<w>160</w> <w>160</w>
<h>80</h> <h>80</h>
</coordinates> </coordinates>
...@@ -63,14 +64,14 @@ m1=0,1 ...@@ -63,14 +64,14 @@ m1=0,1
*@ name ; text* *@ name ; text*
*@ type : DataType* *@ type : DataType*
/- Doc : Doc/ /- Doc : Doc/
</panel_attributes> fg=blue</panel_attributes>
<additional_attributes/> <additional_attributes/>
</element> </element>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>650</x> <x>710</x>
<y>230</y> <y>260</y>
<w>110</w> <w>110</w>
<h>40</h> <h>40</h>
</coordinates> </coordinates>
...@@ -81,8 +82,8 @@ m1=0..*</panel_attributes> ...@@ -81,8 +82,8 @@ m1=0..*</panel_attributes>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>0</x> <x>60</x>
<y>200</y> <y>230</y>
<w>200</w> <w>200</w>
<h>100</h> <h>100</h>
</coordinates> </coordinates>
...@@ -98,21 +99,20 @@ fg=blue</panel_attributes> ...@@ -98,21 +99,20 @@ fg=blue</panel_attributes>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>190</x> <x>250</x>
<y>250</y> <y>120</y>
<w>100</w> <w>100</w>
<h>50</h> <h>200</h>
</coordinates> </coordinates>
<panel_attributes>lt=&lt;- <panel_attributes>lt=&lt;-
m1=0..* m1= 0..*</panel_attributes>
</panel_attributes> <additional_attributes>80.0;10.0;30.0;10.0;30.0;180.0;10.0;180.0</additional_attributes>
<additional_attributes>80.0;20.0;10.0;20.0</additional_attributes>
</element> </element>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>270</x> <x>330</x>
<y>570</y> <y>600</y>
<w>190</w> <w>190</w>
<h>100</h> <h>100</h>
</coordinates> </coordinates>
...@@ -128,8 +128,8 @@ fg=blue</panel_attributes> ...@@ -128,8 +128,8 @@ fg=blue</panel_attributes>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>180</x> <x>240</x>
<y>270</y> <y>300</y>
<w>50</w> <w>50</w>
<h>250</h> <h>250</h>
</coordinates> </coordinates>
...@@ -141,8 +141,8 @@ m1=0..* ...@@ -141,8 +141,8 @@ m1=0..*
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>530</x> <x>590</x>
<y>580</y> <y>610</y>
<w>180</w> <w>180</w>
<h>130</h> <h>130</h>
</coordinates> </coordinates>
...@@ -160,8 +160,8 @@ fg=blue</panel_attributes> ...@@ -160,8 +160,8 @@ fg=blue</panel_attributes>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>450</x> <x>510</x>
<y>580</y> <y>610</y>
<w>100</w> <w>100</w>
<h>90</h> <h>90</h>
</coordinates> </coordinates>
...@@ -172,8 +172,8 @@ m1= 0,1</panel_attributes> ...@@ -172,8 +172,8 @@ m1= 0,1</panel_attributes>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>740</x> <x>800</x>
<y>0</y> <y>30</y>
<w>160</w> <w>160</w>
<h>210</h> <h>210</h>
</coordinates> </coordinates>
...@@ -195,21 +195,22 @@ blob</panel_attributes> ...@@ -195,21 +195,22 @@ blob</panel_attributes>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>790</x> <x>850</x>
<y>620</y> <y>650</y>
<w>110</w> <w>110</w>
<h>50</h> <h>50</h>
</coordinates> </coordinates>
<panel_attributes>Doc <panel_attributes>Doc
-- --
- ...</panel_attributes> - ...
fg=blue</panel_attributes>
<additional_attributes/> <additional_attributes/>
</element> </element>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>520</x> <x>580</x>
<y>60</y> <y>90</y>
<w>130</w> <w>130</w>
<h>80</h> <h>80</h>
</coordinates> </coordinates>
...@@ -224,21 +225,21 @@ Extends ...@@ -224,21 +225,21 @@ Extends
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>410</x> <x>470</x>
<y>140</y> <y>180</y>
<w>130</w> <w>130</w>
<h>60</h> <h>50</h>
</coordinates> </coordinates>
<panel_attributes>lt=&lt;- <panel_attributes>lt=&lt;-
m1=0..* m1=0..*
</panel_attributes> </panel_attributes>
<additional_attributes>110.0;30.0;80.0;30.0;80.0;10.0;10.0;10.0</additional_attributes> <additional_attributes>110.0;20.0;10.0;20.0</additional_attributes>
</element> </element>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>650</x> <x>710</x>
<y>10</y> <y>40</y>
<w>110</w> <w>110</w>
<h>220</h> <h>220</h>
</coordinates> </coordinates>
...@@ -250,8 +251,8 @@ m1=0,1 ...@@ -250,8 +251,8 @@ m1=0,1
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>720</x> <x>780</x>
<y>610</y> <y>640</y>
<w>90</w> <w>90</w>
<h>50</h> <h>50</h>
</coordinates> </coordinates>
...@@ -263,8 +264,8 @@ m1=0..* ...@@ -263,8 +264,8 @@ m1=0..*
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>890</x> <x>950</x>
<y>80</y> <y>110</y>
<w>50</w> <w>50</w>
<h>220</h> <h>220</h>
</coordinates> </coordinates>
...@@ -276,8 +277,8 @@ m1= 1 ...@@ -276,8 +277,8 @@ m1= 1
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>520</x> <x>580</x>
<y>310</y> <y>340</y>
<w>170</w> <w>170</w>
<h>50</h> <h>50</h>
</coordinates> </coordinates>
...@@ -290,21 +291,21 @@ fg=blue</panel_attributes> ...@@ -290,21 +291,21 @@ fg=blue</panel_attributes>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>410</x> <x>470</x>
<y>160</y> <y>210</y>
<w>130</w> <w>130</w>
<h>190</h> <h>170</h>
</coordinates> </coordinates>
<panel_attributes>lt=&lt;- <panel_attributes>lt=&lt;-
m1=0..* m1=0..*
</panel_attributes> </panel_attributes>
<additional_attributes>110.0;160.0;50.0;160.0;50.0;10.0;10.0;10.0</additional_attributes> <additional_attributes>110.0;140.0;50.0;140.0;50.0;10.0;10.0;10.0</additional_attributes>
</element> </element>
<element> <element>
<id>Relation</id> <id>Relation</id>
<coordinates> <coordinates>
<x>680</x> <x>740</x>
<y>320</y> <y>350</y>
<w>80</w> <w>80</w>
<h>50</h> <h>50</h>
</coordinates> </coordinates>
...@@ -316,8 +317,8 @@ m1=0..* ...@@ -316,8 +317,8 @@ m1=0..*
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>740</x> <x>800</x>
<y>330</y> <y>360</y>
<w>160</w> <w>160</w>
<h>130</h> <h>130</h>
</coordinates> </coordinates>
...@@ -329,14 +330,15 @@ m1=0..* ...@@ -329,14 +330,15 @@ m1=0..*
/@ readable : boolean/ /@ readable : boolean/
/@ eventable : boolean/ /@ eventable : boolean/
/- Doc : Doc/ /- Doc : Doc/
fg=blue
</panel_attributes> </panel_attributes>
<additional_attributes/> <additional_attributes/>
</element> </element>
<element> <element>
<id>UMLClass</id> <id>UMLClass</id>
<coordinates> <coordinates>
<x>530</x> <x>590</x>
<y>490</y> <y>520</y>
<w>160</w> <w>160</w>
<h>80</h> <h>80</h>
</coordinates> </coordinates>
...@@ -351,21 +353,21 @@ fg=blue</panel_attributes> ...@@ -351,21 +353,21 @@ fg=blue</panel_attributes>
<element> <element>