On Thu January 14 2010 5:03:47 pm Jerry Wang wrote:
> I am new to CXF, hoping the question I am asking has not been asked before
> as no answer from my search.
> in 2.1.3, there is such ant task implemented in cxf-anttasks-2.1.3.jar.
> how can I find the same ant taks in 2.2.5, has it been renamed and moved to
> a different location?
> Thanks

We pretty much removed it as it was kind of stale and not being worked on and 
a normal ant macro worked much better.     See below for a basic idea.  (or 
the common_build.xml file in our samples directory of our kits where this was 
taken from)

-- 
Daniel Kulp
[email protected]
http://www.dankulp.com/blog




    <macrodef name="wsdl2java">
        <attribute name="srcdestdir" default="${build.src.dir}"/>
        <attribute name="destdir" default="${build.classes.dir}"/>
        <attribute name="file"/>
        <attribute name="servicename.arg" default=""/>
        <attribute name="bindingfile" default=""/>
        <attribute name="databinding" default=""/>
        <attribute name="dir" default="${wsdl.dir}"/>
        <attribute name="package" default="NOT_SPECIFIED"/>
        <sequential>
            <mkdir dir="@{destdir}"/>
            <mkdir dir="@{srcdestdir}"/>
            <condition property="package.a...@{file}" value="-p @{package}">
                <not>
                    <equals arg1="@{package}" arg2="NOT_SPECIFIED"/>
                </not>
            </condition>
            <property name="package.a...@{file}" value=""/>
            <condition property="binding.arg" value='-b "@{bindingfile}"'>
                <not>
                    <equals arg1="@{bindingfile}" arg2=""/>
                </not>
            </condition>
            <property name="binding.arg" value=""/>
            <condition property="databinding.arg" value='-db 
"@{databinding}"'>
                <not>
                    <equals arg1="@{databinding}" arg2=""/>
                </not>
            </condition>
            <property name="databinding.arg" value=""/>
            <java failonerror="true" 
classname="org.apache.cxf.tools.wsdlto.WSDLToJava" fork="yes">
                <classpath>
                    <path refid="cxf.classpath" />
                </classpath>
                <sysproperty key="java.util.logging.config.file" 
value="${cxf.etc.dir}/logging.properties"/>
                <sysproperty key="exitOnFinish" value="true"/>
                <arg line="@{servicename.arg}"/>
                <arg line="${package.a...@{file}}"/>
                <arg line="${databinding.arg}"/>
                <arg line="${binding.arg}"/>
                <arg value="-verbose"/>
                <arg value="-d"/>
                <arg value="@{srcdestdir}"/>
                <arg value="@{dir}/@{file}"/>
            </java>
        </sequential>
    </macrodef>

Reply via email to