Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2012-09-14 10:56:57 -0400
committerHenrik Rentz-Reichert2012-09-14 10:56:57 -0400
commite85be57b8fa78975194d380f076585b26e22a991 (patch)
tree87a83a7f69d36122721e567b2f66cbb2a6560e21
parentd26072a00a2647cabfcda4dbf78291fb07ec2fdd (diff)
downloadorg.eclipse.etrice-e85be57b8fa78975194d380f076585b26e22a991.tar.gz
org.eclipse.etrice-e85be57b8fa78975194d380f076585b26e22a991.tar.xz
org.eclipse.etrice-e85be57b8fa78975194d380f076585b26e22a991.zip
[runtime.java, generator.java, ui.runtime, tutorials] changed generation of runner class
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/Blinky/Blinky.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyController.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyTop.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_Blinky.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_BlinkyRunner.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/HelloWorldTop.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorld.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorldRunner.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/Controller.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/GuiAdapter.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/PedLightsTop.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLights.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLightsRunner.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPingActor.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPongActor1.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PingPong/PingPongTop.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPong.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPongRunner.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPing.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPong.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingDataTop.java7
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystem.java20
-rw-r--r--examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystemRunner.java20
-rw-r--r--plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.xtend4
-rw-r--r--plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.xtend20
-rw-r--r--plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.java4
-rw-r--r--plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.java54
-rw-r--r--plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.modellib.java.zipbin41268 -> 41268 bytes
-rw-r--r--plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.runtime.java.zipbin36835 -> 37250 bytes
-rw-r--r--plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.tutorials.zipbin102806 -> 101076 bytes
-rw-r--r--runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/etunit/EtUnit.java1
-rw-r--r--runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemClassBase.java4
-rw-r--r--runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemRunnerBase.java46
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTest.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTestRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/DynTestee_ac.java91
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTest.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestVariableService.java60
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTest.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTestRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPong.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPongRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPort.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPortRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingData.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingDataRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTest.java4
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTestRunner.java20
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestChoicePoint.java2
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestConfigTest.java2
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestFSMGenerator.java2
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestHandler.java2
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestPingPongThread.java2
-rw-r--r--tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestSendingDataByValue.java2
55 files changed, 385 insertions, 370 deletions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/Blinky.java b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/Blinky.java
index 0e8a70843..848702cdf 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/Blinky.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/Blinky.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import room.basic.service.timing.*;
@@ -26,6 +27,7 @@ public class Blinky extends ActorClassBase {
private TrafficLight2 pedLights;
/*--------------------- end user code ---------------------*/
+
//--------------------- ports
protected BlinkyControlProtocollPort ControlPort = null;
@@ -37,6 +39,7 @@ public class Blinky extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_ControlPort = 1;
public static final int IFITEM_timer = 2;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -59,7 +62,11 @@ public class Blinky extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public BlinkyControlProtocollPort getControlPort (){
return this.ControlPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyController.java b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyController.java
index 0b53832ea..d1bbb6484 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyController.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyController.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import room.basic.service.timing.*;
@@ -18,6 +19,7 @@ import room.basic.service.timing.PTimeout.*;
public class BlinkyController extends ActorClassBase {
+
//--------------------- ports
protected BlinkyControlProtocollConjPort ControlPort = null;
@@ -29,6 +31,7 @@ public class BlinkyController extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_ControlPort = 1;
public static final int IFITEM_timer = 2;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -48,7 +51,11 @@ public class BlinkyController extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public BlinkyControlProtocollConjPort getControlPort (){
return this.ControlPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyTop.java b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyTop.java
index 1a5b1fca6..835aa051a 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyTop.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/BlinkyTop.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
@@ -15,6 +16,7 @@ import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
public class BlinkyTop extends ActorClassBase {
+
//--------------------- ports
//--------------------- saps
@@ -22,6 +24,7 @@ public class BlinkyTop extends ActorClassBase {
//--------------------- services
//--------------------- interface item IDs
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -39,7 +42,11 @@ public class BlinkyTop extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
//--------------------- lifecycle functions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_Blinky.java b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_Blinky.java
index 906d60d8e..db65462b8 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_Blinky.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_Blinky.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystem_Blinky extends SubSystemClassBase{
- public SubSystem_Blinky(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_Blinky(String name) {
+ super(name);
}
@Override
@@ -32,6 +32,7 @@ public class SubSystem_Blinky extends SubSystemClassBase{
@Override
public void instantiateActors(){
+
// all addresses
// Addresses for the Subsystem Systemport
Address addr_item_SystemPort_0 = new Address(0,0,112);
@@ -158,6 +159,17 @@ public class SubSystem_Blinky extends SubSystemClassBase{
addr_item__SubSystem_Blinky_application_controller,
addr_item__SubSystem_Blinky_timingService
});
-
- }
+ }
+
+
+ @Override
+ public void init(){
+ super.init();
+ }
+
+ @Override
+ public void stop(){
+ super.stop();
+ }
+
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_BlinkyRunner.java b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_BlinkyRunner.java
index c0a52d85c..0ed8432c2 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_BlinkyRunner.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/Blinky/SubSystem_BlinkyRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_BlinkyRunner extends SubSystemRunnerBase {
- static SubSystem_Blinky main_component = new SubSystem_Blinky(null, "SubSystem_Blinky");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_Blinky main_component = new SubSystem_Blinky("SubSystem_Blinky");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/HelloWorldTop.java b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/HelloWorldTop.java
index a4f9a5b17..b111b469d 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/HelloWorldTop.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/HelloWorldTop.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
@@ -15,6 +16,7 @@ import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
public class HelloWorldTop extends ActorClassBase {
+
//--------------------- ports
//--------------------- saps
@@ -22,6 +24,7 @@ public class HelloWorldTop extends ActorClassBase {
//--------------------- services
//--------------------- interface item IDs
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -39,7 +42,11 @@ public class HelloWorldTop extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
//--------------------- lifecycle functions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorld.java b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorld.java
index d0e64c0fe..d191fe044 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorld.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorld.java
@@ -15,8 +15,8 @@ import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
public class SubSystem_HelloWorld extends SubSystemClassBase{
- public SubSystem_HelloWorld(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_HelloWorld(String name) {
+ super(name);
}
@Override
@@ -31,6 +31,7 @@ public class SubSystem_HelloWorld extends SubSystemClassBase{
@Override
public void instantiateActors(){
+
// all addresses
// Addresses for the Subsystem Systemport
Address addr_item_SystemPort_0 = new Address(0,0,102);
@@ -66,6 +67,17 @@ public class SubSystem_HelloWorld extends SubSystemClassBase{
new Address[]{
addr_item__SubSystem_HelloWorld_application
});
-
- }
+ }
+
+
+ @Override
+ public void init(){
+ super.init();
+ }
+
+ @Override
+ public void stop(){
+ super.stop();
+ }
+
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorldRunner.java b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorldRunner.java
index 18c521c37..69bc3c720 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorldRunner.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/HelloWorld/SubSystem_HelloWorldRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_HelloWorldRunner extends SubSystemRunnerBase {
- static SubSystem_HelloWorld main_component = new SubSystem_HelloWorld(null, "SubSystem_HelloWorld");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_HelloWorld main_component = new SubSystem_HelloWorld("SubSystem_HelloWorld");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/Controller.java b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/Controller.java
index 3ff0cc492..10769b07e 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/Controller.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/Controller.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import room.basic.service.timing.*;
@@ -21,6 +22,7 @@ import org.eclipse.etrice.tutorials.PedLightGUI.*;
public class Controller extends ActorClassBase {
+
//--------------------- ports
protected PedControlProtocolPort ControlPort = null;
@@ -32,6 +34,7 @@ public class Controller extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_ControlPort = 1;
public static final int IFITEM_timer = 2;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -51,7 +54,11 @@ public class Controller extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PedControlProtocolPort getControlPort (){
return this.ControlPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/GuiAdapter.java b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/GuiAdapter.java
index 6eb33fee5..19da46cbf 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/GuiAdapter.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/GuiAdapter.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import PedLightsController.PedControlProtocol.*;
@@ -24,6 +25,7 @@ public class GuiAdapter extends ActorClassBase {
private TrafficLight2 pedLights;
/*--------------------- end user code ---------------------*/
+
//--------------------- ports
protected PedControlProtocolConjPort ControlPort = null;
@@ -33,6 +35,7 @@ public class GuiAdapter extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_ControlPort = 1;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -54,7 +57,11 @@ public class GuiAdapter extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PedControlProtocolConjPort getControlPort (){
return this.ControlPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/PedLightsTop.java b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/PedLightsTop.java
index 8bade7e5a..9f78affa6 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/PedLightsTop.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/PedLightsTop.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
@@ -15,6 +16,7 @@ import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
public class PedLightsTop extends ActorClassBase {
+
//--------------------- ports
//--------------------- saps
@@ -22,6 +24,7 @@ public class PedLightsTop extends ActorClassBase {
//--------------------- services
//--------------------- interface item IDs
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -39,7 +42,11 @@ public class PedLightsTop extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
//--------------------- lifecycle functions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLights.java b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLights.java
index 1f00a869b..69d45f21f 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLights.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLights.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSys_PedLights extends SubSystemClassBase{
- public SubSys_PedLights(IRTObject parent, String name) {
- super(parent, name);
+ public SubSys_PedLights(String name) {
+ super(name);
}
@Override
@@ -32,6 +32,7 @@ public class SubSys_PedLights extends SubSystemClassBase{
@Override
public void instantiateActors(){
+
// all addresses
// Addresses for the Subsystem Systemport
Address addr_item_SystemPort_0 = new Address(0,0,110);
@@ -148,6 +149,17 @@ public class SubSys_PedLights extends SubSystemClassBase{
addr_item__SubSys_PedLights_PedLightsTopRef_controller,
addr_item__SubSys_PedLights_timingService
});
-
- }
+ }
+
+
+ @Override
+ public void init(){
+ super.init();
+ }
+
+ @Override
+ public void stop(){
+ super.stop();
+ }
+
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLightsRunner.java b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLightsRunner.java
index b635412fc..fc90c0c46 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLightsRunner.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PedLightsController/SubSys_PedLightsRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSys_PedLightsRunner extends SubSystemRunnerBase {
- static SubSys_PedLights main_component = new SubSys_PedLights(null, "SubSys_PedLights");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSys_PedLights main_component = new SubSys_PedLights("SubSys_PedLights");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPingActor.java b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPingActor.java
index 76a2590e2..33ce21e3f 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPingActor.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPingActor.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import room.basic.service.timing.*;
@@ -18,6 +19,7 @@ import PingPong.PingPongProtocol.*;
public class MrPingActor extends ActorClassBase {
+
//--------------------- ports
protected PingPongProtocolConjReplPort PingPongPort = null;
@@ -29,6 +31,7 @@ public class MrPingActor extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_PingPongPort = 1;
public static final int IFITEM_timer = 2;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -48,7 +51,11 @@ public class MrPingActor extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PingPongProtocolConjReplPort getPingPongPort (){
return this.PingPongPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPongActor1.java b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPongActor1.java
index cf161f095..a536f0ad1 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPongActor1.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/MrPongActor1.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import PingPong.PingPongProtocol.*;
@@ -16,6 +17,7 @@ import PingPong.PingPongProtocol.*;
public class MrPongActor1 extends ActorClassBase {
+
//--------------------- ports
protected PingPongProtocolPort PingPongPort = null;
@@ -25,6 +27,7 @@ public class MrPongActor1 extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_PingPongPort = 1;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -43,7 +46,11 @@ public class MrPongActor1 extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PingPongProtocolPort getPingPongPort (){
return this.PingPongPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/PingPongTop.java b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/PingPongTop.java
index 74b5bead7..717664a48 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/PingPongTop.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/PingPongTop.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
@@ -15,6 +16,7 @@ import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
public class PingPongTop extends ActorClassBase {
+
//--------------------- ports
//--------------------- saps
@@ -22,6 +24,7 @@ public class PingPongTop extends ActorClassBase {
//--------------------- services
//--------------------- interface item IDs
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -39,7 +42,11 @@ public class PingPongTop extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
//--------------------- lifecycle functions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPong.java b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPong.java
index b0af8667b..4f18feb9b 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPong.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPong.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystem_PingPong extends SubSystemClassBase{
- public SubSystem_PingPong(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_PingPong(String name) {
+ super(name);
}
@Override
@@ -34,6 +34,7 @@ public class SubSystem_PingPong extends SubSystemClassBase{
@Override
public void instantiateActors(){
+
// all addresses
// Addresses for the Subsystem Systemport
Address addr_item_SystemPort_0 = new Address(0,0,111);
@@ -150,6 +151,17 @@ public class SubSystem_PingPong extends SubSystemClassBase{
addr_item__SubSystem_PingPong_application_MrPong1,
addr_item__SubSystem_PingPong_services
});
-
- }
+ }
+
+
+ @Override
+ public void init(){
+ super.init();
+ }
+
+ @Override
+ public void stop(){
+ super.stop();
+ }
+
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPongRunner.java b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPongRunner.java
index d840fd674..7de24e3ce 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPongRunner.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/PingPong/SubSystem_PingPongRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_PingPongRunner extends SubSystemRunnerBase {
- static SubSystem_PingPong main_component = new SubSystem_PingPong(null, "SubSystem_PingPong");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_PingPong main_component = new SubSystem_PingPong("SubSystem_PingPong");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPing.java b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPing.java
index ed4eecf49..5b9803d54 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPing.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPing.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import SendingData.PingPongProtocol.*;
@@ -16,6 +17,7 @@ import SendingData.PingPongProtocol.*;
public class MrPing extends ActorClassBase {
+
//--------------------- ports
protected PingPongProtocolConjPort PingPongPort = null;
@@ -25,6 +27,7 @@ public class MrPing extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_PingPongPort = 1;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -51,7 +54,11 @@ public class MrPing extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PingPongProtocolConjPort getPingPongPort (){
return this.PingPongPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPong.java b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPong.java
index cd00b7460..7d2903fcc 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPong.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/MrPong.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import SendingData.PingPongProtocol.*;
@@ -16,6 +17,7 @@ import SendingData.PingPongProtocol.*;
public class MrPong extends ActorClassBase {
+
//--------------------- ports
protected PingPongProtocolPort PingPongPort = null;
@@ -25,6 +27,7 @@ public class MrPong extends ActorClassBase {
//--------------------- interface item IDs
public static final int IFITEM_PingPongPort = 1;
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -43,7 +46,11 @@ public class MrPong extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
public PingPongProtocolPort getPingPongPort (){
return this.PingPongPort;
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingDataTop.java b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingDataTop.java
index 18b594d13..62782e691 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingDataTop.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingDataTop.java
@@ -7,6 +7,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
@@ -15,6 +16,7 @@ import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
public class SendingDataTop extends ActorClassBase {
+
//--------------------- ports
//--------------------- saps
@@ -22,6 +24,7 @@ public class SendingDataTop extends ActorClassBase {
//--------------------- services
//--------------------- interface item IDs
+
/*--------------------- attributes ---------------------*/
/*--------------------- operations ---------------------*/
@@ -39,7 +42,11 @@ public class SendingDataTop extends ActorClassBase {
// own service implementations
}
+
+
//--------------------- attribute setters and getters
+
+
//--------------------- port getters
//--------------------- lifecycle functions
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystem.java b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystem.java
index 69ecf97d5..2f27e1681 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystem.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystem.java
@@ -15,8 +15,8 @@ import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
public class SendingData_SubSystem extends SubSystemClassBase{
- public SendingData_SubSystem(IRTObject parent, String name) {
- super(parent, name);
+ public SendingData_SubSystem(String name) {
+ super(name);
}
@Override
@@ -31,6 +31,7 @@ public class SendingData_SubSystem extends SubSystemClassBase{
@Override
public void instantiateActors(){
+
// all addresses
// Addresses for the Subsystem Systemport
Address addr_item_SystemPort_0 = new Address(0,0,106);
@@ -114,6 +115,17 @@ public class SendingData_SubSystem extends SubSystemClassBase{
addr_item__SendingData_SubSystem_SendigDataTopRef_ref0,
addr_item__SendingData_SubSystem_SendigDataTopRef_ref1
});
-
- }
+ }
+
+
+ @Override
+ public void init(){
+ super.init();
+ }
+
+ @Override
+ public void stop(){
+ super.stop();
+ }
+
};
diff --git a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystemRunner.java b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystemRunner.java
index 15189bbaa..27bac6060 100644
--- a/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystemRunner.java
+++ b/examples/org.eclipse.etrice.tutorials/src-gen/SendingData/SendingData_SubSystemRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SendingData_SubSystemRunner extends SubSystemRunnerBase {
- static SendingData_SubSystem main_component = new SendingData_SubSystem(null, "SendingData_SubSystem");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SendingData_SubSystem main_component = new SendingData_SubSystem("SendingData_SubSystem");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.xtend b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.xtend
index 5ec7ae279..f5489ef7c 100644
--- a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.xtend
+++ b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.xtend
@@ -76,8 +76,8 @@ class SubSystemClassGen {
«cc.userCode(2)»
- public «comp.name»(IRTObject parent, String name) {
- super(parent, name);
+ public «comp.name»(String name) {
+ super(name);
}
@Override
diff --git a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.xtend b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.xtend
index 69dba9085..c0cc6cc1f 100644
--- a/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.xtend
+++ b/plugins/org.eclipse.etrice.generator.java/src/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.xtend
@@ -47,27 +47,15 @@ class SubSystemRunnerGen {
class «ssc.name+"Runner"» extends SubSystemRunnerBase {
- static «ssc.name» main_component = new «ssc.name»(null, "«ssc.name»");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ «ssc.name» main_component = new «ssc.name»("«ssc.name»");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
'''
diff --git a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.java b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.java
index 8e14ef1bd..3854a7427 100644
--- a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.java
+++ b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemClassGen.java
@@ -154,10 +154,10 @@ public class SubSystemClassGen {
_builder.append("public ");
String _name_2 = comp.getName();
_builder.append(_name_2, " ");
- _builder.append("(IRTObject parent, String name) {");
+ _builder.append("(String name) {");
_builder.newLineIfNotEmpty();
_builder.append("\t\t");
- _builder.append("super(parent, name);");
+ _builder.append("super(name);");
_builder.newLine();
_builder.append("\t");
_builder.append("}");
diff --git a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.java b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.java
index 99ffe08aa..fd0f3c901 100644
--- a/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.java
+++ b/plugins/org.eclipse.etrice.generator.java/xtend-gen/org/eclipse/etrice/generator/java/gen/SubSystemRunnerGen.java
@@ -80,26 +80,13 @@ public class SubSystemRunnerGen {
_builder.newLineIfNotEmpty();
_builder.newLine();
_builder.append("\t");
- _builder.append("static ");
- String _name_3 = ssc.getName();
- _builder.append(_name_3, " ");
- _builder.append(" main_component = new ");
- String _name_4 = ssc.getName();
- _builder.append(_name_4, " ");
- _builder.append("(null, \"");
- String _name_5 = ssc.getName();
- _builder.append(_name_5, " ");
- _builder.append("\");");
- _builder.newLineIfNotEmpty();
- _builder.newLine();
- _builder.append("\t");
_builder.append("/**");
_builder.newLine();
_builder.append(" ");
_builder.append("* main function");
_builder.newLine();
_builder.append(" ");
- _builder.append("* creates component and starts and stops the lifecycle");
+ _builder.append("* creates the main component and starts and stops the lifecycle");
_builder.newLine();
_builder.append(" ");
_builder.append("*/");
@@ -107,39 +94,24 @@ public class SubSystemRunnerGen {
_builder.append("\t");
_builder.append("public static void main(String[] args) {");
_builder.newLine();
- _builder.newLine();
- _builder.append("\t\t");
- _builder.append("System.out.println(\"*** T H E B E G I N ***\");");
- _builder.newLine();
- _builder.append("\t\t");
- _builder.newLine();
- _builder.append("\t\t");
- _builder.append("main_component.init(); // lifecycle init");
- _builder.newLine();
- _builder.append("\t\t");
- _builder.append("main_component.start(); // lifecycle start");
- _builder.newLine();
- _builder.newLine();
- _builder.append("\t\t");
- _builder.append("// application runs until quit ");
- _builder.newLine();
- _builder.append("\t\t");
- _builder.append("waitForQuit();");
- _builder.newLine();
- _builder.append("\t\t");
- _builder.newLine();
_builder.append("\t\t");
- _builder.append("// end the lifecycle");
+ _builder.append("// instantiate the main component");
_builder.newLine();
_builder.append("\t\t");
- _builder.append("main_component.stop(); // lifecycle stop");
- _builder.newLine();
+ String _name_3 = ssc.getName();
+ _builder.append(_name_3, " ");
+ _builder.append(" main_component = new ");
+ String _name_4 = ssc.getName();
+ _builder.append(_name_4, " ");
+ _builder.append("(\"");
+ String _name_5 = ssc.getName();
+ _builder.append(_name_5, " ");
+ _builder.append("\");");
+ _builder.newLineIfNotEmpty();
_builder.append("\t\t");
- _builder.append("main_component.destroy(); // lifecycle destroy");
- _builder.newLine();
_builder.newLine();
_builder.append("\t\t");
- _builder.append("System.out.println(\"*** T H E E N D ***\");");
+ _builder.append("run(main_component, args);");
_builder.newLine();
_builder.append("\t");
_builder.append("}");
diff --git a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.modellib.java.zip b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.modellib.java.zip
index aecdf03b0..d6f9062ad 100644
--- a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.modellib.java.zip
+++ b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.modellib.java.zip
Binary files differ
diff --git a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.runtime.java.zip b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.runtime.java.zip
index 75a6514dd..a82766b2f 100644
--- a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.runtime.java.zip
+++ b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.runtime.java.zip
Binary files differ
diff --git a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.tutorials.zip b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.tutorials.zip
index 47fe39c2e..76cdd3445 100644
--- a/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.tutorials.zip
+++ b/plugins/org.eclipse.etrice.ui.runtime/contents/org.eclipse.etrice.tutorials.zip
Binary files differ
diff --git a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/etunit/EtUnit.java b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/etunit/EtUnit.java
index 04233a314..1f13e88f4 100644
--- a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/etunit/EtUnit.java
+++ b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/etunit/EtUnit.java
@@ -52,6 +52,7 @@ public class EtUnit {
out.close();
out = new BufferedWriter(fstream);
+ out.write("etUnit report\n");
}
catch (IOException e) {
System.err.println("unable to open "+path);
diff --git a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemClassBase.java b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemClassBase.java
index 0eb198936..5a1cb1ac2 100644
--- a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemClassBase.java
+++ b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemClassBase.java
@@ -32,8 +32,8 @@ public abstract class SubSystemClassBase extends RTObject implements IEventRecei
private TestSemaphore testSem=null;
private int testErrorCode;
- public SubSystemClassBase(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystemClassBase(String name) {
+ super(null, name);
DebuggingService.getInstance().getAsyncLogger()
.setMSC(name + "_Async", "");
diff --git a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemRunnerBase.java b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemRunnerBase.java
index 0d1d9c039..14148e001 100644
--- a/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemRunnerBase.java
+++ b/runtime/org.eclipse.etrice.runtime.java/src/org/eclipse/etrice/runtime/java/modelbase/SubSystemRunnerBase.java
@@ -12,6 +12,42 @@ import java.io.InputStreamReader;
*/
public class SubSystemRunnerBase {
+ private static final String OPTION_RUN_AS_TEST = "-run_as_test";
+
+ private static boolean test = false;
+ protected static TestSemaphore testSem = new TestSemaphore(0);
+
+ protected static void run(SubSystemClassBase main_component, String[] args) {
+
+ System.out.println("*** T H E B E G I N ***");
+
+ for (String arg : args) {
+ if (arg.equals(OPTION_RUN_AS_TEST)) {
+
+ System.out.println("*** running as test");
+ test = true;
+ }
+ }
+
+ if (test)
+ main_component.setTestSemaphore(testSem);
+
+ main_component.init(); // lifecycle init
+ main_component.start(); // lifecycle start
+
+ // application runs until quit
+ if (test)
+ waitForTestcase();
+ else
+ waitForQuit();
+
+ // end the lifecycle
+ main_component.stop(); // lifecycle stop
+ main_component.destroy(); // lifecycle destroy
+
+ System.out.println("*** T H E E N D ***");
+ }
+
/**
* blocks until the String "quit" is entered on the console
*/
@@ -31,4 +67,14 @@ public class SubSystemRunnerBase {
}
}
+ public static void waitForTestcase() {
+ try{
+ System.out.println("=== waitForTestcase: before acq. semaphore, thread "+Thread.currentThread().getName());
+ testSem.acquire(1);
+ System.out.println("=== waitForTestcase: after acq. semaphore, thread "+Thread.currentThread().getName());
+ }catch(InterruptedException e){
+ System.out.println("Semaphore fault !");
+ }
+ }
+
}
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTest.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTest.java
index 5c7641adb..0c40f4d99 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTest.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTest.java
@@ -15,8 +15,8 @@ import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
public class SubSystem_CPTest extends SubSystemClassBase{
- public SubSystem_CPTest(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_CPTest(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTestRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTestRunner.java
index deef6a09a..ac612a848 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTestRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ChoicePointTest/SubSystem_CPTestRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_CPTestRunner extends SubSystemRunnerBase {
- static SubSystem_CPTest main_component = new SubSystem_CPTest(null, "SubSystem_CPTest");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_CPTest main_component = new SubSystem_CPTest("SubSystem_CPTest");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/DynTestee_ac.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/DynTestee_ac.java
index 0a35ec308..852a29879 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/DynTestee_ac.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/DynTestee_ac.java
@@ -9,6 +9,7 @@ import org.eclipse.etrice.runtime.java.modelbase.ActorClassBase;
import org.eclipse.etrice.runtime.java.modelbase.SubSystemClassBase;
import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
import org.eclipse.etrice.runtime.java.debugging.DebuggingService;
+import static org.eclipse.etrice.runtime.java.etunit.EtUnit.*;
import org.eclipse.etrice.integration.ConfigTest.TestCommProtocol.*;
@@ -41,10 +42,10 @@ public class DynTestee_ac extends ActorClassBase {
boolean blocker;
Dyn_DC1 dc_dump;
int int_dump;
- private DynConfigLock lock_blocker;
- private DynConfigLock lock_dc_i;
private DynConfigLock lock_int_i;
private DynConfigLock lock_blockMe;
+ private DynConfigLock lock_dc_i;
+ private DynConfigLock lock_blocker;
/*--------------------- operations ---------------------*/
//--------------------- construction
@@ -72,10 +73,10 @@ public class DynTestee_ac extends ActorClassBase {
this(parent, name, port_addr, peer_addr);
this.variableService = variableService;
- lock_blocker = new DynConfigLock();
- lock_dc_i = new DynConfigLock();
lock_int_i = new DynConfigLock();
lock_blockMe = new DynConfigLock();
+ lock_dc_i = new DynConfigLock();
+ lock_blocker = new DynConfigLock();
}
//--------------------- attribute setters and getters
@@ -92,44 +93,6 @@ public class DynTestee_ac extends ActorClassBase {
return this.int_dump;
}
- public boolean getBlocker(){
- if(lock_blocker == null)
- return blocker;
- else
- synchronized(lock_blocker){
- return blocker;
- }
- }
- public void setBlocker(boolean blocker){
- if(lock_blocker == null)
- this.blocker = blocker;
- else
- synchronized(lock_blocker){
- this.blocker = blocker;
- }
- }
- public DynConfigLock getBlockerLock(){
- return lock_blocker;
- }
- public Dyn_DC1 getDc_i(){
- if(lock_dc_i == null)
- return dc_i;
- else
- synchronized(lock_dc_i){
- return dc_i;
- }
- }
- public void setDc_i(Dyn_DC1 dc_i){
- if(lock_dc_i == null)
- this.dc_i = dc_i;
- else
- synchronized(lock_dc_i){
- this.dc_i = dc_i;
- }
- }
- public DynConfigLock getDc_iLock(){
- return lock_dc_i;
- }
public int getInt_i(){
if(lock_int_i == null)
return int_i;
@@ -168,14 +131,52 @@ public class DynTestee_ac extends ActorClassBase {
public DynConfigLock getBlockMeLock(){
return lock_blockMe;
}
- public void setAndWriteDc_dump(Dyn_DC1 dc_dump){
- setDc_dump(dc_dump);
- variableService.write(this.getInstancePath()+"/dc_dump", dc_dump);
+ public Dyn_DC1 getDc_i(){
+ if(lock_dc_i == null)
+ return dc_i;
+ else
+ synchronized(lock_dc_i){
+ return dc_i;
+ }
}
+ public void setDc_i(Dyn_DC1 dc_i){
+ if(lock_dc_i == null)
+ this.dc_i = dc_i;
+ else
+ synchronized(lock_dc_i){
+ this.dc_i = dc_i;
+ }
+ }
+ public DynConfigLock getDc_iLock(){
+ return lock_dc_i;
+ }
+ public boolean getBlocker(){
+ if(lock_blocker == null)
+ return blocker;
+ else
+ synchronized(lock_blocker){
+ return blocker;
+ }
+ }
+ public void setBlocker(boolean blocker){
+ if(lock_blocker == null)
+ this.blocker = blocker;
+ else
+ synchronized(lock_blocker){
+ this.blocker = blocker;
+ }
+ }
+ public DynConfigLock getBlockerLock(){
+ return lock_blocker;
+ }
public void setAndWriteInt_dump(int int_dump){
setInt_dump(int_dump);
variableService.write(this.getInstancePath()+"/int_dump", int_dump);
}
+ public void setAndWriteDc_dump(Dyn_DC1 dc_dump){
+ setDc_dump(dc_dump);
+ variableService.write(this.getInstancePath()+"/dc_dump", dc_dump);
+ }
//--------------------- port getters
public TestCommProtocolConjPort getConj_DynConfigPort (){
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTest.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTest.java
index 65ccc192e..6742af62a 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTest.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTest.java
@@ -16,8 +16,8 @@ import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
public class SubSystemConfigTest extends SubSystemClassBase{
- public SubSystemConfigTest(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystemConfigTest(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestRunner.java
index d2fb576b4..d1d7dd0e6 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystemConfigTestRunner extends SubSystemRunnerBase {
- static SubSystemConfigTest main_component = new SubSystemConfigTest(null, "SubSystemConfigTest");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystemConfigTest main_component = new SubSystemConfigTest("SubSystemConfigTest");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestVariableService.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestVariableService.java
index a16a8255b..d4ab0bc86 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestVariableService.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/ConfigTest/SubSystemConfigTestVariableService.java
@@ -56,45 +56,53 @@ public class SubSystemConfigTestVariableService extends VariableService{
}
try{
boolean changed = false;
- id = "/SubSystemConfigTest/top/testee2/dc_i/long_array_i";
- long[] _long_array_i = null;
+ id = "/SubSystemConfigTest/top/testee2/dc_i/int_i";
+ Integer _int_i = null;
object = values.get(id);
if(object != null){
- _long_array_i = ensureLongArray(object, 1);
- if(!Arrays.equals(_long_array_i, (long[])getDiffMap().get(id)))
+ _int_i = ensureInt(object);
+ if(!_int_i.equals((Integer)getDiffMap().get(id)))
changed = true;
} else
warning(id, "is missing");
- id = "/SubSystemConfigTest/top/testee2/dc_i/dc_i/double_i";
- Double _double_i = null;
+ id = "/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i";
+ char[] _char_i = null;
object = values.get(id);
if(object != null){
- _double_i = ensureDouble(object);
- if(!_double_i.equals((Double)getDiffMap().get(id)))
+ _char_i = ensureCharArray(object, 10);
+ if(!Arrays.equals(_char_i, (char[])getDiffMap().get(id)))
changed = true;
} else
warning(id, "is missing");
- id = "/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i";
- char[] _char_i = null;
+ id = "/SubSystemConfigTest/top/testee2/dc_i/long_array_i";
+ long[] _long_array_i = null;
object = values.get(id);
if(object != null){
- _char_i = ensureCharArray(object, 10);
- if(!Arrays.equals(_char_i, (char[])getDiffMap().get(id)))
+ _long_array_i = ensureLongArray(object, 1);
+ if(!Arrays.equals(_long_array_i, (long[])getDiffMap().get(id)))
changed = true;
} else
warning(id, "is missing");
- id = "/SubSystemConfigTest/top/testee2/dc_i/int_i";
- Integer _int_i = null;
+ id = "/SubSystemConfigTest/top/testee2/dc_i/dc_i/double_i";
+ Double _double_i = null;
object = values.get(id);
if(object != null){
- _int_i = ensureInt(object);
- if(!_int_i.equals((Integer)getDiffMap().get(id)))
+ _double_i = ensureDouble(object);
+ if(!_double_i.equals((Double)getDiffMap().get(id)))
changed = true;
} else
warning(id, "is missing");
if(changed)
synchronized(_top_testee2.getDc_iLock()){
if(_top_testee2.getDc_iLock().isUpdate()){
+ if(_int_i != null){
+ _top_testee2.getDc_i().setInt_i(_int_i);
+ getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/int_i", _int_i);
+ }
+ if(_char_i != null){
+ _top_testee2.getDc_i().getDc_i().setChar_i(_char_i);
+ getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i", _char_i);
+ }
if(_long_array_i != null){
_top_testee2.getDc_i().setLong_array_i(_long_array_i);
getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/long_array_i", _long_array_i);
@@ -103,14 +111,6 @@ public class SubSystemConfigTestVariableService extends VariableService{
_top_testee2.getDc_i().getDc_i().setDouble_i(_double_i);
getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/double_i", _double_i);
}
- if(_char_i != null){
- _top_testee2.getDc_i().getDc_i().setChar_i(_char_i);
- getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i", _char_i);
- }
- if(_int_i != null){
- _top_testee2.getDc_i().setInt_i(_int_i);
- getDiffMap().put("/SubSystemConfigTest/top/testee2/dc_i/int_i", _int_i);
- }
}
}
}catch(IllegalArgumentException e){
@@ -168,10 +168,10 @@ public class SubSystemConfigTestVariableService extends VariableService{
protected Map<String, Object> getAttributeValues(){
Map<String, Object> values = new HashMap<String, Object>();
values.put("/SubSystemConfigTest/top/testee2/int_i", _top_testee2.getInt_i());
+ values.put("/SubSystemConfigTest/top/testee2/dc_i/int_i", _top_testee2.getDc_i().getInt_i());
+ values.put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i", toObjectArray(_top_testee2.getDc_i().getDc_i().getChar_i()));
values.put("/SubSystemConfigTest/top/testee2/dc_i/long_array_i", toObjectArray(_top_testee2.getDc_i().getLong_array_i()));
values.put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/double_i", _top_testee2.getDc_i().getDc_i().getDouble_i());
- values.put("/SubSystemConfigTest/top/testee2/dc_i/dc_i/char_i", toObjectArray(_top_testee2.getDc_i().getDc_i().getChar_i()));
- values.put("/SubSystemConfigTest/top/testee2/dc_i/int_i", _top_testee2.getDc_i().getInt_i());
values.put("/SubSystemConfigTest/top/testee2/blockMe", _top_testee2.getBlockMe());
values.put("/SubSystemConfigTest/top/testee2/blocker", _top_testee2.getBlocker());
@@ -186,15 +186,15 @@ public class SubSystemConfigTestVariableService extends VariableService{
// DataClasses write operations
+ private void writeDataClass(String id, Dyn_DC2 object, Map<String, Object> map){
+ map.put(id+"/double_i", object.getDouble_i());
+ map.put(id+"/char_i", toObjectArray(object.getChar_i()));
+ }
private void writeDataClass(String id, Dyn_DC1 object, Map<String, Object> map){
map.put(id+"/int_i", object.getInt_i());
map.put(id+"/long_array_i", toObjectArray(object.getLong_array_i()));
writeDataClass(id+"/dc_i", object.getDc_i(), map);
}
- private void writeDataClass(String id, Dyn_DC2 object, Map<String, Object> map){
- map.put(id+"/double_i", object.getDouble_i());
- map.put(id+"/char_i", toObjectArray(object.getChar_i()));
- }
@Override
protected int getPollingTimerUser(){
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTest.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTest.java
index 3d0dbffb1..99f869776 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTest.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTest.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystem_HandlerTest extends SubSystemClassBase{
- public SubSystem_HandlerTest(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_HandlerTest(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTestRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTestRunner.java
index 8b1f1aeb0..aae766fec 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTestRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/HandlerTest/SubSystem_HandlerTestRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_HandlerTestRunner extends SubSystemRunnerBase {
- static SubSystem_HandlerTest main_component = new SubSystem_HandlerTest(null, "SubSystem_HandlerTest");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_HandlerTest main_component = new SubSystem_HandlerTest("SubSystem_HandlerTest");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPong.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPong.java
index 64139b1d4..e2547467b 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPong.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPong.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystem_PingPong extends SubSystemClassBase{
- public SubSystem_PingPong(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_PingPong(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPongRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPongRunner.java
index 138b60d34..406588a1d 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPongRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTest/SubSystem_PingPongRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_PingPongRunner extends SubSystemRunnerBase {
- static SubSystem_PingPong main_component = new SubSystem_PingPong(null, "SubSystem_PingPong");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_PingPong main_component = new SubSystem_PingPong("SubSystem_PingPong");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPort.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPort.java
index 7ffdf1a68..1115ffc4f 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPort.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPort.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystem_PingPongReplPort extends SubSystemClassBase{
- public SubSystem_PingPongReplPort(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystem_PingPongReplPort(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPortRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPortRunner.java
index 3019e0f17..cdf516fe5 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPortRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/PingPongThreadTestReplPort/SubSystem_PingPongReplPortRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystem_PingPongReplPortRunner extends SubSystemRunnerBase {
- static SubSystem_PingPongReplPort main_component = new SubSystem_PingPongReplPort(null, "SubSystem_PingPongReplPort");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystem_PingPongReplPort main_component = new SubSystem_PingPongReplPort("SubSystem_PingPongReplPort");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingData.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingData.java
index c0b3dc9d5..97037c2ac 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingData.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingData.java
@@ -15,8 +15,8 @@ import org.eclipse.etrice.runtime.java.modelbase.InterfaceItemBase;
public class SubSys_SendingData extends SubSystemClassBase{
- public SubSys_SendingData(IRTObject parent, String name) {
- super(parent, name);
+ public SubSys_SendingData(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingDataRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingDataRunner.java
index ce6cce587..952a338f9 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingDataRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/SendingDataByValueTest/SubSys_SendingDataRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSys_SendingDataRunner extends SubSystemRunnerBase {
- static SubSys_SendingData main_component = new SubSys_SendingData(null, "SubSys_SendingData");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSys_SendingData main_component = new SubSys_SendingData("SubSys_SendingData");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTest.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTest.java
index 6b3b43322..dd5565373 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTest.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTest.java
@@ -16,8 +16,8 @@ import room.basic.service.timing.*;
public class SubSystemHFSMTest extends SubSystemClassBase{
- public SubSystemHFSMTest(IRTObject parent, String name) {
- super(parent, name);
+ public SubSystemHFSMTest(String name) {
+ super(name);
}
@Override
diff --git a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTestRunner.java b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTestRunner.java
index da248b509..9a816ca6e 100644
--- a/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTestRunner.java
+++ b/tests/org.eclipse.etrice.integration.tests/src-gen/org/eclipse/etrice/integration/tests/SubSystemHFSMTestRunner.java
@@ -11,26 +11,14 @@ import org.eclipse.etrice.runtime.java.modelbase.SubSystemRunnerBase;
class SubSystemHFSMTestRunner extends SubSystemRunnerBase {
- static SubSystemHFSMTest main_component = new SubSystemHFSMTest(null, "SubSystemHFSMTest");
-
/**
* main function
- * creates component and starts and stops the lifecycle
+ * creates the main component and starts and stops the lifecycle
*/
public static void main(String[] args) {
-
- System.out.println("*** T H E B E G I N ***");
+ // instantiate the main component
+ SubSystemHFSMTest main_component = new SubSystemHFSMTest("SubSystemHFSMTest");
- main_component.init(); // lifecycle init
- main_component.start(); // lifecycle start
-
- // application runs until quit
- waitForQuit();
-
- // end the lifecycle
- main_component.stop(); // lifecycle stop
- main_component.destroy(); // lifecycle destroy
-
- System.out.println("*** T H E E N D ***");
+ run(main_component, args);
}
};
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestChoicePoint.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestChoicePoint.java
index 37bf1777b..76de9eef6 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestChoicePoint.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestChoicePoint.java
@@ -28,7 +28,7 @@ public class IntegrationTestChoicePoint extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSystem_CPTest(null,"MainComponent");
+ main_component = new SubSystem_CPTest("MainComponent");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestConfigTest.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestConfigTest.java
index eccb2d9d4..20086662d 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestConfigTest.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestConfigTest.java
@@ -29,7 +29,7 @@ public class IntegrationTestConfigTest extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSystemConfigTest(null,"SubSystemConfigTest");
+ main_component = new SubSystemConfigTest("SubSystemConfigTest");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestFSMGenerator.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestFSMGenerator.java
index f9266a817..3eba845d0 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestFSMGenerator.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestFSMGenerator.java
@@ -26,7 +26,7 @@ public class IntegrationTestFSMGenerator extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSystemHFSMTest(null,"MainComponent");
+ main_component = new SubSystemHFSMTest("MainComponent");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestHandler.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestHandler.java
index e0353b2d3..e934b95f9 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestHandler.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestHandler.java
@@ -28,7 +28,7 @@ public class IntegrationTestHandler extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSystem_HandlerTest(null,"MainComponent");
+ main_component = new SubSystem_HandlerTest("MainComponent");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestPingPongThread.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestPingPongThread.java
index 560da4806..55b335373 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestPingPongThread.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestPingPongThread.java
@@ -26,7 +26,7 @@ public class IntegrationTestPingPongThread extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSystem_PingPong(null,"MainComponent");
+ main_component = new SubSystem_PingPong("MainComponent");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);
diff --git a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestSendingDataByValue.java b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestSendingDataByValue.java
index c9cfd5d3b..fd20f448f 100644
--- a/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestSendingDataByValue.java
+++ b/tests/org.eclipse.etrice.integration.tests/src/org/eclipse/etrice/integration/tests/IntegrationTestSendingDataByValue.java
@@ -26,7 +26,7 @@ public class IntegrationTestSendingDataByValue extends IntegrationTestBase {
@Before
public void setUp() throws Exception {
- main_component = new SubSys_SendingData(null,"MainComponent");
+ main_component = new SubSys_SendingData("MainComponent");
// hand over the semaphore to the subsystem
main_component.setTestSemaphore(this.testSem);

Back to the top