Hi, currently I'm going to upgrade the JiBX version from 1.0.1 to 1.2.5. Now I'm facing an issue where I couldn't find a solution so far(Neither in the documentation and examples on the website, nor on the mailing-list).
My classes to map look like: ,-----------------------------. ,------------------------. |RequestSet | |Request | |-----------------------------| |------------------------| |-ArrayList<Request> requests;| |-RequestBody requestBody| |-----------------------------| |------------------------| `-----------------------------' `------------------------' ,-------------------------. |RequestBody | |-------------------------| |-AccountData accountData;| |-------------------------| +--->`-------------------------'<---+ / ^ ^ \ / / \ / \ \ / | | \ ,----------. ,--------------. ,-------------. ,-------------. |GetRequest| |InstallRequest| |UpdateRequest| |DeleteRequest| |----------| |--------------| |-------------| |-------------| |----------| |--------------| |-------------| |-------------| `----------' `--------------' `-------------' `-------------' ,------------------------------. ,-------------------------. |ResponseSet | |Response | |------------------------------| |-------------------------| |-ArrayList<Response> requests;| |-ResponseBody requestBody| |------------------------------| |-------------------------| `------------------------------' `-------------------------' ,--------------------------. |ResponseBody | |--------------------------| |-AccountData accountData; | |--------------------------| +--->`--------------------------'<--+ / ^ ^ \ / / \ / \ \ / | | \ ,-----------. ,---------------. ,--------------. ,--------------. |GetResponse| |InstallResponse| |UpdateResponse| |DeleteResponse| |-----------| |---------------| |--------------| |--------------| |-----------| |---------------| |--------------| |--------------| `-----------' `---------------' `--------------' `--------------' The XML can look like: <request_set> <response_set> <request> <response> <get> <get> <account_data /> <account_data /> </get> </get> </request> </response> <request> <response> <install> <install> <account_data /> <account_data /> </install> </install> </request> </response> <request> <response> <update> <update> <account_data /> <account_data /> </update> </update> </request> </response> <request> <response> <delete> <delete> <account_data /> <account_data /> </delete> </delete> </request> </response> </request_set> </response_set> With JiBX 1.0.1 I had the following binding definition, which is not valid anymore, as the 'name' of a mapping must now be unique... <mapping name="request_set" class="my.package.request.RequestSet" pre-get="preMarshall"> <collection field="requests" item-type="my.package.request.Request" usage="optional" /> </mapping> <mapping name="request" class="my.package.request.Request"> <structure field="requestBody" usage="optional" /> </mapping> <mapping class="my.package.request.RequestBody" abstract="true" post-set="postUnmarshall"> <structure field="accountData" usage="optional" /> </mapping> <mapping name="install" class="my.package.request.InstallRequest" extends="my.package.request.RequestBody"> <structure map-as="my.package.request.RequestBody" /> </mapping> <mapping name="get" class="my.package.request.GetRequest" extends="my.package.request.RequestBody"> <structure map-as="my.package.request.RequestBody" /> </mapping> <mapping name="update" class="my.package.request.UpdateRequest" extends="my.package.request.RequestBody"> <structure map-as="my.package.request.RequestBody" /> </mapping> <mapping name="delete" class="my.package.request.DeleteRequest" extends="my.package.request.RequestBody"> <structure map-as="my.package.request.RequestBody" /> </mapping> <mapping name="response_set" class="my.package.response.ResponseSet"> <collection field="responses" item-type="my.package.response.Response" usage="optional" /> </mapping> <mapping name="response" class="my.package.response.Response"> <structure field="responseBody" usage="optional" /> </mapping> <mapping class="my.package.response.ResponseBody" abstract="true"> <structure field="accountData" usage="optional" /> </mapping> <mapping name="install" class="my.package.response.InstallResponse" extends="my.package.response.ResponseBody"> <structure map-as="my.package.response.ResponseBody" usage="optional" /> </mapping> <mapping name="get" class="my.package.response.GetResponse" extends="my.package.response.ResponseBody"> <structure map-as="my.package.response.ResponseBody" usage="optional" /> </mapping> <mapping name="update" class="my.package.response.UpdateResponse" extends="my.package.response.ResponseBody"> <structure map-as="my.package.response.ResponseBody" usage="optional" /> </mapping> <mapping name="delete" class="my.package.response.DeleteResponse" extends="my.package.response.ResponseBody"> <structure map-as="my.package.response.ResponseBody" usage="optional" /> </mapping> How can I realize this kind of mapping with JiBX 1.2.5? Thanks, Joerg ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ jibx-users mailing list jibx-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jibx-users