incubator-odf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian C <...@amham.net>
Subject Can't get codegen running
Date Sun, 17 Jun 2012 08:25:26 GMT
Hi Guys,

I am trying to get the code generation running.

The page http://incubator.apache.org/odftoolkit/odfdom/ODFDOM-Code-Generator.html
seems to be out of date.

After some poking around in the schema2template code I can see the
creation of a maven plugin to do the job.
And examining the odfdom pom I can see a profile there to call the above mojo.

So I eventually got to (I am a newbie to Maven :-) )

mvn org.apache.odftoolkit:schema2template-maven-plugin:0.8.9-incubating-SNAPSHOT:codegen
-P codegen

(Is that how to generate the code? )

It generates an error saying

[ERROR] Failed to execute goal
org.apache.odftoolkit:schema2template-maven-plugin:0.8.9-incubating-SNAPSHOT:codegen
(default-cli) on project odfdom-java: The parameters
'signatureSchemaFile', 'pkgResourceRoot', 'manifestSchemaFile',
'targetRoot', 'odf12SchemaFile', 'configFile', 'odf11SchemaFile',
'domResourceRoot' for goal
org.apache.odftoolkit:schema2template-maven-plugin:0.8.9-incubating-SNAPSHOT:codegen
are missing or invalid -> [Help 1]

They parameters are defined in the pom and I manually made sure the
references directories etc were there. (odf-schemas was not there and
could not get the build to download then for

I tried changing the pom and fiddling with the configuration
parameters to see if it was even reading them... it didn't seem so.
Also the -P does not seem to be needed to kick in the profile. Yet it
was needed some iterations ago ?!?

Anyone point me in the correct direction please?

I was going to look at using schema2 template manually I can see code
in there intended to do the job. The OdfHelper class. Or even manually
call the velocity templates in the same way. But that would be
re-inventing the wheel.

Everything else seems to work ok I can build the odfdom and simpleAPI
jars and they seem to work. I can process odt documents.

But I want to be able to generate code from the schema.

Thanks in advance.

Ian C

Mime
View raw message