• R/O
  • HTTP
  • SSH
  • HTTPS

tutorial: Commit

This repository is for tutorials of Eos.


Commit MetaInfo

Revision2bce2592c368b2253527577ef3276045e2bee679 (tree)
Time2015-01-16 09:29:17
Authorkinoshita-eos <kinoshita@yasu...>
Commiterkinoshita-eos

Log Message

Add: PIONE tutorial about Sequence Method(or).
new file: SampleCode/PIONE/Basic13/Input/2.txt
new file: SampleCode/PIONE/Basic13/InputOr.pione
new file: SampleCode/PIONE/Basic13/OutputOr.pione

Change Summary

Incremental Difference

--- /dev/null
+++ b/SampleCode/PIONE/Basic13/Input/2.txt
@@ -0,0 +1 @@
1+Data2
--- /dev/null
+++ b/SampleCode/PIONE/Basic13/InputOr.pione
@@ -0,0 +1,6 @@
1+Rule Main
2+ input '1.txt' or '2.txt' or '3.txt'
3+ output 'out.txt'
4+Action
5+ cp {$I[1]} {$O[1]}
6+End
--- /dev/null
+++ b/SampleCode/PIONE/Basic13/OutputOr.pione
@@ -0,0 +1,13 @@
1+param $Mode := 1
2+
3+Rule Main
4+ output 'out1.txt' or 'out2.txt' or 'err.txt'
5+Action
6+ if [ {$Mode} -eq 1 ] ; then
7+ echo "Mode: {$Mode}" > {$O[1].nth(1)}
8+ elif [ {$Mode} -eq 2 ] ;then
9+ echo "Mode: {$Mode}" > {$O[1].nth(2)}
10+ else
11+ echo "Error: Mode {$Mode} is not Supported!" > {$O[1].nth(3)}
12+ fi
13+End
Show on old repository browser