-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
49 changed files
with
5,880 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/.classpath
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<classpath> | ||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/> | ||
<classpathentry kind="src" path="src"/> | ||
<classpathentry kind="src" path="src-gen"/> | ||
<classpathentry kind="src" path="test"/> | ||
<classpathentry kind="src" path="test-gen"/> | ||
<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/5"/> | ||
<classpathentry kind="output" path="bin"/> | ||
</classpath> |
7 changes: 7 additions & 0 deletions
7
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/.gitignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
/bin/ | ||
*.l2s | ||
*.y2g | ||
*.g2u | ||
*.lgsm | ||
*.gsts | ||
*.uppaal |
23 changes: 23 additions & 0 deletions
23
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/.project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<projectDescription> | ||
<name>hu.bme.mit.gamma.tutorial.contract.finish</name> | ||
<comment></comment> | ||
<projects> | ||
</projects> | ||
<buildSpec> | ||
<buildCommand> | ||
<name>org.eclipse.xtext.ui.shared.xtextBuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
<buildCommand> | ||
<name>org.eclipse.jdt.core.javabuilder</name> | ||
<arguments> | ||
</arguments> | ||
</buildCommand> | ||
</buildSpec> | ||
<natures> | ||
<nature>org.eclipse.jdt.core.javanature</nature> | ||
<nature>org.eclipse.xtext.ui.shared.xtextNature</nature> | ||
</natures> | ||
</projectDescription> |
11 changes: 11 additions & 0 deletions
11
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/.settings/org.eclipse.jdt.core.prefs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
eclipse.preferences.version=1 | ||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled | ||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=11 | ||
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve | ||
org.eclipse.jdt.core.compiler.compliance=11 | ||
org.eclipse.jdt.core.compiler.debug.lineNumber=generate | ||
org.eclipse.jdt.core.compiler.debug.localVariable=generate | ||
org.eclipse.jdt.core.compiler.debug.sourceFile=generate | ||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error | ||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error | ||
org.eclipse.jdt.core.compiler.source=11 |
429 changes: 429 additions & 0 deletions
429
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/model/.Crossroad.gsm
Large diffs are not rendered by default.
Oops, something went wrong.
53 changes: 53 additions & 0 deletions
53
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/model/Controller/Controller.gcd
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
package controller | ||
import "/hu.bme.mit.gamma.tutorial.contract.finish/model/Interfaces/Interfaces.gcd" | ||
@TransitionPriority = order-based | ||
statechart Controller [ | ||
port PoliceInterrupt : requires PoliceInterrupt | ||
port SecondaryPolice : provides PoliceInterrupt | ||
port SecondaryControl : provides Control | ||
port PriorityControl : provides Control | ||
port PriorityPolice : provides PoliceInterrupt | ||
] { | ||
timeout SecondaryPreparesTimeout2 | ||
timeout InitTimeout3 | ||
timeout PriorityPreparesTimeout4 | ||
timeout SecondaryTimeout5 | ||
timeout PriorityTimeout6 | ||
transition from Entry0 to PriorityPrepares | ||
transition from Entry1 to Init | ||
transition from Init to Operating when timeout InitTimeout3 | ||
transition from Interrupted to Operating when PoliceInterrupt.police / raise | ||
PriorityPolice.police; raise SecondaryPolice.police; | ||
transition from Operating to Interrupted when PoliceInterrupt.police / raise | ||
PriorityPolice.police; raise SecondaryPolice.police; | ||
transition from Priority to PriorityPrepares when timeout PriorityTimeout6 | ||
transition from PriorityPrepares to Secondary when timeout PriorityPreparesTimeout4 | ||
transition from Secondary to SecondaryPrepares when timeout SecondaryTimeout5 | ||
transition from SecondaryPrepares to Priority when timeout SecondaryPreparesTimeout2 | ||
region main_region { | ||
state Operating { | ||
region operating { | ||
initial Entry0 | ||
state PriorityPrepares { | ||
entry / set PriorityPreparesTimeout4 := 1 s; raise PriorityControl.toggle; | ||
} | ||
state Secondary { | ||
entry / set SecondaryTimeout5 := 2 s; raise PriorityControl.toggle; raise | ||
SecondaryControl.toggle; | ||
} | ||
state SecondaryPrepares { | ||
entry / set SecondaryPreparesTimeout2 := 1 s; raise SecondaryControl.toggle; | ||
} | ||
state Priority { | ||
entry / set PriorityTimeout6 := 2 s; raise PriorityControl.toggle; raise | ||
SecondaryControl.toggle; | ||
} | ||
} | ||
} | ||
initial Entry1 | ||
state Init { | ||
entry / set InitTimeout3 := 2 s; raise PriorityControl.toggle; | ||
} | ||
state Interrupted | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
tutorial/hu.bme.mit.gamma.tutorial.contract.finish/model/Controller/Controller.ggen
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import "Interfaces/Interfaces.gcd" | ||
import external "Controller.sct" | ||
|
||
statechart { | ||
statechart : Controller | ||
mappings { | ||
map PriorityControl = Control as provided | ||
map SecondaryControl = Control as provided | ||
map PoliceInterrupt = PoliceInterrupt as required | ||
map PriorityPolice = PoliceInterrupt as provided | ||
map SecondaryPolice = PoliceInterrupt as provided | ||
} | ||
} |
Oops, something went wrong.