summaryrefslogtreecommitdiffstats
path: root/test/samples/uscxml
diff options
context:
space:
mode:
authorStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2013-01-16 00:31:12 (GMT)
committerStefan Radomski <radomski@tk.informatik.tu-darmstadt.de>2013-01-16 00:31:12 (GMT)
commit57b7b1cb196ea9f51aebaba1a838b9a86a9f83fe (patch)
treed2ae2a83f1357b66c9712b741a2ad048444caa06 /test/samples/uscxml
parent1088a76a715ef8a2728ad3fa8cde02bde4eec760 (diff)
downloaduscxml-57b7b1cb196ea9f51aebaba1a838b9a86a9f83fe.zip
uscxml-57b7b1cb196ea9f51aebaba1a838b9a86a9f83fe.tar.gz
uscxml-57b7b1cb196ea9f51aebaba1a838b9a86a9f83fe.tar.bz2
More work on Prolog datamodel
Diffstat (limited to 'test/samples/uscxml')
-rw-r--r--test/samples/uscxml/test-prolog.scxml26
1 files changed, 14 insertions, 12 deletions
diff --git a/test/samples/uscxml/test-prolog.scxml b/test/samples/uscxml/test-prolog.scxml
index 85d45bc..266bd8d 100644
--- a/test/samples/uscxml/test-prolog.scxml
+++ b/test/samples/uscxml/test-prolog.scxml
@@ -1,20 +1,22 @@
<scxml datamodel="prolog" initial="start" binding="late">
<datamodel>
- <!-- data id="facts">
- cat(tom).
- animal(X):- cat(X).
- </data -->
- <data id="likes" src="prolog/likes.pl" />
+ <data id="facts">
+% see http://www.swi-prolog.org/FAQ/Multifile.html
+:- multifile animal/1.
+cat(tom).
+animal(X):- cat(X).
+ </data>
</datamodel>
- <!-- script>
- cat(tom).
- cat(X).
- animal(X).
- </script -->
<script>
- likes(sam,curry).
- likes(sam,chips).
+mouse(jerry).
+animal(X):- mouse(X).
</script>
<state id="start">
+ <transition target="end" cond="not(cat(jerry)), cat(tom), mouse(jerry)." />
+ </state>
+ <state id="end" final="true">
+ <onentry>
+ <log expr="animal(X)." />
+ </onentry>
</state>
</scxml> \ No newline at end of file