You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to generate kotlin code from a xsd schema that is "well formed and valid". There is no registered namespace, so the XmlSlurper constructor is called with true, false. The error messages suggest that the code generation does not cover all use cases:
Warning: validation was turned on but an org.xml.sax.ErrorHandler was not
set, which is probably not what is desired. Parser will use a default
ErrorHandler to print the first 10 errors. Please call
the 'setErrorHandler' method to fix this.
Error: URI=null Line=2: Document root element "xs:schema", must match DOCTYPE root "null".
Error: URI=null Line=2: Document is invalid: no grammar found.
TODO add support to traverseElements() for node type: xs:element
Exception in thread "main" java.lang.IllegalStateException: TODO add support to gatherElements() for node type: xs:element
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83)
at org.codehaus.groovy.reflection.CachedConstructor.doConstructorInvoke(CachedConstructor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrap.callConstructor(ConstructorSite.java:84)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:59)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:238)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:250)
at com.javagen.schema.xml.XmlSchemaNormalizer.traverseElements(XmlSchemaNormalizer.groovy:373)
at com.javagen.schema.xml.XmlSchemaNormalizer$traverseElements$2.callCurrent(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:157)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:169)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy:704)
at com.javagen.schema.xml.XmlSchemaNormalizer$buildSchema$0.callCurrent(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:157)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:177)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy:652)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy)
at com.javagen.schema.xml.XmlSchemaNormalizer$buildSchema.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128)
at com.javagen.schema.kotlin.KotlinGen.gen(KotlinGen.groovy:188)
at com.javagen.schema.kotlin.KotlinGen$gen.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
at com.javagen.schema.kotlin.KotlinGenMain.main(KotlinGenMain.groovy:65)
The text was updated successfully, but these errors were encountered:
I want to generate kotlin code from a xsd schema that is "well formed and valid". There is no registered namespace, so the XmlSlurper constructor is called with true, false. The error messages suggest that the code generation does not cover all use cases:
Warning: validation was turned on but an org.xml.sax.ErrorHandler was not
set, which is probably not what is desired. Parser will use a default
ErrorHandler to print the first 10 errors. Please call
the 'setErrorHandler' method to fix this.
Error: URI=null Line=2: Document root element "xs:schema", must match DOCTYPE root "null".
Error: URI=null Line=2: Document is invalid: no grammar found.
TODO add support to traverseElements() for node type: xs:element
Exception in thread "main" java.lang.IllegalStateException: TODO add support to gatherElements() for node type: xs:element
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83)
at org.codehaus.groovy.reflection.CachedConstructor.doConstructorInvoke(CachedConstructor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrap.callConstructor(ConstructorSite.java:84)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:59)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:238)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:250)
at com.javagen.schema.xml.XmlSchemaNormalizer.traverseElements(XmlSchemaNormalizer.groovy:373)
at com.javagen.schema.xml.XmlSchemaNormalizer$traverseElements$2.callCurrent(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:157)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:169)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy:704)
at com.javagen.schema.xml.XmlSchemaNormalizer$buildSchema$0.callCurrent(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:51)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:157)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:177)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy:652)
at com.javagen.schema.xml.XmlSchemaNormalizer.buildSchema(XmlSchemaNormalizer.groovy)
at com.javagen.schema.xml.XmlSchemaNormalizer$buildSchema.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128)
at com.javagen.schema.kotlin.KotlinGen.gen(KotlinGen.groovy:188)
at com.javagen.schema.kotlin.KotlinGen$gen.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
at com.javagen.schema.kotlin.KotlinGenMain.main(KotlinGenMain.groovy:65)
The text was updated successfully, but these errors were encountered: