diff options
author | atikhomirov | 2010-04-27 21:06:41 -0400 |
---|---|---|
committer | atikhomirov | 2010-04-27 21:06:41 -0400 |
commit | f9efde529b73f9c7bc08675e32f87c1710249c77 (patch) | |
tree | 9382a1f4fa907ce09b8547917857a4688696d9b4 | |
parent | 67290d1848ba8a58077b7ecb42fe72f4c5007026 (diff) | |
download | org.eclipse.gmf-tooling-f9efde529b73f9c7bc08675e32f87c1710249c77.tar.gz org.eclipse.gmf-tooling-f9efde529b73f9c7bc08675e32f87c1710249c77.tar.xz org.eclipse.gmf-tooling-f9efde529b73f9c7bc08675e32f87c1710249c77.zip |
delegate method access to the template that knows naming scheme
-rw-r--r-- | plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateLinkCommand.xpt | 8 | ||||
-rw-r--r-- | plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateNodeCommand.xpt | 6 |
2 files changed, 4 insertions, 10 deletions
diff --git a/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateLinkCommand.xpt b/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateLinkCommand.xpt index 83651f1d3..6e1d92e4f 100644 --- a/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateLinkCommand.xpt +++ b/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateLinkCommand.xpt @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2009 Borland Software Corporation + * Copyright (c) 2007, 2010 Borland Software Corporation and others * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 @@ -82,11 +82,7 @@ public class «createCommandClassName» extends org.eclipse.gmf.runtime.emf.type «ENDIF-» «ENDDEFINE» - -«DEFINE initialize(link : gmfgen::GenLink, newElementvVar : String) FOR gmfgen::TypeModelFacet»«IF modelElementInitializer <> null-» -«link.diagram.getElementTypesQualifiedClassName()».init_«link.getUniqueIdentifier()»(«newElementvVar»); -«ENDIF»«ENDDEFINE» - +«DEFINE initialize(gmfgen::GenLink link, String newElementVar) FOR gmfgen::TypeModelFacet»«EXPAND xpt::providers::ElementInitializers::initMethodCall(self, newElementVar) FOR link»«ENDDEFINE» «DEFINE execute(link : gmfgen::GenLink) FOR gmfgen::FeatureLinkModelFacet» «IF metaFeature.ecoreFeature.changeable-» diff --git a/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateNodeCommand.xpt b/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateNodeCommand.xpt index 8234e1190..92c1472c0 100644 --- a/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateNodeCommand.xpt +++ b/plugins/org.eclipse.gmf.codegen/templates/xpt/diagram/commands/CreateNodeCommand.xpt @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2009 Borland Software Corporation + * Copyright (c) 2007, 2010 Borland Software Corporation and others * * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 @@ -153,6 +153,4 @@ protected org.eclipse.emf.ecore.EObject getElementToEdit() { «ENDIF-» «ENDDEFINE» -«DEFINE initialize(node : gmfgen::GenNode, newElementVar : String) FOR gmfgen::TypeModelFacet»«IF modelElementInitializer <> null-» -«node.getDiagram().getElementTypesQualifiedClassName()».init_«node.getUniqueIdentifier()»(«newElementVar»); -«ENDIF»«ENDDEFINE»
\ No newline at end of file +«DEFINE initialize(node : gmfgen::GenNode, newElementVar : String) FOR gmfgen::TypeModelFacet»«EXPAND xpt::providers::ElementInitializers::initMethodCall(self, newElementVar) FOR node»«ENDDEFINE» |