Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/org.eclipse.gmf.graphdef.codegen/templates/top/Figure.xpt')
-rw-r--r--plugins/org.eclipse.gmf.graphdef.codegen/templates/top/Figure.xpt95
1 files changed, 95 insertions, 0 deletions
diff --git a/plugins/org.eclipse.gmf.graphdef.codegen/templates/top/Figure.xpt b/plugins/org.eclipse.gmf.graphdef.codegen/templates/top/Figure.xpt
new file mode 100644
index 000000000..932398ae9
--- /dev/null
+++ b/plugins/org.eclipse.gmf.graphdef.codegen/templates/top/Figure.xpt
@@ -0,0 +1,95 @@
+/*
+ * Copyright (c) 2006 Borland Software Corporation
+ *
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Artem Tikhomirov (Borland) - initial API and implementation
+ */
+
+«IMPORT "http://www.eclipse.org/gmf/2005/GraphicalDefinition"»
+«IMPORT "http://www.eclipse.org/emf/2002/Ecore"»
+«IMPORT "templates"»
+«EXTENSION Util»
+
+«DEFINE FigureClass(boolean isInnerClass) FOR gmfgraph::Figure»
+«packageStatement()»
+/**
+ * @generated
+ */
+public class «compilationUnitName()» extends «qualifiedClassNameGEF()» {
+ /**
+ * @generated
+ */
+ public «compilationUnitName()»() {
+ «EXPAND Layout::Init("this") FOR layout-»
+ «EXPAND Attrs::Init("this")-»
+«IF !children.typeSelect(Figure).isEmpty()-»
+ createContents();
+ }
+«EXPAND Children::CreateChildren-»
+«ELSE-»
+ }
+«ENDIF-»
+«additionalMethods()»
+«EXPAND Extras::extraMethods»
+«EXPAND Extras::localCoordinates»
+«IF isInnerClass-»
+}
+«additionalStaticFields()»
+«ELSE-»
+«additionalStaticFields()»
+}
+«ENDIF-»
+«ENDDEFINE»
+
+
+«DEFINE FigureClass(boolean isInnerClass) FOR gmfgraph::PolylineConnection»
+«packageStatement()»
+/**
+ * @generated
+ */
+public class «compilationUnitName()» extends «qualifiedClassNameGEF()» {
+
+ /**
+ * @generated
+ */
+ public «compilationUnitName()»() {
+ «EXPAND Attrs::Init("this")»
+«IF hasSourceDecoration()-»
+ setSourceDecoration(createSourceDecoration());
+«ENDIF-»
+«IF hasTargetDecoration()-»
+ setTargetDecoration(createTargetDecoration());
+«ENDIF-»
+ }
+«IF hasSourceDecoration()»
+ /**
+ * @generated
+ */
+ private org.eclipse.draw2d.RotatableDecoration createSourceDecoration() {
+ «EXPAND Decoration::Instantiate("df") FOR sourceDecoration-»
+ return df;
+ }
+«ENDIF-»
+«IF hasTargetDecoration()»
+ /**
+ * @generated
+ */
+ private org.eclipse.draw2d.RotatableDecoration createTargetDecoration() {
+ «EXPAND Decoration::Instantiate("df") FOR targetDecoration-»
+ return df;
+ }
+«ENDIF-»
+«additionalMethods()»
+«IF isInnerClass-»
+}
+«additionalStaticFields()»
+«ELSE-»
+«additionalStaticFields()»
+}
+«ENDIF-»
+«ENDDEFINE» \ No newline at end of file

Back to the top