summaryrefslogtreecommitdiffstats
path: root/scilab/modules/xcos/etc/SimulinkImportConfiguration.xsd
blob: 4a2a12be0a55b3cd40eeed12eb780dd3071ad476 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            xmlns:jxb="http://java.sun.com/xml/ns/jaxb"
            jxb:version="2.0">
	
	<!--Each Migration Schema, can consist of many blocks, and only one general parameters section -->
	<!--<xsd:element name="generals" type="GeneralParameters"/> general section will be added as a block to BlockPalette-->
	<xsd:element name="blocks" type="BlockPalette"/>	
	
	<xsd:complexType name="GeneralParameters">
	  <xsd:sequence>
	    <xsd:element name="string" type="StringParameter" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="integer" type="IntegerParameters" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="simple" type="SimpleParameter" minOccurs="0" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	</xsd:complexType>

	<xsd:complexType name="BlockPalette">
	  <xsd:sequence>
	    <xsd:element name="block" type="Block" minOccurs="0" maxOccurs="unbounded"/>
	  </xsd:sequence>
	</xsd:complexType>
	<!-- parameter won't be found in Block scope, It'll be searched among general parameters. This way it will be possible to shadow parameter -->
	<xsd:complexType name="Block">
	  <xsd:sequence>
	    <xsd:element name="string" type="StringParameter" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="integer" type="IntegerParameters" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="simple" type="SimpleParameter" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="str2int" type="Str2IntParameters" minOccurs="0" maxOccurs="unbounded"/>
	    <xsd:element name="int2str" type="Int2StrParameters" minOccurs="0" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>	
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	</xsd:complexType>
	<!-- parameters that differs only in parameter name ex:Constant Value -->
	<xsd:complexType name="SimpleParameter">
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	 </xsd:complexType>
	<!-- parameters that in name, and have different string values ex:CSCOPE SCOPE -->
	<xsd:complexType name="StringParameter">
	  <xsd:sequence>
	    <xsd:element name="parMap" type="StringValueMap" minOccurs="1" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	 </xsd:complexType>

	<xsd:complexType name="StringValueMap">
	    <xsd:attribute name="simVal" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcosVal" type="xsd:string" use="required"/>
	 </xsd:complexType>
	<!-- parameters that needs to be calculated before setting -->
	<xsd:complexType name="IntegerParameters">
	  <xsd:sequence>
	    <xsd:element name="parMap" type="IntegerValueMap" minOccurs="1" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	 </xsd:complexType>

	<xsd:complexType name="IntegerValueMap">
	    <xsd:attribute name="simVal" type="xsd:integer" use="required"/>
	    <xsd:attribute name="xcosVal" type="xsd:integer" use="required"/>
	 </xsd:complexType>

	<xsd:complexType name="Str2IntParameters">
	  <xsd:sequence>
	    <xsd:element name="parMap" type="Str2IntValueMap" minOccurs="1" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	 </xsd:complexType>

	<xsd:complexType name="Str2IntValueMap">
	    <xsd:attribute name="simVal" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcosVal" type="xsd:integer" use="required"/>
	 </xsd:complexType>

	<xsd:complexType name="Int2StrParameters">
	  <xsd:sequence>
	    <xsd:element name="parMap" type="Int2StrValueMap" minOccurs="1" maxOccurs="unbounded"/>
	  </xsd:sequence>
	    <xsd:attribute name="sim" type="xsd:string" use="required"/>
	    <xsd:attribute name="xcos" type="xsd:string" use="required"/>
	    <xsd:attribute name="description" type="xsd:string" use="optional"/>
	 </xsd:complexType>
	<xsd:complexType name="Int2StrValueMap">
	    <xsd:attribute name="simVal" type="xsd:integer" use="required"/>
	    <xsd:attribute name="xcosVal" type="xsd:string" use="required"/>
	 </xsd:complexType>
	<!--Its possible that Ill have to add more parameter types, such as: boolean -->
</xsd:schema>