Hi Peter,
here is an ant task example useing templates and one reference model.
<target name="generate.eos.isip" depends="setProps">
<property name="eogenerator.model" value="isip.eomodeld"/>
<property name="eogenerator.superclassname"
value="de.swk.isip.bo.common.IsipObject"/>
<property name="eogenerator.superclasspackage"
value="de.swk.isip.bo"/>
<property name="eogenerator.destination"
value="./FOBusinessObjects.subproj/src/de/swk/isip/bo"/>
<property name="eogenerator.refmodel"
value="hortigate.eomodeld"/>
<property name="eogenerator.home"
value="${wo.wolocalroot}/Developer/Executables" />
<exec executable="${eogenerator.home}/eogenerator.exe">
<arg value="-model" />
<arg path="${eogenerator.model}" />
<arg value="-refmodel" />
<arg path="${eogenerator.refmodel}" />
<arg value="-destination" />
<arg path="${eogenerator.destination}" />
<arg value="-subclassDestination" />
<arg path="${eogenerator.destination}/impl" />
<arg value="-templatedir" />
<arg path="./eogen.templates" />
<arg value="-javaTemplate" />
<arg value="SuperclassSource.eotemplate" />
<arg value="-subclassJavaTemplate" />
<arg value="SubclassSource.eotemplate" />
<arg value="-java" />
<arg value="-define-EOGenericRecord" />
<arg value="${eogenerator.superclassname}" />
<arg value="-define-SuperClassPackage" />
<arg value="${eogenerator.superclasspackage}" />
</exec>
</target>
Befor running the first time you had to create the package folders by hand.
Stefan
Peter Thompson schrieb:
> I am having problems getting EOGenerator (v1.7 from Rubicode) working
> with my PC.
>
> I am using eclipse 3.2 and WOLips (latest stable version). I can
> create an EOModel OK (which verifies), I can successfully generate SQL
> to create tables etc... and can build and run WO projects generally.
> I cannot generate Java classes with EOGenerator from the model and
> need some help.
>
> I have configured WOLips EOGenerator options as follows:
>
> > Executable Path = D:\\dev\\apps\\eogenerator\\eogenerator.exe
> > Template Folder = D:\\dev\\apps\\eogenerator\\Templates
> > Java Template = JavaSourceEOF52.eotemplate
> > Subclass Java Template = JavaSubclassSourceEOF5.eotemplate
>
> The top two are correct paths (escaped) to EOGenerator.
>
> I can right click my model, use "WOLips Tools" option to "Create EO
> Generator File" OK - generated file (Authors.eogen) as follows:
>
> D:\\dev\\apps\\eogenerator\\eogenerator.exe -destination src -java
> -javaTemplate JavaSourceEOF52.eotemplate -model D:Authors.eomodeld
> -packagedirs -subclassDestination src -subclassJavaTemplate
> JavaSubclassSourceEOF5.eotemplate -templatedir
> ../../apps/eogenerator/Templates -verbose
>
> However, when I right-click this eogen file, and choose to
> "EOGenerate...", an "EOGenerator finished with the following
> results" window pops up with
>
> > D:\dev\workspace\Authors\Authors.eogen:
> > Finished.
>
> i.e. I do not get any generated class files messages (as expected),
> and nothing appears to be generated. Then within Eclipse the eogen
> file shows a red-cross as if something is wrong with it.
>
> Another avenue... I have tried to run it on the Windows command line
> but get a pop-up exception saying "This application has failed to
> start because the EOAccess.dll was not found. re-installing the
> application may fix this problem".
>
> Any help you can give would be greatly appreciated.
>
> Thanks,
> Peter Thompson
>
This archive was generated by hypermail 2.0.0 : Wed Aug 01 2007 - 04:26:11 EDT