diff options
Diffstat (limited to 'language-web/src/main/html')
-rw-r--r-- | language-web/src/main/html/index.html | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/language-web/src/main/html/index.html b/language-web/src/main/html/index.html new file mode 100644 index 00000000..915234d3 --- /dev/null +++ b/language-web/src/main/html/index.html | |||
@@ -0,0 +1,48 @@ | |||
1 | <!DOCTYPE html> | ||
2 | <html> | ||
3 | <head> | ||
4 | <meta charset="utf-8"> | ||
5 | <title>Example Web Editor</title> | ||
6 | </head> | ||
7 | <body> | ||
8 | <div class="container"> | ||
9 | <div class="header"> | ||
10 | <h1>Example Problem Web Editor</h1> | ||
11 | </div> | ||
12 | <div class="content"> | ||
13 | <div class="xtext-editor"><pre>class Family { | ||
14 | contains Person[] members | ||
15 | } | ||
16 | |||
17 | class Person { | ||
18 | Person[] children opposite parent | ||
19 | Person[0..1] parent opposite children | ||
20 | int age | ||
21 | TaxStatus taxStatus | ||
22 | } | ||
23 | |||
24 | enum TaxStatus { | ||
25 | child, student, adult, retired | ||
26 | } | ||
27 | |||
28 | % A child cannot have any dependents. | ||
29 | error invalidTaxStatus(Person p) :- | ||
30 | taxStatus(p, child), children(p, _q). | ||
31 | |||
32 | Family('family'). | ||
33 | members('family', anne). | ||
34 | members('family', bob). | ||
35 | members('family', ciri). | ||
36 | children(anne, ciri). | ||
37 | ?children(bob, ciri). | ||
38 | taxStatus(anne, adult). | ||
39 | age(anne, 35). | ||
40 | bobAge: 27. | ||
41 | age(bob, bobAge). | ||
42 | !age(ciri, bobAge). | ||
43 | |||
44 | scope Family = 1, Person += 5..10.</pre></div> | ||
45 | </div> | ||
46 | </div> | ||
47 | </body> | ||
48 | </html> | ||