You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,6 +82,9 @@ The following feature model in UVL syntax enriches the previous version with new
82
82
</code>
83
83
</pre>
84
84
85
+
## Import Mechanism
86
+
UVL supports referencing submodels for composing larger UVL models. See [here](https://universal-variability-language.github.io/language/submodels) for more details
87
+
85
88
## Examples
86
89
A set of further example UVL models is available [here](https://github.com/Universal-Variability-Language/uvl-models). We are happy to merge your examples if you want to [contribute](https://github.com/Universal-Variability-Language/uvl-models/pulls).
Copy file name to clipboardExpand all lines: language/submodels.md
+7-1Lines changed: 7 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,7 @@ Larger variability models may be hard to overview. To simplify viewing and editi
4
4
5
5
Consider our sandwich model as example:
6
6
7
+
<pre>
7
8
<code>
8
9
<b>features</b>
9
10
Sandwich
@@ -18,21 +19,25 @@ Consider our sandwich model as example:
18
19
<b>constraints</b>
19
20
Ketchup => Cheese
20
21
</code>
22
+
</pre>
21
23
22
24
Here, it may make sense to decompose the Sauce into a separate UVL model:
23
25
26
+
<pre>
24
27
<code>
25
28
<b>features</b>
26
29
Type
27
30
<b>alternative</b>
28
31
Ketchup
29
32
Mustard
30
33
</code>
34
+
</pre>
31
35
32
36
Suppose we stored this submodel in a path ./submodels/Sauces.uvl
33
37
34
38
We can then use this submodel by using the **imports** keyword in a composed model. Further, we can reference the root feature of the imported model at any point the feature tree.
35
39
40
+
<pre>
36
41
<code>
37
42
<b>imports</b>
38
43
submodels.Sauces as Sauce
@@ -45,4 +50,5 @@ We can then use this submodel by using the **imports** keyword in a composed mod
0 commit comments