sccd.xml 934 B

12345678910111213141516171819202122232425262728
  1. <?xml version="1.1" ?>
  2. <diagram author="Sam Pieters" name="GlobalInputParameterTest">
  3. <description>
  4. Check if the model receives input with parameters.
  5. </description>
  6. <inport name="Input"/>
  7. <class name="MainApp" default="true">
  8. <constructor>
  9. <body>
  10. self.test_value = 0
  11. </body>
  12. </constructor>
  13. <scxml initial="state1">
  14. <state id="state1">
  15. <transition port="Input" event="input_event" target="../state2">
  16. <parameter name="int_value" />
  17. <script>
  18. self.test_value = int_value
  19. </script>
  20. </transition>
  21. </state>
  22. <state id="state2">
  23. <transition target="../state3" cond="self.test_value == 3"/>
  24. </state>
  25. <state id="state3" />
  26. </scxml>
  27. </class>
  28. </diagram>