Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortarendt2012-11-26 10:39:40 -0500
committertarendt2012-11-26 10:39:40 -0500
commit9131e8feeacd798c336cb923fcf1c117f487ab21 (patch)
tree4d27a66994dfd34650b618f5b03945cfde191533
parent1422b10cfc5c49f9cf2389f94e4252c4473f8668 (diff)
downloadorg.eclipse.emf.refactor.refactoring-9131e8feeacd798c336cb923fcf1c117f487ab21.tar.gz
org.eclipse.emf.refactor.refactoring-9131e8feeacd798c336cb923fcf1c117f487ab21.tar.xz
org.eclipse.emf.refactor.refactoring-9131e8feeacd798c336cb923fcf1c117f487ab21.zip
templates changed
-rw-r--r--org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringDataManagement.javajet4
-rw-r--r--org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringGuiHandler.javajet4
-rw-r--r--org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringTest.javajet5
-rw-r--r--org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringWizard.javajet4
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/ConfigHenshin.javajet6
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringControllerHenshin.javajet72
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringDataManagementHenshin.javajet55
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringGuiHandlerHenshin.javajet38
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringInformationHenshin.javajet18
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringTestHenshin.javajet28
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardHenshin.javajet15
-rw-r--r--org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardPageHenshin.javajet48
12 files changed, 150 insertions, 147 deletions
diff --git a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringDataManagement.javajet b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringDataManagement.javajet
index 8acc39f..d79c4be 100644
--- a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringDataManagement.javajet
+++ b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringDataManagement.javajet
@@ -5,9 +5,9 @@ imports="org.eclipse.emf.refactor.refactoring.generator.core.*"%>
* <copyright>
* </copyright>
*
- * $Id: RefactoringDataManagement.javajet,v 1.2 2012/10/16 21:03:02 tarendt Exp $
+ * $Id: RefactoringDataManagement.javajet,v 1.3 2012/11/26 15:39:40 tarendt Exp $
*/
- package <%=info.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.util.List;
diff --git a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringGuiHandler.javajet b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringGuiHandler.javajet
index eea7214..f1b8d39 100644
--- a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringGuiHandler.javajet
+++ b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringGuiHandler.javajet
@@ -5,9 +5,9 @@ imports="org.eclipse.emf.refactor.refactoring.generator.core.*"%>
* <copyright>
* </copyright>
*
- * $Id: RefactoringGuiHandler.javajet,v 1.2 2012/10/16 21:03:02 tarendt Exp $
+ * $Id: RefactoringGuiHandler.javajet,v 1.3 2012/11/26 15:39:40 tarendt Exp $
*/
- package <%=info.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.util.List;
import org.eclipse.emf.ecore.EObject;
diff --git a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringTest.javajet b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringTest.javajet
index 3fcaabc..d5b3371 100644
--- a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringTest.javajet
+++ b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringTest.javajet
@@ -5,7 +5,7 @@ imports="org.eclipse.emf.refactor.refactoring.generator.core.*"%>
* <copyright>
* </copyright>
*
- * $Id: RefactoringTest.javajet,v 1.2 2012/10/16 21:03:02 tarendt Exp $
+ * $Id: RefactoringTest.javajet,v 1.3 2012/11/26 15:39:40 tarendt Exp $
*/
package <%=info.getPackageName()%>;
@@ -19,9 +19,8 @@ import java.util.Collection;
import java.util.List;
import org.eclipse.emf.refactor.refactoring.core.Refactoring;
-import <%=info.getPackageName()%>.RefactoringController;
-import <%=info.getPackageName()%>.RefactoringGuiHandler;
import org.eclipse.emf.refactor.refactoring.runtime.test.JUnitTestCaseAdapter;
+
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
diff --git a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringWizard.javajet b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringWizard.javajet
index 94e9e93..ef1c8e3 100644
--- a/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringWizard.javajet
+++ b/org.eclipse.emf.refactor.refactoring.generator/templates/RefactoringWizard.javajet
@@ -5,9 +5,9 @@ imports="org.eclipse.emf.refactor.refactoring.generator.core.*"%>
* <copyright>
* </copyright>
*
- * $Id: RefactoringWizard.javajet,v 1.2 2012/10/16 21:03:02 tarendt Exp $
+ * $Id: RefactoringWizard.javajet,v 1.3 2012/11/26 15:39:40 tarendt Exp $
*/
- package <%=info.getPackageName()%>;
+package <%=info.getPackageName()%>;
import org.eclipse.emf.refactor.refactoring.interfaces.IController;
import org.eclipse.emf.refactor.refactoring.runtime.ltk.ui.AbstractRefactoringWizard;
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/ConfigHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/ConfigHenshin.javajet
index 7058ac1..7941737 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/ConfigHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/ConfigHenshin.javajet
@@ -1,6 +1,6 @@
-<%@ jet package="org.eclipse.emf.refactor.refactoring" class="RefactoringController"
-imports="org.eclipse.emf.refactor.refactoring.generator.core.*"%>
-<%RefactoringInfo info = (RefactoringInfo) argument; %>
+<%@ jet package="org.eclipse.emf.refactor.refactoring" class="Configuration"
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
<?xml version="1.0" encoding="UTF-8"?>
<config>
<% for (ParameterInfo pi : info.getParameters()) { %>
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringControllerHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringControllerHenshin.javajet
index 04a41f6..133c222 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringControllerHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringControllerHenshin.javajet
@@ -1,23 +1,23 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringController"
-imports="org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringControllerHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringControllerHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.refactor.henshin.runtime.HenshinLtkEmfRefactoringProcessorAdapter;
-import org.eclipse.emf.refactor.henshin.runtime.HenshinRunner;
-import org.eclipse.emf.refactor.henshin.core.IHenshinController;
-import org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement;
-import org.eclipse.emf.refactor.common.core.EmfRefactoring;
+import org.eclipse.emf.refactor.refactoring.core.Refactoring;
+import org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinController;
+import org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement;
+import org.eclipse.emf.refactor.refactoring.henshin.managers.HenshinRuntimeManager;
+import org.eclipse.emf.refactor.refactoring.henshin.runtime.HenshinLtkEmfRefactoringProcessorAdapter;
import org.eclipse.ltk.core.refactoring.participants.RefactoringProcessor;
/**
@@ -27,10 +27,10 @@ import org.eclipse.ltk.core.refactoring.participants.RefactoringProcessor;
public final class RefactoringController implements IHenshinController{
/**
- * EmfRefactoring supported by the controller.
+ * Refactoring supported by the controller.
* @generated
*/
- private EmfRefactoring parent;
+ private Refactoring parent;
/**
* DataManagement object of the model refactoring.
@@ -46,12 +46,12 @@ public final class RefactoringController implements IHenshinController{
private List<EObject> selection = new ArrayList<EObject>();
/**
- * HenshinRunner that executes Henshin transformations using
+ * HenshinRuntimeManager that executes Henshin transformations using
* the Henshin interpreter.
* @generated
*/
- private HenshinRunner henshinRunner =
- new HenshinRunner(new ArrayList<EObject>(0), dataManagement);
+ private HenshinRuntimeManager henshinRuntimeManager =
+ new HenshinRuntimeManager(new ArrayList<EObject>(0), dataManagement);
/**
* Ltk RefactoringProcessor of the model refactoring.
@@ -60,32 +60,32 @@ public final class RefactoringController implements IHenshinController{
private InternalRefactoringProcessor refactoringProcessor = null;
/**
- * Gets the EmfRefactoring supported by the controller.
- * @return EmfRefactoring supported by the controller.
- * @see org.eclipse.emf.refactor.common.core.IController#getParent()
+ * Gets the Refactoring supported by the controller.
+ * @return Refactoring supported by the controller.
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IController#getParent()
* @generated
*/
@Override
- public EmfRefactoring getParent() {
+ public Refactoring getParent() {
return this.parent;
}
/**
- * Sets the EmfRefactoring supported by the controller.
- * @param emfRefactoring EmfRefactoring supported by the controller.
- * @see org.eclipse.emf.refactor.common.core.IController#
- * setParent(org.eclipse.emf.refactor.common.core.EmfRefactoring)
+ * Sets the Refactoring supported by the controller.
+ * @param refactoring Refactoring supported by the controller.
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IController#
+ * setParent(org.eclipse.emf.refactor.refactoring.core.Refactoring)
* @generated
*/
@Override
- public void setParent(EmfRefactoring emfRefactoring) {
- this.parent = emfRefactoring;
+ public void setParent(Refactoring refactoring) {
+ this.parent = refactoring;
}
/**
* Returns the DataManagement object of the model refactoring.
* @return DataManagement object of the model refactoring.
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinController#
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinController#
* getDataManagementObject()
* @generated
*/
@@ -95,23 +95,23 @@ public final class RefactoringController implements IHenshinController{
}
/**
- * Gets a HenshinRunner that executes Henshin transformations using
+ * Gets a HenshinRuntimeManager that executes Henshin transformations using
* the Henshin interpreter.
- * @return HenshinRunner that executes Henshin transformations using
+ * @return HenshinRuntimeManager that executes Henshin transformations using
* the Henshin interpreter.
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinController#
- * getHenshinRunner()
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinController#
+ * getHenshinRuntimeManager()
* @generated
*/
@Override
- public HenshinRunner getHenshinRunner() {
- return this.henshinRunner;
+ public HenshinRuntimeManager getHenshinRuntimeManager() {
+ return this.henshinRuntimeManager;
}
/**
* Returns the ltk RefactoringProcessor of the model refactoring.
* @return Ltk RefactoringProcessor of the model refactoring.
- * @see org.eclipse.emf.refactor.common.core.IController#
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IController#
* getLtkRefactoringProcessor()
* @generated
*/
@@ -123,14 +123,14 @@ public final class RefactoringController implements IHenshinController{
/**
* Sets the selected EObject (invocation context of the model refactoring).
* @param selection Invocation context of the model refactoring.
- * @see org.eclipse.emf.refactor.common.core.IController#
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IController#
* setSelection(java.util.List)
* @generated
*/
@Override
public void setSelection(List<EObject> selection) {
this.selection = selection;
- this.henshinRunner = new HenshinRunner(this.selection, this.dataManagement);
+ this.henshinRuntimeManager = new HenshinRuntimeManager(this.selection, this.dataManagement);
this.refactoringProcessor =
new InternalRefactoringProcessor(this.selection);
}
@@ -148,8 +148,8 @@ public final class RefactoringController implements IHenshinController{
*/
@Override
public void run() {
- henshinRunner = new HenshinRunner(selection, dataManagement);
- henshinRunner.run();
+ henshinRuntimeManager = new HenshinRuntimeManager(selection, dataManagement);
+ henshinRuntimeManager.run();
}
};
}
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringDataManagementHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringDataManagementHenshin.javajet
index 3347108..ddd9f4b 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringDataManagementHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringDataManagementHenshin.javajet
@@ -1,21 +1,21 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringDataManagement"
-imports="org.eclipse.emf.refactor.generator.* org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringDataManagementHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringDataManagementHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.util.List;
import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement;
-import org.eclipse.emf.refactor.henshin.core.IHenshinInformation;
-import org.eclipse.emf.refactor.runtime.DataManagementAdapter;
-import org.eclipse.emf.refactor.common.core.Port;
+import org.eclipse.emf.refactor.refactoring.core.Port;
+import org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement;
+import org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinInformation;
+import org.eclipse.emf.refactor.refactoring.runtime.DataManagementAdapter;
/**
* Class for specific data concerning a model refactoring.
@@ -26,6 +26,14 @@ public class RefactoringDataManagement extends DataManagementAdapter
private final String SELECTEDEOBJECT = "selectedEObject";
+<% if (! info.getCheckInitialFileName().isEmpty()) { %>
+ private final String INITIALFILENAME = "<%=info.getCheckInitialFileName()%>";
+<% } %>
+<% if (! info.getCheckFinalFileName().isEmpty()) { %>
+ private final String FINALFILENAME = "<%=info.getCheckFinalFileName()%>";
+<% } %>
+ private final String CHANGEFILENAME = "<%=info.getCreateChangeFileName()%>";
+
/**
* HenshinInformation object used for checking the initial
* conditions of the EMF model refactoring.
@@ -65,12 +73,12 @@ public class RefactoringDataManagement extends DataManagementAdapter
*/
private void addPorts(){
this.inPorts.add
- (new Port<<%=refactoringConfig.getSelectedEObjectClass()%>>
- (SELECTEDEOBJECT, <%=refactoringConfig.getSelectedEObjectClass()%>.class));
-<% for (ParameterConfig pc : refactoringConfig.getParameters()) { %>
+ (new Port<<%=info.getSelectedEObjectClass()%>>
+ (SELECTEDEOBJECT, <%=info.getSelectedEObjectClass()%>.class));
+<% for (ParameterInfo pi : info.getParameters()) { %>
this.inPorts.add
(new Port<String>
- ("<%=pc.getName()%>", String.class, "unspecified"));
+ ("<%=pi.getName()%>", String.class, "unspecified"));
<% } %>
}
@@ -79,20 +87,17 @@ public class RefactoringDataManagement extends DataManagementAdapter
* @generated
*/
private void addInformation() {
-<% if (! refactoringConfig.getCheckInitialFileName().isEmpty()) { %>
- this.initialConditionsInformation.
- setTransformationFileName("<%=refactoringConfig.getCheckInitialFileName()%>");
+<% if (! info.getCheckInitialFileName().isEmpty()) { %>
+ this.initialConditionsInformation.setTransformationFileName(INITIALFILENAME);
<% } %>
-<% if (! refactoringConfig.getCheckFinalFileName().isEmpty()) { %>
- this.finalConditionsInformation.
- setTransformationFileName("<%=refactoringConfig.getCheckFinalFileName()%>");
+<% if (! info.getCheckFinalFileName().isEmpty()) { %>
+ this.finalConditionsInformation.setTransformationFileName(FINALFILENAME);
<% } %>
- this.createChangeInformation.
- setTransformationFileName("<%=refactoringConfig.getCreateChangeFileName()%>");
+ this.createChangeInformation.setTransformationFileName(CHANGEFILENAME);
}
/**
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement#
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement#
* getCreateChangeHenshinInformation()
* @generated
*/
@@ -102,7 +107,7 @@ public class RefactoringDataManagement extends DataManagementAdapter
}
/**
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement#
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement#
* getFinalConditionsHenshinInformation()
* @generated
*/
@@ -112,7 +117,7 @@ public class RefactoringDataManagement extends DataManagementAdapter
}
/**
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement#
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement#
* getInitialConditionsHenshinInformation()
* @generated
*/
@@ -122,7 +127,7 @@ public class RefactoringDataManagement extends DataManagementAdapter
}
/**
- * @see org.eclipse.emf.refactor.common.core.IDataManagement#
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IDataManagement#
* preselect(java.util.List)
* @generated
*/
@@ -130,7 +135,7 @@ public class RefactoringDataManagement extends DataManagementAdapter
@Override
public void preselect(List<EObject> selection) {
getInPortByName(SELECTEDEOBJECT).
- setValue((<%=refactoringConfig.getSelectedEObjectClass()%>) selection.get(0));
+ setValue((<%=info.getSelectedEObjectClass()%>) selection.get(0));
}
}
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringGuiHandlerHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringGuiHandlerHenshin.javajet
index df4f148..bd93763 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringGuiHandlerHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringGuiHandlerHenshin.javajet
@@ -1,18 +1,18 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringGuiHandler"
-imports="org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringGuiHandlerHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringGuiHandlerHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.util.List;
import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.refactor.common.core.EmfRefactoring;
-import org.eclipse.emf.refactor.common.core.ui.IGuiHandler;
+import org.eclipse.emf.refactor.refactoring.core.Refactoring;
+import org.eclipse.emf.refactor.refactoring.interfaces.IGuiHandler;
import org.eclipse.ltk.ui.refactoring.RefactoringWizard;
/**
@@ -22,42 +22,42 @@ import org.eclipse.ltk.ui.refactoring.RefactoringWizard;
public class RefactoringGuiHandler implements IGuiHandler {
/**
- * EmfRefactoring supported by the GuiHandler.
+ * Refactoring supported by the GuiHandler.
* @generated
*/
- EmfRefactoring parent;
+ private Refactoring parent;
/**
- * @see org.eclipse.emf.refactor.common.core.ui.IGuiHandler#getParent()
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IGuiHandler#getParent()
* @generated
*/
@Override
- public EmfRefactoring getParent() {
+ public Refactoring getParent() {
return parent;
}
/**
- * @see org.eclipse.emf.refactor.common.core.ui.IGuiHandler#
- * setParent(org.eclipse.emf.refactor.common.core.EmfRefactoring)
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IGuiHandler#
+ * setParent(org.eclipse.emf.refactor.refactoring.core.Refactoring)
* @generated
*/
@Override
- public void setParent(EmfRefactoring emfRefactoring) {
- this.parent = emfRefactoring;
+ public void setParent(Refactoring refactoring) {
+ this.parent = refactoring;
}
/**
- * @see org.eclipse.emf.refactor.common.core.ui.IGuiHandler#show()
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IGuiHandler#show()
* @generated
*/
@Override
public RefactoringWizard show() {
- return new <%=refactoringConfig.getPackageName()%>.RefactoringWizard
- ((RefactoringController)this.parent.getController());
+ return new <%=info.getPackageName()%>.RefactoringWizard
+ ((RefactoringController) this.parent.getController());
}
/**
- * @see org.eclipse.emf.refactor.common.core.ui.IGuiHandler#
+ * @see org.eclipse.emf.refactor.refactoring.interfaces.IGuiHandler#
* showInMenu(java.util.List)
* @generated
*/
@@ -65,7 +65,7 @@ public class RefactoringGuiHandler implements IGuiHandler {
public boolean showInMenu(List<EObject> selection) {
for(EObject o:selection){
if(null != o){
- if (o instanceof <%=refactoringConfig.getSelectedEObjectClass()%>) {
+ if (o instanceof <%=info.getSelectedEObjectClass()%>) {
return true;
}
}
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringInformationHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringInformationHenshin.javajet
index 53e7145..e3837c0 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringInformationHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringInformationHenshin.javajet
@@ -1,22 +1,22 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringInformation"
-imports="org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringInformationHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringInformationHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+ package <%=info.getPackageName()%>;
import java.io.File;
import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.Platform;
-import org.eclipse.emf.refactor.henshin.runtime.HenshinInformationAdapter;
-import org.eclipse.emf.refactor.henshin.core.IHenshinDataManagement;
+import org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinDataManagement;
+import org.eclipse.emf.refactor.refactoring.henshin.runtime.HenshinInformationAdapter;
import org.osgi.framework.Bundle;
-import <%=refactoringConfig.getRootPackageName()%>.Activator;
+import <%=info.getRootPackageName()%>.Activator;
/**
* Class used for specifying a Henshin file that shall be used by
@@ -44,7 +44,7 @@ public class RefactoringInformation extends HenshinInformationAdapter {
}
/**
- * @see org.eclipse.emf.refactor.henshin.core.IHenshinInformation#
+ * @see org.eclipse.emf.refactor.refactoring.henshin.interfaces.IHenshinInformation#
* getHenshinDataManagement()
* @generated
*/
@@ -54,7 +54,7 @@ public class RefactoringInformation extends HenshinInformationAdapter {
}
/**
- * @see org.eclipse.emf.refactor.henshin.runtime.
+ * @see org.eclipse.emf.refactor.refactoring.henshin.runtime.
* HenshinInformationAdapter#getTransformationFileName()
* @generated
*/
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringTestHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringTestHenshin.javajet
index 4760b15..aa82caa 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringTestHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringTestHenshin.javajet
@@ -1,14 +1,14 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringTest"
-imports="org.eclipse.emf.refactor.generator.*"%>
-<%RefactoringConfig refactoringConfig = (RefactoringConfig) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringTestHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringTestHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
-package <%=refactoringConfig.getPackageName()%>;
+package <%=info.getPackageName()%>;
import java.io.File;
import java.io.FilenameFilter;
@@ -21,11 +21,11 @@ import java.util.List;
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.ecore.xmi.impl.XMIResourceFactoryImpl;
import org.eclipse.emf.henshin.model.HenshinPackage;
-import org.eclipse.emf.refactor.common.core.EmfRefactoring;
-import <%=refactoringConfig.getPackageName()%>.RefactoringController;
-import <%=refactoringConfig.getPackageName()%>.RefactoringGuiHandler;
-import org.eclipse.emf.refactor.runtime.test.JUnitTestCaseAdapter;
-import <%=refactoringConfig.getSelectedEObjectJar()%>.<%=refactoringConfig.getMetaModelName()%>Package;
+import org.eclipse.emf.refactor.refactoring.core.Refactoring;
+import org.eclipse.emf.refactor.refactoring.runtime.test.JUnitTestCaseAdapter;
+
+// import <%=info.getSelectedEObjectJar()%>.<%=info.getMetaModelName()%>Package;
+
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.runners.Parameterized;
@@ -51,11 +51,11 @@ public class RefactoringTest extends JUnitTestCaseAdapter {
* @generated
*/
public RefactoringTest(String number) throws IOException {
- super("<%=refactoringConfig.getRefactoringId()%>",
- "<%=refactoringConfig.getNamespacePrefix()%>",
+ super("<%=info.getRefactoringId()%>",
+ "<%=info.getNamespacePrefix()%>",
new File(".").getCanonicalPath(),
- new EmfRefactoring(null, "", "<%=refactoringConfig.getNamespaceUri()%>", new RefactoringGuiHandler(), new RefactoringController()));
- register(<%=refactoringConfig.getMetaModelName()%>Package.eINSTANCE);
+ new Refactoring(null, "", "<%=info.getNamespaceUri()%>", new RefactoringGuiHandler(), new RefactoringController()));
+ // register(<%=info.getMetaModelName()%>Package.eINSTANCE);
register(HenshinPackage.eINSTANCE);
Resource.Factory.Registry.INSTANCE.getExtensionToFactoryMap( ).put("henshin", new XMIResourceFactoryImpl());
this.number = number;
@@ -74,7 +74,7 @@ public class RefactoringTest extends JUnitTestCaseAdapter {
private static List<String> getTestNumbers() {
List<String> numbers = new ArrayList<String>();
try {
- String pathPrefix = new File(".").getCanonicalPath() + "/tests/" + "<%=refactoringConfig.getRefactoringId()%>";
+ String pathPrefix = new File(".").getCanonicalPath() + "/tests/" + "<%=info.getRefactoringId()%>";
File testCaseDir = new File(pathPrefix,"/");
FilenameFilter filter = new FilenameFilter() {
public boolean accept(File dir, String name) {
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardHenshin.javajet
index a00bfba..54bd375 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardHenshin.javajet
@@ -1,24 +1,23 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringWizard"
-imports="org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringWizardHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringWizardHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+package <%=info.getPackageName()%>;
-import org.eclipse.emf.refactor.common.core.IController;
-import org.eclipse.emf.refactor.runtime.ltk.ui.AbstractRefactoringWizard;
+import org.eclipse.emf.refactor.refactoring.interfaces.IController;
+import org.eclipse.emf.refactor.refactoring.runtime.ltk.ui.AbstractRefactoringWizard;
/**
* Class used for providing an implementation of an LTK
* RefactoringWizard in EMF Refactor.
* @generated
*/
-public class RefactoringWizard
- extends AbstractRefactoringWizard {
+public class RefactoringWizard extends AbstractRefactoringWizard {
/**
* Default constructor implementation.
diff --git a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardPageHenshin.javajet b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardPageHenshin.javajet
index 0a42d1c..17725f4 100644
--- a/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardPageHenshin.javajet
+++ b/org.eclipse.emf.refactor.refactoring.henshin/templates/RefactoringWizardPageHenshin.javajet
@@ -1,13 +1,13 @@
<%@ jet package="org.eclipse.emf.refactor" class="RefactoringWizardPage"
-imports="org.eclipse.emf.refactor.generator.* org.eclipse.emf.refactor.henshin.generator.*"%>
-<%RefactoringConfigHenshin refactoringConfig = (RefactoringConfigHenshin) argument; %>
+imports="org.eclipse.emf.refactor.refactoring.henshin.generator.HenshinRefactoringInfo org.eclipse.emf.refactor.refactoring.generator.core.*"%>
+<%HenshinRefactoringInfo info = (HenshinRefactoringInfo) argument; %>
/**
* <copyright>
* </copyright>
*
- * $Id: RefactoringWizardPageHenshin.javajet,v 1.1 2012/11/26 11:49:12 tarendt Exp $
+ * $Id: RefactoringWizardPageHenshin.javajet,v 1.2 2012/11/26 15:39:38 tarendt Exp $
*/
- package <%=refactoringConfig.getPackageName()%>;
+ package <%=info.getPackageName()%>;
import org.eclipse.ltk.ui.refactoring.UserInputWizardPage;
import org.eclipse.swt.SWT;
@@ -33,18 +33,18 @@ public class RefactoringWizardPage extends
*/
private final RefactoringController controller;
-<% for (ParameterConfig pc : refactoringConfig.getParameters()) { %>
+<% for (ParameterInfo pi : info.getParameters()) { %>
/**
* Label for each parameter.
* @generated
*/
- private Label <%=pc.getName()%>Label;
+ private Label <%=pi.getName()%>Label;
/**
* TextField for each parameter.
* @generated
*/
- private Text <%=pc.getName()%>Widget;
+ private Text <%=pi.getName()%>Widget;
<% } %>
/**
@@ -70,18 +70,18 @@ public class RefactoringWizardPage extends
public void handleEvent(Event event) {
getWizard().getContainer().updateButtons();
-<% for (ParameterConfig pc : refactoringConfig.getParameters()) { %>
- if (<%=pc.getName()%>Widget != null) {
- String <%=pc.getName()%> = <%=pc.getName()%>Widget.getText();
- if (!<%=pc.getName()%>.isEmpty()){
+<% for (ParameterInfo pi : info.getParameters()) { %>
+ if (<%=pi.getName()%>Widget != null) {
+ String <%=pi.getName()%> = <%=pi.getName()%>Widget.getText();
+ if (!<%=pi.getName()%>.isEmpty()){
((RefactoringDataManagement)
this.controller.getDataManagementObject()).
- getInPortByName("<%=pc.getName()%>").
- setValue(<%=pc.getName()%>);
+ getInPortByName("<%=pi.getName()%>").
+ setValue(<%=pi.getName()%>);
} else {
((RefactoringDataManagement)
this.controller.getDataManagementObject()).
- getInPortByName("<%=pc.getName()%>").
+ getInPortByName("<%=pi.getName()%>").
setValue("unspecified");
}
}
@@ -102,18 +102,18 @@ public class RefactoringWizardPage extends
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
composite.setLayout(gl);
-<% for (ParameterConfig pc : refactoringConfig.getParameters()) { %>
+<% for (ParameterInfo pi : info.getParameters()) { %>
- <%=pc.getName()%>Label = new Label(composite, SWT.NONE);
- <%=pc.getName()%>Label.setText("<%=pc.getDescription()%>: ");
- <%=pc.getName()%>Label.setEnabled(true);
+ <%=pi.getName()%>Label = new Label(composite, SWT.NONE);
+ <%=pi.getName()%>Label.setText("<%=pi.getDescription()%>: ");
+ <%=pi.getName()%>Label.setEnabled(true);
- <%=pc.getName()%>Widget = new Text(composite, SWT.BORDER);
- <%=pc.getName()%>Widget.setToolTipText
- ("value of variable '<%=pc.getName()%>'");
- <%=pc.getName()%>Widget.setEnabled(true);
- <%=pc.getName()%>Widget.setLayoutData(gd);
- <%=pc.getName()%>Widget.addListener(SWT.Modify, this);
+ <%=pi.getName()%>Widget = new Text(composite, SWT.BORDER);
+ <%=pi.getName()%>Widget.setToolTipText
+ ("value of variable '<%=pi.getName()%>'");
+ <%=pi.getName()%>Widget.setEnabled(true);
+ <%=pi.getName()%>Widget.setLayoutData(gd);
+ <%=pi.getName()%>Widget.addListener(SWT.Modify, this);
<% } %>

Back to the top