diff options
author | jsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68> | 2011-03-13 19:24:17 +0000 |
---|---|---|
committer | jsdelfino <jsdelfino@13f79535-47bb-0310-9956-ffa450edef68> | 2011-03-13 19:24:17 +0000 |
commit | f605cae050e85d7e915007cc9498924594d5b01c (patch) | |
tree | 4671cdaacca9cb5e232ee77c8a08b315d4b77a86 /sca-cpp/trunk | |
parent | ea149af7638e1edb2f652789ddf87cf111747b98 (diff) |
Add test components that evaluate python expressions.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1081207 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-cpp/trunk')
-rw-r--r-- | sca-cpp/trunk/modules/edit/apps/testlogic/app.composite | 68 | ||||
-rw-r--r-- | sca-cpp/trunk/modules/edit/palettes/logic/palette.composite | 16 |
2 files changed, 84 insertions, 0 deletions
diff --git a/sca-cpp/trunk/modules/edit/apps/testlogic/app.composite b/sca-cpp/trunk/modules/edit/apps/testlogic/app.composite index 415de6a677..f8b354f3e1 100644 --- a/sca-cpp/trunk/modules/edit/apps/testlogic/app.composite +++ b/sca-cpp/trunk/modules/edit/apps/testlogic/app.composite @@ -52,4 +52,72 @@ <service name="number"/> <property>3</property> </component> + <service name="eval" promote="eval"/> + <component t:x="287" t:y="37" name="eval" t:title="py expr" t:color="magenta1"> + <t:implementation.python script="nuvem/eval_.py"/> + <service name="eval"/> + <reference target="text3" name="py"/> + <reference name="ref"/> + </component> + <service name="eval2" promote="eval2"/> + <component t:x="287" t:y="130" name="eval2" t:title="py expr" t:color="magenta1"> + <t:implementation.python script="nuvem/eval_.py"/> + <service name="eval"/> + <reference target="text4" name="py"/> + <reference target="number3" name="ref"/> + </component> + <component t:x="350" t:y="160" name="number3" t:title="number" t:color="orange1"> + <t:implementation.python script="nuvem/number.py"/> + <service name="number"/> + <property>5</property> + </component> + <service name="exec" promote="exec"/> + <component t:x="289" t:y="365" name="exec" t:title="py script" t:color="magenta1"> + <t:implementation.python script="nuvem/exec_.py"/> + <service name="exec"/> + <reference target="get" name="py"/> + <reference target="number4" name="ref"/> + </component> + <component t:x="357" t:y="289" name="number4" t:title="number" t:color="orange1"> + <t:implementation.python script="nuvem/number.py"/> + <service name="number"/> + <property>5</property> + </component> + <component t:x="358" t:y="267" name="get" t:title="http get" t:color="green1"> + <implementation.cpp path="lib/http" library="libhttpget"/> + <service name="get"/> + <reference target="text5" name="url"/> + </component> + <service name="exec2" promote="exec2"/> + <component t:x="287" t:y="245" name="exec2" t:title="py script" t:color="magenta1"> + <t:implementation.python script="nuvem/exec_.py"/> + <service name="exec"/> + <reference target="text6" name="py"/> + <reference target="number5" name="ref"/> + </component> + <component t:x="350" t:y="37" name="text3" t:title="text" t:color="orange1"> + <t:implementation.python script="nuvem/text.py"/> + <service name="text"/> + <property>3.14116 * 5 * 5</property> + </component> + <component t:x="350" t:y="130" name="text4" t:title="text" t:color="orange1"> + <t:implementation.python script="nuvem/text.py"/> + <service name="text"/> + <property>3.14116 * ref.get(r) * ref.get(r)</property> + </component> + <component t:x="359" t:y="286" name="number5" t:title="number" t:color="orange1"> + <t:implementation.python script="nuvem/number.py"/> + <service name="number"/> + <property>5</property> + </component> + <component t:x="357" t:y="245" name="text6" t:title="text" t:color="orange1"> + <t:implementation.python script="nuvem/text.py"/> + <service name="text"/> + <property>val = 3.14116 * ref.get(r) * ref.get(r)</property> + </component> + <component t:x="423" t:y="365" name="text5" t:title="text" t:color="orange1"> + <t:implementation.python script="nuvem/text.py"/> + <service name="text"/> + <property>http://people.apache.org/~jsdelfino/tuscany/test/surface.py</property> + </component> </composite> diff --git a/sca-cpp/trunk/modules/edit/palettes/logic/palette.composite b/sca-cpp/trunk/modules/edit/palettes/logic/palette.composite index e24d93a987..0db971bdfd 100644 --- a/sca-cpp/trunk/modules/edit/palettes/logic/palette.composite +++ b/sca-cpp/trunk/modules/edit/palettes/logic/palette.composite @@ -29,6 +29,8 @@ <service name="equals" promote="equals"/> <service name="greater" promote="greater"/> <service name="lesser" promote="lesser"/> + <service name="eval" promote="eval"/> + <service name="exec" promote="exec"/> <component name="if" t:title="if" t:color="magenta1"> <t:implementation.python script="nuvem/if_.py"/> @@ -79,4 +81,18 @@ <reference name="value2"/> </component> + <component name="eval" t:title="py expr" t:color="magenta1"> + <t:implementation.python script="nuvem/eval_.py"/> + <service name="eval"/> + <reference name="py"/> + <reference name="ref"/> + </component> + + <component name="exec" t:title="py script" t:color="magenta1"> + <t:implementation.python script="nuvem/exec_.py"/> + <service name="exec"/> + <reference name="py"/> + <reference name="ref"/> + </component> + </composite> |