diff --git a/BankAccount/.project.orig b/BankAccount/.project.orig deleted file mode 100644 index ef8b682ba..000000000 --- a/BankAccount/.project.orig +++ /dev/null @@ -1,53 +0,0 @@ -<<<<<<< HEAD - - - BankAccount - - - - - - - - -======= - - - BankAccount - - - - - - de.ovgu.featureide.core.extensibleFeatureProjectBuilder - - - build - src - - - composer - de.ovgu.featureide.composer.ahead - - - equations - configs - - - source - features - - - - - org.eclipse.jdt.core.javabuilder - - - - - - org.eclipse.jdt.core.javanature - de.ovgu.featureide.core.featureProjectNature - - ->>>>>>> master diff --git a/BankAccount/model.xml.orig b/BankAccount/model.xml.orig deleted file mode 100644 index b9ed090b9..000000000 --- a/BankAccount/model.xml.orig +++ /dev/null @@ -1,26 +0,0 @@ - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - -<<<<<<< HEAD -======= - ->>>>>>> master - - - diff --git a/BankAccountOO/.classpath.orig b/BankAccountOO/.classpath.orig deleted file mode 100644 index 3c12f129f..000000000 --- a/BankAccountOO/.classpath.orig +++ /dev/null @@ -1,37 +0,0 @@ -<<<<<<< HEAD -<<<<<<<< HEAD:BankAccountOO/.classpath - - - - - - -======== - - - - - - - - - - - ->>>>>>>> master:de.tu_bs.cs.isf.cbc.statistics.ui/.classpath -======= - - -<<<<<<<< HEAD:ElevatorCorC/.classpath - -======== - - - - - ->>>>>>>> master:BankAccountOO/.classpath - - - ->>>>>>> master diff --git a/BankAccountOO/.project.orig b/BankAccountOO/.project.orig deleted file mode 100644 index 6204d433a..000000000 --- a/BankAccountOO/.project.orig +++ /dev/null @@ -1,53 +0,0 @@ - - -<<<<<<< HEAD - BankAccountOO -======= -<<<<<<<< HEAD:EmailFeatureInteraction/.project - EmailFeatureInteraction -======== - BankAccountOO ->>>>>>>> master:BankAccountOO/.project ->>>>>>> master - - - - - -<<<<<<< HEAD - de.ovgu.featureide.core.extensibleFeatureProjectBuilder - - - build - src - - - composer - de.ovgu.featureide.composer.ahead - - - equations - configs - - - source - features - - - - -======= ->>>>>>> master - org.eclipse.jdt.core.javabuilder - - - - - - org.eclipse.jdt.core.javanature -<<<<<<< HEAD - de.ovgu.featureide.core.featureProjectNature -======= ->>>>>>> master - - diff --git a/BankAccountOO/src/.gitkeep.orig b/BankAccountOO/src/.gitkeep.orig deleted file mode 100644 index f83932533..000000000 --- a/BankAccountOO/src/.gitkeep.orig +++ /dev/null @@ -1,7 +0,0 @@ -/.gitkeep -<<<<<<< HEAD -/Account_helper.java -======= -/Account.java -/Application.java ->>>>>>> master diff --git a/Banking-Evaluation/.project.orig b/Banking-Evaluation/.project.orig deleted file mode 100644 index 347523d62..000000000 --- a/Banking-Evaluation/.project.orig +++ /dev/null @@ -1,29 +0,0 @@ - - - Banking-Evaluation - - - - - - org.eclipse.xtext.ui.shared.xtextBuilder - - - - - org.eclipse.jdt.core.javabuilder - - - - - de.tu_bs.cs.isf.lattice.latticeProjectBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.xtext.ui.shared.xtextNature - de.tu_bs.cs.isf.lattice.LatticeNature - - diff --git a/Banking-Evaluation/diagrams/Account/update.diagram.orig b/Banking-Evaluation/diagrams/Account/update.diagram.orig deleted file mode 100644 index 4edd4b882..000000000 --- a/Banking-Evaluation/diagrams/Account/update.diagram.orig +++ /dev/null @@ -1,4686 +0,0 @@ - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - -======== - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - -======== - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Elevator/continueInDirection.diagram - -======== - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/update.diagram - - - - - - - - - - - - - - - - - diff --git a/Banking-Evaluation/diagrams/Account/updateBalance.diagram.orig b/Banking-Evaluation/diagrams/Account/updateBalance.diagram.orig deleted file mode 100644 index 10f502888..000000000 --- a/Banking-Evaluation/diagrams/Account/updateBalance.diagram.orig +++ /dev/null @@ -1,1877 +0,0 @@ - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - -======== - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - -======== - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - -======== - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - -======== - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getNameWithKeyword.diagram - - - - - - - - - - - - - - - - - - - - - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Account/updateBalance.diagram - - - - - - - - - - - - - - - - - diff --git a/Banking-Evaluation/diagrams/Transaction/lock.diagram.orig b/Banking-Evaluation/diagrams/Transaction/lock.diagram.orig deleted file mode 100644 index 66fd12967..000000000 --- a/Banking-Evaluation/diagrams/Transaction/lock.diagram.orig +++ /dev/null @@ -1,2502 +0,0 @@ - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - -======== - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - -======== - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - -======== - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - -======== - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - -======== - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - -======== - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - - - - - - - - - - - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountCorC/src/Account/bankAccountUpdate.diagram - -======== - ->>>>>>>> master:Banking-Evaluation/diagrams/Transaction/lock.diagram - - - - - - - - - - - - - - - - diff --git a/Elevator/features/Base/Elevator/Elevator.diagram.orig b/Elevator/features/Base/Elevator/Elevator.diagram.orig deleted file mode 100644 index b71df4228..000000000 --- a/Elevator/features/Base/Elevator/Elevator.diagram.orig +++ /dev/null @@ -1,4039 +0,0 @@ - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getClientByAdress.diagram - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Elevator/Elevator.diagram - - - - - - - - - - - - - - - - diff --git a/Elevator/features/Base/Environment/createEnvironment.diagram.orig b/Elevator/features/Base/Environment/createEnvironment.diagram.orig deleted file mode 100644 index 51fce6a5a..000000000 --- a/Elevator/features/Base/Environment/createEnvironment.diagram.orig +++ /dev/null @@ -1,1960 +0,0 @@ - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - -======== - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - -======== - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - -======== - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - -======== - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - -======== - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - -======== - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - -======== - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - -<<<<<<<< HEAD:ElevatorOO/features/Base/Floor/Floor.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - ->>>>>>>> master:Elevator/features/Base/Environment/createEnvironment.diagram - - - - - - - - - - - - - - - - diff --git a/ElevatorCorC/.DS_Store.orig b/ElevatorCorC/.DS_Store.orig deleted file mode 100644 index 386539117..000000000 Binary files a/ElevatorCorC/.DS_Store.orig and /dev/null differ diff --git a/EmailFeatureInteraction/.project.orig b/EmailFeatureInteraction/.project.orig deleted file mode 100644 index 4c71e9eac..000000000 --- a/EmailFeatureInteraction/.project.orig +++ /dev/null @@ -1,21 +0,0 @@ - - -<<<<<<<< HEAD:EmailFeatureInteraction/.project - EmailFeatureInteraction -======== - BankAccountOO ->>>>>>>> master:BankAccountOO/.project - - - - - - org.eclipse.jdt.core.javabuilder - - - - - - org.eclipse.jdt.core.javanature - - diff --git a/EmailOO/.classpath.orig b/EmailOO/.classpath.orig deleted file mode 100644 index 2ed4e4d40..000000000 --- a/EmailOO/.classpath.orig +++ /dev/null @@ -1,14 +0,0 @@ - - -<<<<<<<< HEAD:BankAccountCorC/.classpath - -======== - - - - - ->>>>>>>> master:EmailOO/.classpath - - - diff --git a/EmailOO/src/Client/Client.diagram.orig b/EmailOO/src/Client/Client.diagram.orig deleted file mode 100644 index 0d9a2e87d..000000000 --- a/EmailOO/src/Client/Client.diagram.orig +++ /dev/null @@ -1,2756 +0,0 @@ - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - -<<<<<<<< HEAD:BankAccountOO/features/BankAccount/Account/update.diagram - -======== - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/Client.diagram - - - - - - - - - - - - - - - - diff --git a/EmailOO/src/Client/resetClients.diagram.orig b/EmailOO/src/Client/resetClients.diagram.orig deleted file mode 100644 index 52a3a9119..000000000 --- a/EmailOO/src/Client/resetClients.diagram.orig +++ /dev/null @@ -1,1737 +0,0 @@ - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - -======== - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - -======== - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - -======== - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - -======== - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - -======== - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - -======== - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - -======== - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - -======== - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - -======== - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - -======== - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - -======== - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - -======== - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - -======== - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - -======== - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - -======== - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - -<<<<<<<< HEAD:EmailCorC/src/Client/getName.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======== - - - - - - - - - - - - - - - - ->>>>>>>> master:EmailOO/src/Client/resetClients.diagram - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/IntegerListOO/.classpath.orig b/IntegerListOO/.classpath.orig deleted file mode 100644 index e679e5690..000000000 --- a/IntegerListOO/.classpath.orig +++ /dev/null @@ -1,29 +0,0 @@ -<<<<<<< HEAD - - - - - - -======= -<<<<<<<< HEAD:de.tu_bs.cs.isf.cbc.statistics.ui/.classpath - - - - - - - -======== - - - - - - - - - - ->>>>>>>> master:IntegerListOO/.classpath ->>>>>>> master diff --git a/IntegerListOO/.project.orig b/IntegerListOO/.project.orig deleted file mode 100644 index 8ffa1f833..000000000 --- a/IntegerListOO/.project.orig +++ /dev/null @@ -1,53 +0,0 @@ - - -<<<<<<< HEAD - IntegerListOO -======= -<<<<<<<< HEAD:EmailCorC/.project - EmailCorC -======== - IntegerListOO ->>>>>>>> master:IntegerListOO/.project ->>>>>>> master - - - - - -<<<<<<< HEAD - de.ovgu.featureide.core.extensibleFeatureProjectBuilder - - - build - src - - - composer - de.ovgu.featureide.composer.ahead - - - equations - configs - - - source - features - - - - -======= ->>>>>>> master - org.eclipse.jdt.core.javabuilder - - - - - - org.eclipse.jdt.core.javanature -<<<<<<< HEAD - de.ovgu.featureide.core.featureProjectNature -======= ->>>>>>> master - - diff --git a/IntegerListOO/src/.gitkeep.orig b/IntegerListOO/src/.gitkeep.orig deleted file mode 100644 index bbf00c051..000000000 --- a/IntegerListOO/src/.gitkeep.orig +++ /dev/null @@ -1,6 +0,0 @@ -<<<<<<< HEAD -/.gitkeep -======= -/.gitkeep -/IntList.java ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.exceptions/.classpath.orig b/de.tu-bs.cs.isf.cbc.exceptions/.classpath.orig deleted file mode 100644 index 9a78ee038..000000000 --- a/de.tu-bs.cs.isf.cbc.exceptions/.classpath.orig +++ /dev/null @@ -1,11 +0,0 @@ - - -<<<<<<<< HEAD:EmailCorC/.classpath - -======== - - ->>>>>>>> master:de.tu-bs.cs.isf.cbc.exceptions/.classpath - - - diff --git a/de.tu-bs.cs.isf.cbc.exceptions/.project.orig b/de.tu-bs.cs.isf.cbc.exceptions/.project.orig deleted file mode 100644 index e5342e7af..000000000 --- a/de.tu-bs.cs.isf.cbc.exceptions/.project.orig +++ /dev/null @@ -1,32 +0,0 @@ - - -<<<<<<<< HEAD:de.tu_bs.cs.isf.cbc.cbcclass.model/.project - de.tu_bs.cs.isf.cbc.cbcclass.model -======== - de.tu-bs.cs.isf.cbc.exceptions ->>>>>>>> master:de.tu-bs.cs.isf.cbc.exceptions/.project - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.jdt.core.javanature - org.eclipse.pde.PluginNature - - diff --git a/de.tu-bs.cs.isf.cbc.model/META-INF/MANIFEST.MF.orig b/de.tu-bs.cs.isf.cbc.model/META-INF/MANIFEST.MF.orig deleted file mode 100644 index 0ae9f4f96..000000000 --- a/de.tu-bs.cs.isf.cbc.model/META-INF/MANIFEST.MF.orig +++ /dev/null @@ -1,42 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: %pluginName -Bundle-SymbolicName: de.tu-bs.cs.isf.cbc.model;singleton:=true -Automatic-Module-Name: de.tu-bs.cs.isf.cbc.model -Bundle-Version: 0.1.0.qualifier -Bundle-ClassPath: . -Bundle-Vendor: %providerName -Bundle-Localization: plugin -Bundle-RequiredExecutionEnvironment: JavaSE-1.8 -<<<<<<< HEAD -Export-Package: de.tu_bs.cs.isf.cbc.cbcmodel, - de.tu_bs.cs.isf.cbc.cbcmodel.impl, - de.tu_bs.cs.isf.cbc.cbcmodel.util -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.emf.ecore;visibility:=reexport, - de.tu_bs.cs.isf.cbc.cbcclass.model;visibility:=reexport -Bundle-ActivationPolicy: lazy -Import-Package: de.tu_bs.cs.isf.cbc.util, - helper -======= -Export-Package: de.tu_bs.cs.isf.cbc.cbcclass, - de.tu_bs.cs.isf.cbc.cbcclass.impl, - de.tu_bs.cs.isf.cbc.cbcclass.util, - de.tu_bs.cs.isf.cbc.cbcmodel, - de.tu_bs.cs.isf.cbc.cbcmodel.impl, - de.tu_bs.cs.isf.cbc.cbcmodel.util -Require-Bundle: org.eclipse.core.runtime, - org.eclipse.xtext, - org.eclipse.xtext.xbase, - org.eclipse.equinox.common;bundle-version="3.5.0", - org.eclipse.xtext.common.types, - org.eclipse.xtext.xbase.lib;bundle-version="2.13.0", - org.antlr.runtime;bundle-version="[3.2.0,3.2.1)", - org.objectweb.asm;bundle-version="[9.0.0,10.0.0)";resolution:=optional, - org.eclipse.xtext.util, - org.eclipse.xtend.lib;bundle-version="2.13.0", - org.eclipse.emf.common, - org.eclipse.emf.ecore;visibility:=reexport -Import-Package: org.apache.log4j -Bundle-ActivationPolicy: lazy ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.model/build.properties.orig b/de.tu-bs.cs.isf.cbc.model/build.properties.orig deleted file mode 100644 index 8ef2cb119..000000000 --- a/de.tu-bs.cs.isf.cbc.model/build.properties.orig +++ /dev/null @@ -1,37 +0,0 @@ -# - -<<<<<<< HEAD -======= -source.. = src/,\ - src-gen/,\ - xtend-gen/ ->>>>>>> master -bin.includes = .,\ - model/,\ - META-INF/,\ - plugin.xml,\ - plugin.properties -<<<<<<< HEAD -jars.compile.order = . -source.. = src/ -output.. = bin/ -======= -bin.excludes = **/*.mwe2,\ - **/*.xtend -jars.compile.order = . -source.. = src-gen/,\ - src -output.. = bin/ -additional.bundles = org.eclipse.xtext.xbase,\ - org.eclipse.xtext.common.types,\ - org.eclipse.xtext.xtext.generator,\ - org.eclipse.emf.codegen.ecore,\ - org.eclipse.emf.mwe.utils,\ - org.eclipse.emf.mwe2.launch,\ - org.eclipse.emf.mwe2.lib,\ - org.objectweb.asm,\ - org.apache.commons.logging,\ - org.apache.log4j,\ - com.ibm.icu - ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.aird.orig b/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.aird.orig deleted file mode 100644 index 7c2c16ab0..000000000 --- a/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.aird.orig +++ /dev/null @@ -1,4586 +0,0 @@ - - -<<<<<<< HEAD - -======= - ->>>>>>> master - cbcmodel.ecore - pathmap:/javaclass/org.eclipse.emf.ecore.EObject.java - pathmap:/javaclass/java.lang.String.java - pathmap:/javaclass/org.eclipse.emf.ecore.EClass.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.Resource.java - pathmap:/javaclass/org.eclipse.emf.ecore.EStructuralFeature.java - pathmap:/javaclass/org.eclipse.emf.ecore.EReference.java - pathmap:/javaclass/org.eclipse.emf.common.util.EList.java - pathmap:/javaclass/org.eclipse.emf.common.util.TreeIterator.java - pathmap:/javaclass/java.lang.Object.java - pathmap:/javaclass/org.eclipse.emf.ecore.EOperation.java - pathmap:/javaclass/org.eclipse.emf.common.notify.Notifier.java - pathmap:/javaclass/org.eclipse.emf.ecore.EAttribute.java - pathmap:/javaclass/org.eclipse.emf.ecore.EGenericType.java - pathmap:/javaclass/org.eclipse.emf.ecore.EClassifier.java - pathmap:/javaclass/org.eclipse.emf.ecore.EDataType.java - pathmap:/javaclass/org.eclipse.emf.ecore.ETypeParameter.java - pathmap:/javaclass/org.eclipse.emf.ecore.ENamedElement.java - pathmap:/javaclass/org.eclipse.emf.ecore.EModelElement.java - pathmap:/javaclass/org.eclipse.emf.ecore.EAnnotation.java - pathmap:/javaclass/org.eclipse.emf.common.util.EMap.java - pathmap:/javaclass/java.util.Map.java - pathmap:/javaclass/java.util.Set.java - pathmap:/javaclass/java.util.Collection.java - pathmap:/javaclass/java.util.Iterator.java - pathmap:/javaclass/java.util.Spliterator.java - pathmap:/javaclass/java.util.stream.Stream.java - pathmap:/javaclass/java.lang.Iterable.java - pathmap:/javaclass/java.util.stream.IntStream.java - pathmap:/javaclass/java.util.function.ToIntFunction.java - pathmap:/javaclass/java.util.stream.LongStream.java - pathmap:/javaclass/java.util.function.ToLongFunction.java - pathmap:/javaclass/java.util.stream.DoubleStream.java - pathmap:/javaclass/java.util.function.ToDoubleFunction.java - pathmap:/javaclass/java.util.function.IntFunction.java - pathmap:/javaclass/java.util.Optional.java - pathmap:/javaclass/java.util.function.Supplier.java - pathmap:/javaclass/java.util.stream.Collector.java - pathmap:/javaclass/java.util.stream.Stream$Builder.java - pathmap:/javaclass/java.util.stream.BaseStream.java - pathmap:/javaclass/java.util.function.IntToLongFunction.java - pathmap:/javaclass/java.util.function.IntToDoubleFunction.java - pathmap:/javaclass/java.util.function.IntBinaryOperator.java - pathmap:/javaclass/java.util.OptionalInt.java - pathmap:/javaclass/java.util.function.ObjIntConsumer.java - pathmap:/javaclass/java.util.OptionalDouble.java - pathmap:/javaclass/java.util.IntSummaryStatistics.java - pathmap:/javaclass/java.lang.Integer.java - pathmap:/javaclass/java.util.stream.IntStream$Builder.java - pathmap:/javaclass/java.util.function.IntSupplier.java - pathmap:/javaclass/java.util.function.DoubleSupplier.java - pathmap:/javaclass/java.lang.Class.java - pathmap:/javaclass/java.lang.Comparable.java - pathmap:/javaclass/java.lang.Number.java - pathmap:/javaclass/java.lang.reflect.Constructor.java - pathmap:/javaclass/java.lang.ClassLoader.java - pathmap:/javaclass/java.security.ProtectionDomain.java - pathmap:/javaclass/java.lang.ref.SoftReference.java - pathmap:/javaclass/java.lang.Class$ReflectionData.java - pathmap:/javaclass/sun.reflect.generics.repository.ClassRepository.java - pathmap:/javaclass/java.io.ObjectStreamField.java - pathmap:/javaclass/sun.reflect.ReflectionFactory.java - pathmap:/javaclass/java.lang.Class$AnnotationData.java - pathmap:/javaclass/sun.reflect.annotation.AnnotationType.java - pathmap:/javaclass/java.lang.ClassValue$ClassValueMap.java - pathmap:/javaclass/java.lang.reflect.TypeVariable.java - pathmap:/javaclass/java.lang.reflect.Type.java - pathmap:/javaclass/java.lang.Package.java - pathmap:/javaclass/java.lang.reflect.Method.java - pathmap:/javaclass/java.lang.Class$EnclosingMethodInfo.java - pathmap:/javaclass/java.lang.reflect.Field.java - pathmap:/javaclass/java.io.InputStream.java - pathmap:/javaclass/java.net.URL.java - pathmap:/javaclass/sun.reflect.generics.factory.GenericsFactory.java - pathmap:/javaclass/java.lang.reflect.Executable.java - pathmap:/javaclass/sun.reflect.ConstantPool.java - pathmap:/javaclass/java.lang.Class$MethodArray.java - pathmap:/javaclass/java.lang.annotation.Annotation.java - pathmap:/javaclass/java.lang.reflect.AnnotatedType.java - pathmap:/javaclass/java.io.Serializable.java - pathmap:/javaclass/java.lang.reflect.GenericDeclaration.java - pathmap:/javaclass/sun.reflect.generics.repository.ConstructorRepository.java - pathmap:/javaclass/sun.reflect.ConstructorAccessor.java - pathmap:/javaclass/java.lang.StringBuilder.java - pathmap:/javaclass/sun.reflect.generics.tree.MethodTypeSignature.java - pathmap:/javaclass/sun.reflect.generics.repository.GenericDeclRepository.java - pathmap:/javaclass/sun.reflect.generics.tree.FormalTypeParameter.java - pathmap:/javaclass/sun.reflect.generics.tree.TypeSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.ReturnType.java - pathmap:/javaclass/sun.reflect.generics.tree.FieldTypeSignature.java - pathmap:/javaclass/sun.reflect.generics.visitor.Visitor.java - pathmap:/javaclass/sun.reflect.generics.tree.Signature.java - pathmap:/javaclass/sun.reflect.generics.visitor.TypeTreeVisitor.java - pathmap:/javaclass/sun.reflect.generics.tree.TypeTree.java - pathmap:/javaclass/sun.reflect.generics.tree.ClassTypeSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.ArrayTypeSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.TypeVariableSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.Wildcard.java - pathmap:/javaclass/sun.reflect.generics.tree.SimpleClassTypeSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.BottomSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.ByteSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.BooleanSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.ShortSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.CharSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.IntSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.LongSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.FloatSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.DoubleSignature.java - pathmap:/javaclass/sun.reflect.generics.tree.VoidDescriptor.java - pathmap:/javaclass/java.util.List.java - pathmap:/javaclass/java.util.ListIterator.java - pathmap:/javaclass/sun.reflect.generics.tree.TypeArgument.java - pathmap:/javaclass/sun.reflect.generics.tree.BaseType.java - pathmap:/javaclass/sun.reflect.generics.tree.Tree.java - pathmap:/javaclass/sun.reflect.generics.tree.ClassSignature.java - pathmap:/javaclass/sun.reflect.generics.repository.AbstractRepository.java - pathmap:/javaclass/sun.reflect.generics.visitor.Reifier.java - pathmap:/javaclass/java.lang.StringBuffer.java - pathmap:/javaclass/java.io.ObjectOutputStream.java - pathmap:/javaclass/java.lang.AbstractStringBuilder.java - pathmap:/javaclass/java.io.ObjectOutputStream$BlockDataOutputStream.java - pathmap:/javaclass/java.io.ObjectOutputStream$HandleTable.java - pathmap:/javaclass/java.io.ObjectOutputStream$ReplaceTable.java - pathmap:/javaclass/java.io.SerialCallbackContext.java - pathmap:/javaclass/java.io.ObjectOutputStream$PutFieldImpl.java - pathmap:/javaclass/java.io.ObjectOutputStream$DebugTraceInfoStack.java - pathmap:/javaclass/java.io.OutputStream.java - pathmap:/javaclass/java.io.ObjectOutputStream$PutField.java - pathmap:/javaclass/java.io.ObjectStreamClass.java - pathmap:/javaclass/java.lang.Enum.java - pathmap:/javaclass/java.io.Externalizable.java - pathmap:/javaclass/java.io.IOException.java - pathmap:/javaclass/java.io.ObjectOutput.java - pathmap:/javaclass/java.io.ObjectStreamConstants.java - pathmap:/javaclass/java.io.DataOutputStream.java - pathmap:/javaclass/java.io.DataOutput.java - pathmap:/javaclass/java.io.FilterOutputStream.java - pathmap:/javaclass/java.lang.Thread.java - pathmap:/javaclass/java.lang.Runnable.java - pathmap:/javaclass/java.lang.ThreadGroup.java - pathmap:/javaclass/java.security.AccessControlContext.java - pathmap:/javaclass/java.lang.ThreadLocal$ThreadLocalMap.java - pathmap:/javaclass/sun.nio.ch.Interruptible.java - pathmap:/javaclass/java.lang.StackTraceElement.java - pathmap:/javaclass/java.lang.RuntimePermission.java - pathmap:/javaclass/java.lang.Thread$UncaughtExceptionHandler.java - pathmap:/javaclass/java.lang.Throwable.java - pathmap:/javaclass/java.lang.Thread$State.java - pathmap:/javaclass/java.lang.ref.ReferenceQueue.java - pathmap:/javaclass/java.lang.ref.WeakReference.java - pathmap:/javaclass/java.lang.Void.java - pathmap:/javaclass/java.io.PrintStream.java - pathmap:/javaclass/java.util.Formatter.java - pathmap:/javaclass/java.io.BufferedWriter.java - pathmap:/javaclass/java.io.OutputStreamWriter.java - pathmap:/javaclass/java.nio.charset.Charset.java - pathmap:/javaclass/java.io.File.java - pathmap:/javaclass/java.util.Locale.java - pathmap:/javaclass/java.lang.Appendable.java - pathmap:/javaclass/java.io.Closeable.java - pathmap:/javaclass/java.util.Formatter$FormatString.java - pathmap:/javaclass/java.io.Flushable.java - pathmap:/javaclass/java.io.Writer.java - pathmap:/javaclass/sun.nio.cs.StreamEncoder.java - pathmap:/javaclass/java.nio.charset.CharsetEncoder.java - pathmap:/javaclass/java.nio.ByteBuffer.java - pathmap:/javaclass/java.nio.channels.WritableByteChannel.java - pathmap:/javaclass/java.nio.ByteOrder.java - pathmap:/javaclass/java.nio.ShortBuffer.java - pathmap:/javaclass/java.nio.IntBuffer.java - pathmap:/javaclass/java.nio.LongBuffer.java - pathmap:/javaclass/java.nio.FloatBuffer.java - pathmap:/javaclass/java.nio.DoubleBuffer.java - pathmap:/javaclass/java.nio.Buffer.java - pathmap:/javaclass/java.nio.channels.Channel.java - pathmap:/javaclass/java.nio.charset.CodingErrorAction.java - pathmap:/javaclass/java.nio.charset.CharsetDecoder.java - pathmap:/javaclass/java.nio.charset.CoderResult.java - pathmap:/javaclass/java.nio.charset.CoderResult$Cache.java - pathmap:/javaclass/java.nio.charset.spi.CharsetProvider.java - pathmap:/javaclass/java.lang.ThreadLocal.java - pathmap:/javaclass/java.util.SortedMap.java - pathmap:/javaclass/java.util.concurrent.atomic.AtomicInteger.java - pathmap:/javaclass/sun.misc.Unsafe.java - pathmap:/javaclass/java.io.FileSystem.java - pathmap:/javaclass/java.io.File$PathStatus.java - pathmap:/javaclass/java.nio.file.Path.java - pathmap:/javaclass/java.net.URI.java - pathmap:/javaclass/java.io.FilenameFilter.java - pathmap:/javaclass/java.io.FileFilter.java - pathmap:/javaclass/java.nio.file.FileSystem.java - pathmap:/javaclass/java.nio.file.LinkOption.java - pathmap:/javaclass/java.nio.file.WatchKey.java - pathmap:/javaclass/java.nio.file.WatchService.java - pathmap:/javaclass/java.nio.file.WatchEvent$Kind.java - pathmap:/javaclass/java.nio.file.WatchEvent$Modifier.java - pathmap:/javaclass/java.nio.file.Watchable.java - pathmap:/javaclass/java.nio.file.spi.FileSystemProvider.java - pathmap:/javaclass/java.nio.file.FileStore.java - pathmap:/javaclass/java.nio.file.PathMatcher.java - pathmap:/javaclass/java.nio.file.attribute.UserPrincipalLookupService.java - pathmap:/javaclass/java.nio.file.OpenOption.java - pathmap:/javaclass/java.nio.channels.FileChannel.java - pathmap:/javaclass/java.nio.file.attribute.FileAttribute.java - pathmap:/javaclass/java.nio.channels.AsynchronousFileChannel.java - pathmap:/javaclass/java.util.concurrent.ExecutorService.java - pathmap:/javaclass/java.nio.channels.SeekableByteChannel.java - pathmap:/javaclass/java.nio.file.DirectoryStream.java - pathmap:/javaclass/java.nio.file.DirectoryStream$Filter.java - pathmap:/javaclass/java.nio.file.CopyOption.java - pathmap:/javaclass/java.nio.file.AccessMode.java - pathmap:/javaclass/java.nio.file.attribute.FileAttributeView.java - pathmap:/javaclass/java.nio.file.attribute.BasicFileAttributes.java - pathmap:/javaclass/java.nio.channels.ReadableByteChannel.java - pathmap:/javaclass/java.nio.MappedByteBuffer.java - pathmap:/javaclass/java.nio.channels.FileChannel$MapMode.java - pathmap:/javaclass/java.nio.channels.FileLock.java - pathmap:/javaclass/java.nio.channels.GatheringByteChannel.java - pathmap:/javaclass/java.nio.channels.ScatteringByteChannel.java - pathmap:/javaclass/java.nio.channels.spi.AbstractInterruptibleChannel.java - pathmap:/javaclass/java.io.FileDescriptor.java - pathmap:/javaclass/java.lang.AutoCloseable.java - pathmap:/javaclass/java.nio.channels.InterruptibleChannel.java - pathmap:/javaclass/java.nio.channels.CompletionHandler.java - pathmap:/javaclass/java.util.concurrent.Future.java - pathmap:/javaclass/java.nio.channels.AsynchronousChannel.java - pathmap:/javaclass/java.util.concurrent.TimeUnit.java - pathmap:/javaclass/java.util.concurrent.Callable.java - pathmap:/javaclass/java.util.concurrent.Executor.java - pathmap:/javaclass/java.nio.channels.ByteChannel.java - pathmap:/javaclass/java.nio.file.attribute.AttributeView.java - pathmap:/javaclass/java.nio.file.attribute.FileTime.java - pathmap:/javaclass/java.nio.file.attribute.FileStoreAttributeView.java - pathmap:/javaclass/java.nio.file.attribute.UserPrincipal.java - pathmap:/javaclass/java.nio.file.attribute.GroupPrincipal.java - pathmap:/javaclass/java.security.Principal.java - pathmap:/javaclass/javax.security.auth.Subject.java - pathmap:/javaclass/java.security.PrivilegedAction.java - pathmap:/javaclass/java.security.PrivilegedExceptionAction.java - pathmap:/javaclass/java.nio.file.WatchEvent.java - pathmap:/javaclass/java.util.Locale$Cache.java - pathmap:/javaclass/sun.util.locale.BaseLocale.java - pathmap:/javaclass/sun.util.locale.LocaleExtensions.java - pathmap:/javaclass/java.util.Locale$Category.java - pathmap:/javaclass/java.lang.Character.java - pathmap:/javaclass/java.text.MessageFormat.java - pathmap:/javaclass/java.util.Locale$LanguageRange.java - pathmap:/javaclass/java.util.Locale$FilteringMode.java - pathmap:/javaclass/java.lang.Cloneable.java - pathmap:/javaclass/java.util.Locale$LocaleKey.java - pathmap:/javaclass/sun.util.locale.LocaleObjectCache.java - pathmap:/javaclass/sun.util.locale.LocaleObjectCache$CacheEntry.java - pathmap:/javaclass/sun.util.locale.BaseLocale$Cache.java - pathmap:/javaclass/sun.util.locale.BaseLocale$Key.java - pathmap:/javaclass/sun.util.locale.Extension.java - pathmap:/javaclass/sun.util.locale.InternalLocaleBuilder$CaseInsensitiveChar.java - pathmap:/javaclass/sun.util.locale.InternalLocaleBuilder$CaseInsensitiveString.java - pathmap:/javaclass/java.text.Format.java - pathmap:/javaclass/java.text.FieldPosition.java - pathmap:/javaclass/java.text.AttributedCharacterIterator.java - pathmap:/javaclass/java.text.ParsePosition.java - pathmap:/javaclass/java.text.CharacterIterator.java - pathmap:/javaclass/java.text.AttributedCharacterIterator$Attribute.java - pathmap:/javaclass/java.text.Format$Field.java - pathmap:/javaclass/java.text.Format$FieldDelegate.java - pathmap:/javaclass/java.security.DomainCombiner.java - pathmap:/javaclass/java.security.Permission.java - pathmap:/javaclass/sun.security.util.Debug.java - pathmap:/javaclass/java.security.PermissionCollection.java - pathmap:/javaclass/java.security.Guard.java - pathmap:/javaclass/java.util.Enumeration.java - pathmap:/javaclass/java.math.BigInteger.java - pathmap:/javaclass/java.util.Random.java - pathmap:/javaclass/java.util.concurrent.atomic.AtomicLong.java - pathmap:/javaclass/java.util.function.LongBinaryOperator.java - pathmap:/javaclass/java.lang.ThreadLocal$ThreadLocalMap$Entry.java - pathmap:/javaclass/java.security.BasicPermission.java - pathmap:/javaclass/java.lang.Throwable$PrintStreamOrWriter.java - pathmap:/javaclass/java.io.PrintWriter.java - pathmap:/javaclass/java.lang.ref.ReferenceQueue$Lock.java - pathmap:/javaclass/java.lang.ref.Reference.java - pathmap:/javaclass/java.lang.ref.Reference$Lock.java - pathmap:/javaclass/java.lang.Long.java - pathmap:/javaclass/java.lang.ClassNotFoundException.java - pathmap:/javaclass/java.io.ObjectStreamClass$ExceptionInfo.java - pathmap:/javaclass/java.io.ObjectStreamClass$FieldReflector.java - pathmap:/javaclass/java.io.ObjectStreamClass$ClassDataSlot.java - pathmap:/javaclass/java.lang.ReflectiveOperationException.java - pathmap:/javaclass/java.lang.Exception.java - pathmap:/javaclass/java.io.InvalidClassException.java - pathmap:/javaclass/java.io.ObjectStreamException.java - pathmap:/javaclass/java.io.ObjectInput.java - pathmap:/javaclass/java.io.DataInput.java - pathmap:/javaclass/java.io.SerializablePermission.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap.java - pathmap:/javaclass/java.security.cert.Certificate.java - pathmap:/javaclass/java.util.Vector.java - pathmap:/javaclass/java.util.HashMap.java - pathmap:/javaclass/java.lang.ClassLoader$NativeLibrary.java - pathmap:/javaclass/java.util.Stack.java - pathmap:/javaclass/java.lang.Boolean.java - pathmap:/javaclass/java.security.CodeSource.java - pathmap:/javaclass/sun.misc.URLClassPath.java - pathmap:/javaclass/java.lang.AssertionStatusDirectives.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$Node.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$CounterCell.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$KeySetView.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$ValuesView.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$EntrySetView.java - pathmap:/javaclass/java.util.function.ToDoubleBiFunction.java - pathmap:/javaclass/java.util.function.DoubleBinaryOperator.java - pathmap:/javaclass/java.util.function.ToLongBiFunction.java - pathmap:/javaclass/java.util.function.ToIntBiFunction.java - pathmap:/javaclass/java.util.AbstractMap.java - pathmap:/javaclass/java.util.concurrent.ConcurrentHashMap$CollectionView.java - pathmap:/javaclass/java.security.PublicKey.java - pathmap:/javaclass/java.security.Provider.java - pathmap:/javaclass/java.security.Key.java - pathmap:/javaclass/java.security.Provider$ServiceKey.java - pathmap:/javaclass/java.security.Provider$Service.java - pathmap:/javaclass/java.security.Provider$EngineDescription.java - pathmap:/javaclass/java.util.Properties.java - pathmap:/javaclass/java.security.Provider$UString.java - pathmap:/javaclass/java.io.Reader.java - pathmap:/javaclass/java.util.Properties$LineReader.java - pathmap:/javaclass/java.util.Hashtable.java - pathmap:/javaclass/java.lang.Readable.java - pathmap:/javaclass/java.util.Hashtable$Entry.java - pathmap:/javaclass/java.util.Dictionary.java - pathmap:/javaclass/java.util.RandomAccess.java - pathmap:/javaclass/java.util.AbstractList.java - pathmap:/javaclass/java.util.AbstractCollection.java - pathmap:/javaclass/java.util.HashMap$Node.java - pathmap:/javaclass/java.util.HashMap$TreeNode.java - pathmap:/javaclass/java.util.LinkedHashMap$Entry.java - pathmap:/javaclass/java.security.CodeSigner.java - pathmap:/javaclass/java.net.SocketPermission.java - pathmap:/javaclass/java.security.cert.CertificateFactory.java - pathmap:/javaclass/java.security.cert.CertPath.java - pathmap:/javaclass/java.security.Timestamp.java - pathmap:/javaclass/java.util.Date.java - pathmap:/javaclass/sun.util.calendar.BaseCalendar.java - pathmap:/javaclass/sun.util.calendar.BaseCalendar$Date.java - pathmap:/javaclass/sun.util.calendar.CalendarDate.java - pathmap:/javaclass/sun.util.calendar.AbstractCalendar.java - pathmap:/javaclass/sun.util.calendar.Era.java - pathmap:/javaclass/java.util.TimeZone.java - pathmap:/javaclass/java.time.ZoneId.java - pathmap:/javaclass/java.time.ZoneOffset.java - pathmap:/javaclass/java.time.temporal.TemporalAccessor.java - pathmap:/javaclass/java.time.format.TextStyle.java - pathmap:/javaclass/java.time.zone.ZoneRules.java - pathmap:/javaclass/java.time.temporal.TemporalField.java - pathmap:/javaclass/java.time.temporal.ValueRange.java - pathmap:/javaclass/java.time.temporal.TemporalQuery.java - pathmap:/javaclass/java.time.temporal.Temporal.java - pathmap:/javaclass/java.time.temporal.TemporalAdjuster.java - pathmap:/javaclass/java.time.temporal.TemporalUnit.java - pathmap:/javaclass/java.time.format.ResolverStyle.java - pathmap:/javaclass/java.time.Duration.java - pathmap:/javaclass/java.time.temporal.TemporalAmount.java - pathmap:/javaclass/java.math.BigDecimal.java - pathmap:/javaclass/java.math.BigDecimal$StringBuilderHelper.java - pathmap:/javaclass/java.math.MathContext.java - pathmap:/javaclass/java.math.RoundingMode.java - pathmap:/javaclass/java.math.MutableBigInteger.java - pathmap:/javaclass/java.time.zone.ZoneOffsetTransitionRule.java - pathmap:/javaclass/java.time.zone.ZoneOffsetTransition.java - pathmap:/javaclass/java.time.Month.java - pathmap:/javaclass/java.time.DayOfWeek.java - pathmap:/javaclass/java.time.zone.ZoneOffsetTransitionRule$TimeDefinition.java - pathmap:/javaclass/sun.util.calendar.CalendarSystem.java - pathmap:/javaclass/sun.util.calendar.Gregorian.java - pathmap:/javaclass/sun.util.calendar.Gregorian$Date.java - pathmap:/javaclass/java.net.InetAddress.java - pathmap:/javaclass/java.net.InetAddress$InetAddressHolder.java - pathmap:/javaclass/sun.net.spi.nameservice.NameService.java - pathmap:/javaclass/java.net.InetAddress$Cache.java - pathmap:/javaclass/java.net.InetAddressImpl.java - pathmap:/javaclass/java.net.NetworkInterface.java - pathmap:/javaclass/java.util.LinkedHashMap.java - pathmap:/javaclass/java.net.InetAddress$CacheEntry.java - pathmap:/javaclass/java.net.InetAddress$Cache$Type.java - pathmap:/javaclass/java.net.InterfaceAddress.java - pathmap:/javaclass/java.net.Inet4Address.java - pathmap:/javaclass/java.security.cert.CertificateFactorySpi.java - pathmap:/javaclass/java.security.cert.CRL.java - pathmap:/javaclass/java.util.ArrayList.java - pathmap:/javaclass/sun.misc.URLClassPath$Loader.java - pathmap:/javaclass/java.net.URLStreamHandler.java - pathmap:/javaclass/java.net.URLStreamHandlerFactory.java - pathmap:/javaclass/sun.misc.Resource.java - pathmap:/javaclass/java.util.jar.JarFile.java - pathmap:/javaclass/java.util.jar.Manifest.java - pathmap:/javaclass/java.util.jar.JarEntry.java - pathmap:/javaclass/java.util.jar.JarVerifier.java - pathmap:/javaclass/java.util.zip.ZipEntry.java - pathmap:/javaclass/java.util.zip.ZipFile.java - pathmap:/javaclass/java.util.jar.Attributes.java - pathmap:/javaclass/java.util.jar.Attributes$Name.java - pathmap:/javaclass/java.util.jar.Manifest$FastInputStream.java - pathmap:/javaclass/java.io.FilterInputStream.java - pathmap:/javaclass/sun.security.util.SignatureFileVerifier.java - pathmap:/javaclass/java.io.ByteArrayOutputStream.java - pathmap:/javaclass/sun.security.util.ManifestDigester.java - pathmap:/javaclass/sun.security.util.ManifestEntryVerifier.java - pathmap:/javaclass/sun.security.pkcs.PKCS7.java - pathmap:/javaclass/java.security.MessageDigest.java - pathmap:/javaclass/sun.security.pkcs.SignerInfo.java - pathmap:/javaclass/sun.security.util.ObjectIdentifier.java - pathmap:/javaclass/sun.security.x509.AlgorithmId.java - pathmap:/javaclass/sun.security.pkcs.ContentInfo.java - pathmap:/javaclass/java.security.cert.X509Certificate.java - pathmap:/javaclass/java.security.cert.X509CRL.java - pathmap:/javaclass/sun.security.util.DerInputStream.java - pathmap:/javaclass/sun.security.util.DerValue.java - pathmap:/javaclass/sun.security.util.DerOutputStream.java - pathmap:/javaclass/sun.security.x509.X500Name.java - pathmap:/javaclass/sun.security.timestamp.Timestamper.java - pathmap:/javaclass/sun.security.util.DerInputBuffer.java - pathmap:/javaclass/sun.security.util.BitArray.java - pathmap:/javaclass/java.io.ByteArrayInputStream.java - pathmap:/javaclass/java.security.AlgorithmParameters.java - pathmap:/javaclass/sun.security.util.DerEncoder.java - pathmap:/javaclass/java.security.AlgorithmParametersSpi.java - pathmap:/javaclass/java.security.spec.AlgorithmParameterSpec.java - pathmap:/javaclass/javax.security.auth.x500.X500Principal.java - pathmap:/javaclass/java.security.cert.X509Extension.java - pathmap:/javaclass/java.security.cert.X509CRLEntry.java - pathmap:/javaclass/java.security.cert.CRLReason.java - pathmap:/javaclass/sun.security.util.ByteArrayLexOrder.java - pathmap:/javaclass/sun.security.util.ByteArrayTagOrder.java - pathmap:/javaclass/sun.security.x509.RDN.java - pathmap:/javaclass/sun.security.x509.AVA.java - pathmap:/javaclass/sun.security.x509.GeneralNameInterface.java - pathmap:/javaclass/java.lang.Byte.java - pathmap:/javaclass/sun.security.timestamp.TSResponse.java - pathmap:/javaclass/sun.security.timestamp.TSRequest.java - pathmap:/javaclass/sun.security.timestamp.TimestampToken.java - pathmap:/javaclass/java.security.MessageDigestSpi.java - pathmap:/javaclass/sun.security.pkcs.PKCS9Attributes.java - pathmap:/javaclass/sun.security.pkcs.PKCS9Attribute.java - pathmap:/javaclass/sun.security.util.ManifestDigester$Entry.java - pathmap:/javaclass/sun.security.util.ManifestDigester$Position.java - pathmap:/javaclass/java.util.zip.ZipConstants.java - pathmap:/javaclass/java.util.zip.ZipCoder.java - pathmap:/javaclass/java.util.zip.Inflater.java - pathmap:/javaclass/java.util.Deque.java - pathmap:/javaclass/java.util.zip.ZStreamRef.java - pathmap:/javaclass/java.util.Queue.java - pathmap:/javaclass/java.net.URLConnection.java - pathmap:/javaclass/java.net.Proxy.java - pathmap:/javaclass/sun.net.www.MessageHeader.java - pathmap:/javaclass/java.net.FileNameMap.java - pathmap:/javaclass/java.net.ContentHandlerFactory.java - pathmap:/javaclass/java.net.ContentHandler.java - pathmap:/javaclass/java.net.Proxy$Type.java - pathmap:/javaclass/java.net.SocketAddress.java - pathmap:/javaclass/java.security.ProtectionDomain$Key.java - pathmap:/javaclass/sun.reflect.LangReflectAccess.java - pathmap:/javaclass/sun.reflect.FieldAccessor.java - pathmap:/javaclass/sun.reflect.MethodAccessor.java - pathmap:/javaclass/java.lang.annotation.RetentionPolicy.java - pathmap:/javaclass/java.lang.ClassValue$Entry.java - pathmap:/javaclass/java.lang.ClassValue.java - pathmap:/javaclass/java.util.WeakHashMap.java - pathmap:/javaclass/java.lang.ClassValue$Identity.java - pathmap:/javaclass/java.lang.ClassValue$Version.java - pathmap:/javaclass/java.util.WeakHashMap$Entry.java - pathmap:/javaclass/sun.reflect.generics.repository.MethodRepository.java - pathmap:/javaclass/sun.reflect.generics.repository.FieldRepository.java - pathmap:/javaclass/java.lang.reflect.Member.java - pathmap:/javaclass/java.lang.reflect.AccessibleObject.java - pathmap:/javaclass/java.net.UrlDeserializedState.java - pathmap:/javaclass/java.lang.SecurityManager.java - pathmap:/javaclass/java.lang.reflect.ParameterizedType.java - pathmap:/javaclass/java.lang.reflect.WildcardType.java - pathmap:/javaclass/java.lang.reflect.Parameter.java - pathmap:/javaclass/java.util.function.LongFunction.java - pathmap:/javaclass/java.util.function.LongToIntFunction.java - pathmap:/javaclass/java.util.function.LongToDoubleFunction.java - pathmap:/javaclass/java.util.OptionalLong.java - pathmap:/javaclass/java.util.function.ObjLongConsumer.java - pathmap:/javaclass/java.util.LongSummaryStatistics.java - pathmap:/javaclass/java.util.stream.LongStream$Builder.java - pathmap:/javaclass/java.util.function.LongSupplier.java - pathmap:/javaclass/java.util.function.DoubleFunction.java - pathmap:/javaclass/java.util.function.DoubleToIntFunction.java - pathmap:/javaclass/java.util.function.DoubleToLongFunction.java - pathmap:/javaclass/java.util.function.ObjDoubleConsumer.java - pathmap:/javaclass/java.util.DoubleSummaryStatistics.java - pathmap:/javaclass/java.lang.Double.java - pathmap:/javaclass/java.util.stream.DoubleStream$Builder.java - pathmap:/javaclass/java.util.stream.Collector$Characteristics.java - pathmap:/javaclass/org.eclipse.emf.ecore.EPackage.java - pathmap:/javaclass/org.eclipse.emf.ecore.EFactory.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.ResourceSet.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.Resource$Diagnostic.java - pathmap:/javaclass/org.eclipse.emf.common.notify.AdapterFactory.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.Resource$Factory$Registry.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.URIConverter.java - pathmap:/javaclass/org.eclipse.emf.ecore.EPackage$Registry.java - pathmap:/javaclass/org.eclipse.emf.common.notify.Adapter.java - pathmap:/javaclass/org.eclipse.emf.common.notify.Notification.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.Resource$Factory.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.URIHandler.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.ContentHandler.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$StringAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$PlatformAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$FileAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$URIComponentsAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.Pool.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$StringAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.Pool$AccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.Pool$AccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SubstringAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAndSubsegmentAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$URIPoolAccessUnitBase.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SubstringAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$AccessUnitBase.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$StringAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$SubstringAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool.java - pathmap:/javaclass/org.eclipse.emf.common.util.Pool$ObjectAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$StringAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$AccessUnitBase.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$CharactersAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$SubstringAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$CharSequenceAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$JavaInterningAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$StringsAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.WeakInterningHashSet$Entry.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$StringsAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$CharactersAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$CharSequenceAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$JavaInterningAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.WeakInterningHashSet.java - pathmap:/javaclass/org.eclipse.emf.common.util.InterningSet.java - pathmap:/javaclass/java.util.AbstractSet.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAndSubsegmentAccessUnit$Queue.java - pathmap:/javaclass/org.eclipse.emf.common.util.CommonUtil$StringPool$StringPoolEntry.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAndSegmentCountAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAndSegmentCountAccessUnit$Queue.java - pathmap:/javaclass/java.util.concurrent.atomic.AtomicReference.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$PlatformAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$FileAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.URI$URIPool$URIComponentsAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAccessUnit.java - pathmap:/javaclass/org.eclipse.emf.common.util.SegmentSequence$StringArrayPool$SegmentsAccessUnit$Queue.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock.java - pathmap:/javaclass/java.util.concurrent.locks.Lock.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock$ReadLock.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock$WriteLock.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock$Sync.java - pathmap:/javaclass/java.util.concurrent.locks.Condition.java - pathmap:/javaclass/java.util.concurrent.locks.ReadWriteLock.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock$Sync$ThreadLocalHoldCounter.java - pathmap:/javaclass/java.util.concurrent.locks.ReentrantReadWriteLock$Sync$HoldCounter.java - pathmap:/javaclass/java.lang.IllegalMonitorStateException.java - pathmap:/javaclass/java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.java - pathmap:/javaclass/java.util.concurrent.locks.AbstractQueuedSynchronizer.java - pathmap:/javaclass/java.lang.RuntimeException.java - pathmap:/javaclass/java.util.concurrent.locks.AbstractQueuedSynchronizer$Node.java - pathmap:/javaclass/java.util.concurrent.locks.AbstractOwnableSynchronizer.java - pathmap:/javaclass/org.eclipse.emf.ecore.ETypedElement.java - pathmap:/javaclass/org.eclipse.emf.ecore.EParameter.java - pathmap:/javaclass/de.tu_bs.cs.isf.cbc.model.cbcmodel.CbcmodelPackage.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.EFactoryImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.plugin.EcorePlugin.java - pathmap:/javaclass/org.eclipse.emf.common.EMFPlugin.java - pathmap:/javaclass/java.lang.Override.java - pathmap:/javaclass/java.lang.IllegalArgumentException.java - pathmap:/javaclass/java.lang.Deprecated.java - pathmap:/javaclass/java.text.DateFormat.java - pathmap:/javaclass/org.eclipse.emf.common.notify.NotificationChain.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$DataConverter.java - pathmap:/javaclass/org.eclipse.emf.ecore.InternalEObject.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$DataConverter$Factory.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.EModelElementImpl.java - pathmap:/javaclass/java.util.Calendar.java - pathmap:/javaclass/java.text.NumberFormat.java - pathmap:/javaclass/sun.util.locale.provider.LocaleProviderAdapter.java - pathmap:/javaclass/java.text.DateFormatSymbols.java - pathmap:/javaclass/java.util.Currency.java - pathmap:/javaclass/java.util.HashSet.java - pathmap:/javaclass/java.io.DataInputStream.java - pathmap:/javaclass/sun.util.locale.provider.LocaleProviderAdapter$Type.java - pathmap:/javaclass/java.util.spi.LocaleServiceProvider.java - pathmap:/javaclass/java.text.spi.BreakIteratorProvider.java - pathmap:/javaclass/java.text.spi.CollatorProvider.java - pathmap:/javaclass/java.text.spi.DateFormatProvider.java - pathmap:/javaclass/java.text.spi.DateFormatSymbolsProvider.java - pathmap:/javaclass/java.text.spi.DecimalFormatSymbolsProvider.java - pathmap:/javaclass/java.text.spi.NumberFormatProvider.java - pathmap:/javaclass/java.util.spi.CurrencyNameProvider.java - pathmap:/javaclass/java.util.spi.LocaleNameProvider.java - pathmap:/javaclass/java.util.spi.TimeZoneNameProvider.java - pathmap:/javaclass/java.util.spi.CalendarDataProvider.java - pathmap:/javaclass/java.util.spi.CalendarNameProvider.java - pathmap:/javaclass/sun.util.spi.CalendarProvider.java - pathmap:/javaclass/sun.util.locale.provider.LocaleResources.java - pathmap:/javaclass/java.text.BreakIterator.java - pathmap:/javaclass/java.text.BreakIterator$BreakIteratorCache.java - pathmap:/javaclass/java.text.Collator.java - pathmap:/javaclass/java.text.CollationKey.java - pathmap:/javaclass/java.text.DecimalFormatSymbols.java - pathmap:/javaclass/sun.util.resources.LocaleData.java - pathmap:/javaclass/sun.util.locale.provider.LocaleResources$ResourceReference.java - pathmap:/javaclass/sun.util.locale.provider.ResourceBundleBasedAdapter.java - pathmap:/javaclass/java.util.ResourceBundle.java - pathmap:/javaclass/sun.util.resources.OpenListResourceBundle.java - pathmap:/javaclass/sun.util.resources.TimeZoneNamesBundle.java - pathmap:/javaclass/sun.util.resources.ParallelListResourceBundle.java - pathmap:/javaclass/java.util.concurrent.atomic.AtomicMarkableReference.java - pathmap:/javaclass/java.util.concurrent.atomic.AtomicMarkableReference$Pair.java - pathmap:/javaclass/java.util.ResourceBundle$CacheKey.java - pathmap:/javaclass/java.util.ResourceBundle$BundleReference.java - pathmap:/javaclass/java.util.spi.ResourceBundleControlProvider.java - pathmap:/javaclass/java.util.ResourceBundle$Control.java - pathmap:/javaclass/java.util.ResourceBundle$LoaderReference.java - pathmap:/javaclass/java.util.ResourceBundle$CacheKeyReference.java - pathmap:/javaclass/java.util.ResourceBundle$Control$CandidateListCache.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectOutputStream.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$EPackageDataList.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$EPackageData.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$InternalEObjectList.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$URIList.java - pathmap:/javaclass/org.eclipse.emf.common.util.BasicEList.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$StringList.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$EClassData.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectInputStream$EStructuralFeatureData.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.InternalEList.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap$Internal.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap$Entry$Internal.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$BinaryIO.java - pathmap:/javaclass/org.eclipse.emf.common.util.AbstractEList.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$BinaryIO$FeatureKind.java - pathmap:/javaclass/org.eclipse.emf.ecore.EStructuralFeature$Setting.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap$Entry.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap$Internal$Wrapper.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.FeatureMap$ValueListIterator.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.EContentsEList$FeatureListIterator.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.EContentsEList$FeatureIterator.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$BinaryIO$Version.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectOutputStream$EPackageData.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectOutputStream$EClassData.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectOutputStream$EStructuralFeatureData.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.impl.BinaryResourceImpl$EObjectOutputStream$Check.java - pathmap:/javaclass/org.eclipse.emf.ecore.resource.Resource$Internal.java - pathmap:/javaclass/org.eclipse.emf.ecore.InternalEObject$EStore.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.MinimalEObjectImpl$Container.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.MinimalEObjectImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.BasicEObjectImpl$EPropertiesHolder.java - pathmap:/javaclass/org.eclipse.emf.common.notify.impl.BasicNotifierImpl$EObservableAdapterList$Listener.java - pathmap:/javaclass/org.eclipse.emf.ecore.EStructuralFeature$Internal$DynamicValueHolder.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.BasicEObjectImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.EStructuralFeature$Internal$SettingDelegate.java - pathmap:/javaclass/org.eclipse.emf.ecore.EOperation$Internal$InvocationDelegate.java - pathmap:/javaclass/org.eclipse.emf.common.notify.impl.BasicNotifierImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.plugin.EcorePlugin$Implementation.java - pathmap:/javaclass/org.eclipse.emf.common.util.ResourceLocator.java - pathmap:/javaclass/org.osgi.framework.BundleContext.java - pathmap:/javaclass/org.eclipse.emf.common.EMFPlugin$EclipsePlugin.java - pathmap:/javaclass/org.osgi.framework.Bundle.java - pathmap:/javaclass/org.osgi.framework.ServiceListener.java - pathmap:/javaclass/org.osgi.framework.BundleListener.java - pathmap:/javaclass/org.osgi.framework.FrameworkListener.java - pathmap:/javaclass/org.osgi.framework.ServiceRegistration.java - pathmap:/javaclass/org.osgi.framework.ServiceFactory.java - pathmap:/javaclass/org.osgi.framework.ServiceReference.java - pathmap:/javaclass/org.osgi.framework.ServiceObjects.java - pathmap:/javaclass/org.osgi.framework.Filter.java - pathmap:/javaclass/org.osgi.framework.BundleReference.java - pathmap:/javaclass/org.osgi.framework.Version.java - pathmap:/javaclass/org.osgi.framework.ServiceEvent.java - pathmap:/javaclass/java.util.EventListener.java - pathmap:/javaclass/java.util.EventObject.java - pathmap:/javaclass/org.osgi.framework.BundleEvent.java - pathmap:/javaclass/org.osgi.framework.FrameworkEvent.java - pathmap:/javaclass/org.eclipse.emf.common.EMFPlugin$InternalHelper.java - pathmap:/javaclass/org.eclipse.core.runtime.IPluginDescriptor.java - pathmap:/javaclass/org.eclipse.emf.common.util.Logger.java - pathmap:/javaclass/org.eclipse.emf.common.EMFPlugin$InternalEclipsePlugin.java - pathmap:/javaclass/org.eclipse.core.runtime.Plugin.java - pathmap:/javaclass/org.eclipse.core.runtime.ILog.java - pathmap:/javaclass/org.eclipse.core.runtime.ILogListener.java - pathmap:/javaclass/org.eclipse.core.runtime.IStatus.java - pathmap:/javaclass/org.eclipse.core.runtime.IExtension.java - pathmap:/javaclass/org.eclipse.core.runtime.IExtensionPoint.java - pathmap:/javaclass/org.eclipse.core.runtime.IPluginPrerequisite.java - pathmap:/javaclass/org.eclipse.core.runtime.ILibrary.java - pathmap:/javaclass/org.eclipse.core.runtime.PluginVersionIdentifier.java - pathmap:/javaclass/org.eclipse.core.runtime.IPath.java - pathmap:/javaclass/org.eclipse.core.runtime.IConfigurationElement.java - pathmap:/javaclass/org.eclipse.core.runtime.IContributor.java - pathmap:/javaclass/org.osgi.util.tracker.ServiceTracker.java - pathmap:/javaclass/org.eclipse.osgi.service.debug.DebugOptions.java - pathmap:/javaclass/org.eclipse.core.runtime.Preferences.java - pathmap:/javaclass/org.osgi.framework.BundleActivator.java - pathmap:/javaclass/org.osgi.util.tracker.ServiceTrackerCustomizer.java - pathmap:/javaclass/org.osgi.util.tracker.ServiceTracker$Tracked.java - pathmap:/javaclass/org.osgi.util.tracker.AbstractTracked.java - pathmap:/javaclass/java.util.LinkedList.java - pathmap:/javaclass/java.util.LinkedList$Node.java - pathmap:/javaclass/java.util.AbstractSequentialList.java - pathmap:/javaclass/org.eclipse.osgi.service.debug.DebugTrace.java - pathmap:/javaclass/org.eclipse.core.runtime.ListenerList.java - pathmap:/javaclass/org.eclipse.core.runtime.Preferences$IPropertyChangeListener.java - pathmap:/javaclass/org.eclipse.core.runtime.Preferences$PropertyChangeEvent.java - pathmap:/javaclass/org.eclipse.emf.common.util.DelegatingResourceLocator.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.EPackageImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.impl.ENamedElementImpl.java - pathmap:/javaclass/org.eclipse.emf.ecore.EcorePackage.java - pathmap:/javaclass/org.eclipse.emf.ecore.EcoreFactory.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.BasicExtendedMetaData$EPackageExtendedMetaData.java - pathmap:/javaclass/org.eclipse.emf.ecore.EEnum.java - pathmap:/javaclass/org.eclipse.emf.common.util.Enumerator.java - pathmap:/javaclass/org.eclipse.emf.ecore.util.BasicExtendedMetaData$EPackageExtendedMetaData$Holder.java - pathmap:/javaclass/org.eclipse.emf.ecore.EEnumLiteral.java - platform:/resource/de.tu_bs.cs.isf.cbc.language/model/language.ecore - http://www.eclipse.org/emf/2002/Ecore - platform:/resource/org.eclipse.xtext.xbase/model/Xbase.ecore - platform:/resource/org.eclipse.xtext.common.types/model/JavaVMTypes.ecore - platform:/resource/org.eclipse.xtext.xbase/model/Xbase.genmodel - platform:/resource/org.eclipse.xtext.common.types/model/JavaVMTypes.genmodel - platform:/resource/org.eclipse.xtext.xbase/model/XAnnotations.ecore - platform:/resource/org.eclipse.xtext.xbase/model/Xtype.ecore - ../src-gen/de/tu_bs/cs/isf/cbc/cbcmodel/Kind.java - pathmap:/javaclass/java.util.Collections.java - pathmap:/javaclass/java.util.SortedSet.java - pathmap:/javaclass/java.util.NavigableSet.java - pathmap:/javaclass/java.util.NavigableMap.java - pathmap:/javaclass/java.lang.invoke.MethodHandle.java - pathmap:/javaclass/java.io.OptionalDataException.java - pathmap:/javaclass/java.lang.invoke.MethodType.java - pathmap:/javaclass/java.lang.invoke.LambdaForm.java - pathmap:/javaclass/java.lang.invoke.BoundMethodHandle.java - pathmap:/javaclass/java.lang.invoke.MemberName.java - pathmap:/javaclass/java.lang.invoke.MethodHandleImpl$Intrinsic.java - pathmap:/javaclass/java.lang.invoke.MethodTypeForm.java - pathmap:/javaclass/java.lang.invoke.Invokers.java - pathmap:/javaclass/java.lang.invoke.MethodType$ConcurrentWeakInternSet.java - pathmap:/javaclass/java.lang.IndexOutOfBoundsException.java - pathmap:/javaclass/java.lang.invoke.LambdaForm$NamedFunction.java - pathmap:/javaclass/java.lang.invoke.WrongMethodTypeException.java - pathmap:/javaclass/java.lang.invoke.LambdaForm$BasicType.java - pathmap:/javaclass/sun.invoke.util.Wrapper.java - pathmap:/javaclass/java.lang.ClassCastException.java - pathmap:/javaclass/java.lang.invoke.MethodType$ConcurrentWeakInternSet$WeakEntry.java - pathmap:/javaclass/sun.security.util.DisabledAlgorithmConstraints.java - pathmap:/javaclass/sun.security.util.DisabledAlgorithmConstraints$Constraints.java - pathmap:/javaclass/sun.security.util.AlgorithmDecomposer.java - pathmap:/javaclass/java.security.CryptoPrimitive.java - pathmap:/javaclass/sun.security.util.ConstraintsParameters.java - pathmap:/javaclass/sun.security.util.AbstractAlgorithmConstraints.java - pathmap:/javaclass/sun.security.util.DisabledAlgorithmConstraints$Constraint.java - pathmap:/javaclass/java.security.AlgorithmConstraints.java - pathmap:/javaclass/sun.security.util.ManifestDigester$Section.java - pathmap:/javaclass/java.lang.invoke.LambdaForm$Name.java - pathmap:/javaclass/java.lang.invoke.MemberName$Factory.java - pathmap:/javaclass/java.lang.invoke.LambdaFormEditor.java - pathmap:/javaclass/java.lang.invoke.LambdaFormEditor$Transform.java - pathmap:/javaclass/java.lang.invoke.LambdaFormBuffer.java - pathmap:/javaclass/java.lang.invoke.BoundMethodHandle$SpeciesData.java - pathmap:/javaclass/java.lang.invoke.LambdaFormEditor$Transform$Kind.java - pathmap:/javaclass/java.lang.invoke.MethodHandles$Lookup.java - pathmap:/javaclass/java.lang.invoke.DirectMethodHandle.java - pathmap:/javaclass/java.lang.invoke.MethodHandleInfo.java - pathmap:/javaclass/java.lang.IllegalAccessException.java - platform:/resource/de.tu_bs.cs.isf.cbc.cbcclass.model/model/cbcclass.ecore - platform:/resource/de.tu_bs.cs.isf.cbc.cbcclass.model/model/cbcclass.genmodel -<<<<<<< HEAD - cbcmodel.genmodel - - - - - - - -======= - cbcclass.ecore - cbcmodel.genmodel - genmodel.genmodel - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - bold - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - bold - - ->>>>>>> master - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - -======= - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - ->>>>>>> master - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - -======= - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - -======= - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - -======= - - - - - - - - - ->>>>>>> master - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - -======= - - - - - bold - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - - - - - -======= - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - KEEP_LOCATION - KEEP_SIZE - KEEP_RATIO - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - bold - - -======= - - - - - - labelSize - bold - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - -======= - - - - - - - labelSize - - - labelSize - - - - - - - - - - - labelSize - - - labelSize - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - italic - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD -======= - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - -<<<<<<< HEAD - - - - - - - - -======= - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - - - - - - - - - - -<<<<<<< HEAD - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD -======= - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - - - - - - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - -======= - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - ->>>>>>> master - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ->>>>>>> master - - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - -======= - - - - - - - labelSize - - ->>>>>>> master - labelSize - - - - -<<<<<<< HEAD - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - - labelSize - - - - - - - - - - labelSize - - - labelSize - - - -======= - - - - - - - - - ->>>>>>> master - - - - - - - - - - diff --git a/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.ecore.orig b/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.ecore.orig deleted file mode 100644 index 366c597f1..000000000 --- a/de.tu-bs.cs.isf.cbc.model/model/cbcmodel.ecore.orig +++ /dev/null @@ -1,209 +0,0 @@ - - -======= - xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="cbcmodel" nsURI="http://www.example.org/cbcmodel" nsPrefix="de.tu-bs.cs.isf.cbc.cbcmodel"> ->>>>>>> master - - - - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - - - - - ->>>>>>> master - - - - - - - - - - - -<<<<<<< HEAD -======= - - - - - ->>>>>>> master - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -======= - eType="ecore:EClass cbcclass.ecore#//Field"> ->>>>>>> master - -
- - - -======= - eType="ecore:EClass cbcclass.ecore#//Parameter" containment="true"> ->>>>>>> master - -
- - - - - - -<<<<<<< HEAD -======= - - ->>>>>>> master - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -<<<<<<< HEAD -======= - - - - - - - - - - - - - - - ->>>>>>> master - diff --git a/de.tu-bs.cs.isf.cbc.model/plugin.xml.orig b/de.tu-bs.cs.isf.cbc.model/plugin.xml.orig deleted file mode 100644 index ed329cf40..000000000 --- a/de.tu-bs.cs.isf.cbc.model/plugin.xml.orig +++ /dev/null @@ -1,35 +0,0 @@ - - - - - - - -<<<<<<< HEAD - - - - -======= - - - - - - - - ->>>>>>> master - - - diff --git a/de.tu-bs.cs.isf.cbc.model/src-gen/de/tu_bs/cs/isf/cbc/cbcmodel/impl/JavaVariablesImpl.java.orig b/de.tu-bs.cs.isf.cbc.model/src-gen/de/tu_bs/cs/isf/cbc/cbcmodel/impl/JavaVariablesImpl.java.orig deleted file mode 100644 index cd78feb9b..000000000 --- a/de.tu-bs.cs.isf.cbc.model/src-gen/de/tu_bs/cs/isf/cbc/cbcmodel/impl/JavaVariablesImpl.java.orig +++ /dev/null @@ -1,550 +0,0 @@ -<<<<<<< HEAD -/** - */ -package de.tu_bs.cs.isf.cbc.cbcmodel.impl; - -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Field; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Parameter; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelPackage; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariable; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import java.util.Collection; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.ecore.util.InternalEList; - -/** - * - * An implementation of the model object 'Java Variables'. - * - *

- * The following features are implemented: - *

- *
    - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getVariables Variables}
  • - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getFields Fields}
  • - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getParams Params}
  • - *
- * - * @generated - */ -public class JavaVariablesImpl extends MinimalEObjectImpl.Container implements JavaVariables { - /** - * The cached value of the '{@link #getVariables() Variables}' containment reference list. - * - * - * @see #getVariables() - * @generated - * @ordered - */ - protected EList variables; - - /** - * The cached value of the '{@link #getFields() Fields}' reference list. - * - * - * @see #getFields() - * @generated - * @ordered - */ - protected EList fields; - - /** - * The cached value of the '{@link #getParams() Params}' containment reference list. - * - * - * @see #getParams() - * @generated - * @ordered - */ - protected EList params; - - /** - * - * - * @generated - */ - protected JavaVariablesImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return CbcmodelPackage.Literals.JAVA_VARIABLES; - } - - /** - * - * - * @generated - */ - @Override - public EList getVariables() { - if (variables == null) { - variables = new EObjectContainmentEList(JavaVariable.class, this, CbcmodelPackage.JAVA_VARIABLES__VARIABLES); - } - return variables; - } - - /** - * - * - * @generated NOT - */ - @Override - public EList getFields() { - if (eDirectResource() != null) { - if (eDirectResource().getResourceSet() != null) { - if (eDirectResource().getResourceSet().getResources() != null) { - EList resources = eDirectResource().getResourceSet().getResources(); - URI uri = eDirectResource().getURI(); - uri = uri.trimSegments(1); - uri = uri.appendSegment(uri.lastSegment() + ".cbcclass"); - for (Resource res : resources) { - if (res.getURI().equals(uri)) { - EList content = res.getContents(); - for (EObject o : content) { - if (o instanceof ModelClass) { - return ((ModelClass) o).getFields(); - } - } - } - } - } - } - } - if (fields == null) { - fields = new EObjectResolvingEList(Field.class, this, CbcmodelPackage.JAVA_VARIABLES__FIELDS); - } - return fields; - } - /** - * - * - * @generated NOT - */ - @Override - public EList getParams() { - if (eDirectResource() != null) { - String methodName = eDirectResource().getURI().trimFileExtension().lastSegment(); - if (eDirectResource().getResourceSet() != null) { - if (eDirectResource().getResourceSet().getResources() != null) { - EList resources = eDirectResource().getResourceSet().getResources(); - URI uri = eDirectResource().getURI(); - uri = uri.trimSegments(1); - uri = uri.appendSegment(uri.lastSegment() + ".cbcclass"); - for (Resource res : resources) { - if (res.getURI().equals(uri) || res.getURI().toString().endsWith(uri.toString().replace("platform:/resource",""))) { - EList content = res.getContents(); - for (EObject o : content) { - if (o instanceof ModelClass) { - ModelClass mc = (ModelClass) o; - for (Method method : mc.getMethods()) { - if (method.getName().equals(methodName)) { - return method.getParameters(); - } - } - } - } - } - } - } - } - } - if (params == null) { - params = new EObjectResolvingEList(Parameter.class, this, CbcmodelPackage.JAVA_VARIABLES__PARAMS); - } - return params; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return ((InternalEList)getVariables()).basicRemove(otherEnd, msgs); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return ((InternalEList)getParams()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return getVariables(); - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - return getFields(); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return getParams(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - getVariables().clear(); - getVariables().addAll((Collection)newValue); - return; - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - getFields().clear(); - getFields().addAll((Collection)newValue); - return; - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - getParams().clear(); - getParams().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - getVariables().clear(); - return; - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - getFields().clear(); - return; - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - getParams().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return variables != null && !variables.isEmpty(); - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - return fields != null && !fields.isEmpty(); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return params != null && !params.isEmpty(); - } - return super.eIsSet(featureID); - } - -======= -/** - */ -package de.tu_bs.cs.isf.cbc.cbcmodel.impl; - -import de.tu_bs.cs.isf.cbc.cbcclass.Field; -import de.tu_bs.cs.isf.cbc.cbcclass.Method; -import de.tu_bs.cs.isf.cbc.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcclass.Parameter; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelPackage; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariable; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import java.util.Collection; -import org.eclipse.emf.common.notify.NotificationChain; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EClass; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.InternalEObject; - -import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EObjectContainmentEList; -import org.eclipse.emf.ecore.util.EObjectResolvingEList; -import org.eclipse.emf.ecore.util.InternalEList; - -/** - * - * An implementation of the model object 'Java Variables'. - * - *

- * The following features are implemented: - *

- *
    - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getVariables Variables}
  • - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getFields Fields}
  • - *
  • {@link de.tu_bs.cs.isf.cbc.cbcmodel.impl.JavaVariablesImpl#getParams Params}
  • - *
- * - * @generated - */ -public class JavaVariablesImpl extends MinimalEObjectImpl.Container implements JavaVariables { - /** - * The cached value of the '{@link #getVariables() Variables}' containment reference list. - * - * - * @see #getVariables() - * @generated - * @ordered - */ - protected EList variables; - - /** - * The cached value of the '{@link #getFields() Fields}' reference list. - * - * - * @see #getFields() - * @generated - * @ordered - */ - protected EList fields; - - /** - * The cached value of the '{@link #getParams() Params}' containment reference list. - * - * - * @see #getParams() - * @generated - * @ordered - */ - protected EList params; - - /** - * - * - * @generated - */ - protected JavaVariablesImpl() { - super(); - } - - /** - * - * - * @generated - */ - @Override - protected EClass eStaticClass() { - return CbcmodelPackage.Literals.JAVA_VARIABLES; - } - - /** - * - * - * @generated - */ - @Override - public EList getVariables() { - if (variables == null) { - variables = new EObjectContainmentEList(JavaVariable.class, this, CbcmodelPackage.JAVA_VARIABLES__VARIABLES); - } - return variables; - } - - /** - * - * - * @generated NOT - */ - @Override - public EList getFields() { - if (eDirectResource() != null) { - if (eDirectResource().getResourceSet() != null) { - if (eDirectResource().getResourceSet().getResources() != null) { - EList resources = eDirectResource().getResourceSet().getResources(); - URI uri = eDirectResource().getURI(); - uri = uri.trimSegments(1); - uri = uri.appendSegment(uri.lastSegment() + ".cbcclass"); - for (Resource res : resources) { - if (res.getURI().equals(uri)) { - EList content = res.getContents(); - for (EObject o : content) { - if (o instanceof ModelClass) { - return ((ModelClass) o).getFields(); - } - } - } - } - } - } - } - if (fields == null) { - fields = new EObjectResolvingEList(Field.class, this, CbcmodelPackage.JAVA_VARIABLES__FIELDS); - } - return fields; - } - /** - * - * - * @generated NOT - */ - @Override - public EList getParams() { - if (eDirectResource() != null) { - String methodName = eDirectResource().getURI().trimFileExtension().lastSegment(); - if (eDirectResource().getResourceSet() != null) { - if (eDirectResource().getResourceSet().getResources() != null) { - EList resources = eDirectResource().getResourceSet().getResources(); - URI uri = eDirectResource().getURI(); - uri = uri.trimSegments(1); - uri = uri.appendSegment(uri.lastSegment() + ".cbcclass"); - for (Resource res : resources) { - if (res.getURI().equals(uri) || res.getURI().toString().endsWith(uri.toString().replace("platform:/resource",""))) { - EList content = res.getContents(); - for (EObject o : content) { - if (o instanceof ModelClass) { - ModelClass mc = (ModelClass) o; - for (Method method : mc.getMethods()) { - if (method.getName().equals(methodName)) { - return method.getParameters(); - } - } - } - } - } - } - } - } - } - if (params == null) { - params = new EObjectResolvingEList(Parameter.class, this, CbcmodelPackage.JAVA_VARIABLES__PARAMS); - } - return params; - } - - /** - * - * - * @generated - */ - @Override - public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return ((InternalEList)getVariables()).basicRemove(otherEnd, msgs); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return ((InternalEList)getParams()).basicRemove(otherEnd, msgs); - } - return super.eInverseRemove(otherEnd, featureID, msgs); - } - - /** - * - * - * @generated - */ - @Override - public Object eGet(int featureID, boolean resolve, boolean coreType) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return getVariables(); - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - return getFields(); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return getParams(); - } - return super.eGet(featureID, resolve, coreType); - } - - /** - * - * - * @generated - */ - @SuppressWarnings("unchecked") - @Override - public void eSet(int featureID, Object newValue) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - getVariables().clear(); - getVariables().addAll((Collection)newValue); - return; - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - getFields().clear(); - getFields().addAll((Collection)newValue); - return; - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - getParams().clear(); - getParams().addAll((Collection)newValue); - return; - } - super.eSet(featureID, newValue); - } - - /** - * - * - * @generated - */ - @Override - public void eUnset(int featureID) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - getVariables().clear(); - return; - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - getFields().clear(); - return; - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - getParams().clear(); - return; - } - super.eUnset(featureID); - } - - /** - * - * - * @generated - */ - @Override - public boolean eIsSet(int featureID) { - switch (featureID) { - case CbcmodelPackage.JAVA_VARIABLES__VARIABLES: - return variables != null && !variables.isEmpty(); - case CbcmodelPackage.JAVA_VARIABLES__FIELDS: - return fields != null && !fields.isEmpty(); - case CbcmodelPackage.JAVA_VARIABLES__PARAMS: - return params != null && !params.isEmpty(); - } - return super.eIsSet(featureID); - } - ->>>>>>> master -} //JavaVariablesImpl \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.mutation/.project.orig b/de.tu-bs.cs.isf.cbc.mutation/.project.orig deleted file mode 100644 index 9332e07c0..000000000 --- a/de.tu-bs.cs.isf.cbc.mutation/.project.orig +++ /dev/null @@ -1,28 +0,0 @@ - - - de.tu-bs.cs.isf.cbc.mutation - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/de.tu-bs.cs.isf.cbc.mutation/build.properties.orig b/de.tu-bs.cs.isf.cbc.mutation/build.properties.orig deleted file mode 100644 index 61c689bda..000000000 --- a/de.tu-bs.cs.isf.cbc.mutation/build.properties.orig +++ /dev/null @@ -1,6 +0,0 @@ -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - muJava/openjava.jar,\ - plugin.xml diff --git a/de.tu-bs.cs.isf.cbc.tool/.classpath.orig b/de.tu-bs.cs.isf.cbc.tool/.classpath.orig deleted file mode 100644 index c91aa6381..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/.classpath.orig +++ /dev/null @@ -1,20 +0,0 @@ - - -<<<<<<< HEAD -======= - ->>>>>>> master - - - - - - -<<<<<<< HEAD - -======= - - ->>>>>>> master - - diff --git a/de.tu-bs.cs.isf.cbc.tool/META-INF/MANIFEST.MF.orig b/de.tu-bs.cs.isf.cbc.tool/META-INF/MANIFEST.MF.orig deleted file mode 100644 index b83189b4b..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/META-INF/MANIFEST.MF.orig +++ /dev/null @@ -1,64 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Tool -Bundle-SymbolicName: de.tu-bs.cs.isf.cbc.tool;singleton:=true -Bundle-Version: 1.0.0.qualifier -Bundle-RequiredExecutionEnvironment: JavaSE-16, - JavaSE-1.8 -Require-Bundle: org.eclipse.graphiti, - org.eclipse.graphiti.ui, - org.eclipse.ui.views.properties.tabbed, - org.eclipse.graphiti.pattern, - org.eclipse.emf.transaction, - org.eclipse.xtext;bundle-version="2.10.0", - org.eclipse.draw2d;bundle-version="3.10.100", - org.emftext.language.java, -<<<<<<< HEAD - org.eclipse.jdt.core, - de.tu_bs.cs.isf.cbc.cbcclass.model, - de.tu_bs.cs.isf.cbc.statistics, - org.eclipse.graphiti.mm, - org.eclipse.swt, - de.ovgu.featureide.fm.core, - org.eclipse.mylyn.commons.ui, - org.eclipse.ui.workbench, - org.eclipse.core.commands -Import-Package: de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass, - de.tu_bs.cs.isf.cbcclass.tool.patterns, - helper, - org.eclipse.jdt.core.dom, - org.emftext.language.java.resource.java.util, - de.ovgu.featureide.fm.core.base, - de.ovgu.featureide.fm.core.io.manager, - org.eclipse.compare.internal, - org.eclipse.emf.common.ui, - org.eclipse.jdt.core -Export-Package: de.tu_bs.cs.isf.cbc.tool.diagram, - de.tu_bs.cs.isf.cbc.tool.features, - de.tu_bs.cs.isf.cbc.tool.helper, - de.tu_bs.cs.isf.cbc.tool.model, - de.tu_bs.cs.isf.cbc.tool.patterns -======= - de.ovgu.featureide.fm.core, - org.eclipse.mylyn.commons.ui, - org.testng;bundle-version="7.4.0", - de.tu-bs.cs.isf.cbc.util;bundle-version="1.0.0" -Import-Package: de.ovgu.featureide.fm.core.base, - de.ovgu.featureide.fm.core.io.manager, - de.tu_bs.cs.isf.cbc.cbcclass, - de.tu_bs.cs.isf.cbc.cbcmodel, - de.tu_bs.cs.isf.cbc.cbcmodel.impl, - de.tu_bs.cs.isf.cbc.exceptions, - de.tu_bs.cs.isf.cbc.parser.exceptions, - de.tu_bs.cs.isf.cbc.statistics, - de.tu_bs.cs.isf.commands.toolbar.handler.family, - de.tu_bs.cs.isf.lattice, - org.eclipse.emf.common.ui -Export-Package: de.tu_bs.cs.isf.cbc.tool.diagram, - de.tu_bs.cs.isf.cbc.tool.features, - de.tu_bs.cs.isf.cbc.tool.helper, - de.tu_bs.cs.isf.cbc.tool.patterns, - de.tu_bs.cs.isf.cbc.tool.propertiesview -Bundle-ClassPath: lib/com.microsoft.z3.jar, - . ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.tool/build.properties.orig b/de.tu-bs.cs.isf.cbc.tool/build.properties.orig deleted file mode 100644 index 7e967f047..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/build.properties.orig +++ /dev/null @@ -1,11 +0,0 @@ -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - plugin.xml,\ -<<<<<<< HEAD - icons/ -======= - icons/,\ - lib/com.microsoft.z3.jar ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.tool/plugin.xml.orig b/de.tu-bs.cs.isf.cbc.tool/plugin.xml.orig deleted file mode 100644 index 7e8a4a288..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/plugin.xml.orig +++ /dev/null @@ -1,186 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - >>>>>> master - id="Configurations" - label="Configurations"> - - - - - - - - - -<<<<<<< HEAD -======= - - - - ->>>>>>> master - - - - - - - - - >>>>>> master - afterSection="Replacements" - class="de.tu_bs.cs.isf.cbc.tool.propertiesview.ConfigurationsSection" - filter="de.tu_bs.cs.isf.cbc.tool.propertiesview.PictogramFilterVariational" - id="Configurations" - tab="Configurations"> - - - - - - - - - -<<<<<<< HEAD -======= - - - - ->>>>>>> master - - - - - - -<<<<<<< HEAD - -======= - ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCFeatureProvider.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCFeatureProvider.java.orig deleted file mode 100644 index 330964042..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCFeatureProvider.java.orig +++ /dev/null @@ -1,200 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.diagram; - -import org.eclipse.graphiti.dt.IDiagramTypeProvider; -import org.eclipse.graphiti.features.ICreateFeature; -import org.eclipse.graphiti.features.IDeleteFeature; -import org.eclipse.graphiti.features.IReconnectionFeature; -import org.eclipse.graphiti.features.context.ICustomContext; -import org.eclipse.graphiti.features.context.IDeleteContext; -import org.eclipse.graphiti.features.context.IReconnectionContext; -import org.eclipse.graphiti.features.custom.ICustomFeature; -import org.eclipse.graphiti.mm.pictograms.Connection; -import org.eclipse.graphiti.pattern.DefaultFeatureProviderWithPatterns; - -import de.tu_bs.cs.isf.cbc.tool.features.ChangeNameOfAssociatedClassFeature; -import de.tu_bs.cs.isf.cbc.tool.features.ChangeNameOfAssociatedMethodFeature; -import de.tu_bs.cs.isf.cbc.tool.features.ChangeNameOfFormulaFeature; -import de.tu_bs.cs.isf.cbc.tool.features.CreateExtraSelectionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.DeleteConnectionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.EditCommentFeature; -import de.tu_bs.cs.isf.cbc.tool.features.EditCompositionTechniqueOfFormula; -import de.tu_bs.cs.isf.cbc.tool.features.ExtractMethodStubsFeature; -import de.tu_bs.cs.isf.cbc.tool.features.GenerateIntermediateConditionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.GenerateIntermediateConditionFeature2; -import de.tu_bs.cs.isf.cbc.tool.features.GenerateTextualRepresentation; -import de.tu_bs.cs.isf.cbc.tool.features.LayoutFeature; -import de.tu_bs.cs.isf.cbc.tool.features.ReconnectionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameConditionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameRenamingFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameStatementFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameVariableFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameVariantFeature; -import de.tu_bs.cs.isf.cbc.tool.features.ShowKeyFileFeature; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.features.UpdateDiagramFeature; -======= -import de.tu_bs.cs.isf.cbc.tool.features.TestAllStatements; -import de.tu_bs.cs.isf.cbc.tool.features.TestAndAssertionGenerator; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.features.UpdateDiagramFeature; -import de.tu_bs.cs.isf.cbc.tool.features.UpdateInformationFlowFeature; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.tool.features.VerifyAllStatements; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyMethodCallStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyOriginalCallStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyPostRepetitionStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyPreRepetitionStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyPreSelectionStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyStatement; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyStatementInlining; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyStrengthWeakCorrect; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyVariantWithInnerLoops; -import de.tu_bs.cs.isf.cbc.tool.features.VerifyVariantWithoutInnerLoops; -import de.tu_bs.cs.isf.cbc.tool.features.intermediate.AboveCompositionFirstFeature; -import de.tu_bs.cs.isf.cbc.tool.features.intermediate.AboveCompositionSecondFeature; -import de.tu_bs.cs.isf.cbc.tool.features.intermediate.AboveRepetitionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.intermediate.AboveSelectionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.intermediate.BelowImplementationFeature; -import de.tu_bs.cs.isf.cbc.tool.helper.GenerateCodeFromModel; -import de.tu_bs.cs.isf.cbc.tool.patterns.CompositionPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.ConditionPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.ConnectionPattern; -<<<<<<< HEAD -======= -import de.tu_bs.cs.isf.cbc.tool.patterns.FieldPattern; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.tool.patterns.FormulaPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.GlobalConditionsPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.MethodStatementPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.OriginalStatementPattern; -<<<<<<< HEAD -======= -import de.tu_bs.cs.isf.cbc.tool.patterns.ParameterPattern; ->>>>>>> master -//import de.tu_bs.cs.isf.cbc.tool.patterns.MethodStatementPattern; -//import de.tu_bs.cs.isf.cbc.tool.patterns.OriginalStatementPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.RenamePattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.RenamingPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.ReturnPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.SelectionPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.SkipStatementPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.SmallRepetitionPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.StatementPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.StrengthWeakStatementPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.VariablePattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.VariablesPattern; -import de.tu_bs.cs.isf.cbc.tool.patterns.VariantPattern; - -public class CbCFeatureProvider extends DefaultFeatureProviderWithPatterns { - - public CbCFeatureProvider(IDiagramTypeProvider dtp) { - super(dtp); - addPattern(new FormulaPattern()); - addPattern(new OriginalStatementPattern()); - addPattern(new CompositionPattern()); - addPattern(new SelectionPattern()); - addPattern(new SmallRepetitionPattern()); - addPattern(new SkipStatementPattern()); - addPattern(new MethodStatementPattern()); - addPattern(new ReturnPattern()); - addPattern(new StrengthWeakStatementPattern()); - addPattern(new StatementPattern()); - addPattern(new GlobalConditionsPattern()); - addPattern(new ConditionPattern()); - addPattern(new VariablesPattern()); - addPattern(new VariablePattern()); - addPattern(new RenamingPattern()); - addPattern(new RenamePattern()); -<<<<<<< HEAD -======= - addPattern(new FieldPattern()); //this one is remove by getCreateFeatures() below - addPattern(new ParameterPattern()); //this one is remove by getCreateFeatures() below ->>>>>>> master - addPattern(new VariantPattern()); //this one is remove by getCreateFeatures() below - addConnectionPattern(new ConnectionPattern()); - } - - @Override - public ICreateFeature[] getCreateFeatures() { - ICreateFeature[] oldArray = super.getCreateFeatures(); -<<<<<<< HEAD - ICreateFeature[] array = new ICreateFeature[oldArray.length]; - for (int i = 0; i < oldArray.length; i++) { - array[i] = oldArray[i]; - } - array[array.length - 1] = new CreateExtraSelectionFeature(this); -======= - ICreateFeature[] array = new ICreateFeature[oldArray.length-2];//remove the last two from above - for (int i = 0; i < array.length; i++) { - array[i] = oldArray[i]; - } - array[array.length - 1] = new CreateExtraSelectionFeature(this);//replace the third last with ExtraSelection ->>>>>>> master - return array; - } - - @Override - public IReconnectionFeature getReconnectionFeature(IReconnectionContext context) { - return new ReconnectionFeature(this); - } - - @Override - public IDeleteFeature getDeleteFeature(IDeleteContext context) { - if (context.getPictogramElement() instanceof Connection) { - return new DeleteConnectionFeature(this); - } - return super.getDeleteFeature(context); - } - - @Override - public ICustomFeature[] getCustomFeatures(ICustomContext context) { - return new ICustomFeature[] { - new ExtractMethodStubsFeature(this), //! - new GenerateCodeFromModel(this), -<<<<<<< HEAD - new GenerateTextualRepresentation(this), -======= - new GenerateTextualRepresentation(this), - new TestAllStatements(this), - new TestStatement(this), - new TestAndAssertionGenerator(this), ->>>>>>> master - new VerifyStatement(this), - new VerifyOriginalCallStatement(this), - new VerifyMethodCallStatement(this), - new VerifyPreRepetitionStatement(this), - new VerifyPostRepetitionStatement(this), - new VerifyPreSelectionStatement(this), - new VerifyStrengthWeakCorrect(this), - new VerifyVariantWithInnerLoops(this), - new VerifyVariantWithoutInnerLoops(this), //! - new EditCommentFeature(this), - new EditCompositionTechniqueOfFormula(this), //! - new ChangeNameOfFormulaFeature(this), - new RenameStatementFeature(this), - new RenameConditionFeature(this), - new RenameVariantFeature(this), - new RenameVariableFeature(this), - new RenameRenamingFeature(this), - new LayoutFeature(this), - new GenerateIntermediateConditionFeature(this), - new GenerateIntermediateConditionFeature2(this), - new ChangeNameOfAssociatedClassFeature(this), - new ChangeNameOfAssociatedMethodFeature(this), - new AboveCompositionFirstFeature(this), - new AboveCompositionSecondFeature(this), - new AboveSelectionFeature(this), - new AboveRepetitionFeature(this), - new BelowImplementationFeature(this), - new VerifyAllStatements(this), - new VerifyStatementInlining(this), -<<<<<<< HEAD - new UpdateDiagramFeature(this), - new ShowKeyFileFeature(this)}; -======= - new UpdateDiagramFeature(this), - new ShowKeyFileFeature(this), - new UpdateInformationFlowFeature(this)}; ->>>>>>> master - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCToolBehaviorProvider.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCToolBehaviorProvider.java.orig deleted file mode 100644 index a8f91b1c8..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/diagram/CbCToolBehaviorProvider.java.orig +++ /dev/null @@ -1,233 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.diagram; - -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.dt.IDiagramTypeProvider; -import org.eclipse.graphiti.features.ICreateConnectionFeature; -import org.eclipse.graphiti.features.ICreateFeature; -import org.eclipse.graphiti.features.IFeatureProvider; -import org.eclipse.graphiti.features.context.ICustomContext; -import org.eclipse.graphiti.features.context.IDoubleClickContext; -import org.eclipse.graphiti.features.context.IPictogramElementContext; -import org.eclipse.graphiti.features.custom.ICustomFeature; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.palette.IPaletteCompartmentEntry; -import org.eclipse.graphiti.palette.impl.ConnectionCreationToolEntry; -import org.eclipse.graphiti.palette.impl.ObjectCreationToolEntry; -import org.eclipse.graphiti.palette.impl.PaletteCompartmentEntry; -import org.eclipse.graphiti.tb.ContextMenuEntry; -import org.eclipse.graphiti.tb.DefaultToolBehaviorProvider; -import org.eclipse.graphiti.tb.IContextButtonPadData; -import org.eclipse.graphiti.tb.IContextMenuEntry; -import org.eclipse.graphiti.tb.IToolBehaviorProvider; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method; -======= -import de.tu_bs.cs.isf.cbc.cbcclass.Method; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.AbstractStatementImpl; -import de.tu_bs.cs.isf.cbc.tool.features.RenameConditionFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameRenamingFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameStatementFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameVariableFeature; -import de.tu_bs.cs.isf.cbc.tool.features.RenameVariantFeature; - -/** - * Own implementation of a ToolBehaviorProvider - * - * @author Tobias - * - */ -public class CbCToolBehaviorProvider extends DefaultToolBehaviorProvider implements IToolBehaviorProvider { - - /** - * Constructor of the class - * - * @param diagramTypeProvider - * The DiagramTypeProvider - */ - public CbCToolBehaviorProvider(IDiagramTypeProvider diagramTypeProvider) { - super(diagramTypeProvider); - } - - @Override - public IContextButtonPadData getContextButtonPad(IPictogramElementContext context) { - IContextButtonPadData data = super.getContextButtonPad(context); - PictogramElement pe = context.getPictogramElement(); - boolean notDelete = false; - - if (pe.getLink().getBusinessObjects() != null) { - for (EObject object : pe.getLink().getBusinessObjects()) { - if (object.getClass().equals(AbstractStatementImpl.class) && !(pe instanceof ContainerShape)) { - AbstractStatement statement = (AbstractStatement) object; - if (!(statement.eContainer() instanceof SelectionStatement)) { - notDelete = true; - } - } - } - } - if (notDelete) { - setGenericContextButtons(data, pe, CONTEXT_BUTTON_UPDATE); - } else { - setGenericContextButtons(data, pe, CONTEXT_BUTTON_DELETE | CONTEXT_BUTTON_UPDATE); - } - - return data; - } - - @Override - public ICustomFeature getDoubleClickFeature(IDoubleClickContext context) { - ICustomFeature customFeature = new RenameStatementFeature(getFeatureProvider()); - if (customFeature.canExecute(context)) { - return customFeature; - } - customFeature = new RenameConditionFeature(getFeatureProvider()); - if (customFeature.canExecute(context)) { - return customFeature; - } - customFeature = new RenameVariantFeature(getFeatureProvider()); - if (customFeature.canExecute(context)) { - return customFeature; - } - customFeature = new RenameVariableFeature(getFeatureProvider()); - if (customFeature.canExecute(context)) { - return customFeature; - } - customFeature = new RenameRenamingFeature(getFeatureProvider()); - if (customFeature.canExecute(context)) { - return customFeature; - } - return super.getDoubleClickFeature(context); - } - - @Override - public IContextMenuEntry[] getContextMenu(ICustomContext context) { - // create a sub-menu for all custom features -<<<<<<< HEAD -======= - ContextMenuEntry subMenuTest = new ContextMenuEntry(null, context); - subMenuTest.setText("Test"); - subMenuTest.setDescription("Test features submenu"); - // display sub-menu hierarchical or flat - subMenuTest.setSubmenu(true); - ->>>>>>> master - ContextMenuEntry subMenuVerify = new ContextMenuEntry(null, context); - subMenuVerify.setText("Verify"); - subMenuVerify.setDescription("Verify features submenu"); - // display sub-menu hierarchical or flat - subMenuVerify.setSubmenu(true); - - ContextMenuEntry subMenuPrint = new ContextMenuEntry(null, context); - subMenuPrint.setText("Edit"); - subMenuPrint.setDescription("Generate features submenu"); - // display sub-menu hierarchical or flat - subMenuPrint.setSubmenu(true); - - // create a menu-entry in the sub-menu for each custom feature - ICustomFeature[] customFeatures = getFeatureProvider().getCustomFeatures(context); - for (int i = 0; i < customFeatures.length; i++) { - ICustomFeature customFeature = customFeatures[i]; - if (customFeature.canExecute(context)) { -<<<<<<< HEAD - if (customFeature.getName().contains("Verify")) { -======= - if (customFeature.getName().contains("Test") || customFeature.getName().contains("test")) { - ContextMenuEntry menuEntry = new ContextMenuEntry(customFeature, context); - subMenuTest.add(menuEntry); - } else if (customFeature.getName().contains("Verify")) { ->>>>>>> master - ContextMenuEntry menuEntry = new ContextMenuEntry(customFeature, context); - subMenuVerify.add(menuEntry); - } else { - ContextMenuEntry menuEntry = new ContextMenuEntry(customFeature, context); - subMenuPrint.add(menuEntry); - } - } - } - -<<<<<<< HEAD - IContextMenuEntry ret[] = new IContextMenuEntry[] { subMenuVerify, subMenuPrint }; -======= - IContextMenuEntry ret[] = new IContextMenuEntry[] { subMenuTest, subMenuVerify, subMenuPrint }; ->>>>>>> master - return ret; - } - - @Override - public IPaletteCompartmentEntry[] getPalette() { - List ret = new ArrayList(); - - // add new compartment at the end of the existing compartments - PaletteCompartmentEntry compartmentStatementEntry = new PaletteCompartmentEntry("Statements", null); - ret.add(compartmentStatementEntry); - - PaletteCompartmentEntry compartmentOtherEntry = new PaletteCompartmentEntry("Other", null); - ret.add(compartmentOtherEntry); - - PaletteCompartmentEntry compartmentConnectionEntry = new PaletteCompartmentEntry("Connections", null); - ret.add(compartmentConnectionEntry); - - // add all create-features to the new stack-entry - IFeatureProvider featureProvider = getFeatureProvider(); - ICreateFeature[] createFeatures = featureProvider.getCreateFeatures(); - for (ICreateFeature cf : createFeatures) { - ObjectCreationToolEntry objectCreationToolEntry = new ObjectCreationToolEntry(cf.getCreateName(), cf.getCreateDescription(), cf.getCreateImageId(), cf.getCreateLargeImageId(), cf); - if (cf.getCreateName().contains("Variable") - || cf.getCreateName().contains("Condition") || cf.getCreateName().contains("Renam") - || cf.getCreateName().equals("ProductVariant")){ - compartmentOtherEntry.addToolEntry(objectCreationToolEntry); - } else if (!cf.getCreateName().contentEquals("RefinementList")) { - compartmentStatementEntry.addToolEntry(objectCreationToolEntry); - } - } - - // add all create-connection-features to the new stack-entry - ICreateConnectionFeature[] createConnectionFeatures = featureProvider.getCreateConnectionFeatures(); - for (ICreateConnectionFeature cf : createConnectionFeatures) { - ConnectionCreationToolEntry connectionCreationToolEntry = new ConnectionCreationToolEntry( - cf.getCreateName(), cf.getCreateDescription(), cf.getCreateImageId(), cf.getCreateLargeImageId()); - connectionCreationToolEntry.addCreateConnectionFeature(cf); - compartmentConnectionEntry.addToolEntry(connectionCreationToolEntry); - } - - return ret.toArray(new IPaletteCompartmentEntry[ret.size()]); - } - - @Override - public String getToolTip(GraphicsAlgorithm ga) { - PictogramElement pe = ga.getPictogramElement(); - Object bo = getFeatureProvider().getBusinessObjectForPictogramElement(pe); - if (bo instanceof AbstractStatement) { - String comment = ((AbstractStatement) bo).getComment(); - if (comment != null && !comment.isEmpty()) { - return comment; - } - } else if (bo instanceof CbCFormula) { - String comment = ((CbCFormula) bo).getComment(); - CbCFormula domainObject = (CbCFormula) bo; -<<<<<<< HEAD - if (domainObject.getMethodObj() != null && domainObject.getMethodObj().getParentClass().getInheritsFrom() != null) { -======= - if (domainObject.getMethodObj() != null && domainObject.getMethodObj().getParentClass() != null && domainObject.getMethodObj().getParentClass().getInheritsFrom() != null) { ->>>>>>> master - for (Method m : domainObject.getMethodObj().getParentClass().getInheritsFrom().getMethods()) { - if (m.getCbcStartTriple().getName().equals(domainObject.getName())) { - comment = "This method has a super implementation. See properties view for more information." + (comment == null ? "" : (" // " + comment)); - } - } - } - if (comment != null && !comment.isEmpty()) { - return comment; - } - } - return (String) super.getToolTip(ga); - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/CompositionPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/CompositionPattern.java.orig deleted file mode 100644 index fdb86dbc5..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/CompositionPattern.java.orig +++ /dev/null @@ -1,637 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.CompositionStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class CompositionPattern extends IdPattern implements IPattern { - - private static final String ID_ST1_TEXT = "statement1NameText"; - private static final String ID_CONDITION_TEXT = "conditionText"; -<<<<<<< HEAD -======= - private static final String ID_CONDITION_MOD = "otherConditionModifiables"; ->>>>>>> master - private static final String ID_ST2_TEXT = "statement2NameText"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_NAME_TEXT = "nameText"; - private static final String ID_PRE1_TEXT = "pre1NameText"; -<<<<<<< HEAD - private static final String ID_POST2_TEXT = "post2NameText"; -======= - private static final String ID_PRE1_MOD = "preConditionModifiables"; - private static final String ID_POST2_TEXT = "post2NameText"; - private static final String ID_POST2_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Header: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_ST1_HEADER = "statement1Header"; - private static final String ID_ST2_HEADER = "statement2Header"; - private static final String ID_IMC_HEADER = "intermediateCondHeader"; - //lines: - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; - private static final String ID_HOR3_LINE = "hor3Line"; - private static final String ID_HOR4_LINE = "hor4Line"; -<<<<<<< HEAD -======= - private static final String ID_HOR5_LINE = "hor5Line"; - private static final String ID_HOR6_LINE = "hor6Line"; - private static final String ID_HOR7_LINE = "hor7Line"; ->>>>>>> master - private static final String ID_VER1_LINE = "ver1Line"; - private static final String ID_VER2_LINE = "ver2Line"; - private static final String ID_VER3_LINE = "ver3Line"; - - - /** - * Constructor of the class - */ - public CompositionPattern() { - super(); - } - - @Override - public String getCreateName() { - return "CompositionStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a CompositionStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof CompositionStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - CompositionStatement compoStatement = CbcmodelFactory.eINSTANCE.createCompositionStatement(); - compoStatement.setName("compositionStatement"); - AbstractStatement statement1 = CbcmodelFactory.eINSTANCE.createAbstractStatement(); - statement1.setName("statement1"); - compoStatement.setFirstStatement(statement1); - Condition pre1 = CbcmodelFactory.eINSTANCE.createCondition(); - pre1.setName(""); - statement1.setPreCondition(pre1); - Condition post1 = CbcmodelFactory.eINSTANCE.createCondition(); - post1.setName(""); - statement1.setPostCondition(post1); - - Condition condition = CbcmodelFactory.eINSTANCE.createCondition(); - condition.setName("intermediateCond"); - compoStatement.setIntermediateCondition(condition); - AbstractStatement statement2 = CbcmodelFactory.eINSTANCE.createAbstractStatement(); - statement2.setName("statement2"); - compoStatement.setSecondStatement(statement2); - Condition pre2 = CbcmodelFactory.eINSTANCE.createCondition(); - pre2.setName(""); - statement2.setPreCondition(pre2); - Condition post2 = CbcmodelFactory.eINSTANCE.createCondition(); - post2.setName(""); - statement2.setPostCondition(post2); - - addGraphicalRepresentation(context, compoStatement); - return new Object[] { compoStatement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - CompositionStatement addedStatement = (CompositionStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - int width = context.getWidth() <= 0 ? 500 : context.getWidth(); -<<<<<<< HEAD - int height = context.getHeight() <= 0 ? 300 : context.getHeight(); -======= - int height = context.getHeight() <= 0 ? 350 : context.getHeight(); ->>>>>>> master - //font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShapeStatement1 = peCreateService.createShape(outerContainerShape, true); - MultiText statement1Text = gaService.createMultiText(textShapeStatement1, ""); - setId(statement1Text, ID_ST1_TEXT); - statement1Text.setValue(addedStatement.getFirstStatement().getName()); - statement1Text.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statement1Text.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeCondition = peCreateService.createShape(outerContainerShape, true); - MultiText conditionText = gaService.createMultiText(textShapeCondition, "{" + addedStatement.getIntermediateCondition().getName() + "}"); - setId(conditionText, ID_CONDITION_TEXT); - conditionText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - conditionText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD -======= - Shape textShapeIntmConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText intmConditionTextMod = gaService.createMultiText(textShapeIntmConditionMod, ""); - setId(intmConditionTextMod, ID_CONDITION_MOD); - String modString = ""; - for (String s : addedStatement.getIntermediateCondition().getModifiables()) { - modString += s + ", "; - } - intmConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - intmConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - intmConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - ->>>>>>> master - Shape textShapeStatement2 = peCreateService.createShape(outerContainerShape, true); - MultiText statement2Text = gaService.createMultiText(textShapeStatement2, ""); - setId(statement2Text, ID_ST2_TEXT); - statement2Text.setValue(addedStatement.getSecondStatement().getName()); - statement2Text.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statement2Text.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeName = peCreateService.createShape(outerContainerShape, false); - MultiText nameText = gaService.createMultiText(textShapeName, "Composition"); - setId(nameText, ID_NAME_TEXT); - nameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setFont(headerFont); - - Shape pre1Shape = peCreateService.createShape(outerContainerShape, false); - MultiText pre1NameText = gaService.createMultiText(pre1Shape, "{" + addedStatement.getFirstStatement().getPreCondition().getName()+ "}"); - setId(pre1NameText, ID_PRE1_TEXT); - pre1NameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - pre1NameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE1_MOD); - modString = ""; - for (String s : addedStatement.getIntermediateCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - ->>>>>>> master - Shape post2Shape = peCreateService.createShape(outerContainerShape, false); - MultiText post2NameText = gaService.createMultiText(post2Shape, "{" + addedStatement.getSecondStatement().getPostCondition().getName()+ "}"); - setId(post2NameText, ID_POST2_TEXT); - post2NameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - post2NameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD -======= - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST2_MOD); - modString = ""; - for (String s : addedStatement.getIntermediateCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - ->>>>>>> master - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - //Header: - Shape preHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text preHeader = gaService.createText(preHeaderShape, "precondition"); - setId(preHeader, ID_PRE_HEADER); - preHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setFont(headerFont); - - Shape postHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text postHeader = gaService.createText(postHeaderShape, "postcondition"); - setId(postHeader, ID_POST_HEADER); - postHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setFont(headerFont); - - Shape st1HeaderShape = peCreateService.createShape(outerContainerShape, false); - Text st1Header = gaService.createText(st1HeaderShape, "statement 1"); - setId(st1Header, ID_ST1_HEADER); - st1Header.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - st1Header.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - st1Header.setFont(headerFont); - - Shape st2HeaderShape = peCreateService.createShape(outerContainerShape, false); - Text st2Header = gaService.createText(st2HeaderShape, "statement 2"); - setId(st2Header, ID_ST2_HEADER); - st2Header.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - st2Header.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - st2Header.setFont(headerFont); - - Shape imcHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text imcHeader = gaService.createText(imcHeaderShape, "intermediate condition"); - setId(imcHeader, ID_IMC_HEADER); - imcHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - imcHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - imcHeader.setFont(headerFont); - //lines: - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Line = gaService.createPolyline(hor1LineShape); - setId(hor1Line, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Line = gaService.createPolyline(hor2LineShape); - setId(hor2Line, ID_HOR2_LINE); - - Shape hor3LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor3Line = gaService.createPolyline(hor3LineShape); - setId(hor3Line, ID_HOR3_LINE); - - Shape hor4LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor4Line = gaService.createPolyline(hor4LineShape); - setId(hor4Line, ID_HOR4_LINE); - -<<<<<<< HEAD -======= - Shape hor5LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor5Line = gaService.createPolyline(hor5LineShape); - setId(hor5Line, ID_HOR5_LINE); - - Shape hor6LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor6Line = gaService.createPolyline(hor6LineShape); - setId(hor6Line, ID_HOR6_LINE); - - Shape hor7LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor7Line = gaService.createPolyline(hor7LineShape); - setId(hor7Line, ID_HOR7_LINE); - ->>>>>>> master - Shape ver1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline ver1Line = gaService.createPolyline(ver1LineShape); - setId(ver1Line, ID_VER1_LINE); - - Shape ver2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline ver2Line = gaService.createPolyline(ver2LineShape); - setId(ver2Line, ID_VER2_LINE); - - Shape ver3LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline ver3Line = gaService.createPolyline(ver3LineShape); - setId(ver3Line, ID_VER3_LINE); - - peCreateService.createChopboxAnchor(textShapeStatement1); - peCreateService.createChopboxAnchor(textShapeStatement2); - peCreateService.createChopboxAnchor(outerContainerShape); - - link(outerContainerShape, addedStatement); - link(textShapeCondition, addedStatement.getIntermediateCondition()); -<<<<<<< HEAD - link(textShapeStatement1, addedStatement.getFirstStatement()); - link(textShapeStatement2, addedStatement.getSecondStatement()); - link(pre1Shape, addedStatement.getFirstStatement().getPreCondition()); - link(post2Shape, addedStatement.getSecondStatement().getPostCondition()); -======= - link(textShapeIntmConditionMod, addedStatement.getIntermediateCondition()); - link(textShapeStatement1, addedStatement.getFirstStatement()); - link(textShapeStatement2, addedStatement.getSecondStatement()); - link(pre1Shape, addedStatement.getFirstStatement().getPreCondition()); - link(textShapePreConditionMod, addedStatement.getFirstStatement().getPreCondition()); - link(post2Shape, addedStatement.getSecondStatement().getPostCondition()); - link(textShapePostConditionMod, addedStatement.getSecondStatement().getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int thirdWidth = mainRectangle.getWidth() / 3; - int halfWidth = mainRectangle.getWidth() / 2; -<<<<<<< HEAD - int sizeName = 60; //size of the name from the Statement (Composition) -======= - int sizeName = 40; //size of the name from the Statement (Composition) ->>>>>>> master - int HeightWithoutName = mainRectangle.getHeight() - sizeName; //size from the statement without the Name block, -20 for some space - int sizeHeader = 20; - int blockSize = HeightWithoutName / 2 - sizeHeader; //size from one block (statement, pre, ..) - int positionLine1 = mainRectangle.getHeight() - HeightWithoutName; - int positionLine2 = mainRectangle.getHeight() - HeightWithoutName / 2; - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), sizeName); - changesDone = true; - } else if (id.equals(ID_ST1_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine2 + sizeHeader, thirdWidth, blockSize); - changesDone = true; - } else if (id.equals(ID_CONDITION_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionLine2 + sizeHeader, thirdWidth, blockSize); -======= - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionLine2 + sizeHeader + blockSize/3, thirdWidth, 2 * blockSize/3); - changesDone = true; - } else if (id.equals(ID_CONDITION_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionLine2 + sizeHeader, thirdWidth, blockSize/3); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_ST2_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionLine2 + sizeHeader, thirdWidth, blockSize); - changesDone = true; - } else if (id.equals(ID_PRE1_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine1 + sizeHeader, halfWidth, blockSize); - changesDone = true; - } else if (id.equals(ID_POST2_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionLine1 + sizeHeader, halfWidth, blockSize); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine1 + sizeHeader + blockSize/3, halfWidth, 2 * blockSize/3); - changesDone = true; - } else if (id.equals(ID_PRE1_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine1 + sizeHeader, halfWidth, blockSize/3); - changesDone = true; - } else if (id.equals(ID_POST2_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionLine1 + sizeHeader + blockSize/3, halfWidth, 2 * blockSize/3); - changesDone = true; - } else if (id.equals(ID_POST2_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionLine1 + sizeHeader, halfWidth, blockSize/3); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - - //HEADER: - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine1, halfWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionLine1, halfWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_ST1_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine2, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_ST2_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionLine2, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_IMC_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionLine2, thirdWidth, sizeHeader); - changesDone = true; - //lines: - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine1, mainRectangle.getWidth(), positionLine1}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine1 + sizeHeader, mainRectangle.getWidth(), positionLine1 + sizeHeader}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR3_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine2 , mainRectangle.getWidth(), positionLine2}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR4_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine2 + sizeHeader, mainRectangle.getWidth(), positionLine2 + sizeHeader}); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD -======= - } else if (id.equals(ID_HOR5_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth, positionLine2 + sizeHeader + blockSize/3, thirdWidth*2, positionLine2 + sizeHeader + blockSize/3}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR6_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine1 + sizeHeader + blockSize/3, halfWidth, positionLine1 + sizeHeader + blockSize/3}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR7_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { halfWidth, positionLine1 + sizeHeader + blockSize/3, mainRectangle.getWidth(), positionLine1 + sizeHeader + blockSize/3}); - polyline.getPoints().addAll(pointList); - changesDone = true; ->>>>>>> master - } else if (id.equals(ID_VER1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { halfWidth, positionLine1, halfWidth, positionLine2 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth, positionLine2, thirdWidth, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER3_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth * 2, positionLine2, thirdWidth * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - CompositionStatement domainObject = (CompositionStatement) context.getDomainObject(); - if (checkIsProven(domainObject) && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!checkIsProven(domainObject) && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) -======= - } else if (!checkIsProven(domainObject) && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!checkIsProven(domainObject) && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) ->>>>>>> master - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - else if (id.equals(ID_IMAGE_PROVEN)) { - CompositionStatement domainObject = (CompositionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - CompositionStatement domainObject = (CompositionStatement) context.getDomainObject(); - if (checkIsProven(domainObject)) { - domainObject.setProven(true); - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - updateParent(domainObject); -<<<<<<< HEAD - } else { - domainObject.setProven(false); -======= - } else if (domainObject.isTested()) { - domainObject.setTested(true); - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - updateParent(domainObject); - } else { - domainObject.setProven(false); - domainObject.setTested(false); ->>>>>>> master - rectangle.setForeground(manageColor(IColorConstant.RED)); - updateParent(domainObject); - } - return true; - } - else if (id.equals(ID_IMAGE_PROVEN)) { - CompositionStatement domainObject = (CompositionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject)) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } - - private boolean checkIsProven(CompositionStatement statement) { - AbstractStatement firstStatement = statement.getFirstStatement(); - AbstractStatement secondStatement = statement.getSecondStatement(); - AbstractStatement firstStatementToCheck = null; - AbstractStatement secondStatementToCheck = null; - if (firstStatement.getRefinement() != null) { - firstStatementToCheck = firstStatement.getRefinement(); - } else { - firstStatementToCheck = firstStatement; - } - if (secondStatement.getRefinement() != null) { - secondStatementToCheck = secondStatement.getRefinement(); - } else { - secondStatementToCheck = secondStatement; - } - if (firstStatementToCheck.isProven() && secondStatementToCheck.isProven()) { - return true; - } else { - return false; - } - } - - private void updateParent(AbstractStatement statement) { - if(statement.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {statement.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConditionPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConditionPattern.java.orig deleted file mode 100644 index 54cb08cd0..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConditionPattern.java.orig +++ /dev/null @@ -1,536 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -<<<<<<< HEAD -======= -import java.io.IOException; -import java.util.Collections; - -import org.eclipse.core.resources.IProject; -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.URI; -import org.eclipse.emf.ecore.EObject; ->>>>>>> master -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDeleteContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.context.IRemoveContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.impl.TextImpl; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.mm.pictograms.impl.ShapeImpl; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -<<<<<<< HEAD - -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.GlobalConditions; -======= -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.xtext.resource.SaveOptions; - -import de.tu_bs.cs.isf.cbc.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.CompositionStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.GlobalConditions; -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.SmallRepetitionStatement; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.StrengthWeakStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.AbstractStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.CompositionStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.ReturnStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.SkipStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.StrengthWeakStatementImpl; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateConditionsOfChildren; -======= -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateContractsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateMethodCallsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateOriginalCallsToProve; -import de.tu_bs.cs.isf.cbc.util.FeatureUtil; -import de.tu_bs.cs.isf.cbc.util.UpdateConditionsOfChildren; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; ->>>>>>> master - -/** - * Class that creates the graphical representation of Conditions - * - * @author Tobias - * - */ -public class ConditionPattern extends IdPattern implements IPattern { - -<<<<<<< HEAD - // private static final String ID_NAME_TEXT = "conditionNameText"; - // private static final String ID_MAIN_RECTANGLE = "mainRectangle"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_MOD = "postConditionModifiables"; - private static final String ID_OTHER_MOD = "otherConditionModifiables"; ->>>>>>> master - - /** - * Constructor of the class - */ - public ConditionPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Condition"; - } - - @Override - public String getCreateDescription() { - return "Create a Condition."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof Condition; - } - - @Override - public boolean canCreate(ICreateContext context) { - return getBusinessObjectForPictogramElement(context.getTargetContainer()) instanceof GlobalConditions; - } - - @Override - public Object[] create(ICreateContext context) { - Condition condition = CbcmodelFactory.eINSTANCE.createCondition(); - condition.setName("{}"); -<<<<<<< HEAD - GlobalConditions conditions = (GlobalConditions) getBusinessObjectForPictogramElement( - context.getTargetContainer()); -======= - GlobalConditions conditions = (GlobalConditions) getBusinessObjectForPictogramElement(context.getTargetContainer()); ->>>>>>> master - conditions.getConditions().add(condition); - updatePictogramElement(context.getTargetContainer()); - return new Object[] { condition }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof GlobalConditions; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - return null; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - return false; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - Condition domainObject = (Condition) context.getDomainObject(); -<<<<<<< HEAD -======= - if (id.equals(ID_PRE_MOD) || id.equals(ID_POST_MOD) || id.equals(ID_OTHER_MOD)) { - String modString = ""; - for (String s : domainObject.getModifiables()) { - modString += s + ", "; - } - modString = "modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"; - if (!(modString.equals(nameText.getValue()))) { - return Reason.createTrueReason("Name differs. Expected: '" + modString + "'"); - } else { - return Reason.createFalseReason(); - } - } ->>>>>>> master - if (domainObject.getName() == null || !(domainObject.getName().equals(nameText.getValue()) - || nameText.getValue().equals("{" + domainObject.getName() + "}"))) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } -<<<<<<< HEAD - -======= ->>>>>>> master - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - Condition domainObject = (Condition) context.getDomainObject(); -<<<<<<< HEAD -======= - if (id.equals(ID_PRE_MOD) || id.equals(ID_POST_MOD) || id.equals(ID_OTHER_MOD)) { - if (!nameText.getValue().equals("")) { - String modString = ""; - for (String s : domainObject.getModifiables()) { - modString += s + ", "; - } - nameText.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - } - return true; - } ->>>>>>> master - if (domainObject.eContainer().getClass().equals(AbstractStatementImpl.class) - || domainObject.eContainer().getClass().equals(SkipStatementImpl.class) - || domainObject.eContainer().getClass().equals(ReturnStatementImpl.class) - || domainObject.eContainer().getClass().equals(StrengthWeakStatementImpl.class) - || domainObject.eContainer().getClass().equals(CompositionStatementImpl.class)) { - nameText.setValue("{" + domainObject.getName() + "}"); - } else { - nameText.setValue(domainObject.getName()); - } - return true; - } - return false; - } - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof Condition && ga instanceof MultiText) { - Condition condition = ((Condition) domainObject); - if (condition.eContainer() instanceof AbstractStatement) { - AbstractStatement statement = (AbstractStatement) condition.eContainer(); - if (statement.eContainer() instanceof CbCFormula || statement instanceof StrengthWeakStatement) { - return true; - } else if (statement.getPreCondition() != null && statement.getPreCondition().equals(condition)) { - return false; - } else if (statement.getPostCondition() != null && statement.getPostCondition().equals(condition)) { - return false; - } - return true; - } else if (condition.eContainer() instanceof GlobalConditions) { - return true; - } - } - if (domainObject instanceof Condition && ga instanceof Text) { - Condition condition = ((Condition) domainObject); - if (condition.eContainer() instanceof ModelClass) { - ModelClass mc = (ModelClass) condition.eContainer(); - if (mc.getName().equals(getDiagram().getName())) { - return true; - } - } - } - return false; - } - - @Override -<<<<<<< HEAD - public String getInitialValue(IDirectEditingContext context) { - Condition condition = (Condition) getBusinessObjectForPictogramElement(context.getPictogramElement()); - return System.getProperty("line.separator") + condition.getName() + System.getProperty("line.separator"); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - if (value == null) { - return "Condition must not be empty"; - } - if (value.length() > 0) { - if (value.contains("modifiable(")) { - String[] valueSplitted = value.split(";"); - if (valueSplitted.length > 1 - && !valueSplitted[0].trim().matches("modifiable\\(\\w+[\\[\\]\\*]*(,\\w+[\\[\\]\\*]*)*\\)")) { - return null;// "modifiable variables must be defined as: modifiable(x,y,z,...);"; - } else if ((value.contains("forall") || value.contains("exists"))) { - return null; - } - } -======= - public String getInitialValue(IDirectEditingContext context, String id) { - Condition condition = (Condition) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (id.equals(ID_PRE_MOD) || id.equals(ID_POST_MOD) || id.equals(ID_OTHER_MOD)) { - String modString = ""; - for (String s : condition.getModifiables()) { - modString += s + ", "; - } - return System.getProperty("line.separator") + ("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");") + System.getProperty("line.separator"); - } else { - return System.getProperty("line.separator") + condition.getName() + System.getProperty("line.separator"); - } - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context, String id) { - if (value == null) { - return "Must not be empty"; - } - if (id.equals(ID_PRE_MOD) || id.equals(ID_POST_MOD) || id.equals(ID_OTHER_MOD)) { - if (value.length() > 0) { - if (!value.trim().startsWith("modifiable(") || !value.trim().endsWith(");")) { - return "Does not match modifiable string"; - } - } - } else { - if (value.length() > 0) { - // valid string for condition or global condition - } ->>>>>>> master - } - return null; - } - - @Override -<<<<<<< HEAD - public void setValue(String value, IDirectEditingContext context) { - Condition condition = (Condition) getBusinessObjectForPictogramElement(context.getPictogramElement()); - condition.setName(value.trim()); - if (condition.eContainer() instanceof ModelClass) { - ShapeImpl shape = (ShapeImpl)context.getPictogramElement(); - TextImpl text = (TextImpl)shape.getGraphicsAlgorithm(); - text.setValue("{" + condition.getName() + "}"); - } else if (!(condition.eContainer() instanceof GlobalConditions)) { - // TODO: updateOriginalCallsToProve, updateMethodCallsToProve and - // updateContractsToProve - // needs to be triggered, when the whole diagram is saved and not exiting - // code-edit mode - //UpdateOriginalCallsToProve.updateOriginalCallsToProve(condition); TODO von max auskommentiert aufgrund nullpointerexception bei änderung einer bedingung - //UpdateMethodCallsToProve.updateMethodCallsToProve(condition); TODO von max auskommentiert aufgrund nullpointerexception bei änderung einer bedingung - //UpdateContractsToProve.updateContractsToProve(condition); TODO von max auskommentiert aufgrund nullpointerexception bei änderung einer bedingung -======= - public void setValue(String value, IDirectEditingContext context, String id) { - Condition condition = (Condition) getBusinessObjectForPictogramElement(context.getPictogramElement()); - var container = condition.eContainer().eContainer(); - if (container != null) { - if (container.eContainer() instanceof AbstractStatement) { - ((AbstractStatement)container.eContainer()).setTested(false); - TestStatement.setPathTested(TestStatement.getPathLeaf(container), false); - } - } - - if (id.equals(ID_PRE_MOD) || id.equals(ID_POST_MOD) || id.equals(ID_OTHER_MOD)) { - String[] split = value.trim().replace("modifiable(", "").replace(");", "").split(","); - condition.getModifiables().clear(); - for (String s : split) { - if (!s.equals("")) condition.getModifiables().add(s.trim()); - } - UpdateConditionsOfChildren.updateConditionsofChildren(condition); - updatePictogramElement(context.getPictogramElement()); - return; - } - condition.setName(value.trim()); - URI peURI = context.getPictogramElement().eResource().getURI(); - if (condition.eContainer() instanceof ModelClass) { - Shape shape = (Shape)context.getPictogramElement(); - Text text = (Text)shape.getGraphicsAlgorithm(); - text.setValue("{" + condition.getName() + "}"); - } else if (!(condition.eContainer() instanceof GlobalConditions)) { - if (peURI.lastSegment().contains(FeatureUtil.getInstance().getCallingClass(peURI))) { //change from CbCClass - try { - condition.eResource().setTrackingModification(true); - condition.eResource().save(Collections.EMPTY_MAP); - } catch (IOException e) { - e.printStackTrace(); - } - } - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof CbCFormula) { - CbCFormula formula = (CbCFormula) obj; - final AbstractStatement statement; - - // CbCFormula or AbstractStatement? - if (formula.getPostCondition() == condition) { - statement = formula.getStatement(); - } else { - statement = findStatementForCondition(condition, formula); - } - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), statement, lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - } - } - - try { - if (project.hasNature("de.ovgu.featureide.core.featureProjectNature")) { - UpdateOriginalCallsToProve.updateOriginalCallsToProve(condition); - UpdateMethodCallsToProve.updateMethodCallsToProve(condition); - UpdateContractsToProve.updateContractsToProve(condition); - } - } catch (CoreException e) { - e.printStackTrace(); - } - ->>>>>>> master - UpdateConditionsOfChildren.updateConditionsofChildren(condition); - } else if (condition.eContainer() instanceof GlobalConditions) { - CbCFormula formula = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof CbCFormula) { - formula = (CbCFormula) obj; - formula.setProven(false); -<<<<<<< HEAD -======= - formula.setTested(false); - TestStatement.setPathTested(formula.getStatement(), false); ->>>>>>> master - UpdateConditionsOfChildren.setAllStatementsUnproven(formula.getStatement()); - } - } - } - updatePictogramElement(context.getPictogramElement()); - } - - @Override - public boolean canRemove(IRemoveContext context) { - Shape shape = (Shape) context.getPictogramElement(); - if (shape.getGraphicsAlgorithm() instanceof Text) { - Text text = (Text) shape.getGraphicsAlgorithm(); - if (text.getValue().trim().endsWith("inherited")) { - return false; - } - } - return true; - } - - @Override - public boolean canDelete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - if (shape.getGraphicsAlgorithm() instanceof Text) { - Text text = (Text) shape.getGraphicsAlgorithm(); - if (text.getValue().trim().endsWith("inherited")) { - return false; - } - } - return true; - } - - @Override - public void delete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - ContainerShape container = shape.getContainer(); - - Condition condition = (Condition) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (condition.eContainer() != null && (condition.eContainer() instanceof GlobalConditions) || condition.eContainer() instanceof ModelClass) { - int indexToDelete = getIndex(shape.getGraphicsAlgorithm()); - - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) > indexToDelete) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) - 1); - } - } - if (condition.eContainer() instanceof ModelClass) { - super.delete(context); - layoutPictogramElement(container); - return; - } - super.delete(context); - layoutPictogramElement(container); - } else { - super.delete(context); - } - CbCFormula formula = null; - for (Shape childShape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(childShape); - if (obj instanceof CbCFormula) { - formula = (CbCFormula) obj; - } - } - formula.setProven(false); -<<<<<<< HEAD - UpdateConditionsOfChildren.setAllStatementsUnproven(formula.getStatement()); - } -======= - formula.setTested(false); - UpdateConditionsOfChildren.setAllStatementsUnproven(formula.getStatement()); - } - - private AbstractStatement findStatementForCondition(Condition condition, CbCFormula formula) { - return findStatementForCondition(condition, formula.getStatement().getRefinement()); - } - - private AbstractStatement findStatementForCondition(Condition condition, AbstractStatement statement) { - if (statement instanceof SelectionStatement) { - final SelectionStatement selection = (SelectionStatement) statement; - for (Condition guard : selection.getGuards()) { - if (guard == condition) { - return selection; - } - } - - for (AbstractStatement command : selection.getCommands()) { - final AbstractStatement returnValue = findStatementForCondition(condition, command); - if (returnValue != null) { - return returnValue; - } - } - - return null; - } - - if (statement instanceof SmallRepetitionStatement) { - final SmallRepetitionStatement repetition = (SmallRepetitionStatement) statement; - - if (repetition.getGuard() == condition) { - return repetition; - } - - if (repetition.getLoopStatement() != null) { - final AbstractStatement returnValue = findStatementForCondition(condition, repetition.getLoopStatement()); - if (returnValue != null) { - return returnValue; - } - } - } - - if (statement instanceof CompositionStatement) { - final CompositionStatement composition = (CompositionStatement) statement; - final AbstractStatement firstResult = findStatementForCondition(condition, composition.getFirstStatement()); - if (firstResult != null) { - return firstResult; - } - - return findStatementForCondition(condition, composition.getSecondStatement()); - } - - - - return null; - } ->>>>>>> master -} diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConnectionPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConnectionPattern.java.orig deleted file mode 100644 index 9d0511a1a..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ConnectionPattern.java.orig +++ /dev/null @@ -1,231 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -<<<<<<< HEAD -======= -import org.eclipse.core.resources.IProject; ->>>>>>> master -import org.eclipse.graphiti.features.context.IAddConnectionContext; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateConnectionContext; -import org.eclipse.graphiti.features.context.impl.AddConnectionContext; -import org.eclipse.graphiti.mm.GraphicsAlgorithmContainer; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.pictograms.Anchor; -import org.eclipse.graphiti.mm.pictograms.Connection; -import org.eclipse.graphiti.mm.pictograms.ConnectionDecorator; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.AbstractConnectionPattern; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.util.IColorConstant; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.AbstractStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.ReturnStatementImpl; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.SkipStatementImpl; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateConditionsOfChildren; -======= -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.cbc.util.UpdateConditionsOfChildren; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; ->>>>>>> master - -/** - * Class that creates the graphical representation of the parent hierarchy between Algorithms - * @author Tobias - * - */ -public class ConnectionPattern extends AbstractConnectionPattern { - - @Override - public String getCreateName() { - return "Refinement"; - } - - @Override - public String getCreateDescription() { - return "Firsty, select the abstract, then the refined."; - } - - @Override - public boolean canAdd(IAddContext context) { - return context instanceof IAddConnectionContext; - } - - @Override - public PictogramElement add(IAddContext context) { - IAddConnectionContext addConContext = (IAddConnectionContext) context; - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - - Connection connection = peCreateService.createFreeFormConnection(getDiagram()); - connection.setStart(addConContext.getSourceAnchor()); - connection.setEnd(addConContext.getTargetAnchor()); - - Polyline polyline = gaService.createPlainPolyline(connection); - polyline.setForeground(manageColor(IColorConstant.BLACK)); - - ConnectionDecorator cd; - cd = peCreateService.createConnectionDecorator(connection, false, 1.0, true); - createArrow(cd); - - return connection; - } - - @Override - public boolean canStartConnection(ICreateConnectionContext context) { - // Defines the start of the connection; allowed are objects that may - // contain other objects - Object domainObject = getBusinessObjectForPictogramElement(context.getSourcePictogramElement()); - if (domainObject != null && (domainObject.getClass().equals(SkipStatementImpl.class) || domainObject.getClass().equals(ReturnStatementImpl.class))) { - return false; - } - if (domainObject != null && (domainObject instanceof AbstractStatement)) { - AbstractStatement statement = (AbstractStatement) domainObject; - if (statement.getRefinement() != null) { - return false; - } - } - if (domainObject != null && (domainObject instanceof CbCFormula)) { - CbCFormula formula = (CbCFormula) domainObject; - if (formula.getStatement().getRefinement() != null) { - return false; - } - } - if (domainObject != null && (domainObject instanceof AbstractStatement || domainObject instanceof CbCFormula)) { - Object parentContainerObject = getBusinessObjectForPictogramElement(((Shape)context.getSourcePictogramElement()).getContainer()); - if (parentContainerObject != null && (parentContainerObject.getClass().equals(AbstractStatementImpl.class))) { - return false; - } - if (!(context.getSourcePictogramElement() instanceof ContainerShape)) { - return true; - } - } - return false; - } - - @Override - public boolean canCreate(ICreateConnectionContext context) { - PictogramElement sourcePictogramElement = context.getSourcePictogramElement(); - PictogramElement targetPictogramElement = context.getTargetPictogramElement(); - - if (sourcePictogramElement == null || targetPictogramElement == null || targetPictogramElement.equals(getDiagram()) || !(targetPictogramElement instanceof ContainerShape)) { - return false; - } - - Object sourceDomainObject = getBusinessObjectForPictogramElement(sourcePictogramElement); - Object targetDomainObject = getBusinessObjectForPictogramElement(targetPictogramElement); - - if (sourceDomainObject instanceof CbCFormula) { - sourceDomainObject = ((CbCFormula) sourceDomainObject).getStatement(); - } - if (targetDomainObject instanceof CbCFormula) { - return false; - } - if (sourceDomainObject instanceof AbstractStatement && targetDomainObject instanceof AbstractStatement) { - AbstractStatement targetStatement = (AbstractStatement) targetDomainObject; - AbstractStatement sourceStatement = (AbstractStatement) sourceDomainObject; - if (checkLoop(sourceStatement, targetStatement)) { - return false; - } - if (sourceStatement.getRefinement() != null) { - return false; - } - if (targetStatement.getParent() != null) { - return false; - } - if (sourceStatement.equals(targetStatement)) { - return false; - } - } - return true; - } - - /** - * checks if the connection creates a loop in the taxonomy - * @param sourceStatement the source statement of the connection - * @param targetStatement the target statement of the connection - * @return boolean if the connection creates a loop - */ - private boolean checkLoop(AbstractStatement sourceStatement, AbstractStatement targetStatement) { - boolean isParent = false; - if (targetStatement.getRefinement() != null) { - if (targetStatement.getRefinement().equals(sourceStatement)) { - return true; - } - } - if (sourceStatement.getParent() != null) { - isParent = checkLoop((AbstractStatement) sourceStatement.getParent(), targetStatement); - if (isParent) { - return true; - } - } - return false; - } - - @Override - public Connection create(ICreateConnectionContext context) { - Anchor sourceAnchor = context.getSourceAnchor(); - Anchor targetAnchor = context.getTargetAnchor(); - - if (targetAnchor == null) { - Shape shape = (Shape) context.getTargetPictogramElement(); - while (shape.getAnchors().isEmpty()) { - shape = shape.getContainer(); - } - targetAnchor = shape.getAnchors().get(0); - } - - AbstractStatement sourceObject; - if (getBusinessObjectForPictogramElement(sourceAnchor.getParent()) instanceof CbCFormula) { - sourceObject = ((CbCFormula) getBusinessObjectForPictogramElement(sourceAnchor.getParent())).getStatement(); - } else { - sourceObject = (AbstractStatement) getBusinessObjectForPictogramElement(sourceAnchor.getParent()); - } - AbstractStatement targetObject = (AbstractStatement) getBusinessObjectForPictogramElement(targetAnchor.getParent()); - - sourceObject.setRefinement(targetObject); - UpdateConditionsOfChildren.updateRefinedStatement(sourceObject, targetObject); - -<<<<<<< HEAD -======= - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), sourceObject, lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - ->>>>>>> master - AddConnectionContext addContext = new AddConnectionContext(sourceAnchor, targetAnchor); - Connection connection = (Connection) getFeatureProvider().addIfPossible(addContext); - - return connection; - } - - /** - * Helper method to create an arrow at the end of the connection - * @param gaContainer the connection decorator - * @return A polyline that is formed like an arrow - */ - private Polyline createArrow(GraphicsAlgorithmContainer gaContainer) { - Polyline polyline = Graphiti.getGaCreateService().createPlainPolyline(gaContainer, - new int[] { -15, 10, 0, 0, -15, -10 }); - polyline.setForeground(manageColor(IColorConstant.BLACK)); - return polyline; - } -} diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/FormulaPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/FormulaPattern.java.orig deleted file mode 100644 index bed3d7fb8..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/FormulaPattern.java.orig +++ /dev/null @@ -1,575 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.io.IOException; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method; -======= -import de.tu_bs.cs.isf.cbc.cbcclass.Method; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.model.CbcModelUtil; -======= -import de.tu_bs.cs.isf.cbc.util.CbcModelUtil; ->>>>>>> master - -/** - * Class that creates the graphical representation of Conditions - * - * @author Tobias - * - */ -public class FormulaPattern extends IdPattern implements IPattern { - - private static final String ID_STATEMENT_TEXT = "statementNameText"; - private static final String ID_NAME_TEXT = "nameText"; - private static final String ID_PRE_TEXT = "preConditionText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postConditionText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postConditionText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - private static final String ID_IMAGE_INHERITANCE = "imageinheritance"; - // Header: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_ST_HEADER = "stHeader"; - private static final String ID_POST_HEADER = "postHeader"; - // lines: - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; -<<<<<<< HEAD -======= - private static final String ID_HOR3_LINE = "hor3Line"; - private static final String ID_HOR4_LINE = "hor4Line"; ->>>>>>> master - private static final String ID_VER1_LINE = "ver1Line"; - private static final String ID_VER2_LINE = "ver2Line"; - - /** - * Constructor of the class - */ - public FormulaPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Formula"; - } - - @Override - public String getCreateDescription() { - return "Create a Formula."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof CbCFormula; - } - - @Override - public boolean canCreate(ICreateContext context) { - CbCFormula formula = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof CbCFormula) { - formula = (CbCFormula) obj; - } - } - if (formula != null) - return false; - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - CbCFormula formula = CbcmodelFactory.eINSTANCE.createCbCFormula(); - formula.setName(getDiagram().getName()); - AbstractStatement statement = CbcmodelFactory.eINSTANCE.createAbstractStatement(); - statement.setName("statement"); - formula.setStatement(statement); - Condition preCondition = CbcmodelFactory.eINSTANCE.createCondition(); - preCondition.setName("pre"); - statement.setPreCondition(preCondition); - Condition postCondition = CbcmodelFactory.eINSTANCE.createCondition(); - postCondition.setName("post"); - statement.setPostCondition(postCondition); - - // Use the following instead of the above line to store the model - // data in a seperate file parallel to the diagram file - try { - CbcModelUtil.saveFormulaToModelFile(formula, getDiagram()); - } catch (CoreException | IOException e) { - e.printStackTrace(); - } - addGraphicalRepresentation(context, formula); - return new Object[] { formula }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - CbCFormula addedFormula = (CbCFormula) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 400 : context.getWidth(); - int height = context.getHeight() <= 0 ? 200 : context.getHeight(); ->>>>>>> master - // header font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedFormula); - - // Statement name - Shape textShapePreCondition = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionText = gaService.createMultiText(textShapePreCondition, ""); - setId(preConditionText, ID_PRE_TEXT); - preConditionText.setValue("{" + addedFormula.getStatement().getPreCondition().getName() + "}"); - preConditionText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -======= - - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedFormula.getStatement().getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape textShapeStatement = peCreateService.createShape(outerContainerShape, true); - MultiText statementText = gaService.createMultiText(textShapeStatement, ""); - setId(statementText, ID_STATEMENT_TEXT); - statementText.setValue(addedFormula.getStatement().getName()); - statementText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostCondition = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionText = gaService.createMultiText(textShapePostCondition, ""); - postConditionText.setValue("{" + addedFormula.getStatement().getPostCondition().getName() + "}"); - setId(postConditionText, ID_POST_TEXT); - postConditionText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -======= - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedFormula.getStatement().getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape textShapeName = peCreateService.createShape(outerContainerShape, false); - MultiText nameText = gaService.createMultiText(textShapeName, "Formula"); - setId(nameText, ID_NAME_TEXT); - nameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setFont(headerFont); - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - Shape inheritanceShape = peCreateService.createShape(outerContainerShape, false); - Image imageInheritance = gaService.createImage(inheritanceShape, CbCImageProvider.IMG_INHERITANCE); - setId(imageInheritance, ID_IMAGE_INHERITANCE); - - // Header: - Shape preHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text preHeader = gaService.createText(preHeaderShape, "precondition"); - setId(preHeader, ID_PRE_HEADER); - preHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setFont(headerFont); - - Shape postHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text postHeader = gaService.createText(postHeaderShape, "postcondition"); - setId(postHeader, ID_POST_HEADER); - postHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setFont(headerFont); - - Shape stHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text stHeader = gaService.createText(stHeaderShape, "statement"); - setId(stHeader, ID_ST_HEADER); - stHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - stHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - stHeader.setFont(headerFont); - // lines: - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); -<<<<<<< HEAD -======= - - Shape hor3LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor3Polyline = gaService.createPolyline(hor3LineShape); - setId(hor3Polyline, ID_HOR3_LINE); - - Shape hor4LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor4Polyline = gaService.createPolyline(hor4LineShape); - setId(hor4Polyline, ID_HOR4_LINE); ->>>>>>> master - - Shape ver1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline ver1Polyline = gaService.createPolyline(ver1LineShape); - setId(ver1Polyline, ID_VER1_LINE); - - Shape ver2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline ver2Polyline = gaService.createPolyline(ver2LineShape); - setId(ver2Polyline, ID_VER2_LINE); - - peCreateService.createChopboxAnchor(textShapeStatement); - - link(outerContainerShape, addedFormula); - link(getDiagram(), addedFormula); - link(textShapePreCondition, addedFormula.getStatement().getPreCondition()); -<<<<<<< HEAD - link(textShapeStatement, addedFormula.getStatement()); - link(textShapePostCondition, addedFormula.getStatement().getPostCondition()); -======= - link(textShapePreConditionMod, addedFormula.getStatement().getPreCondition()); - link(textShapeStatement, addedFormula.getStatement()); - link(textShapePostCondition, addedFormula.getStatement().getPostCondition()); - link(textShapePostConditionMod, addedFormula.getStatement().getPostCondition()); ->>>>>>> master - link(proveShape, addedFormula); - link(inheritanceShape, addedFormula); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; - // stable sizes from Name and Header save space when the diagram gets big! - int sizeName = 30; // size from Formular block - int sizeHeader = 20; // size from the Header - int positionHeader = 40; // position where the Header is - int sizeText = mainRectangle.getHeight() - positionHeader - sizeHeader; // size from the blocks (pre, statement, post) - int positionText = positionHeader + sizeHeader; // position from the blocks (pre, statement, post) -<<<<<<< HEAD -======= - int modThird = sizeText / 3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 5, mainRectangle.getWidth(), sizeName); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText, third, sizeText); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText + modThird, third, sizeText - modThird); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText, third, modThird); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_STATEMENT_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, positionText, third, sizeText); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, third * 2, positionText, third, sizeText); -======= - Graphiti.getGaService().setLocationAndSize(ga, third * 2, positionText + modThird, third, sizeText - modThird); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, positionText, third, modThird); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - } else if (id.equals(ID_IMAGE_INHERITANCE)) { - Graphiti.getGaService().setLocationAndSize(ga, 10, 10, 19, 20); - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionHeader, third, sizeHeader); - changesDone = true; - } else if (id.equals(ID_ST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third, positionHeader, third, sizeHeader); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, positionHeader, third, sizeHeader); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionHeader, mainRectangle.getWidth(), positionHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList(new int[] { 0, positionHeader + sizeHeader, - mainRectangle.getWidth(), positionHeader + sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD -======= - } else if (id.equals(ID_HOR3_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList(new int[] { 0, positionText + modThird, - third, positionText + modThird }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR4_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList(new int[] { third * 2, positionText + modThird, - mainRectangle.getWidth(), positionText + modThird }); - polyline.getPoints().addAll(pointList); - changesDone = true; ->>>>>>> master - } else if (id.equals(ID_VER1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, positionHeader, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, positionHeader, third * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - AbstractStatement statement = domainObject.getStatement(); - AbstractStatement statementToCheck = null; - if (statement.getRefinement() != null) { - statementToCheck = statement.getRefinement(); - } else { - statementToCheck = statement; - } -<<<<<<< HEAD - if (statementToCheck.isProven() && ((rectangle.getForeground() != null - && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!statementToCheck.isProven() && ((rectangle.getForeground() != null - && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); -======= - try { - if (statementToCheck.isProven() && ((rectangle.getForeground() != null - && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!statementToCheck.isProven() && statementToCheck.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!statementToCheck.isProven() && !statementToCheck.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } catch (Exception e) { - // TODO: find better solution than this exception handling to fix the manageColor error that happens when a diagram is opened. ->>>>>>> master - } - } else if (id.equals(ID_IMAGE_PROVEN)) { - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - AbstractStatement statement = domainObject.getStatement(); - AbstractStatement statementToCheck = null; - if (statement.getRefinement() != null) { - statementToCheck = statement.getRefinement(); - } else { - statementToCheck = statement; - } - Image image = (Image) context.getGraphicsAlgorithm(); - if (statementToCheck.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!statementToCheck.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } else if (id.equals(ID_IMAGE_INHERITANCE)) { - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - boolean superImpl = false; -<<<<<<< HEAD - if (domainObject.getMethodObj() != null && domainObject.getMethodObj().getParentClass().getInheritsFrom() != null) { -======= - if (domainObject.getMethodObj() != null && domainObject.getMethodObj().getParentClass() != null && domainObject.getMethodObj().getParentClass().getInheritsFrom() != null) { ->>>>>>> master - for (Method m : domainObject.getMethodObj().getParentClass().getInheritsFrom().getMethods()) { - if (m.getCbcStartTriple().getName().equals(domainObject.getName())) { - superImpl = true; - } - } - } - Image image = (Image) context.getGraphicsAlgorithm(); - if (superImpl && image.getTransparency().equals(1.0)) { - return Reason.createTrueReason("Method has super implementation. Expected inheritance symbol."); - } else if (!superImpl && image.getTransparency().equals(0.0)) { - return Reason.createTrueReason("Method has no super implementation. Did not expect inheritance symbol."); - } - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - AbstractStatement statement = domainObject.getStatement(); - AbstractStatement statementToCheck = null; - if (statement.getRefinement() != null) { - statementToCheck = statement.getRefinement(); - } else { - statementToCheck = statement; - } - if (statementToCheck.isProven()) { - domainObject.setProven(true); - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); -<<<<<<< HEAD - } else { - domainObject.setProven(false); -======= - } else if (statementToCheck.isTested()) { - domainObject.setTested(true); - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - } else { - domainObject.setProven(false); - domainObject.setTested(false); ->>>>>>> master - rectangle.setForeground(manageColor(IColorConstant.RED)); - } - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - AbstractStatement statement = domainObject.getStatement(); - AbstractStatement statementToCheck = null; - if (statement.getRefinement() != null) { - statementToCheck = statement.getRefinement(); - } else { - statementToCheck = statement; - } - if (statementToCheck.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } else if (id.equals(ID_IMAGE_INHERITANCE)) { - CbCFormula domainObject = (CbCFormula) context.getDomainObject(); - boolean superImpl = false; - if (domainObject.getMethodObj() != null && domainObject.getMethodObj().getParentClass().getInheritsFrom() != null) { - for (Method m : domainObject.getMethodObj().getParentClass().getInheritsFrom().getMethods()) { - if (m.getCbcStartTriple().getName().equals(domainObject.getName())) { - superImpl = true; - } - } - } - Image image = (Image) context.getGraphicsAlgorithm(); - if (superImpl) { - image.setId(CbCImageProvider.IMG_INHERITANCE); - domainObject.setComment("This method has a super implementation!"); - image.setTransparency(0.0); - } else { - domainObject.setComment(""); - image.setTransparency(1.0); - } - } - return false; - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/GlobalConditionsPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/GlobalConditionsPattern.java.orig deleted file mode 100644 index 1524f2a79..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/GlobalConditionsPattern.java.orig +++ /dev/null @@ -1,222 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.io.IOException; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.EList; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.GlobalConditions; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.model.CbcModelUtil; -======= -import de.tu_bs.cs.isf.cbc.util.CbcModelUtil; ->>>>>>> master - -/** - * Class that creates the graphical representation of global conditions - * @author Tobias - * - */ -public class GlobalConditionsPattern extends IdPattern implements IPattern { - - private static final String ID_NAME_TEXT = "globalConditionsName"; - private static final String ID_CONDITION_TEXT = "globalcondition"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - //line: - private static final String ID_HOR1_LINE = "hor1Line"; - - - /** - * Constructor of the class - */ - public GlobalConditionsPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Global Conditions"; - } - - @Override - public String getCreateDescription() { - return "Create a list of global conditions."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof GlobalConditions; - } - - @Override - public boolean canCreate(ICreateContext context) { - GlobalConditions conds = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof GlobalConditions) { - conds = (GlobalConditions) obj; - } - } - if (conds != null) return false; - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - GlobalConditions conditions = CbcmodelFactory.eINSTANCE.createGlobalConditions(); - Condition condition = CbcmodelFactory.eINSTANCE.createCondition(); - condition.setName("{}"); - conditions.getConditions().add(condition); - - try { - CbcModelUtil.saveGlobalConditionsToModelFile(conditions, getDiagram()); - } catch (CoreException | IOException e) { - e.printStackTrace(); - } - - addGraphicalRepresentation(context, conditions); - return new Object[] { conditions }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - GlobalConditions addedGlobalConditions = (GlobalConditions) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - - int width = context.getWidth() <= 0 ? 200 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); - - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedGlobalConditions); - - // method name - Shape nameTextShape = peCreateService.createShape(outerContainerShape, false); - Text conditionsNameText = gaService.createText(nameTextShape, "Global Conditions"); - setId(conditionsNameText, ID_NAME_TEXT); - conditionsNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - conditionsNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - conditionsNameText.setFont(headerFont); - - //line: - Shape hor1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1line = gaService.createPolyline(hor1Shape); - setId(hor1line, ID_HOR1_LINE); - - link(outerContainerShape, addedGlobalConditions); - link(nameTextShape, addedGlobalConditions); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GlobalConditions conditions = (GlobalConditions) getBusinessObjectForPictogramElement(context.getRootPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int height = mainRectangle.getHeight(); - if (conditions.getConditions().size() >= 1) { - height = height / (conditions.getConditions().size() + 1); - } - - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), height); - changesDone = true; - } else if (id.equals(ID_CONDITION_TEXT)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, 0, height * (index + 1), mainRectangle.getWidth(), height); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, height, mainRectangle.getWidth(), height}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - ContainerShape containerShape = (ContainerShape) context.getPictogramElement(); - GlobalConditions conditions = (GlobalConditions) context.getDomainObject(); - if (containerShape.getChildren().size() - 2 != conditions.getConditions().size()) { - return Reason.createTrueReason("Number of Conditions differ. Expected: " + conditions.getConditions().size() - + " " + (containerShape.getChildren().size() - 2)); - } - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - EList conditions = ((GlobalConditions) context.getDomainObject()).getConditions(); - while (((ContainerShape) context.getPictogramElement()).getChildren().size() - 2 < conditions.size()) { - int newIndex = ((ContainerShape) context.getPictogramElement()).getChildren().size() - 2; - Condition condition = conditions.get(newIndex); - Shape shapeText = Graphiti.getPeCreateService().createShape((ContainerShape) context.getPictogramElement(), true); - MultiText conditionNameText = Graphiti.getGaService().createMultiText(shapeText, condition.getName()); - setId(conditionNameText, ID_CONDITION_TEXT); - setIndex(conditionNameText, newIndex); - conditionNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - conditionNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeText, condition); - } - return true; - } - return false; - } -} - diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/MethodStatementPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/MethodStatementPattern.java.orig deleted file mode 100644 index 9c27b16d7..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/MethodStatementPattern.java.orig +++ /dev/null @@ -1,605 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.ArrayList; -import java.util.List; -import java.util.regex.Pattern; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDeleteContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import de.tu_bs.cs.isf.cbc.cbcmodel.MethodStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -======= -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.DiagramPartsExtractor; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.util.FileUtil; - -public class MethodStatementPattern extends IdPattern implements IPattern { - - private static final String ID_NAME_TEXT = "statementText"; - private static final String ID_PRE_TEXT = "preText"; - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - // Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_NAME_HEADER = "statementHeader"; - private static final String ID_NAME_HEADER2 = "statementHeader2"; - // Separating lines: - private static final String ID_HEADER_SEPARATER = "headerSeparater"; - private static final String ID_POST_SEP = "postSep"; - private static final String ID_PRE_SEP = "preSep"; - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; - - /** - * Constructor of the class - */ - public MethodStatementPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Method-Call Statement"; - } - - @Override - public String getCreateDescription() { - return "Create a Method Statement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof MethodStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - MethodStatement statement = CbcmodelFactory.eINSTANCE.createMethodStatement();// - statement.setName("method();"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - MethodStatement addedStatement = (MethodStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>> master - // Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, true); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape preShape = peCreateService.createShape(outerContainerShape, false); - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -======= - - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -======= - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - // Header:--------------- - Shape textHeader = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader = gaService.createText(textHeader, "Method-Call"); - setId(statementNameHeader, ID_NAME_HEADER); - statementNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setFont(headerFont); - - // Header:--------------- - Shape textHeader2 = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader2 = gaService.createText(textHeader2, "Statement"); - setId(statementNameHeader2, ID_NAME_HEADER2); - statementNameHeader2.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setFont(headerFont); - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - // Separator: - Shape headerSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline headerPolyline = gaService.createPolyline(headerSepShape); - setId(headerPolyline, ID_HEADER_SEPARATER); - - Shape preSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline prePolyline = gaService.createPolyline(preSepShape); - setId(prePolyline, ID_PRE_SEP); - - Shape postSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline postPolyline = gaService.createPolyline(postSepShape); - setId(postPolyline, ID_POST_SEP); -<<<<<<< HEAD -======= - - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); ->>>>>>> master - - peCreateService.createChopboxAnchor(outerContainerShape); - peCreateService.createChopboxAnchor(textShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; -<<<<<<< HEAD -======= - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, mainRectangle.getHeight() - 40); -======= - Graphiti.getGaService().setLocationAndSize(ga, third * 2, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, thirdBlockHeight); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - // Header: - } else if (id.equals(ID_NAME_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 5, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_NAME_HEADER2)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 20, third, 20); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 20, third, 20); - changesDone = true; - // LINES: - } else if (id.equals(ID_HEADER_SEPARATER)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, 40, mainRectangle.getWidth(), 40 }); -<<<<<<< HEAD - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); -======= ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); -<<<<<<< HEAD -======= - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, thirdBlockHeight+40, third, thirdBlockHeight+40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 2*third, thirdBlockHeight+40, mainRectangle.getWidth(), thirdBlockHeight+40 }); ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText - && context.getDomainObject() instanceof MethodStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - MethodStatement domainObject = (MethodStatement) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && ((rectangle.getForeground() != null - && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!domainObject.isProven() && ((rectangle.getForeground() != null - && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } ->>>>>>> master - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText - && context.getDomainObject() instanceof AbstractStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - MethodStatement domainObject = (MethodStatement) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - MethodStatement domainObject = (MethodStatement) context.getDomainObject(); - if (domainObject.isProven()) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { domainObject.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } -<<<<<<< HEAD - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); -======= - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); ->>>>>>> master - EObject[] objArray = { domainObject.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - MethodStatement domainObject = (MethodStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof MethodStatement && ga instanceof MultiText) { - return true; - } - return false; - } - - @Override - public String getInitialValue(IDirectEditingContext context) { - MethodStatement statement = (MethodStatement) getBusinessObjectForPictogramElement( - context.getPictogramElement()); - return System.getProperty("line.separator") + statement.getName() + System.getProperty("line.separator"); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - value = value.replaceAll("\n", ""); - value = value.replaceAll("\r", ""); - if (value == null || value.length() == 0) { - return "Statement must not be empty"; - } - if (Pattern.matches(".*[a-zA-Z0-9]+[(].*[)].*", value) == false) { - return "Statement must contain a method-call"; - } - if (Pattern.matches(".*original[(].*[)].*", value) == true) { - return "Please use an Original-Call Statement for an original-call"; - } - if (!value.contains(";")) { - return "Statement must contain the end line character \";\""; - } - return null; - } - - private void updateParent(AbstractStatement statement) { - if (statement.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { statement.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } - - @Override - public void setValue(String value, IDirectEditingContext context) { - MethodStatement statement = (MethodStatement) getBusinessObjectForPictogramElement( - context.getPictogramElement()); - statement.setName(value.trim()); - statement.setProven(false); -<<<<<<< HEAD - JavaVariables vars = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof JavaVariables) { - vars = (JavaVariables) obj; - } - } - UpdateModifiableOfConditions.setVars(vars); - FileUtil.setApplicationUri(getDiagram().eResource().getURI()); - UpdateModifiableOfConditions.updateAssignmentStatement(statement); -======= - statement.setTested(false); - TestStatement.setPathTested(statement, false); - updateParent(statement); - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); - UpdateModifiableOfConditions.setVars(vars); - FileUtil.setApplicationUri(getDiagram().eResource().getURI()); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); ->>>>>>> master - updatePictogramElement(context.getPictogramElement()); - } - - @Override - public void delete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - ContainerShape container = shape.getContainer(); - MethodStatement statement = (MethodStatement) getBusinessObjectForPictogramElement( - context.getPictogramElement()); - if (statement != null && statement.eContainer() != null - && statement.eContainer() instanceof SelectionStatement) { - int indexToDelete = getIndex(shape.getGraphicsAlgorithm()); - SelectionStatement selectionStatement = (SelectionStatement) statement.eContainer(); - int indexInSelSt = selectionStatement.getCommands().indexOf(statement); - selectionStatement.getGuards().remove(indexInSelSt); - super.delete(context); - List shapesToDelete = new ArrayList(); - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) == indexToDelete) { - shapesToDelete.add(childShape); - } - } - for (Shape deleteShape : shapesToDelete) { - EcoreUtil.delete(deleteShape, true); - } - - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) > indexToDelete) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) - 1); - } - } - layoutPictogramElement(container); - } else { - super.delete(context); - } - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java.orig deleted file mode 100644 index 82cfcf23c..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java.orig +++ /dev/null @@ -1,834 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.ArrayList; -import java.util.List; -import java.util.regex.Pattern; - -<<<<<<< HEAD -import org.eclipse.core.resources.IProject; -======= ->>>>>>> master -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDeleteContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -import de.tu_bs.cs.isf.cbc.cbcmodel.OriginalStatement; -======== ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; - -public class OriginalStatementPattern extends IdPattern implements IPattern { - -======== -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -======= -import de.tu_bs.cs.isf.cbc.tool.helper.DiagramPartsExtractor; ->>>>>>> 8141930a (Added class DiagramPartsExtractor which eliminates tons of duplicated code.) -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; - -/** - * Class that creates the graphical representation of Conditions - * - * @author Tobias - * - */ -public class StatementPattern extends IdPattern implements IPattern { - ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= -import de.tu_bs.cs.isf.cbc.cbcmodel.OriginalStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.DiagramPartsExtractor; - -public class OriginalStatementPattern extends IdPattern implements IPattern { - ->>>>>>> master - private static final String ID_NAME_TEXT = "statementText"; - private static final String ID_PRE_TEXT = "preText"; - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - // Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_NAME_HEADER = "statementHeader"; -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - private static final String ID_NAME_HEADER2 = "statementHeader2"; -======== ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - private static final String ID_NAME_HEADER2 = "statementHeader2"; ->>>>>>> master - // Separating lines: - private static final String ID_HEADER_SEPARATER = "headerSeparater"; - private static final String ID_POST_SEP = "postSep"; - private static final String ID_PRE_SEP = "preSep"; - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; - - /** - * Constructor of the class - */ - public OriginalStatementPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Original-Call Statement"; - } - - @Override - public String getCreateDescription() { - return "Create an Original Statement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof OriginalStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - OriginalStatement statement = CbcmodelFactory.eINSTANCE.createOriginalStatement();// - statement.setName("original();"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== - ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - OriginalStatement addedStatement = (OriginalStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); -======== - manageColor(IColorConstant.LIGHT_ORANGE); - - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - // System.out.println("contributorID: - // "+targetDiagram.getDiagramTypeId()+".PropertyContributor"); - AbstractStatement addedStatement = (AbstractStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>> master - // Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, true); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape preShape = peCreateService.createShape(outerContainerShape, false); - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== -======= ->>>>>>> master - - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - // Header:--------------- - Shape textHeader = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader = gaService.createText(textHeader, "Original-Call"); - setId(statementNameHeader, ID_NAME_HEADER); - statementNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setFont(headerFont); - -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======= ->>>>>>> master - // Header:--------------- - Shape textHeader2 = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader2 = gaService.createText(textHeader2, "Statement"); - setId(statementNameHeader2, ID_NAME_HEADER2); - statementNameHeader2.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setFont(headerFont); - -<<<<<<< HEAD -======== ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - // Separator: - Shape headerSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline headerPolyline = gaService.createPolyline(headerSepShape); - setId(headerPolyline, ID_HEADER_SEPARATER); - - Shape preSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline prePolyline = gaService.createPolyline(preSepShape); - setId(prePolyline, ID_PRE_SEP); - - Shape postSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline postPolyline = gaService.createPolyline(postSepShape); - setId(postPolyline, ID_POST_SEP); -<<<<<<< HEAD - -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== -======= - ->>>>>>> master - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); -<<<<<<< HEAD - ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - ->>>>>>> master - peCreateService.createChopboxAnchor(outerContainerShape); - peCreateService.createChopboxAnchor(textShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, mainRectangle.getHeight() - 40); -======== -======= ->>>>>>> master - Graphiti.getGaService().setLocationAndSize(ga, third * 2, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, thirdBlockHeight); -<<<<<<< HEAD ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - // Header: - } else if (id.equals(ID_NAME_HEADER)) { -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - Graphiti.getGaService().setLocationAndSize(ga, third, 5, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_NAME_HEADER2)) { -======== ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - Graphiti.getGaService().setLocationAndSize(ga, third, 5, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_NAME_HEADER2)) { ->>>>>>> master - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 20, third, 20); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 20, third, 20); - changesDone = true; - // LINES: - } else if (id.equals(ID_HEADER_SEPARATER)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, 40, mainRectangle.getWidth(), 40 }); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); -======== ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== -======= ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, thirdBlockHeight+40, third, thirdBlockHeight+40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 2*third, thirdBlockHeight+40, mainRectangle.getWidth(), thirdBlockHeight+40 }); -<<<<<<< HEAD ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - && context.getDomainObject() instanceof OriginalStatement) { -======== - && context.getDomainObject() instanceof AbstractStatement) { ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - && context.getDomainObject() instanceof OriginalStatement) { ->>>>>>> master - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - OriginalStatement domainObject = (OriginalStatement) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && ((rectangle.getForeground() != null - && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - } else if (!domainObject.isProven() && ((rectangle.getForeground() != null - && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } -======== -======= ->>>>>>> master - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); -<<<<<<< HEAD - } ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - } ->>>>>>> master - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - -<<<<<<< HEAD - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - -======= ->>>>>>> master - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (context.getGraphicsAlgorithm() instanceof MultiText - && context.getDomainObject() instanceof AbstractStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - OriginalStatement domainObject = (OriginalStatement) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - OriginalStatement domainObject = (OriginalStatement) context.getDomainObject(); - if (domainObject.isProven()) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { domainObject.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======== - } - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { domainObject.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig - } -======= - } - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } ->>>>>>> master - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if (domainObject.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { domainObject.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } -<<<<<<< HEAD - - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - - updateParent(domainObject); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - OriginalStatement domainObject = (OriginalStatement) context.getDomainObject(); -======== - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - OriginalStatement domainObject = (OriginalStatement) context.getDomainObject(); ->>>>>>> master - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } -<<<<<<< HEAD - - private void updateParent(AbstractStatement statement) { - if (statement.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { statement.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } -======= ->>>>>>> master - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof OriginalStatement && ga instanceof MultiText) { - return true; - } - return false; - } - - @Override - public String getInitialValue(IDirectEditingContext context) { -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - OriginalStatement statement = (OriginalStatement) getBusinessObjectForPictogramElement( -======== - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement( ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - OriginalStatement statement = (OriginalStatement) getBusinessObjectForPictogramElement( ->>>>>>> master - context.getPictogramElement()); - return System.getProperty("line.separator") + statement.getName() + System.getProperty("line.separator"); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - value = value.replaceAll("\n", ""); - value = value.replaceAll("\r", ""); - if (value == null || value.length() == 0) { - return "Statement must not be empty"; - } -<<<<<<< HEAD - if (Pattern.matches(".*original[(].*[)].*", value) == true) { - return "Please use an Original-Call Statement for an original-call"; - } else if (Pattern.matches(".*[a-zA-Z0-9]+[(].*[)].*", value) == true) { - return "Please use an Method-Call Statement for an method-call"; - } -======= ->>>>>>> master - if (value.contains(";") && !CompareMethodBodies.readAndTestMethodBodyWithJaMoPP2(value)) { - return "Statement has not the correct syntax."; - } - - if (Pattern.matches(".*original[(].*[)].*", value) == false) { - return "Statement must contain an original-call"; - } else if (Pattern.matches(".*original[(][^.[(]]*[)].*", value) == false) { - return "No nested method-calls in an original-call allowed."; - } - return null; - } - - @Override - public void setValue(String value, IDirectEditingContext context) { -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -======= ->>>>>>> master - OriginalStatement statement = (OriginalStatement) getBusinessObjectForPictogramElement( - context.getPictogramElement()); - statement.setName(value.trim()); - statement.setProven(false); -<<<<<<< HEAD - JavaVariables vars = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof JavaVariables) { - vars = (JavaVariables) obj; - } - } - UpdateModifiableOfConditions.setVars(vars); - FileUtil.setApplicationUri(getDiagram().eResource().getURI()); - UpdateModifiableOfConditions.updateAssignmentStatement(statement); -======== - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement( - context.getPictogramElement()); - statement.setName(value.trim()); - statement.setProven(false); - statement.setTested(false); - TestStatement.setPathTested(statement, false); - updateParent(statement); - - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); - UpdateModifiableOfConditions.setVars(vars); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), statement, lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - statement.setTested(false); - TestStatement.setPathTested(statement, false); - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); - UpdateModifiableOfConditions.setVars(vars); - FileUtil.setApplicationUri(getDiagram().eResource().getURI()); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); ->>>>>>> master - updatePictogramElement(context.getPictogramElement()); - } - - @Override - public void delete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - ContainerShape container = shape.getContainer(); -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java - OriginalStatement statement = (OriginalStatement) getBusinessObjectForPictogramElement( -======== - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement( ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= - OriginalStatement statement = (OriginalStatement) getBusinessObjectForPictogramElement( ->>>>>>> master - context.getPictogramElement()); - if (statement != null && statement.eContainer() != null - && statement.eContainer() instanceof SelectionStatement) { - int indexToDelete = getIndex(shape.getGraphicsAlgorithm()); - SelectionStatement selectionStatement = (SelectionStatement) statement.eContainer(); - int indexInSelSt = selectionStatement.getCommands().indexOf(statement); - selectionStatement.getGuards().remove(indexInSelSt); - super.delete(context); - List shapesToDelete = new ArrayList(); - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) == indexToDelete) { - shapesToDelete.add(childShape); - } - } - for (Shape deleteShape : shapesToDelete) { - EcoreUtil.delete(deleteShape, true); - } - - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) > indexToDelete) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) - 1); - } - } - layoutPictogramElement(container); - } else { - super.delete(context); - } - } -<<<<<<< HEAD -<<<<<<<< HEAD:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/OriginalStatementPattern.java -} -======== -} ->>>>>>>> master:de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StatementPattern.java.orig -======= -} ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/RenamingPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/RenamingPattern.java.orig deleted file mode 100644 index 382df53ba..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/RenamingPattern.java.orig +++ /dev/null @@ -1,318 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.io.IOException; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.EList; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Rename; -import de.tu_bs.cs.isf.cbc.cbcmodel.Renaming; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.model.CbcModelUtil; -======= -import de.tu_bs.cs.isf.cbc.util.CbcModelUtil; ->>>>>>> master - -/** - * Class that creates the graphical representation for renaming - * @author Tobias - * - */ -public class RenamingPattern extends IdPattern implements IPattern { - - private static final String ID_NAME_TEXT = "RenamingName"; - private static final String ID_RENAME_FUNCTION = "functionName"; - private static final String ID_RENAME_TYPE = "functionType"; - private static final String ID_RENAME_NEW = "newFunctionName"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - //Header: - private static final String ID_TYPE_HEADER = "typeHeader"; - private static final String ID_DESTINATION_HEADER = "destinationHeader"; - private static final String ID_RENAMED_HEADER = "renamedHeader"; //the name that is used in the diagram - //lines: - private static final String ID_HOR1_LINE = "hor1Header"; - private static final String ID_HOR2_LINE = "hor2Header"; - private static final String ID_VER1_LINE = "ver1Header"; - private static final String ID_VER2_LINE = "ver2Header"; - - /** - * Constructor of the class - */ - public RenamingPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Renaming"; - } - - @Override - public String getCreateDescription() { - return "Create a list of function renaming."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof Renaming; - } - - @Override - public boolean canCreate(ICreateContext context) { - Renaming renaming = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof Renaming) { - renaming = (Renaming) obj; - } - } - if (renaming != null) return false; - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - Renaming renaming = CbcmodelFactory.eINSTANCE.createRenaming(); - Rename rename = CbcmodelFactory.eINSTANCE.createRename(); - rename.setType("pred"); - rename.setFunction("Example.example"); - rename.setNewName("exp"); - renaming.getRename().add(rename); - - try { - CbcModelUtil.saveRenamingToModelFile(renaming, getDiagram()); - } catch (CoreException | IOException e) { - e.printStackTrace(); - } - - addGraphicalRepresentation(context, renaming); - return new Object[] { renaming }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - Renaming addedRenaming = (Renaming) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - - int width = context.getWidth() <= 0 ? 400 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); - - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedRenaming); - - Shape nameTextShape = peCreateService.createShape(outerContainerShape, false); - Text renamingNameText = gaService.createText(nameTextShape, "Renaming"); - setId(renamingNameText, ID_NAME_TEXT); - renamingNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - renamingNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - renamingNameText.setFont(headerFont); - - //header: - Shape typeHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text typeHeader = gaService.createText(typeHeaderShape, "data type"); - setId(typeHeader, ID_TYPE_HEADER); - typeHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - typeHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - typeHeader.setFont(headerFont); - - Shape destinationHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text destinationHeader = gaService.createText(destinationHeaderShape, "original name"); - setId(destinationHeader, ID_DESTINATION_HEADER); - destinationHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - destinationHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - destinationHeader.setFont(headerFont); - - Shape remanedHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text remanedHeader = gaService.createText(remanedHeaderShape, "renamed"); - setId(remanedHeader, ID_RENAMED_HEADER); - remanedHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - remanedHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - remanedHeader.setFont(headerFont); - - //lines: - Shape hor1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1line = gaService.createPolyline(hor1Shape); - setId(hor1line, ID_HOR1_LINE); - - Shape hor2Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2line = gaService.createPolyline(hor2Shape); - setId(hor2line, ID_HOR2_LINE); - - Shape ver1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline ver1line = Graphiti.getGaService().createPolyline(ver1Shape); - setId(ver1line, ID_VER1_LINE); - - Shape ver2Shape = peCreateService.createShape(outerContainerShape, false); - Polyline ver2line = Graphiti.getGaService().createPolyline(ver2Shape); - setId(ver2line, ID_VER2_LINE); - - link(outerContainerShape, addedRenaming); - link(nameTextShape, addedRenaming); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - Renaming renaming = (Renaming) getBusinessObjectForPictogramElement(context.getRootPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int height = mainRectangle.getHeight(); - if (renaming.getRename().size() >= 1) { - height = height / (renaming.getRename().size() + 2); - } - int width = mainRectangle.getWidth() / 3; - - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), height); - changesDone = true; - } else if (id.equals(ID_RENAME_FUNCTION)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, width, height * (index + 2), width, height); - changesDone = true; - } else if (id.equals(ID_RENAME_TYPE)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, 0, height * (index + 2), width, height); - changesDone = true; - } else if (id.equals(ID_RENAME_NEW)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, width * 2, height * (index + 2), width, height); - changesDone = true; - } else if (id.equals(ID_TYPE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, height, width, height); - changesDone = true; - } else if (id.equals(ID_DESTINATION_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, width, height, width, height); - changesDone = true; - } else if (id.equals(ID_RENAMED_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, width * 2, height, width, height); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, height, mainRectangle.getWidth(), height}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, height * 2, mainRectangle.getWidth(), height * 2 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { width, height, width, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { width * 2, height, width * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - ContainerShape containerShape = (ContainerShape) context.getPictogramElement(); - Renaming renaming = (Renaming) context.getDomainObject(); - if (containerShape.getChildren().size() - 8 != renaming.getRename().size() * 3) { - return Reason.createTrueReason("Number of function renaming differ. Expected: " + renaming.getRename().size() - + " " + (containerShape.getChildren().size() - 8)); - } - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - EList renames = ((Renaming) context.getDomainObject()).getRename(); - while ((((ContainerShape) context.getPictogramElement()).getChildren().size() - 8) / 3 < renames.size()) { - int newIndex = (((ContainerShape) context.getPictogramElement()).getChildren().size() - 8) / 3; - Rename rename = renames.get(newIndex); - Shape shapeFunctionText = Graphiti.getPeCreateService().createShape((ContainerShape) context.getPictogramElement(), true); - Text functionNameText = Graphiti.getGaService().createText(shapeFunctionText, rename.getFunction()); - setId(functionNameText, ID_RENAME_FUNCTION); - setIndex(functionNameText, newIndex); - functionNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - functionNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeFunctionText, rename); - - Shape shapeTypeText = Graphiti.getPeCreateService().createShape((ContainerShape) context.getPictogramElement(), true); - Text functionTypeText = Graphiti.getGaService().createText(shapeTypeText, rename.getType()); - setId(functionTypeText, ID_RENAME_TYPE); - setIndex(functionTypeText, newIndex); - functionTypeText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - functionTypeText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeTypeText, rename); - - Shape shapeNewNameText = Graphiti.getPeCreateService().createShape((ContainerShape) context.getPictogramElement(), true); - Text functionNewNameText = Graphiti.getGaService().createText(shapeNewNameText, rename.getNewName()); - setId(functionNewNameText, ID_RENAME_NEW); - setIndex(functionNewNameText, newIndex); - functionNewNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - functionNewNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeNewNameText, rename); - } - return true; - } - return false; - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig deleted file mode 100644 index cb9874677..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig +++ /dev/null @@ -1,628 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -<<<<<<< HEAD -======= -import org.eclipse.core.resources.IProject; ->>>>>>> master -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import de.tu_bs.cs.isf.cbc.cbcmodel.ReturnStatement; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -======= -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.DiagramPartsExtractor; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; ->>>>>>> master - - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class ReturnPattern extends IdPattern implements IPattern { - - - private static final String ID_NAME_TEXT = "statementText"; - private static final String ID_PRE_TEXT = "preText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_NAME_HEADER = "statementHeader"; -<<<<<<< HEAD -======= - private static final String ID_NAME_HEADER2 = "statementHeader2"; ->>>>>>> master - //Separating lines: - private static final String ID_HEADER_SEPARATER = "headerSeparater"; - private static final String ID_POST_SEP = "postSep"; - private static final String ID_PRE_SEP = "preSep"; -<<<<<<< HEAD -======= - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; ->>>>>>> master - - /** - * Constructor of the class - */ - public ReturnPattern() { - super(); - } - - @Override - public String getCreateName() { - return "ReturnStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a ReturnStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof ReturnStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - ReturnStatement statement = CbcmodelFactory.eINSTANCE.createReturnStatement(); - statement.setName("Statement"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - statement.setComment("returnStatement"); - - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - ReturnStatement addedStatement = (ReturnStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>> master - //Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, true); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape preShape = peCreateService.createShape(outerContainerShape, false); -<<<<<<< HEAD - MultiText preNameText = gaService.createMultiText(preShape, "{" + addedStatement.getPreCondition().getName()+ "}"); -======= - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); ->>>>>>> master - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - //Header:--------------- - Shape textHeader = peCreateService.createShape(outerContainerShape, false); -<<<<<<< HEAD - Text statementNameHeader = gaService.createText(textHeader, "ReturnStatement"); -======= - Text statementNameHeader = gaService.createText(textHeader, "Return"); ->>>>>>> master - setId(statementNameHeader, ID_NAME_HEADER); - statementNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setFont(headerFont); -<<<<<<< HEAD -======= - - // Header:--------------- - Shape textHeader2 = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader2 = gaService.createText(textHeader2, "Statement"); - setId(statementNameHeader2, ID_NAME_HEADER2); - statementNameHeader2.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setFont(headerFont); ->>>>>>> master - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - //Separator: - Shape headerSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline headerPolyline = gaService.createPolyline(headerSepShape); - setId(headerPolyline, ID_HEADER_SEPARATER); - - Shape preSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline prePolyline = gaService.createPolyline(preSepShape); - setId(prePolyline, ID_PRE_SEP); - - Shape postSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline postPolyline = gaService.createPolyline(postSepShape); - setId(postPolyline, ID_POST_SEP); - -<<<<<<< HEAD -======= - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); - ->>>>>>> master - peCreateService.createChopboxAnchor(outerContainerShape); - peCreateService.createChopboxAnchor(textShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); -<<<<<<< HEAD - link(postShape, addedStatement.getPostCondition()); -======= - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; -<<<<<<< HEAD -======= - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, mainRectangle.getHeight() - 40); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, thirdBlockHeight); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - //Header: - } else if (id.equals(ID_NAME_HEADER)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); //mainrectangle anpassen -======= - Graphiti.getGaService().setLocationAndSize(ga, third, 5, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_NAME_HEADER2)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); // mainrectangle anpassen ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 20, third, 20); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 20, third, 20); - changesDone = true; - //LINES: - } else if (id.equals(ID_HEADER_SEPARATER)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, 40, mainRectangle.getWidth(), 40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); -======= - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, thirdBlockHeight+40, third, thirdBlockHeight+40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 2*third, thirdBlockHeight+40, mainRectangle.getWidth(), thirdBlockHeight+40 }); ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof ReturnStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - ReturnStatement domainObject = (ReturnStatement) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!domainObject.isProven() && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) ->>>>>>> master - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof AbstractStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven()) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } -<<<<<<< HEAD -======= - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } ->>>>>>> master - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } - } - - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - updateParent(domainObject); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } - - private void updateParent(AbstractStatement statement) { - if (statement.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { statement.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof AbstractStatement && ga instanceof MultiText) { - return true; - } - return false; - } - - @Override - public String getInitialValue(IDirectEditingContext context) { - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - return statement.getName(); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - if (value == null || value.length() == 0) { - return "Statement must not be empty"; - } - if (value.contains(";") && !CompareMethodBodies.readAndTestMethodBodyWithJaMoPP2(value)) { - return "Statement has not the correct syntax."; - } - return null; - } - - @Override - public void setValue(String value, IDirectEditingContext context) { - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - statement.setName(value); - statement.setProven(false); -<<<<<<< HEAD - JavaVariables vars = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof JavaVariables) { - vars = (JavaVariables) obj; - } - } - UpdateModifiableOfConditions.setVars(vars); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); -======= - statement.setTested(false); - TestStatement.setPathTested(statement, false); - updateParent(statement); - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); - UpdateModifiableOfConditions.setVars(vars); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), statement, lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - ->>>>>>> master - updatePictogramElement(context.getPictogramElement()); - } -} - diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig.orig deleted file mode 100644 index cb9874677..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/ReturnPattern.java.orig.orig +++ /dev/null @@ -1,628 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -<<<<<<< HEAD -======= -import org.eclipse.core.resources.IProject; ->>>>>>> master -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import de.tu_bs.cs.isf.cbc.cbcmodel.ReturnStatement; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -======= -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateModifiableOfConditions; -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; -import de.tu_bs.cs.isf.cbc.util.DiagramPartsExtractor; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; ->>>>>>> master - - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class ReturnPattern extends IdPattern implements IPattern { - - - private static final String ID_NAME_TEXT = "statementText"; - private static final String ID_PRE_TEXT = "preText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_NAME_HEADER = "statementHeader"; -<<<<<<< HEAD -======= - private static final String ID_NAME_HEADER2 = "statementHeader2"; ->>>>>>> master - //Separating lines: - private static final String ID_HEADER_SEPARATER = "headerSeparater"; - private static final String ID_POST_SEP = "postSep"; - private static final String ID_PRE_SEP = "preSep"; -<<<<<<< HEAD -======= - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; ->>>>>>> master - - /** - * Constructor of the class - */ - public ReturnPattern() { - super(); - } - - @Override - public String getCreateName() { - return "ReturnStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a ReturnStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof ReturnStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - ReturnStatement statement = CbcmodelFactory.eINSTANCE.createReturnStatement(); - statement.setName("Statement"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - statement.setComment("returnStatement"); - - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - ReturnStatement addedStatement = (ReturnStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>> master - //Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, true); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape preShape = peCreateService.createShape(outerContainerShape, false); -<<<<<<< HEAD - MultiText preNameText = gaService.createMultiText(preShape, "{" + addedStatement.getPreCondition().getName()+ "}"); -======= - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); ->>>>>>> master - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - //Header:--------------- - Shape textHeader = peCreateService.createShape(outerContainerShape, false); -<<<<<<< HEAD - Text statementNameHeader = gaService.createText(textHeader, "ReturnStatement"); -======= - Text statementNameHeader = gaService.createText(textHeader, "Return"); ->>>>>>> master - setId(statementNameHeader, ID_NAME_HEADER); - statementNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setFont(headerFont); -<<<<<<< HEAD -======= - - // Header:--------------- - Shape textHeader2 = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader2 = gaService.createText(textHeader2, "Statement"); - setId(statementNameHeader2, ID_NAME_HEADER2); - statementNameHeader2.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader2.setFont(headerFont); ->>>>>>> master - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - //Separator: - Shape headerSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline headerPolyline = gaService.createPolyline(headerSepShape); - setId(headerPolyline, ID_HEADER_SEPARATER); - - Shape preSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline prePolyline = gaService.createPolyline(preSepShape); - setId(prePolyline, ID_PRE_SEP); - - Shape postSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline postPolyline = gaService.createPolyline(postSepShape); - setId(postPolyline, ID_POST_SEP); - -<<<<<<< HEAD -======= - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); - ->>>>>>> master - peCreateService.createChopboxAnchor(outerContainerShape); - peCreateService.createChopboxAnchor(textShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); -<<<<<<< HEAD - link(postShape, addedStatement.getPostCondition()); -======= - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; -<<<<<<< HEAD -======= - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, mainRectangle.getHeight() - 40); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, thirdBlockHeight); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - //Header: - } else if (id.equals(ID_NAME_HEADER)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); //mainrectangle anpassen -======= - Graphiti.getGaService().setLocationAndSize(ga, third, 5, third, 20); // mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_NAME_HEADER2)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); // mainrectangle anpassen ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 20, third, 20); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 20, third, 20); - changesDone = true; - //LINES: - } else if (id.equals(ID_HEADER_SEPARATER)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, 40, mainRectangle.getWidth(), 40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); -======= - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, thirdBlockHeight+40, third, thirdBlockHeight+40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 2*third, thirdBlockHeight+40, mainRectangle.getWidth(), thirdBlockHeight+40 }); ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof ReturnStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - ReturnStatement domainObject = (ReturnStatement) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!domainObject.isProven() && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) ->>>>>>> master - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof AbstractStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven()) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } -<<<<<<< HEAD -======= - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } ->>>>>>> master - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } - } - - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - updateParent(domainObject); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } - - private void updateParent(AbstractStatement statement) { - if (statement.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { statement.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof AbstractStatement && ga instanceof MultiText) { - return true; - } - return false; - } - - @Override - public String getInitialValue(IDirectEditingContext context) { - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - return statement.getName(); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - if (value == null || value.length() == 0) { - return "Statement must not be empty"; - } - if (value.contains(";") && !CompareMethodBodies.readAndTestMethodBodyWithJaMoPP2(value)) { - return "Statement has not the correct syntax."; - } - return null; - } - - @Override - public void setValue(String value, IDirectEditingContext context) { - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - statement.setName(value); - statement.setProven(false); -<<<<<<< HEAD - JavaVariables vars = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof JavaVariables) { - vars = (JavaVariables) obj; - } - } - UpdateModifiableOfConditions.setVars(vars); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); -======= - statement.setTested(false); - TestStatement.setPathTested(statement, false); - updateParent(statement); - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); - UpdateModifiableOfConditions.setVars(vars); - UpdateModifiableOfConditions.updateAssignmentStatement(statement, new FileUtil(getDiagram().eResource().getURI().toPlatformString(true))); - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), statement, lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - ->>>>>>> master - updatePictogramElement(context.getPictogramElement()); - } -} - diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SelectionPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SelectionPattern.java.orig deleted file mode 100644 index 3f9f1caa9..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SelectionPattern.java.orig +++ /dev/null @@ -1,712 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.SelectionStatement; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; - -/** - * Class that creates the graphical representation of Conditions - * - * @author Tobias - * - */ -public class SelectionPattern extends IdPattern implements IPattern { - - private static final String ID_STATEMENT_TEXT = "statementSelNameText"; - private static final String ID_CONDITION_TEXT = "conditionSelText"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_NAME_TEXT = "nameText"; - private static final String ID_PRE_TEXT = "preText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_IMAGE_PROVEN = "imageproven"; - // HEADERS: - private static final String ID_GUARD_HEADER = "guardHeader"; - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_STATEMENT_HEADER = "statementHeader"; - private static final String ID_POST_HEADER = "postHeader"; - // lines: - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; - private static final String ID_HOR3_LINE = "hor3Line"; - private static final String ID_HOR4_LINE = "hor4Line"; - private static final String ID_HOR5_LINE = "hor5Line"; - private static final String ID_HOR6_LINE = "hor6Line"; - private static final String ID_HOR7_LINE = "hor7Line"; - private static final String ID_HOR8_LINE = "hor8Line"; -<<<<<<< HEAD -======= - private static final String ID_HOR9_LINE = "hor9Line"; - private static final String ID_HOR10_LINE = "hor10Line"; ->>>>>>> master - private static final String ID_VER1_LINE = "ver1Line"; // in guards - private static final String ID_VER2_LINE = "ver2Line"; // in pre conds - private static final String ID_VER3_LINE = "ver3Line"; // in statements - - /** - * Constructor of the class - */ - public SelectionPattern() { - super(); - } - - @Override - public String getCreateName() { - return "SelectionStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a SelectionStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof SelectionStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - SelectionStatement selectionStatement = CbcmodelFactory.eINSTANCE.createSelectionStatement(); - selectionStatement.setName("selectionStatement"); - AbstractStatement statement = CbcmodelFactory.eINSTANCE.createAbstractStatement(); - statement.setName("statement"); - selectionStatement.getCommands().add(statement); - Condition condition = CbcmodelFactory.eINSTANCE.createCondition(); - condition.setName("guard"); - selectionStatement.getGuards().add(condition); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - addGraphicalRepresentation(context, selectionStatement); - return new Object[] { selectionStatement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - SelectionStatement addedStatement = (SelectionStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 200 : context.getWidth(); - int height = context.getHeight() <= 0 ? 300 : context.getHeight(); - // font: -======= - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 500 : context.getHeight(); - // Font: ->>>>>>> master - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - Shape textShapeName = peCreateService.createShape(outerContainerShape, false); - MultiText nameText = gaService.createMultiText(textShapeName, "SelectionStatement IF..FI"); - setId(nameText, ID_NAME_TEXT); - nameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -<<<<<<< HEAD -======= - nameText.setFont(headerFont); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - // HEADERS: - - Shape guardHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text guardHeader = gaService.createText(guardHeaderShape, "guards"); - setId(guardHeader, ID_GUARD_HEADER); - guardHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - guardHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - guardHeader.setFont(headerFont); - - Shape preHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text preHeader = Graphiti.getGaService().createText(preHeaderShape, "precondition"); - setId(preHeader, ID_PRE_HEADER); - preHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preHeader.setFont(headerFont); - - Shape statementHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text statementHeader = Graphiti.getGaService().createText(statementHeaderShape, "statements"); - setId(statementHeader, ID_STATEMENT_HEADER); - statementHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementHeader.setFont(headerFont); - - Shape postHeaderShape = peCreateService.createShape(outerContainerShape, false); - Text postHeader = Graphiti.getGaService().createText(postHeaderShape, "postcondition"); - setId(postHeader, ID_POST_HEADER); - postHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postHeader.setFont(headerFont); - - // LINES: - - Shape hor1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1line = gaService.createPolyline(hor1Shape); - setId(hor1line, ID_HOR1_LINE); - - Shape hor2Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2line = gaService.createPolyline(hor2Shape); - setId(hor2line, ID_HOR2_LINE); - - Shape hor3Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor3line = gaService.createPolyline(hor3Shape); - setId(hor3line, ID_HOR3_LINE); - - Shape hor4Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor4line = gaService.createPolyline(hor4Shape); - setId(hor4line, ID_HOR4_LINE); - - Shape hor5Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor5line = gaService.createPolyline(hor5Shape); - setId(hor5line, ID_HOR5_LINE); - - Shape hor6Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor6line = gaService.createPolyline(hor6Shape); - setId(hor6line, ID_HOR6_LINE); - - Shape hor7Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor7line = gaService.createPolyline(hor7Shape); - setId(hor7line, ID_HOR7_LINE); - - Shape hor8Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor8line = gaService.createPolyline(hor8Shape); - setId(hor8line, ID_HOR8_LINE); -<<<<<<< HEAD -======= - - Shape hor9Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor9line = gaService.createPolyline(hor9Shape); - setId(hor9line, ID_HOR9_LINE); - - Shape hor10Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor10line = gaService.createPolyline(hor10Shape); - setId(hor10line, ID_HOR10_LINE); ->>>>>>> master - - peCreateService.createChopboxAnchor(outerContainerShape); - - link(outerContainerShape, addedStatement); - - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - SelectionStatement statement = (SelectionStatement) getBusinessObjectForPictogramElement( - context.getRootPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int width = mainRectangle.getWidth(); - int sizeHeader = 20; - int sizeName = 40; // name = SelectionStatement IF..FI - int sizeBlock = (mainRectangle.getHeight() - sizeName) / 4 - sizeHeader; // Height from one Block - int positionLine1 = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName) / 4 * 4 + 20; // guard - int positionLine2 = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName) / 4 * 3 + 20; // pre - int positionLine3 = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName) / 4 * 2 + 20; // statement - int positionLine4 = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName) / 4 * 1 + 20; // post -<<<<<<< HEAD -======= - int positionLine5 = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName) / 4 * 0 + 20; // virtual line - int positionPreModLine = (positionLine3-positionLine2-20)/3 + positionLine2; // modifiables pre - int positionPostModLine = (positionLine5-positionLine4-20)/3 + positionLine4; // modifiables post ->>>>>>> master - if (statement.getCommands().size() > 1) { - width = width / statement.getCommands().size(); - } - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), sizeName); - changesDone = true; - } else if (id.equals(ID_CONDITION_TEXT)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, width * index, positionLine1, width, sizeBlock); - changesDone = true; - } else if (id.equals(ID_STATEMENT_TEXT)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, width * index, positionLine3, width, sizeBlock); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { - int index = getIndex(context.getGraphicsAlgorithm()); -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, width * index, positionLine2, width, sizeBlock); -======= - Graphiti.getGaService().setLocationAndSize(ga, width * index, positionPreModLine, width, (sizeBlock/3)*2); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine2, mainRectangle.getWidth(), sizeBlock/3); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - // Header: - } else if (id.equals(ID_POST_TEXT) && getIndex(context.getGraphicsAlgorithm()) == 0) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine4, mainRectangle.getWidth(), sizeBlock); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, positionPostModLine, mainRectangle.getWidth(), (sizeBlock/3)*2); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine4, mainRectangle.getWidth(), sizeBlock/3); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_GUARD_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine1 - sizeHeader, mainRectangle.getWidth(), - sizeHeader); - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine2 - sizeHeader, mainRectangle.getWidth(), - sizeHeader); - changesDone = true; - } else if (id.equals(ID_STATEMENT_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine3 - sizeHeader, mainRectangle.getWidth(), - sizeHeader); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionLine4 - sizeHeader, mainRectangle.getWidth(), - sizeHeader); - changesDone = true; - // lines: - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine1 - sizeHeader, mainRectangle.getWidth(), positionLine1 - sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionLine1, mainRectangle.getWidth(), positionLine1 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR3_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine2 - sizeHeader, mainRectangle.getWidth(), positionLine2 - sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR4_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionLine2, mainRectangle.getWidth(), positionLine2 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR5_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine3 - sizeHeader, mainRectangle.getWidth(), positionLine3 - sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR6_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionLine3, mainRectangle.getWidth(), positionLine3 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR7_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionLine4 - sizeHeader, mainRectangle.getWidth(), positionLine4 - sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR8_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionLine4, mainRectangle.getWidth(), positionLine4 }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD -======= - } else if (id.equals(ID_HOR9_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionPreModLine, mainRectangle.getWidth(), positionPreModLine }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR10_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, positionPostModLine, mainRectangle.getWidth(), positionPostModLine }); - polyline.getPoints().addAll(pointList); - changesDone = true; ->>>>>>> master - } else if (id.equals(ID_VER1_LINE)) { - int index = getIndex(context.getGraphicsAlgorithm()); - if (index > 0) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { width * index, positionLine1, width * index, positionLine2 - sizeHeader }); - polyline.getPoints().addAll(pointList); - } else { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - } - changesDone = true; - } else if (id.equals(ID_VER2_LINE)) { - int index = getIndex(context.getGraphicsAlgorithm()); - if (index > 0) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( -<<<<<<< HEAD - new int[] { width * index, positionLine2, width * index, positionLine3 - sizeHeader }); -======= - new int[] { width * index, positionPreModLine, width * index, positionLine3 - sizeHeader }); ->>>>>>> master - polyline.getPoints().addAll(pointList); - } else { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - } - changesDone = true; - } else if (id.equals(ID_VER3_LINE)) { - int index = getIndex(context.getGraphicsAlgorithm()); - if (index > 0) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { width * index, positionLine3, width * index, positionLine4 - sizeHeader }); - polyline.getPoints().addAll(pointList); - } else { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - } - } - changesDone = true; - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - ContainerShape containerShape = (ContainerShape) context.getPictogramElement(); - SelectionStatement statement = (SelectionStatement) context.getDomainObject(); -<<<<<<< HEAD - if (containerShape.getChildren().size() - 14 != statement.getCommands().size() * 7) { -======= - if (containerShape.getChildren().size() - 16 != statement.getCommands().size() * 9) { ->>>>>>> master - return Reason.createTrueReason("Number of Commands and Guards differ. Expected: " - + statement.getCommands().size() + " " + containerShape.getChildren().size()); - } - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - if (checkIsProven(statement) && ((rectangle.getForeground() != null - && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!checkIsProven(statement) && ((rectangle.getForeground() != null - && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); -======= - } else if (!statement.isProven() && statement.isTested() - && ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!checkIsProven(statement) && !statement.isTested() && ((rectangle.getForeground() != null - && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven or tested. Expected red color."); ->>>>>>> master - } - } else if (id.equals(ID_IMAGE_PROVEN)) { - SelectionStatement domainObject = (SelectionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - ContainerShape containerShape = (ContainerShape) context.getPictogramElement(); - SelectionStatement statement = (SelectionStatement) context.getDomainObject(); -<<<<<<< HEAD - // 7 = number of graphics elements in update (vertical lines + blocks) - // 13 = number of graphics in doAdd (horizontal lines + header + name) - while (containerShape.getChildren().size() - 14 != statement.getCommands().size() * 7) { - // if (containerShape.getChildren().size() - 1 != statement.getCommands().size() - // * 4) { - EList childStatements = ((SelectionStatement) context.getDomainObject()) - .getCommands(); - int newIndex = (containerShape.getChildren().size() - 14) / 7; - // int newIndex = childStatements.size() - 1; -======= - // 9 = number of graphics elements in update (vertical lines + blocks) - // 16 = number of graphics in doAdd (horizontal lines + header + name) - while (containerShape.getChildren().size() - 16 != statement.getCommands().size() * 9) { - EList childStatements = ((SelectionStatement) context.getDomainObject()).getCommands(); - int newIndex = (containerShape.getChildren().size() - 16) / 9; ->>>>>>> master - AbstractStatement childStatement = childStatements.get(newIndex); - Shape shapeText = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), true); - MultiText statementNameText = Graphiti.getGaService().createMultiText(shapeText, - childStatement.getName()); - setId(statementNameText, ID_STATEMENT_TEXT); - setIndex(statementNameText, newIndex); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - peCreateService.createChopboxAnchor(shapeText); - link(shapeText, childStatement); - - Shape shapeTextPre = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), false); - MultiText preNameText = Graphiti.getGaService().createMultiText(shapeTextPre, - "{" + childStatement.getPreCondition().getName() + "}"); - setId(preNameText, ID_PRE_TEXT); - setIndex(preNameText, newIndex); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeTextPre, childStatement.getPreCondition()); -<<<<<<< HEAD -======= - - Shape textShapePreConditionMod = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), true); - MultiText preConditionTextMod = Graphiti.getGaService().createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : childStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - if (newIndex == 0) { - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - } else { - preConditionTextMod.setValue(""); - } - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(textShapePreConditionMod, childStatement.getPreCondition()); ->>>>>>> master - - Shape shapeTextPost = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), false); - MultiText postNameText = Graphiti.getGaService().createMultiText(shapeTextPost, - "{" + childStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - setIndex(postNameText, newIndex); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeTextPost, childStatement.getPostCondition()); -<<<<<<< HEAD -======= - - Shape textShapePostConditionMod = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), true); - MultiText postConditionTextMod = Graphiti.getGaService().createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - if (childStatement.getParent() != null) { - for (String s : childStatement.getParent().getPostCondition().getModifiables()) { - modString += s + ", "; - } - } - if (newIndex == 0) { - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - } else { - postConditionTextMod.setValue(""); - } - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(textShapePostConditionMod, childStatement.getPostCondition()); ->>>>>>> master - - // vertical lines, that need to be added, when ExtraSelection is used: - Shape ver1Shape = peCreateService.createShape((ContainerShape) context.getPictogramElement(), false); - Polyline ver1line = Graphiti.getGaService().createPolyline(ver1Shape); - setId(ver1line, ID_VER1_LINE); - setIndex(ver1line, newIndex); - - Shape ver2Shape = peCreateService.createShape((ContainerShape) context.getPictogramElement(), false); - Polyline ver2line = Graphiti.getGaService().createPolyline(ver2Shape); - setId(ver2line, ID_VER2_LINE); - setIndex(ver2line, newIndex); - - Shape ver3Shape = peCreateService.createShape((ContainerShape) context.getPictogramElement(), false); - Polyline ver3line = Graphiti.getGaService().createPolyline(ver3Shape); - setId(ver3line, ID_VER3_LINE); - setIndex(ver3line, newIndex); - - EList childConditions = ((SelectionStatement) context.getDomainObject()).getGuards(); - Condition childCondition = childConditions.get(newIndex); - - Shape shapeTextCond = Graphiti.getPeCreateService() - .createShape((ContainerShape) context.getPictogramElement(), true); - MultiText conditionNameText = Graphiti.getGaService().createMultiText(shapeTextCond, - childCondition.getName()); - setId(conditionNameText, ID_CONDITION_TEXT); - setIndex(conditionNameText, newIndex); - conditionNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - conditionNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeTextCond, childCondition); - } - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - if (checkIsProven(statement)) { - statement.setProven(true); - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - updateParent(statement); -<<<<<<< HEAD - } else { - statement.setProven(false); -======= - } else if (statement.isTested()) { - statement.setTested(true); - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - updateParent(statement); - } else { - statement.setProven(false); - statement.setTested(false); ->>>>>>> master - rectangle.setForeground(manageColor(IColorConstant.RED)); - updateParent(statement); - } - - // TODO: update parent may be redundant here - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - - updateParent(statement); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - SelectionStatement domainObject = (SelectionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject)) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } - - private boolean checkIsProven(SelectionStatement statement) { - boolean isProven = statement.isPreProve(); - for (AbstractStatement childStatement : statement.getCommands()) { - AbstractStatement statementToCheck = null; - if (childStatement.getRefinement() != null) { - statementToCheck = childStatement.getRefinement(); - } else { - statementToCheck = childStatement; - } - if (!statementToCheck.isProven()) { - isProven = false; - } - } - return isProven; - - } - - private void updateParent(AbstractStatement statement) { - if (statement.getParent() != null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = { statement.getParent() }; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) - updatePictogramElement(pElement.getContainer()); - } - } - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SkipStatementPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SkipStatementPattern.java.orig deleted file mode 100644 index 30f74da64..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SkipStatementPattern.java.orig +++ /dev/null @@ -1,476 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.SkipStatement; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class SkipStatementPattern extends IdPattern implements IPattern { - - private static final String ID_NAME_TEXT = "statementNameText"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; -<<<<<<< HEAD - private static final String ID_PRE_TEXT = "preNameText"; - private static final String ID_POST_TEXT = "postNameText"; -======= - private static final String ID_PRE_TEXT = "preText"; - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - //lines: - private static final String ID_SEP_LEFT = "sepLeft"; - private static final String ID_SEP_RIGHT = "sepRight"; - private static final String ID_SEP_HEADER1 = "sepHeader1"; - private static final String ID_SEP_HEADER2 = "sepHeader"; -<<<<<<< HEAD -======= - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; ->>>>>>> master - - - /** - * Constructor of the class - */ - public SkipStatementPattern() { - super(); - } - - @Override - public String getCreateName() { - return "SkipStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a SkipStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof SkipStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - SkipStatement statement = CbcmodelFactory.eINSTANCE.createSkipStatement(); - statement.setName(";"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - SkipStatement addedStatement = (SkipStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 200 : context.getHeight(); ->>>>>>> master - - //Font for the Header: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, false); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setValue("Skip"); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setFont(headerFont); - - Shape preShape = peCreateService.createShape(outerContainerShape, false); -<<<<<<< HEAD - MultiText preNameText = gaService.createMultiText(preShape, "{" + addedStatement.getPreCondition().getName() + "}"); -======= - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); ->>>>>>> master - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape postShape = peCreateService.createShape(outerContainerShape, false); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - //Header: - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - //lines: - Shape leftSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline polylineLeft = gaService.createPolyline(leftSepShape); - setId(polylineLeft, ID_SEP_LEFT); - - Shape rightSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline polylineRight = gaService.createPolyline(rightSepShape); - setId(polylineRight, ID_SEP_RIGHT); - - Shape header1SepShape = peCreateService.createShape(outerContainerShape, false); - Polyline header1line = gaService.createPolyline(header1SepShape); - setId(header1line, ID_SEP_HEADER1); - - Shape header2SepShape = peCreateService.createShape(outerContainerShape, false); - Polyline header2line = gaService.createPolyline(header2SepShape); - setId(header2line, ID_SEP_HEADER2); -<<<<<<< HEAD -======= - - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); ->>>>>>> master - - peCreateService.createChopboxAnchor(outerContainerShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); -<<<<<<< HEAD - link(postShape, addedStatement.getPostCondition()); -======= - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int halfWidth = mainRectangle.getWidth() / 2; - //stable sizes from Name and Header save space when the diagram gets big! -<<<<<<< HEAD - int sizeName = 30; //size from Name block - int sizeHeader = 20; //size from the Header - int positionHeader = 40; //position where the Header is - int sizeText = mainRectangle.getHeight() - positionHeader - sizeName; //size from the blocks (pre, statement, post) - int positionText = positionHeader + sizeName; //position from the blocks (pre, statement, post) -======= - int sizeName = 40; //size from Name block - int sizeHeader = 20; //size from the Header - int positionHeader = 40; //position where the Header is - int positionText = positionHeader + sizeHeader; //position from the blocks (pre, statement, post) - int thirdBlockHeight = (mainRectangle.getHeight()-positionHeader-sizeHeader)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), sizeName); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText, halfWidth, sizeText); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionText, halfWidth, sizeText); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText+thirdBlockHeight, halfWidth, thirdBlockHeight*2); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionText, halfWidth, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionText+thirdBlockHeight, halfWidth, thirdBlockHeight*2); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionText, halfWidth, thirdBlockHeight); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionHeader, halfWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, halfWidth, positionHeader, halfWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_SEP_HEADER1)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionHeader, mainRectangle.getWidth(), positionHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_SEP_HEADER2)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionHeader + sizeHeader, mainRectangle.getWidth(), positionHeader + sizeHeader }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_SEP_LEFT)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { halfWidth, positionHeader, halfWidth, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD -======= - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionText+thirdBlockHeight, halfWidth, positionText+thirdBlockHeight }); - polyline.getPoints().addAll(pointList); - changesDone = true; ->>>>>>> master - } else if (id.equals(ID_SEP_RIGHT)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { halfWidth * 2, positionHeader, halfWidth * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD - } -======= - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { halfWidth, positionText+thirdBlockHeight, mainRectangle.getWidth(), positionText+thirdBlockHeight }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } ->>>>>>> master - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!domainObject.isProven() && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } ->>>>>>> master - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven()) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } -<<<<<<< HEAD -======= - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } ->>>>>>> master - } else { - rectangle.setForeground(manageColor(IColorConstant.RED)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven()) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } -} diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SmallRepetitionPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SmallRepetitionPattern.java.orig deleted file mode 100644 index 833dae09d..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/SmallRepetitionPattern.java.orig +++ /dev/null @@ -1,650 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.SmallRepetitionStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.Variant; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class SmallRepetitionPattern extends IdPattern implements IPattern { - - private static final String ID_STATEMENT_TEXT = "statementRepNameText"; - private static final String ID_CONDITION_TEXT = "conditionRepText"; - private static final String ID_VARIANT_TEXT = "variantRepText"; - private static final String ID_INVARIANT_TEXT = "invariantRepText"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_NAME_TEXT = "nameText"; - private static final String ID_PRE_TEXT = "preNameText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postNameText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postNameText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Headers: - private static final String ID_VARIANT_HEADER = "variantHeader"; - private static final String ID_INVARIANT_HEADER = "invariantHeader"; - private static final String ID_GUARD_HEADER = "guardHeader"; - private static final String ID_LOOP_HEADER = "loopHeader"; - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - //lines: - private static final String ID_HOR1_SEP = "hor1SEP"; // HOR = horizontal - private static final String ID_HOR2_SEP = "hor2SEP"; - private static final String ID_HOR3_SEP = "hor3SEP"; - private static final String ID_HOR4_SEP = "hor4SEP"; -<<<<<<< HEAD -======= - private static final String ID_HOR5_SEP = "hor5SEP"; - private static final String ID_HOR6_SEP = "hor6SEP"; ->>>>>>> master - private static final String ID_VER1_SEP = "ver1SEP"; //VER = vertical - private static final String ID_VER2_SEP = "ver2SEP"; - - - /** - * Constructor of the class - */ - public SmallRepetitionPattern() { - super(); - } - - @Override - public String getCreateName() { -<<<<<<< HEAD - return "SmallRepetitionStatement"; -======= - return "RepetitionStatement"; ->>>>>>> master - } - - @Override - public String getCreateDescription() { -<<<<<<< HEAD - return "Create a RepetitionStatement with only the loop statement."; -======= - return "Create a RepetitionStatement with the loop statement."; ->>>>>>> master - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof SmallRepetitionStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - SmallRepetitionStatement repetitionStatement = CbcmodelFactory.eINSTANCE.createSmallRepetitionStatement(); - repetitionStatement.setName("repetitionStatement"); - AbstractStatement statement = CbcmodelFactory.eINSTANCE.createAbstractStatement(); - statement.setName("loop"); - repetitionStatement.setLoopStatement(statement); - Condition condition = CbcmodelFactory.eINSTANCE.createCondition(); - condition.setName("guard"); - repetitionStatement.setGuard(condition); - Condition invariant = CbcmodelFactory.eINSTANCE.createCondition(); - invariant.setName("invariant"); - repetitionStatement.setInvariant(invariant); - Variant variant = CbcmodelFactory.eINSTANCE.createVariant(); - variant.setName("variant"); - repetitionStatement.setVariant(variant); - - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - Condition preRep = CbcmodelFactory.eINSTANCE.createCondition(); - preRep.setName(""); - repetitionStatement.setPreCondition(preRep); - Condition postRep = CbcmodelFactory.eINSTANCE.createCondition(); - postRep.setName(""); - repetitionStatement.setPostCondition(postRep); - - addGraphicalRepresentation(context, repetitionStatement); - return new Object[] { repetitionStatement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - -<<<<<<< HEAD -manageColor(IColorConstant.DARK_GREEN); -======= - manageColor(IColorConstant.DARK_GREEN); - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - SmallRepetitionStatement addedStatement = (SmallRepetitionStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 300 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 450 : context.getWidth(); - int height = context.getHeight() <= 0 ? 350 : context.getHeight(); ->>>>>>> master - //Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShapeStatement1 = peCreateService.createShape(outerContainerShape, true); - MultiText statement1Text = gaService.createMultiText(textShapeStatement1, ""); - setId(statement1Text, ID_STATEMENT_TEXT); - statement1Text.setValue(addedStatement.getLoopStatement().getName()); - statement1Text.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statement1Text.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeCondition = peCreateService.createShape(outerContainerShape, true); - MultiText conditionText = gaService.createMultiText(textShapeCondition, ""); - setId(conditionText, ID_CONDITION_TEXT); - conditionText.setValue(addedStatement.getGuard().getName()); - conditionText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - conditionText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeInvariant = peCreateService.createShape(outerContainerShape, true); - MultiText invariantText = gaService.createMultiText(textShapeInvariant, ""); - setId(invariantText, ID_INVARIANT_TEXT); - invariantText.setValue(addedStatement.getInvariant().getName()); - invariantText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - invariantText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeVariant = peCreateService.createShape(outerContainerShape, true); - MultiText variantText = gaService.createMultiText(textShapeVariant, ""); - setId(variantText, ID_VARIANT_TEXT); - variantText.setValue(addedStatement.getVariant().getName()); - variantText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - variantText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapeName = peCreateService.createShape(outerContainerShape, false); - MultiText nameText = gaService.createMultiText(textShapeName, "RepetitionStatement DO...OD"); - setId(nameText, ID_NAME_TEXT); - nameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - nameText.setFont(headerFont); - - Shape pre1Shape = peCreateService.createShape(outerContainerShape, false); - MultiText pre1NameText = gaService.createMultiText(pre1Shape, "{" + addedStatement.getLoopStatement().getPreCondition().getName() + "}"); - setId(pre1NameText, ID_PRE_TEXT); - pre1NameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - pre1NameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - ->>>>>>> master - Shape post1Shape = peCreateService.createShape(outerContainerShape, false); - MultiText post1NameText = gaService.createMultiText(post1Shape, "{" + addedStatement.getLoopStatement().getPostCondition().getName() + "}"); - setId(post1NameText, ID_POST_TEXT); - post1NameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - post1NameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD -======= - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - ->>>>>>> master - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - //HEADER: - Shape variantHeader = peCreateService.createShape(outerContainerShape, false); - Text variantNameHeader = gaService.createText(variantHeader, "variant"); - setId(variantNameHeader, ID_VARIANT_HEADER); - variantNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - variantNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - variantNameHeader.setFont(headerFont); - - Shape invariantHeader = peCreateService.createShape(outerContainerShape, false); - Text invariantNameHeader = gaService.createText(invariantHeader, "invariant"); - setId(invariantNameHeader, ID_INVARIANT_HEADER); - invariantNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - invariantNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - invariantNameHeader.setFont(headerFont); - - Shape guardHeader = peCreateService.createShape(outerContainerShape, false); - Text guardNameHeader = gaService.createText(guardHeader, "guard"); - setId(guardNameHeader, ID_GUARD_HEADER); - guardNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - guardNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - guardNameHeader.setFont(headerFont); - - Shape loopHeader = peCreateService.createShape(outerContainerShape, false); - Text loopNameHeader = gaService.createText(loopHeader, "loop statement"); - setId(loopNameHeader, ID_LOOP_HEADER); - loopNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - loopNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - loopNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - //lines: - Shape ver1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline ver1line = gaService.createPolyline(ver1Shape); - setId(ver1line, ID_VER1_SEP); - - Shape ver2Shape = peCreateService.createShape(outerContainerShape, false); - Polyline ver2line = gaService.createPolyline(ver2Shape); - setId(ver2line, ID_VER2_SEP); - - Shape hor1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1line = gaService.createPolyline(hor1Shape); - setId(hor1line, ID_HOR1_SEP); - - Shape hor2Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2line = gaService.createPolyline(hor2Shape); - setId(hor2line, ID_HOR2_SEP); - - Shape hor3Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor3line = gaService.createPolyline(hor3Shape); - setId(hor3line, ID_HOR3_SEP); - - Shape hor4Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor4line = gaService.createPolyline(hor4Shape); - setId(hor4line, ID_HOR4_SEP); - -<<<<<<< HEAD -======= - Shape hor5Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor5line = gaService.createPolyline(hor5Shape); - setId(hor5line, ID_HOR5_SEP); - - Shape hor6Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor6line = gaService.createPolyline(hor6Shape); - setId(hor6line, ID_HOR6_SEP); - ->>>>>>> master - peCreateService.createChopboxAnchor(textShapeStatement1); - peCreateService.createChopboxAnchor(outerContainerShape); - - link(outerContainerShape, addedStatement); - link(textShapeCondition, addedStatement.getGuard()); - link(textShapeStatement1, addedStatement.getLoopStatement()); - link(textShapeVariant, addedStatement.getVariant()); - link(textShapeInvariant, addedStatement.getInvariant()); - link(pre1Shape, addedStatement.getLoopStatement().getPreCondition()); -<<<<<<< HEAD - link(post1Shape, addedStatement.getLoopStatement().getPostCondition()); -======= - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(post1Shape, addedStatement.getLoopStatement().getPostCondition()); - link(textShapePostConditionMod, addedStatement.getLoopStatement().getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int thirdWidth = mainRectangle.getWidth() / 3; -<<<<<<< HEAD - int sizeName = 60; - int sizeHeader = 20; - int sizeBlock = (mainRectangle.getHeight() - sizeName) / 2 - sizeHeader; - int positionFirstLine = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName ) + 20; // +20 for some space between Name and Header - int positionSecondLine = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName ) / 2 + 20; -======= - int sizeName = 40; - int sizeHeader = 20; - int sizeBlockUpper = ((mainRectangle.getHeight() - sizeName) / 3) - sizeHeader; - int sizeBlockLower = ((mainRectangle.getHeight() - sizeName) / 3) * 2 - sizeHeader; - int positionFirstLine = mainRectangle.getHeight() - (mainRectangle.getHeight() - sizeName ) + 20; // +20 for some space between Name and Header - int positionSecondLine = mainRectangle.getHeight() - ((mainRectangle.getHeight() - sizeName ) / 3) * 2 + 20; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), sizeName); - changesDone = true; - } else if (id.equals(ID_INVARIANT_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, positionFirstLine, thirdWidth, sizeBlock); - changesDone = true; - } else if (id.equals(ID_CONDITION_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionFirstLine, thirdWidth, sizeBlock); - changesDone = true; - } else if (id.equals(ID_VARIANT_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionFirstLine, thirdWidth, sizeBlock); - changesDone = true; - } else if (id.equals(ID_STATEMENT_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionSecondLine, thirdWidth, sizeBlock); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionSecondLine, thirdWidth, sizeBlock); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionSecondLine, thirdWidth, sizeBlock); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, positionFirstLine, thirdWidth, sizeBlockUpper); - changesDone = true; - } else if (id.equals(ID_CONDITION_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionFirstLine, thirdWidth, sizeBlockUpper); - changesDone = true; - } else if (id.equals(ID_VARIANT_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionFirstLine, thirdWidth, sizeBlockUpper); - changesDone = true; - } else if (id.equals(ID_STATEMENT_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionSecondLine, thirdWidth, sizeBlockLower); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionSecondLine + sizeBlockLower/3, thirdWidth, (sizeBlockLower/3)*2); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionSecondLine, thirdWidth, sizeBlockLower/3); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionSecondLine + sizeBlockLower/3, thirdWidth, (sizeBlockLower/3)*2); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionSecondLine, thirdWidth, sizeBlockLower/3); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - changesDone = true; - //HEADERS: - } else if (id.equals(ID_VARIANT_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionFirstLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_INVARIANT_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionFirstLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_GUARD_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionFirstLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_LOOP_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth, positionSecondLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, positionSecondLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, thirdWidth * 2, positionSecondLine - sizeHeader, thirdWidth, sizeHeader); - changesDone = true; - //lines: - } else if (id.equals(ID_HOR1_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionFirstLine, mainRectangle.getWidth(), positionFirstLine }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionFirstLine -sizeHeader, mainRectangle.getWidth(), positionFirstLine - sizeHeader}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR3_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionSecondLine - sizeHeader, mainRectangle.getWidth(), positionSecondLine - sizeHeader}); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR4_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionSecondLine, mainRectangle.getWidth(), positionSecondLine }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD -======= - } else if (id.equals(ID_HOR5_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, positionSecondLine + sizeBlockLower/3, thirdWidth, positionSecondLine + sizeBlockLower/3 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR6_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth*2, positionSecondLine + sizeBlockLower/3, mainRectangle.getWidth(), positionSecondLine + sizeBlockLower/3 }); - polyline.getPoints().addAll(pointList); - changesDone = true; ->>>>>>> master - } else if (id.equals(ID_VER1_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth, positionFirstLine - sizeHeader, thirdWidth, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_VER2_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { thirdWidth * 2, positionFirstLine - sizeHeader, thirdWidth * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_VARIANT_TEXT)) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - Variant domainObject = (Variant) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - SmallRepetitionStatement domainObject = (SmallRepetitionStatement) context.getDomainObject(); - if (checkIsProven(domainObject) && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!checkIsProven(domainObject) && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!checkIsProven(domainObject) && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) ->>>>>>> master - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } else if (id.equals(ID_IMAGE_PROVEN)) { - SmallRepetitionStatement domainObject = (SmallRepetitionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!checkIsProven(domainObject) && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_VARIANT_TEXT)) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - Variant domainObject = (Variant) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - SmallRepetitionStatement domainObject = (SmallRepetitionStatement) context.getDomainObject(); - if (checkIsProven(domainObject)) { - domainObject.setProven(true); - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - updateParent(domainObject); -<<<<<<< HEAD - } else { - domainObject.setProven(false); -======= - } else if (domainObject.isTested()) { - domainObject.setTested(true); - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - updateParent(domainObject); - } else { - domainObject.setProven(false); - domainObject.setTested(false); ->>>>>>> master - domainObject.setVariantProven(false); - rectangle.setForeground(manageColor(IColorConstant.RED)); - updateParent(domainObject); - } - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - SmallRepetitionStatement domainObject = (SmallRepetitionStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (checkIsProven(domainObject)) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - } - } - return false; - } -<<<<<<< HEAD - -======= - ->>>>>>> master - private boolean checkIsProven(SmallRepetitionStatement statement) { - AbstractStatement loopStatement = statement.getLoopStatement(); - AbstractStatement firstStatementToCheck = null; - if (loopStatement.getRefinement() != null) { - firstStatementToCheck = loopStatement.getRefinement(); - } else { - firstStatementToCheck = loopStatement; - } - if (firstStatementToCheck.isProven() && statement.isPreProven() && statement.isPostProven() && statement.isVariantProven()) { - return true; - } else { - return false; - } - } - - private void updateParent(AbstractStatement statement) { - if(statement.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {statement.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - if (obj.length > 0) { - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } - } - } -} - diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StrengthWeakStatementPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StrengthWeakStatementPattern.java.orig deleted file mode 100644 index 965473fd3..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/StrengthWeakStatementPattern.java.orig +++ /dev/null @@ -1,551 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.util.List; - -import org.eclipse.emf.ecore.EObject; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Image; -import org.eclipse.graphiti.mm.algorithms.MultiText; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.services.IPeService; -import org.eclipse.graphiti.util.ColorConstant; -import org.eclipse.graphiti.util.IColorConstant; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.StrengthWeakStatement; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCImageProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.HighlightHelper; -<<<<<<< HEAD -======= -import de.tu_bs.cs.isf.cbc.tool.features.TestStatement; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.util.CompareMethodBodies; - - -/** - * Class that creates the graphical representation of Conditions - * @author Tobias - * - */ -public class StrengthWeakStatementPattern extends IdPattern implements IPattern { - - - private static final String ID_NAME_TEXT = "statementText"; - private static final String ID_PRE_TEXT = "preText"; -<<<<<<< HEAD - private static final String ID_POST_TEXT = "postText"; -======= - private static final String ID_PRE_MOD = "preConditionModifiables"; - private static final String ID_POST_TEXT = "postText"; - private static final String ID_POST_MOD = "postConditionModifiables"; ->>>>>>> master - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - private static final String ID_IMAGE_PROVEN = "imageproven"; - //Headers: - private static final String ID_PRE_HEADER = "preHeader"; - private static final String ID_POST_HEADER = "postHeader"; - private static final String ID_NAME_HEADER = "statementHeader"; - //Separating lines: - private static final String ID_HEADER_SEPARATER = "headerSeparater"; - private static final String ID_POST_SEP = "postSep"; - private static final String ID_PRE_SEP = "preSep"; -<<<<<<< HEAD -======= - private static final String ID_HOR1_LINE = "hor1Line"; - private static final String ID_HOR2_LINE = "hor2Line"; ->>>>>>> master - - /** - * Constructor of the class - */ - public StrengthWeakStatementPattern() { - super(); - } - - @Override - public String getCreateName() { - return "StrengthWeakStatement"; - } - - @Override - public String getCreateDescription() { - return "Create a StrengthWeakStatement."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof StrengthWeakStatement; - } - - @Override - public boolean canCreate(ICreateContext context) { - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - StrengthWeakStatement statement = CbcmodelFactory.eINSTANCE.createStrengthWeakStatement(); - statement.setName("Statement"); - Condition pre = CbcmodelFactory.eINSTANCE.createCondition(); - pre.setName(""); - statement.setPreCondition(pre); - Condition post = CbcmodelFactory.eINSTANCE.createCondition(); - post.setName(""); - statement.setPostCondition(post); - - addGraphicalRepresentation(context, statement); - return new Object[] { statement }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - manageColor(IColorConstant.DARK_GREEN); -<<<<<<< HEAD -======= - manageColor(IColorConstant.LIGHT_ORANGE); ->>>>>>> master - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - StrengthWeakStatement addedStatement = (StrengthWeakStatement) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - -<<<<<<< HEAD - int width = context.getWidth() <= 0 ? 300 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); -======= - int width = context.getWidth() <= 0 ? 350 : context.getWidth(); - int height = context.getHeight() <= 0 ? 150 : context.getHeight(); ->>>>>>> master - //Font: - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - mainRectangle.setForeground(manageColor(IColorConstant.RED)); - mainRectangle.setLineWidth(2); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, - context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedStatement); - - // Statement name - Shape textShape = peCreateService.createShape(outerContainerShape, true); - MultiText statementNameText = gaService.createMultiText(textShape, ""); - setId(statementNameText, ID_NAME_TEXT); - statementNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape preShape = peCreateService.createShape(outerContainerShape, true); -<<<<<<< HEAD - MultiText preNameText = gaService.createMultiText(preShape, "{" + addedStatement.getPreCondition().getName()+ "}"); -======= - MultiText preNameText = gaService.createMultiText(preShape, - "{" + addedStatement.getPreCondition().getName() + "}"); ->>>>>>> master - setId(preNameText, ID_PRE_TEXT); - preNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - -<<<<<<< HEAD - Shape postShape = peCreateService.createShape(outerContainerShape, true); - MultiText postNameText = gaService.createMultiText(postShape, "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); -======= - Shape textShapePreConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText preConditionTextMod = gaService.createMultiText(textShapePreConditionMod, ""); - setId(preConditionTextMod, ID_PRE_MOD); - String modString = ""; - for (String s : addedStatement.getPreCondition().getModifiables()) { - modString += s + ", "; - } - preConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - preConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape postShape = peCreateService.createShape(outerContainerShape, true); - MultiText postNameText = gaService.createMultiText(postShape, - "{" + addedStatement.getPostCondition().getName() + "}"); - setId(postNameText, ID_POST_TEXT); - postNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - - Shape textShapePostConditionMod = peCreateService.createShape(outerContainerShape, true); - MultiText postConditionTextMod = gaService.createMultiText(textShapePostConditionMod, ""); - setId(postConditionTextMod, ID_POST_MOD); - modString = ""; - for (String s : addedStatement.getPostCondition().getModifiables()) { - modString += s + ", "; - } - postConditionTextMod.setValue("modifiable(" + (modString.equals("") ? "" : modString.substring(0, modString.length() - 2)) + ");"); - postConditionTextMod.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postConditionTextMod.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); ->>>>>>> master - - Shape proveShape = peCreateService.createShape(outerContainerShape, false); - Image image = gaService.createImage(proveShape, CbCImageProvider.IMG_UNPROVEN); - setId(image, ID_IMAGE_PROVEN); - - //Header:--------------- - Shape textHeader = peCreateService.createShape(outerContainerShape, false); - Text statementNameHeader = gaService.createText(textHeader, "Statement"); - setId(statementNameHeader, ID_NAME_HEADER); - statementNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - statementNameHeader.setFont(headerFont); - - Shape preHeader = peCreateService.createShape(outerContainerShape, false); - Text preNameHeader = gaService.createText(preHeader, "weakened precondition"); - setId(preNameHeader, ID_PRE_HEADER); - preNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - preNameHeader.setFont(headerFont); - - Shape postHeader = peCreateService.createShape(outerContainerShape, false); - Text postNameHeader = gaService.createText(postHeader, "strengthend postcondition"); - setId(postNameHeader, ID_POST_HEADER); - postNameHeader.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - postNameHeader.setFont(headerFont); - - //Separator: - Shape headerSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline headerPolyline = gaService.createPolyline(headerSepShape); - setId(headerPolyline, ID_HEADER_SEPARATER); - - Shape preSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline prePolyline = gaService.createPolyline(preSepShape); - setId(prePolyline, ID_PRE_SEP); - - Shape postSepShape = peCreateService.createShape(outerContainerShape, false); - Polyline postPolyline = gaService.createPolyline(postSepShape); - setId(postPolyline, ID_POST_SEP); - -<<<<<<< HEAD -======= - Shape hor1LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1Polyline = gaService.createPolyline(hor1LineShape); - setId(hor1Polyline, ID_HOR1_LINE); - - Shape hor2LineShape = peCreateService.createShape(outerContainerShape, false); - Polyline hor2Polyline = gaService.createPolyline(hor2LineShape); - setId(hor2Polyline, ID_HOR2_LINE); - ->>>>>>> master - peCreateService.createChopboxAnchor(outerContainerShape); - peCreateService.createChopboxAnchor(textShape); - - link(outerContainerShape, addedStatement); - link(textShape, addedStatement); - link(preShape, addedStatement.getPreCondition()); -<<<<<<< HEAD - link(postShape, addedStatement.getPostCondition()); -======= - link(textShapePreConditionMod, addedStatement.getPreCondition()); - link(postShape, addedStatement.getPostCondition()); - link(textShapePostConditionMod, addedStatement.getPostCondition()); ->>>>>>> master - link(proveShape, addedStatement); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int third = mainRectangle.getWidth() / 3; -<<<<<<< HEAD -======= - int thirdBlockHeight = (mainRectangle.getHeight() - 40)/3; ->>>>>>> master - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_PRE_TEXT)) { -<<<<<<< HEAD - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, mainRectangle.getHeight() - 40); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, mainRectangle.getHeight() - 40); -======= - Graphiti.getGaService().setLocationAndSize(ga, 0, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_PRE_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 40, third, thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, thirdBlockHeight+40, third, 2*thirdBlockHeight); - changesDone = true; - } else if (id.equals(ID_POST_MOD)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 40, third, thirdBlockHeight); ->>>>>>> master - changesDone = true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - //Changes start - //Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 20, 10, 10, 10); - Graphiti.getGaService().setLocationAndSize(ga, mainRectangle.getWidth() - 22, 6, 12, 12); - //Changes end - changesDone = true; - //Header: - } else if (id.equals(ID_NAME_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third, 20, third, 20); //mainrectangle anpassen - changesDone = true; - } else if (id.equals(ID_PRE_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 20, third, 20); - changesDone = true; - } else if (id.equals(ID_POST_HEADER)) { - Graphiti.getGaService().setLocationAndSize(ga, third * 2, 20, third, 20); - changesDone = true; - //LINES: - } else if (id.equals(ID_HEADER_SEPARATER)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { 0, 40, mainRectangle.getWidth(), 40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; -<<<<<<< HEAD - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService().createPointList( - new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); -======= - } else if (id.equals(ID_PRE_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third * 2, 0, third * 2, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, thirdBlockHeight+40, third, thirdBlockHeight+40 }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_POST_SEP)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { third, 0, third, mainRectangle.getHeight() }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } else if (id.equals(ID_HOR2_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 2*third, thirdBlockHeight+40, mainRectangle.getWidth(), thirdBlockHeight+40 }); ->>>>>>> master - polyline.getPoints().addAll(pointList); - changesDone = true; - } - - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof StrengthWeakStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - StrengthWeakStatement domainObject = (StrengthWeakStatement) context.getDomainObject(); - if (domainObject.getName() == null || !domainObject.getName().equals(nameText.getValue())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - if (domainObject.isProven() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); -<<<<<<< HEAD - } else if (!domainObject.isProven() && - ((rectangle.getForeground() != null && rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } -======= - } else if (!domainObject.isProven() && domainObject.isTested() && - ((rectangle.getForeground() != null && !rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is tested. Expected orange color."); - } else if (!domainObject.isProven() && !domainObject.isTested() && - ((rectangle.getForeground() != null && (rectangle.getForeground().equals(manageColor(IColorConstant.DARK_GREEN)) || rectangle.getForeground().equals(manageColor(IColorConstant.LIGHT_ORANGE)))) - || rectangle.getForeground() == null)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } ->>>>>>> master - } else if (id.equals(ID_IMAGE_PROVEN)) { - AbstractStatement domainObject = (AbstractStatement) context.getDomainObject(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_UNPROVEN)) { - return Reason.createTrueReason("Statement is proven. Expected green color."); - } else if (!domainObject.isProven() && image.getId().equals(CbCImageProvider.IMG_PROVEN)) { - return Reason.createTrueReason("Statement is not proven. Expected red color."); - } - } - if(HighlightHelper.instance.needsInitialHighlightUpdate(context)) { - return Reason.createTrueReason("Element needs to be highlighted."); - } - return Reason.createFalseReason(); - } - - @Override - protected boolean update(IdUpdateContext context, String id) { - if(context.getGraphicsAlgorithm() instanceof MultiText && context.getDomainObject() instanceof StrengthWeakStatement) { - MultiText nameText = (MultiText) context.getGraphicsAlgorithm(); - StrengthWeakStatement domainObject = (StrengthWeakStatement) context.getDomainObject(); - nameText.setValue(domainObject.getName()); - return true; - } - else if (id.equals(ID_MAIN_RECTANGLE)) { - RoundedRectangle rectangle = (RoundedRectangle) context.getGraphicsAlgorithm(); - StrengthWeakStatement domainObject = (StrengthWeakStatement) context.getDomainObject(); - AbstractStatement childStatement = domainObject.getRefinement(); - if (domainObject.isProven() && ((childStatement != null && childStatement.isProven()) || childStatement == null)) { - rectangle.setForeground(manageColor(IColorConstant.DARK_GREEN)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } -<<<<<<< HEAD -======= - } else if (domainObject.isTested()) { - rectangle.setForeground(manageColor(IColorConstant.LIGHT_ORANGE)); - if(domainObject.getParent()!= null) { - IPeService pe = Graphiti.getPeService(); - EObject[] objArray = {domainObject.getParent()}; - Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); - Shape pElement = (Shape) obj[0]; - if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); - } ->>>>>>> master - } else { -// rectangle.setForeground(manageColor(IColorConstant.RED)); -// if(domainObject.getParent()!= null) { -// IPeService pe = Graphiti.getPeService(); -// EObject[] objArray = {domainObject.getParent()}; -// Object[] obj = pe.getLinkedPictogramElements(objArray, getDiagram()); -// if (obj.length > 0) { -// Shape pElement = (Shape) obj[0]; -// if (pElement.getContainer() != null) updatePictogramElement(pElement.getContainer()); -// } -// } - rectangle.setForeground(manageColor(new ColorConstant(236, 215, 25))); - } - HighlightHelper.instance.handleHighlightDrawing(context, rectangle); - return true; - } else if (id.equals(ID_IMAGE_PROVEN)) { - StrengthWeakStatement domainObject = (StrengthWeakStatement) context.getDomainObject(); - AbstractStatement childStatement = domainObject.getRefinement(); - Image image = (Image) context.getGraphicsAlgorithm(); - if (domainObject.isProven() && ((childStatement != null && childStatement.isProven()) || childStatement == null)) { - image.setId(CbCImageProvider.IMG_PROVEN); - } else { - image.setId(CbCImageProvider.IMG_UNPROVEN); - //Changes start - image.setId(CbCImageProvider.IMG_WARNING); - //Changes end - } - } - return false; - } - - @Override - public int getEditingType() { - return TYPE_MULTILINETEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof StrengthWeakStatement && ga instanceof MultiText) { - return true; - } - return false; - } - - @Override - public String getInitialValue(IDirectEditingContext context) { - StrengthWeakStatement statement = (StrengthWeakStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - return statement.getName(); - } - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - System.out.println("value in streanghweak: "+value); - if (value == null || value.length() == 0) { - return "Statement must not be empty"; - } - if (value.contains(";") && !CompareMethodBodies.readAndTestMethodBodyWithJaMoPP2(value)) { - return "Statement has not the correct syntax."; - } - return null; - } - - @Override - public void setValue(String value, IDirectEditingContext context) { - AbstractStatement statement = (AbstractStatement) getBusinessObjectForPictogramElement(context.getPictogramElement()); - statement.setName(value); - statement.setProven(false); -<<<<<<< HEAD -======= - statement.setTested(false); ->>>>>>> master - updatePictogramElement(context.getPictogramElement()); - } -} - diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablePattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablePattern.java.orig deleted file mode 100644 index 63de5e9a8..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablePattern.java.orig +++ /dev/null @@ -1,292 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -<<<<<<< HEAD -======= -import org.eclipse.core.resources.IProject; ->>>>>>> master -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.context.IDeleteContext; -import org.eclipse.graphiti.features.context.IDirectEditingContext; -import org.eclipse.graphiti.features.context.IRemoveContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; - -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.ModelClass; -======= -import de.tu_bs.cs.isf.cbc.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariable; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import de.tu_bs.cs.isf.cbc.cbcmodel.VariableKind; -<<<<<<< HEAD -======= -import de.tu_bs.cs.isf.cbc.parser.exceptions.IFbCException; -import de.tu_bs.cs.isf.cbc.tool.helper.GetProjectUtil; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateInformationFlow; -import de.tu_bs.cs.isf.lattice.Lattice; -import de.tu_bs.cs.isf.lattice.Lattices; ->>>>>>> master - -/** - * Class that creates the graphical representation of Methods - * @author Tobias - * - */ -public class VariablePattern extends IdPattern implements IPattern { - public static final String VARIABLE_KIND_PARAMETER = "param"; - public static final String VARIABLE_KIND_RETURN = "return"; - public static final String VARIABLE_KIND_GLOBAL = "global"; - public static final String VARIABLE_KIND_GLOBAL_PARAM = "global param"; - public static final String VARIABLE_KIND_RETURNPARAM = "returnparam"; - - public static final String VARIABLE_KIND_LOCAL = "local"; - - - /** - * Constructor of the class - */ - public VariablePattern() { - super(); - } - - @Override - public String getCreateName() { - return "Variable"; - } - - @Override - public String getCreateDescription() { - return "Create a variable."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof JavaVariable; - } - - @Override - public boolean canCreate(ICreateContext context) { - return getBusinessObjectForPictogramElement(context.getTargetContainer()) instanceof JavaVariables; - } - - @Override - public Object[] create(ICreateContext context) { - JavaVariables variables = (JavaVariables) getBusinessObjectForPictogramElement(context.getTargetContainer()); - JavaVariable variable = CbcmodelFactory.eINSTANCE.createJavaVariable(); - variable.setKind(VariableKind.LOCAL); -<<<<<<< HEAD - variable.setName("int a"); -======= - variable.setName("int a_" + variables.getVariables().size()); ->>>>>>> master - variables.getVariables().add(variable); - updatePictogramElement(context.getTargetContainer()); - return new Object[] { variable }; - } - - @Override - public boolean canAdd(IAddContext context) { - return false; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - return null; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - return false; - } - - public boolean canUpdate(IdUpdateContext context) { - Object bo = getBusinessObjectForPictogramElement(context.getPictogramElement()); - return (bo instanceof JavaVariable); - } - - public IReason updateNeeded(IdUpdateContext context, String id) { - Text nameText = (Text) context.getPictogramElement().getGraphicsAlgorithm(); - JavaVariable domainObject = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (domainObject.getName() == null || !nameText.getValue().equals(domainObject.getDisplayedName())) { - return Reason.createTrueReason("Name differs. Expected: '" + domainObject.getName() + "'"); - } - return Reason.createFalseReason(); - } - - public boolean update(IdUpdateContext context, String id) { - Text nameText = (Text) context.getPictogramElement().getGraphicsAlgorithm(); - JavaVariable domainObject = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - nameText.setValue(domainObject.getDisplayedName()); - return true; - } - - @Override - public int getEditingType() { - return TYPE_TEXT; - } - - @Override - public boolean canDirectEdit(IDirectEditingContext context) { - Object domainObject = getBusinessObjectForPictogramElement(context.getPictogramElement()); - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - if (domainObject instanceof JavaVariable && ga instanceof Text) { - if (((Text) ga).getValue().contains(VARIABLE_KIND_LOCAL.toUpperCase())) return true; - } - return false; - } - - - @Override - public String getInitialValue(IDirectEditingContext context) { - JavaVariable variable = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - return variable.getDisplayedName(); - } - - - @Override - public String checkValueValid(String value, IDirectEditingContext context) { - if (value == null || value.length() == 0) { - return "Variable must not be empty"; - } - - - else if (value.length() > 0 && !value.toLowerCase().matches( - "("+VARIABLE_KIND_PARAMETER + "\\s"+"|"+VARIABLE_KIND_GLOBAL_PARAM + "\\s" + "|"+ VARIABLE_KIND_LOCAL + "\\s" + "|" + VARIABLE_KIND_RETURNPARAM + "\\s"+"|"+VARIABLE_KIND_RETURN+ "\\s"+"|"+VARIABLE_KIND_GLOBAL + "\\s"+ "(static\\s)?" - +")?(int|char|float|long|boolean|byte|short|double|([A-Za-z]\\w*))(\\[\\])?\\s[a-zA-Z]\\w*")) { - return "Variable must contain a kind, a type and a name"; - } - return null; - } - - @Override - public void setValue(String value, IDirectEditingContext context) { - JavaVariable variable = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if(value.trim().length() - value.trim().replaceAll(" ","").length() == 1 /*|| !value.contains("static")*/) { - variable.setKind(VariableKind.LOCAL); - variable.setName(value); -<<<<<<< HEAD - }else { -======= - } else { ->>>>>>> master - if(value.toLowerCase().contains("global param")) { - variable.setKind(VariableKind.GLOBAL_PARAM); - value = value.toLowerCase(); - variable.setName(value.replaceFirst("global param ", "")); - } else { - variable.setKind(translateIntoVariableKind(value.substring(0, value.indexOf(" ")))); - variable.setName(value.substring(value.indexOf(" ")+1)); - } - - } -<<<<<<< HEAD -======= - - //Start of IFbC - final IProject project = GetProjectUtil.getProjectForDiagram(getDiagram()); - final Lattice lattice = Lattices.getLatticeForProject(project); - if (lattice != null) { - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof CbCFormula) { - CbCFormula formula = (CbCFormula) obj; - try { - UpdateInformationFlow.updateInformationFlow(project.getName(), formula.getStatement(), lattice); - } catch (IFbCException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - } - } - ->>>>>>> master - updatePictogramElement(((Shape) context.getPictogramElement())); - } - - private VariableKind translateIntoVariableKind(String kindString) { - VariableKind kind = VariableKind.LOCAL; - kindString = kindString.toLowerCase(); - switch(kindString) { - case VARIABLE_KIND_PARAMETER: - kind = VariableKind.PARAM; - break; - case VARIABLE_KIND_RETURN: - kind = VariableKind.RETURN; - break; - case VARIABLE_KIND_GLOBAL: - kind = VariableKind.GLOBAL; - break; -// case VARIABLE_KIND_GLOBAL_PARAM: -// kind = VariableKind.GLOBAL_PARAM; -// break; - case VARIABLE_KIND_RETURNPARAM: - kind = VariableKind.RETURNPARAM; - break; - } - return kind; - } - - @Override - public boolean canDelete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - Text text = (Text) shape.getGraphicsAlgorithm(); - JavaVariable jv = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (text.getValue().trim().endsWith("inherited")) { - return false; - } - if (!(jv.eContainer() instanceof ModelClass) && (text.getValue().trim().startsWith("PUBLIC") || text.getValue().trim().startsWith("RETURN") || text.getValue().trim().startsWith("PARAM"))) { - return false; - } - return true; - } - - @Override - public boolean canRemove(IRemoveContext context) { - Shape shape = (Shape) context.getPictogramElement(); - Text text = (Text) shape.getGraphicsAlgorithm(); - JavaVariable jv = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (text.getValue().trim().endsWith("inherited")) { - return false; - } - if (!(jv.eContainer() instanceof ModelClass) && (text.getValue().trim().startsWith("PUBLIC") || text.getValue().trim().startsWith("RETURN") || text.getValue().trim().startsWith("PARAM"))) { - return false; - } - return true; - } - - @Override - public void delete(IDeleteContext context) { - Shape shape = (Shape) context.getPictogramElement(); - ContainerShape container = shape.getContainer(); - - JavaVariable variable = (JavaVariable) getBusinessObjectForPictogramElement(context.getPictogramElement()); - if (variable.eContainer() != null && variable.eContainer() instanceof JavaVariables) { - - int indexToDelete = getIndex(shape.getGraphicsAlgorithm()); - - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) > indexToDelete) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) - 1); - } - } - super.delete(context); - layoutPictogramElement(container); - } - } - -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablesPattern.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablesPattern.java.orig deleted file mode 100644 index 14905103d..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/patterns/VariablesPattern.java.orig +++ /dev/null @@ -1,473 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.patterns; - -import java.io.IOException; -import java.util.ArrayList; -import java.util.List; - -import org.eclipse.core.runtime.CoreException; -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.emf.ecore.util.EcoreUtil; -import org.eclipse.graphiti.features.IReason; -import org.eclipse.graphiti.features.context.IAddContext; -import org.eclipse.graphiti.features.context.ICreateContext; -import org.eclipse.graphiti.features.impl.Reason; -import org.eclipse.graphiti.mm.algorithms.GraphicsAlgorithm; -import org.eclipse.graphiti.mm.algorithms.Polyline; -import org.eclipse.graphiti.mm.algorithms.RoundedRectangle; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.styles.Font; -import org.eclipse.graphiti.mm.algorithms.styles.Orientation; -import org.eclipse.graphiti.mm.algorithms.styles.Point; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.pattern.IPattern; -import org.eclipse.graphiti.pattern.id.IdLayoutContext; -import org.eclipse.graphiti.pattern.id.IdPattern; -import org.eclipse.graphiti.pattern.id.IdUpdateContext; -import org.eclipse.graphiti.services.Graphiti; -import org.eclipse.graphiti.services.IGaService; -import org.eclipse.graphiti.services.IPeCreateService; -import org.eclipse.graphiti.util.PredefinedColoredAreas; - -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Field; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Parameter; -======= -import de.tu_bs.cs.isf.cbc.cbcclass.Field; -import de.tu_bs.cs.isf.cbc.cbcclass.Method; -import de.tu_bs.cs.isf.cbc.cbcclass.ModelClass; -import de.tu_bs.cs.isf.cbc.cbcclass.Parameter; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelFactory; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbcmodelPackage; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariable; -import de.tu_bs.cs.isf.cbc.cbcmodel.JavaVariables; -import de.tu_bs.cs.isf.cbc.cbcmodel.VariableKind; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.CbCFormulaImpl; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.tool.model.CbcModelUtil; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -import helper.ClassUtil; -======= -import de.tu_bs.cs.isf.cbc.util.CbcModelUtil; -import de.tu_bs.cs.isf.cbc.util.ClassUtil; -import de.tu_bs.cs.isf.cbc.util.DiagramPartsExtractor; -import de.tu_bs.cs.isf.cbc.util.FeatureUtil; -import de.tu_bs.cs.isf.cbc.util.FileUtil; ->>>>>>> master - -/** - * Class that creates the graphical representation of Methods - * - * @author Tobias - * - */ -public class VariablesPattern extends IdPattern implements IPattern { - - private static final String ID_NAME_TEXT = "variablesName"; - private static final String ID_VARIABLE_TEXT = "variable"; - private static final String ID_MAIN_RECTANGLE = "mainRectangle"; - // lines: - private static final String ID_HOR1_LINE = "hor1Line"; - - /** - * Constructor of the class - */ - public VariablesPattern() { - super(); - } - - @Override - public String getCreateName() { - return "Variables"; - } - - @Override - public String getCreateDescription() { - return "Create a list of variables."; - } - - @Override - public boolean isMainBusinessObjectApplicable(Object mainBusinessObject) { - return mainBusinessObject instanceof JavaVariables; - } - - @Override - public boolean canCreate(ICreateContext context) { -<<<<<<< HEAD - JavaVariables vars = null; - for (Shape shape : getDiagram().getChildren()) { - Object obj = getBusinessObjectForPictogramElement(shape); - if (obj instanceof JavaVariables) { - vars = (JavaVariables) obj; - } - } -======= - DiagramPartsExtractor extractor = new DiagramPartsExtractor(getDiagram()); - JavaVariables vars = extractor.getVars(); ->>>>>>> master - if (vars != null) - return false; - return context.getTargetContainer() instanceof Diagram; - } - - @Override - public Object[] create(ICreateContext context) { - JavaVariables variables = CbcmodelFactory.eINSTANCE.createJavaVariables(); - JavaVariable variable = CbcmodelFactory.eINSTANCE.createJavaVariable(); - variable.setName("int a"); - variable.setKind(VariableKind.LOCAL); - variables.getVariables().add(variable); - - try { - Resource resource = CbcModelUtil.getResource(getDiagram()); - for(EObject c:resource.getContents()){ - if(c instanceof CbCFormulaImpl) { - CbCFormula formula = (CbCFormula) c; - if(formula.getMethodObj()!= null) { - EList fields = formula.getMethodObj().getParentClass().getFields(); - variables.eSet(CbcmodelPackage.eINSTANCE.getJavaVariables_Fields(), fields); - } - } - } - CbcModelUtil.saveVariablesToModelFile(variables, getDiagram()); - } catch (CoreException | IOException e) { - e.printStackTrace(); - } - - addGraphicalRepresentation(context, variables); - return new Object[] { variables }; - } - - @Override - public boolean canAdd(IAddContext context) { - return super.canAdd(context) && context.getTargetContainer() instanceof Diagram; - } - - @Override - public PictogramElement doAdd(IAddContext context) { - Diagram targetDiagram = (Diagram) context.getTargetContainer(); - JavaVariables addedVariables = (JavaVariables) context.getNewObject(); - IPeCreateService peCreateService = Graphiti.getPeCreateService(); - IGaService gaService = Graphiti.getGaService(); - - int width = context.getWidth() <= 0 ? 200 : context.getWidth(); - int height = context.getHeight() <= 0 ? 100 : context.getHeight(); - - Font headerFont = gaService.manageFont(getDiagram(), "Arial", 9, false, true); - - // Main contents area - ContainerShape outerContainerShape = peCreateService.createContainerShape(targetDiagram, true); - RoundedRectangle mainRectangle = gaService.createRoundedRectangle(outerContainerShape, 20, 20); - mainRectangle.setFilled(true); - gaService.setRenderingStyle(mainRectangle, PredefinedColoredAreas.getBlueWhiteAdaptions()); - setId(mainRectangle, ID_MAIN_RECTANGLE); - gaService.setLocationAndSize(mainRectangle, context.getX(), context.getY(), width, height); - - // create link and wire it - link(outerContainerShape, addedVariables); - - // method name - Shape nameTextShape = peCreateService.createShape(outerContainerShape, false); - Text variablesNameText = gaService.createText(nameTextShape, "Variables"); - setId(variablesNameText, ID_NAME_TEXT); - variablesNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - variablesNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - variablesNameText.setFont(headerFont); - - // line: - Shape hor1Shape = peCreateService.createShape(outerContainerShape, false); - Polyline hor1line = gaService.createPolyline(hor1Shape); - setId(hor1line, ID_HOR1_LINE); - - link(outerContainerShape, addedVariables); - link(nameTextShape, addedVariables); - - return outerContainerShape; - } - - @Override - protected boolean layout(IdLayoutContext context, String id) { - boolean changesDone = false; - GraphicsAlgorithm mainRectangle = context.getRootPictogramElement().getGraphicsAlgorithm(); - JavaVariables variables = (JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement()); - EList inheritedFields = null; - if (getDiagram().eResource().getURI().isPlatform()) { -<<<<<<< HEAD - String featureName = ((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI().segment(((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI().segmentCount() - 3); - String className = ((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI().segment(((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI().segmentCount() - 2); - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null &&((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { -======= - String featureName = FeatureUtil.getInstance().getCallingFeature(((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI()); - String className = FeatureUtil.getInstance().getCallingClass(((JavaVariables) getBusinessObjectForPictogramElement(context.getRootPictogramElement())).eResource().getURI()); - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null && classResource.getContents().size() > 0 && ((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { ->>>>>>> master - inheritedFields = ((ModelClass) classResource.getContents().get(0)).getInheritsFrom().getFields(); - } - } - int size = variables.getVariables().size() + (variables.getFields() != null ? variables.getFields().size() : 0) + (inheritedFields != null ? inheritedFields.size() : 0) + (variables.getParams() != null ? variables.getParams().size() : 0) ; - GraphicsAlgorithm ga = context.getGraphicsAlgorithm(); - int height = mainRectangle.getHeight(); - if (size >= 1) { - height = height / (size + 1); - } - - if (id.equals(ID_NAME_TEXT)) { - Graphiti.getGaService().setLocationAndSize(ga, 0, 0, mainRectangle.getWidth(), height); - changesDone = true; - } else if (id.equals(ID_VARIABLE_TEXT)) { - int index = getIndex(context.getGraphicsAlgorithm()); - Graphiti.getGaService().setLocationAndSize(ga, 0, height * (index + 1), mainRectangle.getWidth(), height); - changesDone = true; - } else if (id.equals(ID_HOR1_LINE)) { - Polyline polyline = (Polyline) ga; - polyline.getPoints().clear(); - List pointList = Graphiti.getGaService() - .createPointList(new int[] { 0, height, mainRectangle.getWidth(), height }); - polyline.getPoints().addAll(pointList); - changesDone = true; - } - return changesDone; - } - - @Override - protected IReason updateNeeded(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - ContainerShape containerShape = (ContainerShape) context.getPictogramElement(); - EList variables = ((JavaVariables) context.getDomainObject()).getVariables(); - EList fields = ((JavaVariables) context.getDomainObject()).getFields(); - EList params = ((JavaVariables) context.getDomainObject()).getParams(); - EList inheritedFields = null; -<<<<<<< HEAD - String className = ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 2); - String featureName = ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 4).equals("features") ? ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 3) : ""; - String methodName = getDiagram().eResource().getURI().trimFileExtension().segment(getDiagram().eResource().getURI().segmentCount()-1); - if (getDiagram().eResource().getURI().isPlatform()) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null && ((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { -======= - String className = FeatureUtil.getInstance().getCallingClass(((JavaVariables) context.getDomainObject()).eResource().getURI()); - String featureName = FeatureUtil.getInstance().getCallingFeature(((JavaVariables) context.getDomainObject()).eResource().getURI()); - String methodName = getDiagram().eResource().getURI().trimFileExtension().segment(getDiagram().eResource().getURI().segmentCount()-1); - if (getDiagram().eResource().getURI().isPlatform()) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null && classResource.getContents().size() > 0 && ((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { ->>>>>>> master - inheritedFields = ((ModelClass) classResource.getContents().get(0)).getInheritsFrom().getFields(); - } - } - // in some cases getFields/getParams do not return fields/params; backup via modelclass - if (fields.size() == 0 || params.size() == 0) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); -<<<<<<< HEAD - if (classResource != null && classResource.getContents().get(0) instanceof ModelClass) { - ModelClass mc = (ModelClass) classResource.getContents().get(0); - fields = mc.getFields(); - for (de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method m : mc.getMethods()) { -======= - if (classResource != null && classResource.getContents().size() > 0 && classResource.getContents().get(0) instanceof ModelClass) { - ModelClass mc = (ModelClass) classResource.getContents().get(0); - fields = mc.getFields(); - for (Method m : mc.getMethods()) { ->>>>>>> master - if (m.getName().equals(methodName)) { - params = m.getParameters(); - break; - } - } - } - } - - int size = variables.size() + fields.size() + params.size() + (inheritedFields != null ? inheritedFields.size() : 0); - if (containerShape.getChildren().size() - 2 != size) { - return Reason.createTrueReason("Number of Variables differ. Expected: " + size + " Actual: " + (containerShape.getChildren().size() - 2)); - } - - List found = new ArrayList(); - EList shapes = containerShape.getChildren(); - for (int i = 2; i < shapes.size(); i++) { - Shape shape = shapes.get(i); - EList objects = shape.eContents(); - for (int j = 0; j < objects.size(); j++) { - EObject obj = objects.get(j); - if (obj instanceof Text) { - for (int k = 0; k < fields.size(); k++) { - Field f = fields.get(k); - if (f.getDisplayedName().equalsIgnoreCase(((Text) obj).getValue())) { - found.add(k); - break; - } - } - if (inheritedFields != null) { - for (int k = 0; k < inheritedFields.size(); k++) { - Field f = inheritedFields.get(k); - if (f.getDisplayedName().equalsIgnoreCase(((Text) obj).getValue().replace(" inherited",""))) { - found.add(k + fields.size()); - break; - } - } - } - for (int k = 0; k < params.size(); k++) { - Parameter p = params.get(k); - if ((("PARAM " + p.getType() + " " + p.getName()).equalsIgnoreCase(((Text) obj).getValue()) || ("RETURN " + p.getType() + " " + p.getName()).equalsIgnoreCase(((Text) obj).getValue()))) { - found.add(k + fields.size() + (inheritedFields != null ? inheritedFields.size() : 0)); - break; - } - } - break; - } - } - } - if (found.size() != (fields.size() + params.size() + (inheritedFields != null ? inheritedFields.size() : 0))) { - return Reason.createTrueReason("Class fields differ from ModelClass."); - } - } - updateGraphicsAlgorithmChildren(context.getGraphicsAlgorithm(), context); - return Reason.createFalseReason(); - } - - @Override - public boolean update(IdUpdateContext context, String id) { - if (id.equals(ID_MAIN_RECTANGLE)) { - EList variables = ((JavaVariables) context.getDomainObject()).getVariables(); - EList fields = ((JavaVariables) context.getDomainObject()).getFields(); - EList params = ((JavaVariables) context.getDomainObject()).getParams(); - EList inheritedFields = null; -<<<<<<< HEAD - String className = ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 2); - String featureName = ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 4).equals("features") ? ((JavaVariables) context.getDomainObject()).eResource().getURI().segment(((JavaVariables) context.getDomainObject()).eResource().getURI().segmentCount() - 3) : ""; - String methodName = getDiagram().eResource().getURI().trimFileExtension().segment(getDiagram().eResource().getURI().segmentCount()-1); - if (getDiagram().eResource().getURI().isPlatform()) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null &&((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { -======= - String className = FeatureUtil.getInstance().getCallingClass(((JavaVariables) context.getDomainObject()).eResource().getURI()); - String featureName = FeatureUtil.getInstance().getCallingFeature(((JavaVariables) context.getDomainObject()).eResource().getURI()); - String methodName = getDiagram().eResource().getURI().trimFileExtension().segment(getDiagram().eResource().getURI().segmentCount()-1); - if (getDiagram().eResource().getURI().isPlatform()) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); - if (classResource != null && classResource.getContents().size() > 0 && ((ModelClass) classResource.getContents().get(0)).getInheritsFrom() != null) { ->>>>>>> master - inheritedFields = ((ModelClass) classResource.getContents().get(0)).getInheritsFrom().getFields(); - } - } - - // in some cases getFields/getParams do not return fields/params; backup via modelclass - if (fields.size() == 0 || params.size() == 0) { - Resource classResource = ClassUtil.getClassModelResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI().trimFileExtension().appendFileExtension("cbcmodel")), className, featureName); -<<<<<<< HEAD - if (classResource != null && classResource.getContents().get(0) instanceof ModelClass) { - ModelClass mc = (ModelClass) classResource.getContents().get(0); - fields = mc.getFields(); - for (de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method m : mc.getMethods()) { -======= - if (classResource != null && classResource.getContents().size() > 0 && classResource.getContents().get(0) instanceof ModelClass) { - ModelClass mc = (ModelClass) classResource.getContents().get(0); - fields = mc.getFields(); - for (Method m : mc.getMethods()) { ->>>>>>> master - if (m.getName().equals(methodName)) { - params = m.getParameters(); - break; - } - } - } - } - - List checkedShapes = new ArrayList<>(); - checkedShapes.add(0); - checkedShapes.add(1); - - for (int i = 0; i < params.size() + variables.size() + fields.size() + (inheritedFields != null ? inheritedFields.size() : 0); i++) { - Parameter param = null; - JavaVariable var = null; - Field field = null; - String name = ""; - if (i < params.size()) { - param = params.get(i); - param.eResource(); - if (!param.getName().equals("ret")) { - name = "PARAM " + param.getType() + " " + param.getName(); - } else { - name = "RETURN " + param.getType() + " " + param.getName(); - } - } else if (i < variables.size() + params.size()) { - var = variables.get(i - params.size()); - name = var.getDisplayedName(); - } else if (i < fields.size() + variables.size() + params.size()) { - field = fields.get(i - params.size() - variables.size()); - name = field.getDisplayedName(); - } else { - field = inheritedFields.get(i - params.size() - variables.size() - fields.size()); - name = field.getDisplayedName(); - } - EList shapes = ((ContainerShape) context.getPictogramElement()).getChildren(); - boolean check = false; - for (int j = 2; j < shapes.size(); j++) { - Shape shape = shapes.get(j); - Text text = (Text) shape.getGraphicsAlgorithm(); - if (name.equals(text.getValue().replace(" inherited", ""))) { - check = true; - checkedShapes.add(j); - break; - } - } - if (!check) { - int newIndex = 0; - ContainerShape container = (ContainerShape) context.getPictogramElement(); - for (Shape childShape : container.getChildren()) { - if (getIndex(childShape.getGraphicsAlgorithm()) >= newIndex) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) + 1); - } - } - Shape shapeText = Graphiti.getPeCreateService().createShape((ContainerShape) context.getPictogramElement(), true); - Text variableNameText = Graphiti.getGaService().createText(shapeText, (name + (i < (params.size() + variables.size() + fields.size()) ? "" : " inherited"))); - setId(variableNameText, ID_VARIABLE_TEXT); - setIndex(variableNameText, newIndex); - variableNameText.setHorizontalAlignment(Orientation.ALIGNMENT_CENTER); - variableNameText.setVerticalAlignment(Orientation.ALIGNMENT_CENTER); - link(shapeText, (param != null ? param : (var != null ? var : field))); - checkedShapes.add(shapes.size()-1); - } - } - - //delete shapes that didn't match any param, field or variable - EList shapes = ((ContainerShape) context.getPictogramElement()).getChildren(); - for (int i = 2; i < shapes.size(); i++) { - if (!checkedShapes.contains(i)) { - Shape shape = shapes.get(i); - int indexToDelete = getIndex(shape.getGraphicsAlgorithm()); - for (Shape childShape : shapes) { - if (getIndex(childShape.getGraphicsAlgorithm()) > indexToDelete) { - setIndex(childShape.getGraphicsAlgorithm(), getIndex(childShape.getGraphicsAlgorithm()) - 1); - } - } - EcoreUtil.delete(shape.getLink()); - EcoreUtil.delete(shape); - for (int j = 0; j < checkedShapes.size(); j++) { - int oldVal = checkedShapes.get(j); - if (oldVal > i) { - int newVal = oldVal - 1; - checkedShapes.set(j, newVal); - } - } - i--; - } - } - return true; - } - return false; - } -<<<<<<< HEAD -} -======= -} ->>>>>>> master diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/BasicsSection.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/BasicsSection.java.orig deleted file mode 100644 index 8b7990c42..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/BasicsSection.java.orig +++ /dev/null @@ -1,338 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.propertiesview; - -import org.eclipse.emf.common.util.EList; -import org.eclipse.emf.ecore.EObject; -import org.eclipse.emf.transaction.RecordingCommand; -import org.eclipse.emf.transaction.TransactionalEditingDomain; -import org.eclipse.emf.transaction.util.TransactionUtil; - -import java.util.ArrayList; - -import javax.swing.JOptionPane; - -import org.eclipse.emf.ecore.resource.Resource; -import org.eclipse.graphiti.dt.IDiagramTypeProvider; -import org.eclipse.graphiti.features.context.impl.UpdateContext; -import org.eclipse.graphiti.mm.algorithms.Text; -import org.eclipse.graphiti.mm.algorithms.impl.TextImpl; -import org.eclipse.graphiti.mm.pictograms.ContainerShape; -import org.eclipse.graphiti.mm.pictograms.Diagram; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.mm.pictograms.Shape; -import org.eclipse.graphiti.mm.pictograms.impl.ContainerShapeImpl; -import org.eclipse.graphiti.ui.platform.GFPropertySection; -import org.eclipse.graphiti.ui.services.GraphitiUi; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.StyledText; -import org.eclipse.swt.events.ModifyEvent; -import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.events.SelectionListener; -import org.eclipse.swt.graphics.Color; -import org.eclipse.swt.graphics.Device; -import org.eclipse.swt.graphics.Rectangle; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Display; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.List; -import org.eclipse.swt.widgets.Listener; -import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory; - -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.Method; -import de.tu_bs.cs.isf.cbc.cbcclass.model.cbcclass.impl.MethodImpl; -======= -import de.tu_bs.cs.isf.cbc.cbcclass.Method; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.impl.CbCFormulaImpl; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCDiagramTypeProvider; - -<<<<<<< HEAD -======= -import de.tu_bs.cs.isf.cbc.util.ClassUtil; ->>>>>>> master -import de.tu_bs.cs.isf.cbc.util.Console; - -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCFeatureProvider; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -<<<<<<< HEAD -import helper.ClassUtil; -======= -import de.tu_bs.cs.isf.cbc.util.ClassUtil; ->>>>>>> master - -public class BasicsSection extends GFPropertySection implements ITabbedPropertyConstants { - - - Display display = Display.getCurrent();// for UI updating of back-process - boolean variationalProject = false; - - // Defining the UI properties - private Label classLabel; - private Label classLabelText; - - private Label invariantLabel; - private List invariantList; - - private Label methodSignatureLabel; - private StyledText methodSignatureLabelText; - private boolean methodSignatureLabelChanged = false; - - private Label featureLabel; - private Label featureLabelText; - - private Label compositionTechniqueLabel; - private Label compositionTechniqueLabelText; - - private Button saveButton; - private Object bo; - - @Override - public void createControls(Composite parent, TabbedPropertySheetPage tabbedPropertySheetPage) { - super.createControls(parent, tabbedPropertySheetPage); - Device device = Display.getCurrent(); - TabbedPropertySheetWidgetFactory factory = getWidgetFactory(); - - Composite composite = factory.createFlatFormComposite(parent); - - // Defining GridLayout for properties-view - GridLayout gridLayout = new GridLayout(); - gridLayout.numColumns = 2; - gridLayout.verticalSpacing = 20; - composite.setLayout(gridLayout); - Color white = new Color (device, 255, 255, 255); - - // featureLabel - featureLabel = new Label(composite, SWT.PUSH); - featureLabel.setBackground(white); - featureLabel.setText("Feature: "); - - // featureLabelText - featureLabelText = new Label(composite, SWT.PUSH); - featureLabelText.setBackground(white); - - // compositionTechniqueLabel - compositionTechniqueLabel = new Label(composite, SWT.PUSH); - compositionTechniqueLabel.setBackground(white); - compositionTechniqueLabel.setText("Composition technique: "); - - // compositionTechniqueLabelText - compositionTechniqueLabelText = new Label(composite, SWT.PUSH); - compositionTechniqueLabelText.setBackground(white); - - // classLabel - classLabel = new Label(composite, SWT.PUSH); - classLabel.setBackground(white); - classLabel.setText("Class: "); - - // classLabelText - classLabelText = new Label(composite, SWT.PUSH); - classLabelText.setBackground(white); - - // methodSignatureLabel - methodSignatureLabel = new Label(composite, SWT.PUSH); - methodSignatureLabel.setText("MethodSignature: "); - methodSignatureLabel.setBackground(white); - - // methodSignatureLabelText - methodSignatureLabelText = new StyledText(composite, SWT.WRAP | SWT.PUSH | SWT.BORDER); - GridData methodSignatureLabelTextGridData = new GridData(SWT.FILL, SWT.FILL, true, false); - methodSignatureLabelText.setEditable(true); - methodSignatureLabelText.setLayoutData(methodSignatureLabelTextGridData); - methodSignatureLabelText.setBackground(white); - methodSignatureLabelText.addModifyListener(new ModifyListener() { - @Override - public void modifyText(ModifyEvent e) { - methodSignatureLabelChanged = true; - saveButton.setEnabled(true); - } - }); - - // invariantLabel - invariantLabel = new Label(composite, SWT.PUSH); - invariantLabel.setText("Invariants: "); - invariantLabel.setBackground(white); - - // invariantLabelText - invariantList = new List(composite, SWT.MULTI | SWT.BORDER | SWT.V_SCROLL); - invariantList.setItems(); - int listHeight = invariantList.getItemHeight() * 5; - - Rectangle trim = invariantList.computeTrim(0, 0, 0, listHeight); - GridData invariantLabelTextGridData = new GridData(SWT.FILL, SWT.FILL, true, false); - invariantLabelTextGridData.heightHint = trim.height; - invariantList.setLayoutData(invariantLabelTextGridData); - invariantList.setBackground(white); - invariantList.addSelectionListener(new SelectionListener() { - @Override - public void widgetSelected(SelectionEvent e) { - // TODO Auto-generated method stub - } - - @Override - public void widgetDefaultSelected(SelectionEvent e) { - // TODO Auto-generated method stub - } - }); - - // generateButton - saveButton = new Button(composite, SWT.PUSH); - saveButton.setText("Save"); - saveButton.setEnabled(false); - saveButton.addListener(SWT.Selection, new Listener() { - @Override - public void handleEvent(Event e) { - TransactionalEditingDomain domain = TransactionUtil.getEditingDomain(bo); - domain.getCommandStack().execute(new RecordingCommand(domain) { - @Override - protected void doExecute() { - if(methodSignatureLabelChanged) { - String text = methodSignatureLabelText.getText(); - changeMethodSignature(text); - methodSignatureLabelChanged = false; - } - saveButton.setEnabled(false); - refresh(); - } - }); - } - }); - - } - - @Override - public void refresh() { - CbCDiagramTypeProvider diagramProvider = new CbCDiagramTypeProvider(); - PictogramElement pe = getSelectedPictogramElement(); - bo = diagramProvider.getFeatureProvider().getBusinessObjectForPictogramElement(pe); - if(bo instanceof CbCFormulaImpl) { - updateData(bo); - } - } - - public void changeMethodSignature(String newMethodSignature) { - Method methodobj = null; - if(bo instanceof CbCFormula) { - methodobj = ((CbCFormula) bo).getMethodObj(); - }else if(bo instanceof AbstractStatement) { - CbCFormula formula = getFormula((AbstractStatement)bo); - methodobj = formula.getMethodObj(); - }else { - Console.println("Click on formula!"); - } - - if(methodobj != null) { - String oldName = methodobj.getName(); - String oldSignature = methodobj.getSignature(); - methodobj.setSignature(newMethodSignature.trim()); - if (!oldName.equals(methodobj.getName())) { - methodobj.setSignature(oldSignature); - JOptionPane.showMessageDialog(null, "Can not change name of method in the this state of CorC."); - return; - } - } - getDiagramTypeProvider().getDiagramBehavior().refresh(); - - //automatic update of vp in cbcmodel - Resource diagram_Resource = ClassUtil.getCbcDiagramResource(FileUtil.getProjectLocation(getDiagram().eResource().getURI()), methodobj.getName()); - Diagram diagram = (Diagram) diagram_Resource.getContents().get(0); - ArrayList pes = new ArrayList(); - IDiagramTypeProvider dtp = GraphitiUi.getExtensionManager().createDiagramTypeProvider(diagram, "de.tu-bs.cs.isf.cbc.tool.CbCDiagramTypeProvider"); - CbCFeatureProvider featureProvider = (CbCFeatureProvider) dtp.getFeatureProvider(); - - for (int j = 0; j < diagram_Resource.getContents().get(0).eContents().size(); j++) { - if (diagram_Resource.getContents().get(0).eContents().get(j).getClass().equals(ContainerShapeImpl.class)) { - pes.add((PictogramElement) diagram_Resource.getContents().get(0).eContents().get(j)); - } - } - for (PictogramElement pe : pes) { - ContainerShape container = (ContainerShape) pe; - Shape shape = (Shape) container.getChildren().get(0); - if (shape.getGraphicsAlgorithm() instanceof TextImpl) { - Text text = (Text) container.getChildren().get(0).getGraphicsAlgorithm(); - if (text.getValue().equals("Variables")) { - UpdateContext updateContext = new UpdateContext(pe); - featureProvider.updateIfPossible(updateContext); - } - } - } - } - - public void updateData(Object bo) { - display.syncExec(new Runnable() { - @Override - public void run() { - boolean isVariational = false; - // update methodSignature, invariants, feature -<<<<<<< HEAD - if(((CbCFormulaImpl) bo).getMethodObj() instanceof MethodImpl) { -======= - if(((CbCFormulaImpl) bo).getMethodObj() instanceof Method) { ->>>>>>> master - Method methodObj = (Method) ((CbCFormulaImpl) bo).getMethodObj(); - methodSignatureLabelText.setText(methodObj.getSignature()); - classLabelText.setText(methodObj.getParentClass().getName() + (methodObj.getParentClass().getInheritsFrom() != null ? (" extends " + methodObj.getParentClass().getInheritsFrom().getName()) : "")); - EList classInvariants = methodObj.getParentClass().getClassInvariants(); - EList inheritedClassInvariants = null; - if (methodObj.getParentClass().getInheritsFrom() != null) { - inheritedClassInvariants = methodObj.getParentClass().getInheritsFrom().getClassInvariants(); - } - String[] invariants = new String[classInvariants.size() + (inheritedClassInvariants != null ? inheritedClassInvariants.size() : 0)]; - for (int i = 0; i < classInvariants.size(); i++){ - invariants[i] = classInvariants.get(i).getName(); - } - - if (inheritedClassInvariants != null) { - for (int i = classInvariants.size(); i 0 && !methodObj.getParentClass().getFeature().equals("default")) { - isVariational = true; - featureLabelText.setText(methodObj.getParentClass().getFeature()); - } - } - if (isVariational) { - // update compositionTechnique - if ((((CbCFormulaImpl) bo).getCompositionTechnique()).toString().equals("CONJUNCTIVE_CONTRACTING")) { - compositionTechniqueLabelText.setText("Conjunctive Contract Refinement"); - } else if ((((CbCFormulaImpl) bo).getCompositionTechnique()).toString() - .equals("EXPLICIT_CONTRACTING")) { - compositionTechniqueLabelText.setText("Explicit Contracting"); - } else if ((((CbCFormulaImpl) bo).getCompositionTechnique()).toString().equals("CONTRACT_OVERRIDING")) { - compositionTechniqueLabelText.setText("Contract Overriding"); - } - } else { - featureLabel.dispose(); - featureLabelText.dispose(); - compositionTechniqueLabel.dispose(); - compositionTechniqueLabelText.dispose(); - } - } - }); - } - - public CbCFormula getFormula(AbstractStatement statement) { - if (statement.getParent() != null) { - return getFormula(statement.getParent()); - } - EObject parent = statement.eContainer(); - if (parent != null && parent instanceof AbstractStatement) { - return getFormula((AbstractStatement) parent); - } else if (parent != null && parent instanceof CbCFormula) { - return (CbCFormula) parent; - } - return null; - } -} \ No newline at end of file diff --git a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/CodeReaderSection.java.orig b/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/CodeReaderSection.java.orig deleted file mode 100644 index 95e7d3e30..000000000 --- a/de.tu-bs.cs.isf.cbc.tool/src/de/tu_bs/cs/isf/cbc/tool/propertiesview/CodeReaderSection.java.orig +++ /dev/null @@ -1,384 +0,0 @@ -package de.tu_bs.cs.isf.cbc.tool.propertiesview; - -<<<<<<< HEAD -======= -import java.util.ArrayList; -import java.util.List; - ->>>>>>> master -import org.eclipse.emf.transaction.RecordingCommand; -import org.eclipse.emf.transaction.TransactionalEditingDomain; -import org.eclipse.emf.transaction.util.TransactionUtil; -import org.eclipse.graphiti.mm.pictograms.PictogramElement; -import org.eclipse.graphiti.ui.platform.GFPropertySection; -import org.eclipse.swt.SWT; -import org.eclipse.swt.custom.StyleRange; -import org.eclipse.swt.custom.StyledText; -import org.eclipse.swt.graphics.Color; -import org.eclipse.swt.graphics.Device; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Display; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Listener; -<<<<<<< HEAD -import org.eclipse.swt.widgets.List; -======= ->>>>>>> master -import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; -import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetWidgetFactory; - -import de.tu_bs.cs.isf.cbc.cbcmodel.AbstractStatement; -<<<<<<< HEAD -import de.tu_bs.cs.isf.cbc.cbcmodel.CbCFormula; -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.cbcmodel.GlobalConditions; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCDiagramTypeProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.Predicate; -import de.tu_bs.cs.isf.cbc.tool.helper.PredicateDefinition; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateConditionsOfChildren; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateContractsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateMethodCallsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateOriginalCallsToProve; -import de.tu_bs.cs.isf.cbc.util.FileUtil; -======= -import de.tu_bs.cs.isf.cbc.cbcmodel.Condition; -import de.tu_bs.cs.isf.cbc.tool.diagram.CbCDiagramTypeProvider; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateContractsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateMethodCallsToProve; -import de.tu_bs.cs.isf.cbc.tool.helper.UpdateOriginalCallsToProve; -import de.tu_bs.cs.isf.cbc.util.UpdateConditionsOfChildren; ->>>>>>> master - -/** - * Class for the Code-Reader-Tab of the Properties-View. Formats CorC-Code to - * formatted, editable code and translates it back to CorC-Diagram. - * - * @author David - */ -public class CodeReaderSection extends GFPropertySection implements ITabbedPropertyConstants { - -<<<<<<< HEAD -======= - final List