Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Taal2012-10-21 07:21:10 -0400
committerMartin Taal2012-10-21 07:21:10 -0400
commit49cb9ad054800850f9af88790f7142b569bc2e79 (patch)
tree4a9a3b157341cbab82e201d4eb5521a18e836aa0 /generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml
parent20b5a50d525beb04240f8131720f418e74b1c94d (diff)
downloadorg.eclipse.emf.texo-49cb9ad054800850f9af88790f7142b569bc2e79.tar.gz
org.eclipse.emf.texo-49cb9ad054800850f9af88790f7142b569bc2e79.tar.xz
org.eclipse.emf.texo-49cb9ad054800850f9af88790f7142b569bc2e79.zip
Added readme.txt, ant files and small changes to generator application
Diffstat (limited to 'generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml')
-rw-r--r--generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml60
1 files changed, 60 insertions, 0 deletions
diff --git a/generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml b/generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml
new file mode 100644
index 00000000..59214cce
--- /dev/null
+++ b/generator/org.eclipse.emf.texo.eclipse.generator/examples/texo-gen-macrodef.xml
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+Copyright (c) 2012 Springsite BV (The Netherlands) and others
+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:
+ Martin Taal - Initial API and implementation
+-->
+<project name="Texo Headless Generation Macrodef">
+ <macrodef name="texo.gen">
+ <attribute name="eclipse"/>
+ <attribute name="data"/>
+ <attribute name="project" default=""/>
+ <attribute name="modelLocation"/>
+ <attribute name="dao" default="false"/>
+ <attribute name="jpa" default="false"/>
+ <sequential>
+
+ <condition property="dao.arg" value="-dao" else="">
+ <istrue value="@{dao}"/>
+ </condition>
+
+ <condition property="jpa.arg" value="-jpa" else="">
+ <istrue value="@{jpa}"/>
+ </condition>
+
+ <property name="project.value" value="@{project}"/>
+
+ <condition property="project.arg" value="-project @{project}" else="">
+ <isset property="project.value"/>
+ </condition>
+
+ <echo message="@{eclipse}"/>
+
+ <property name="eclipse.plugins" value="@{eclipse}/plugins"/>
+ <property name="launcher.jar" value="${eclipse.plugins}/org.eclipse.equinox.launcher.jar"/>
+
+ <!-- copy the version numbered launcher jar to an unversion numbered launcher jar -->
+ <copy tofile="${launcher.jar}">
+ <fileset dir="${eclipse.plugins}" includes="**/org.eclipse.equinox.launcher_*.jar"/>
+ </copy>
+
+ <!-- start Eclipse with java -->
+ <java classpath="${launcher.jar}" fork="true"
+ classname="org.eclipse.equinox.launcher.Main"
+ failonerror="true">
+ <arg value="-nosplash"/>
+ <arg value="-data @{data}"/>
+ <arg value="-application org.eclipse.emf.texo.eclipse.generator.TexoCodeGenerator"/>
+ <arg value="${project.arg}"/>
+ <arg value="-modelLocation @{modelLocation}"/>
+ <arg value="${jpa.arg}"/>
+ <arg value="${dao.arg}"/>
+ </java>
+ </sequential>
+ </macrodef>
+</project>

Back to the top