RE: Question about generating Java Source Code from XML Schemas

2013-08-21 Thread Paul Gillen
leDownloadUrls(); BindingConfig config = new BindingConfig(); XmlBeans.compileXmlBeans("TypeName", null, new XmlObject[] { xsdo }, config, null, filer, options); } } -Original Message----- From: Michael Szalay [mailto:michael.sza...@abacus.ch]

Re: Question about generating Java Source Code from XML Schemas

2013-08-21 Thread Michael Bishop
I think I can answer your first question. From what I recall in parsing/reading documents, InputStream is a poor choice for XML documents that include other documents. An InputStream object can't tell you where its source is. Therefore, there is no way to find relative paths. I would try the follow

Question about generating Java Source Code from XML Schemas

2013-08-21 Thread Michael Szalay
Hi all I have some xsd schemas in my source tree and I want to generate java sources with XML Beans. I cannot use ant or maven task, I have to do it in plain java. I use the following java code: final InputStream schema1Stream = BeanGenerator.class.getResourceAsStream("xsd/schema1.xsd"); final X