example/SelectRuleByParam/SelectRuleByParam.pione in pione-0.5.0.alpha.2 vs example/SelectRuleByParam/SelectRuleByParam.pione in pione-0.5.0
- old
+ new
@@ -1,27 +1,18 @@
-.@ PackageName :: "SelectRuleByParam"
-
-Rule Main
+Rule SelectRuleByParam
output 'message.txt'
param $NAME := "A"
Flow
- case $NAME
+ case $NAME
when "A"
- $RULE := A
+ rule A
when "B"
- $RULE := B
+ rule B
when "C"
- $RULE := C
+ rule C
end
- rule RuleSelector {R: $RULE}
-End
-Rule RuleSelector
- output 'message.txt'
- param $R
-Flow
- rule $R
End
Rule A
output 'message.txt'
Action
@@ -37,6 +28,5 @@
Rule C
output 'message.txt'
Action
echo "This is rule C." > {$O[1]}
End
-