Hi Archie, Thanks a lot for your response and spending time on this.
I created a new sample project just like you did and it worked for me as well. However when I try the same configuration in my project it doesn't seem to work. I will continue to debug and keep you posted on how it goes. Thanks again Archie!! Thanks and Regards, Dickson Rodrigues On Thu, Mar 31, 2022 at 4:10 PM Archie Cobbs <archie.co...@gmail.com> wrote: > Not sure why but I was unable to reproduce your issue using a slightly > modified version of your files. > > Here's a shell script trace: > > $ tree > . > ├── binding.xml > ├── build.xml > ├── lib > │ ├── jibx-bind-1.3.3.jar > │ └── jibx-run-1.3.3.jar > └── src > └── java > └── com > └── blahblah > └── model > └── account > ├── Account.java > └── AccountResult.java > > 7 directories, 6 files > $ cat build.xml > <?xml version="1.0" encoding="utf-8"?> > > <project name="jibx-test" default="jibx-bind"> > > <path id="test.classpath"> > <fileset dir="${basedir}/lib" includes="*.jar"/> > </path> > > <target name="clean"> > <delete dir="build" followSymlinks="false" > removeNotFollowedSymlinks="true" includeEmptyDirs="true"/> > </target> > > <target name="javac"> > <mkdir dir="${basedir}/build/classes"/> > <javac includeantruntime="no" > compiler="modern" > deprecation="true" > srcdir="${basedir}/src/java" > destdir="${basedir}/build/classes" > source="1.8" > target="1.8" > debug="true"> > <classpath refid="test.classpath"/> > </javac> > </target> > > <target name="jibx-bind" depends="javac"> > <taskdef name="bind" classname="org.jibx.binding.ant.CompileTask" > classpathref="test.classpath"/> > <bind verbose="false" load="true"> > <classpath> > <pathelement location="${basedir}/build/classes"/> > <path refid="test.classpath"/> > </classpath> > <bindingfileset dir="${basedir}"> > <include name="binding.xml"/> > </bindingfileset> > </bind> > </target> > </project> > $ cat binding.xml > <?xml version="1.0" encoding="utf-8"?> > > <binding name="accountBinding" package="com.blahblah.model.account"> > <mapping name="blahblah_service" > class="com.blahblah.model.account.AccountResult"> > <collection field="accounts" create-type="java.util.ArrayList"> > <structure name="account" > type="com.blahblah.model.account.Account" ordered="false"> > <value name="id" style="element" field="idNumber"/> > <value name="account" style="element" > field="accountNumber" usage="optional"/> > </structure> > </collection> > </mapping> > </binding> > $ cat src/java/com/blahblah/model/account/AccountResult.java > package com.blahblah.model.account; > > import java.util.ArrayList; > import java.util.List; > > public class AccountResult { > > private List<Account> accounts; > } > $ cat src/java/com/blahblah/model/account/Account.java > package com.blahblah.model.account; > > public class Account { > > private String idNumber; > private String accountNumber; > > } > $ ant > Buildfile: /Users/archie/bugs/jibx/build.xml > > javac: > [mkdir] Created dir: /Users/archie/bugs/jibx/build/classes > [javac] Compiling 2 source files to > /Users/archie/bugs/jibx/build/classes > > jibx-bind: > > BUILD SUCCESSFUL > Total time: 0 seconds > $ tree build > build > └── classes > └── com > └── blahblah > └── model > └── account > ├── Account.class > ├── AccountResult.class > ├── JiBX_accountBindingAccountResult_access.class > ├── JiBX_accountBindingFactory.class > └── JiBX_accountBindingMungeAdapter.class > > 5 directories, 5 files > $ > > -Archie > > > > -Archie > > On Thu, Mar 31, 2022 at 1:53 PM Dickson Rodrigues < > rodrigues.dick...@gmail.com> wrote: > >> >> Hi Archie, >> >> Thanks for responding. >> >> Please see the details below, >> >> Build.xml >> >> <target name="jibx"> >> <!-- ## Adds JibX class/method to ANT callable ## --> >> <taskdef name="bind" classname="org.jibx.binding.ant.CompileTask"> >> <classpath> >> <pathelement location ="${LIB_DIR}/jibx-bind-1.3.3.jar"/> >> <pathelement location="${LIB_DIR}/bcel-6.4.1.jar"/> >> <pathelement location="${LIB_DIR}/jibx-run-1.3.3.jar"/> >> <pathelement location="${LIB_DIR}/jibx-extras-1.3.3.jar"/> >> <pathelement location="${LIB_DIR}/xpp3-1.1.3.4.O.jar"/> >> </classpath> >> </taskdef> >> <!-- ## JIBX Compiler ## --> >> <bind verbose="true"> >> <bindingfileset dir="${BINDINGS_DIR}" includes="*Binding.xml"/> >> <classpath> >> <pathelement location ="${UAD_BASE}/classes"/> >> <pathelement location ="junit/lib/clover.jar"/> >> </classpath> >> </bind> >> </target> >> >> Jars included - >> >> ant-1.8.4.jar >> ant-launcher-1.8.4.jar >> bcel-6.4.1.jar >> jibx-bind-1.3.3.jar >> jibx-run-1.3.3.jar >> joda-time-2.10.5.jar >> xpp3-1.1.3.4.O.jar >> jibx-extras-1.3.3.jar >> >> >> Removed the old jibx jars from the lib directory >> >> binding file - >> >> <binding name="accountBinding" package="com.blahblah.model.account"> >> <mapping name="blahblah_service" >> class="com.blahblah.model.account.AccountResult"> >> <collection field="accounts" >> factory="com.blahblah.model.account.AccountResult.listFactory"> >> <structure name="account" type="com.blahblah.model.account.Account" >> ordered="false"> >> <value name="id" style="element" field="idNumber"/> >> <value name="account" style="element" field="accountNumber" >> usage="optional"/> >> </structure> >> </collection> >> </mapping> >> </binding> >> >> >> JiBX_accountBindingAccountResult_access.class is generated under package >> com.blahblah.model.billing. Infact all the _access files for my bindings >> are generated under the same package. Looks like it take the package name >> from the first binding file. >> >> Please let me know if you need more information. >> >> >> Thanks and Regards, >> Dickson Rodrigues >> >> >> On Thu, Mar 31, 2022 at 12:50 PM Archie Cobbs <archie.co...@gmail.com> >> wrote: >> >>> Can you create and post a *minimal* test case Maven project >>> demonstrating the problem? >>> >>> On Thu, Mar 31, 2022 at 10:35 AM Dickson Rodrigues < >>> rodrigues.dick...@gmail.com> wrote: >>> >>>> Hi, >>>> >>>> I am facing the same issue as few others who have reported those here. >>>> https://sourceforge.net/p/jibx/mailman/message/35070901/ and >>>> https://sourceforge.net/p/jibx/mailman/message/35115289/ >>>> I have added the dependency jars, updated the classpath to include >>>> those jars. I have tried giving the package name in the bindings file as >>>> well. >>>> >>>> I am running out of ideas. Anyone have any suggestions? >>>> >>>> *To admins* : Will you please post this on the threads mentioned above >>>> (https://sourceforge.net/p/jibx/mailman/message/35070901/ and >>>> https://sourceforge.net/p/jibx/mailman/message/35115289/) to see if >>>> they were able to resolve the issue and can help me. >>>> >>>> Thanks and Regards, >>>> Dickson Rodrigues >>>> _______________________________________________ >>>> jibx-users mailing list >>>> jibx-users@lists.sourceforge.net >>>> https://lists.sourceforge.net/lists/listinfo/jibx-users >>>> >>> -- >>> Archie L. Cobbs >>> _______________________________________________ >>> jibx-users mailing list >>> jibx-users@lists.sourceforge.net >>> https://lists.sourceforge.net/lists/listinfo/jibx-users >>> >> _______________________________________________ >> jibx-users mailing list >> jibx-users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/jibx-users >> > > > -- > Archie L. Cobbs > _______________________________________________ > jibx-users mailing list > jibx-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/jibx-users >
_______________________________________________ jibx-users mailing list jibx-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jibx-users