Мы пытаемся проанализировать XSD и построить из этого лист свойств (с использованием XML-бинов).
Код выглядит следующим образом:
XmlObject xmlObj = XmlObject.Factory.parse( schema );
sts = XmlBeans.compileXsd(new XmlObject[] { xmlObj }, XmlBeans.getBuiltinTypeSystem(), null);
Вызов compileXsd вызывает исключение с сообщением: 0-й предоставленный ввод не является документом схемы: его тип N =
Наша схема выглядит следующим образом:
<schema xmlns:com.co.workflow="com.co.workflow" xmlns:org.data="org.data" targetNamespace="org.activity" version="1.0">
<complexType class="org.activity.ExecuteCommand" name="executeCommand">
<complexContent>
...
...
Трассировка стека:
The 0th supplied input is not a schema document: its type is N=
at org.apache.xmlbeans.impl.schema.SchemaTypeSystemCompiler.compile(SchemaTypeSystemCompiler.java:211)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.xmlbeans.XmlBeans.compileXmlBeans(XmlBeans.java:667)
at org.apache.xmlbeans.XmlBeans.compileXsd(XmlBeans.java:553)
......