> -----Original Message-----
> From: Aaron Titus [mailto:[email protected]]
> Sent: Thursday, January 15, 2015 1:00 PM
> To: [email protected]
> Subject: Re: How to build a CXF JAX-RS app with Gradle?
>
> On Thu, Jan 15, 2015 at 12:49 PM, KARR, DAVID <[email protected]> wrote:
>
> > > -----Original Message-----
> > > From: Aaron Titus [mailto:[email protected]]
> > > Sent: Thursday, January 15, 2015 9:45 AM
> > > To: [email protected]
> > > Subject: Re: How to build a CXF JAX-RS app with Gradle?
> > >
> > > >
> > > > I can see how you would add to the xjc classpath to provide
> extensions,
> > > > but how would you specify extension command-line arguments?
> > > >
> > >
> > > The only kind of extensions I've used are the ones that go in a
> binding
> > > file. How are the extension arguments different than regular command
> > line
> > > arguments? The example shows how regular arguments work, wouldn't it
> > just
> > > be adding a few more?
> >
> > You show adding arguments to the WSDL task, but not the XJC task.
> >
>
>
> I guess I am not sure how to answer your question. I posted two examples I
> had, one showing java exec directly and one via Ant. The xjc is using the
> Ant task. When you say "extension command line arguments" this makes me
> think you want a java exec task, with arguments, as I have shown.
>
> Do you have an existing Ant task that does what you want? If you do, post
> it here and maybe I can figure the syntax. I'm not a maven user, so I
> can't help interpret going directly from maven to gradle.
>
> The wsdl task is a pure java exec. If you want to run xjc directly (skip
> the ant task) then you could build up a task that does it along the lines
> of what I did here with wsdl2java.
Actually, I now see that in the XJC Ant task, there is a nested "arg" element,
which takes property variations of "line", "value", and "path". In that case,
I guess I would add something like this to the "ant.xjc" element:
arg(line: "-Xxew")
arg(line: "-Xfluent-api")
If I needed to add "-Xxew -Xfluent-api" to the XJC command line. Will this
work?