Browse Source

added more missing (derived) files

terfloth@itemis.de 12 years ago
parent
commit
2db65fa6d9

+ 15 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/stextkeywordsinstatesandregions/ISTextKeywordsInStatesAndRegionsStatemachine.java

@@ -0,0 +1,15 @@
+package org.yakindu.scr.stextkeywordsinstatesandregions;
+import org.yakindu.scr.IStatemachine;
+
+public interface ISTextKeywordsInStatesAndRegionsStatemachine
+		extends
+			IStatemachine {
+
+	public interface SCIDefault {
+		public void raiseE();
+
+	}
+
+	public SCIDefault getSCIDefault();
+
+}

+ 165 - 0
test-plugins/org.yakindu.sct.generator.java.test/src-gen/org/yakindu/scr/stextkeywordsinstatesandregions/STextKeywordsInStatesAndRegionsStatemachine.java

@@ -0,0 +1,165 @@
+package org.yakindu.scr.stextkeywordsinstatesandregions;
+
+public class STextKeywordsInStatesAndRegionsStatemachine
+		implements
+			ISTextKeywordsInStatesAndRegionsStatemachine {
+
+	private final class SCIDefaultImpl implements SCIDefault {
+
+		private boolean e;
+
+		public void raiseE() {
+			e = true;
+		}
+
+		public void clearEvents() {
+			e = false;
+		}
+
+	}
+
+	private SCIDefaultImpl sCIDefault;
+
+	public enum State {
+		default_var, operation_interface, operation_active, $NullState$
+	};
+
+	private final State[] stateVector = new State[2];
+
+	private int nextStateIndex;
+
+	public STextKeywordsInStatesAndRegionsStatemachine() {
+
+		sCIDefault = new SCIDefaultImpl();
+
+	}
+
+	public void init() {
+		for (int i = 0; i < 2; i++) {
+			stateVector[i] = State.$NullState$;
+		}
+
+		clearEvents();
+		clearOutEvents();
+
+	}
+
+	public void enter() {
+		entryAction();
+
+		nextStateIndex = 0;
+		stateVector[0] = State.default_var;
+
+		nextStateIndex = 1;
+		stateVector[1] = State.operation_interface;
+	}
+
+	public void exit() {
+		switch (stateVector[0]) {
+			case default_var :
+				nextStateIndex = 0;
+				stateVector[0] = State.$NullState$;
+				break;
+
+			default :
+				break;
+		}
+
+		switch (stateVector[1]) {
+			case operation_interface :
+				nextStateIndex = 1;
+				stateVector[1] = State.$NullState$;
+				break;
+
+			case operation_active :
+				nextStateIndex = 1;
+				stateVector[1] = State.$NullState$;
+				break;
+
+			default :
+				break;
+		}
+
+		exitAction();
+	}
+
+	protected void clearEvents() {
+		sCIDefault.clearEvents();
+
+	}
+
+	protected void clearOutEvents() {
+	}
+
+	public boolean isStateActive(State state) {
+		switch (state) {
+			case default_var :
+				return stateVector[0] == State.default_var;
+			case operation_interface :
+				return stateVector[1] == State.operation_interface;
+			case operation_active :
+				return stateVector[1] == State.operation_active;
+			default :
+				return false;
+		}
+	}
+
+	public SCIDefault getSCIDefault() {
+		return sCIDefault;
+	}
+
+	public void raiseE() {
+		sCIDefault.raiseE();
+	}
+
+	/* Entry action for statechart 'STextKeywordsInStatesAndRegions'. */
+	private void entryAction() {
+	}
+
+	/* Exit action for state 'STextKeywordsInStatesAndRegions'. */
+	private void exitAction() {
+	}
+
+	/* The reactions of state var. */
+	private void reactDefault_var() {
+	}
+
+	/* The reactions of state interface. */
+	private void reactOperation_interface() {
+		if (isStateActive(State.default_var)) {
+			nextStateIndex = 1;
+			stateVector[1] = State.$NullState$;
+
+			nextStateIndex = 1;
+			stateVector[1] = State.operation_active;
+		}
+	}
+
+	/* The reactions of state active. */
+	private void reactOperation_active() {
+	}
+
+	public void runCycle() {
+
+		clearOutEvents();
+
+		for (nextStateIndex = 0; nextStateIndex < stateVector.length; nextStateIndex++) {
+
+			switch (stateVector[nextStateIndex]) {
+				case default_var :
+					reactDefault_var();
+					break;
+				case operation_interface :
+					reactOperation_interface();
+					break;
+				case operation_active :
+					reactOperation_active();
+					break;
+				default :
+					// $NullState$
+			}
+		}
+
+		clearEvents();
+	}
+}