[ https://jira.codehaus.org/browse/JIBX-458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Don Corley resolved JIBX-458. ----------------------------- Resolution: Fixed Fix Version/s: JiBX 1.2.3 See modular-codegen example in the maven plugin documentation to see how handle multiple schema. > CodeGen cannot generate binding XMLs for schemas which reference other schemas > ------------------------------------------------------------------------------ > > Key: JIBX-458 > URL: https://jira.codehaus.org/browse/JIBX-458 > Project: JiBX > Issue Type: Bug > Components: CodeGen > Affects Versions: JiBX 1.2.3 > Environment: Mac OS X 10.6.8, java version "1.6.0_26" > Java(TM) SE Runtime Environment (build 1.6.0_26-b03-384-10M3425) > Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02-384, mixed mode) > Reporter: James Athey > Assignee: Don Corley > Fix For: JiBX 1.2.3 > > > If CodeGen is run on a schema which references another schema, it fails to > generate binding XMLs (after code generation) with an error like the > following: > Loaded and validated 1 specified schema(s) and 1 referenced schema(s) > Error: Error accessing included binding with path > "schemas_pvisionBinding.xml": <current working > directory>/schemas_pvisionBinding.xml (No such file or directory); on include > element at (source unknown) > Error: Error accessing included binding with path > "protocol_geolocBinding.xml": <current working > directory>/protocol_geolocBinding.xml (No such file or directory); on include > element at (source unknown) > Exception in thread "main" org.jibx.runtime.JiBXException: Terminating due to > errors in bindings > at org.jibx.schema.codegen.CodeGen.writeBindings(CodeGen.java:1618) > at org.jibx.schema.codegen.CodeGen.generate(CodeGen.java:1808) > at org.jibx.schema.codegen.CodeGen.main(CodeGen.java:2202) > The two schemas in this example are "pvision.xsd" and "geoloc.xsd"; > pvision.xsd references geoloc.xsd. It is possible (though cumbersome) to > work around this bug by generating the code and binding XMLs in two steps. > 1. Generate the code for the referenced schema, using the -b switch to set a > different filename for the generated bindings XML. > 2. Generate the code for the referencing schema, using the -i switch to pull > in the bindings XML from the previous step. > This workaround rapidly becomes onerous when more than two schemas are > involved. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------------ RSA(R) Conference 2012 Save $700 by Nov 18 Register now http://p.sf.net/sfu/rsa-sfdev2dev1 _______________________________________________ jibx-devs mailing list jibx-devs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jibx-devs