Hi Linus, I think the Axis2 code generation just doesn't recognize Enum classes. I'll try to get a fix in for this soon.
- Dennis Dennis M. Sosnoski SOA and Web Services in Java Training and Consulting http://www.sosnoski.com - http://www.sosnoski.co.nz Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117 Linus Kamb wrote: > Hi Dennis. > > I pulled down and built your changes to the 1.2 branch, and that does > indeed fix the exception thrown in the CodeGen phase. > > However, I'm still getting the Skeleton interface defined with the > parameter as a String. Is it possible to get that to come out as the > Enum type? > > I figure maybe it's in the xsl template, and I looked at that a bit, but > it quickly boggled my mind... > > Or maybe I've done my binding wrong somehow. But I don't quite see > where I'd put that in, since it's unwrapped, there is no binding for the > method. > > Thanks, > Linus > > > Andrey A. Chujko wrote: > >> Hello Dennis, >> >> The new issue is here https://issues.apache.org/jira/browse/AXIS2-2670. >> Though, I had solved the problem with wrapping all the input parameters into >> a wrapper/filter object, which could be utilized with all GetProducs family >> routines. >> >> Kind regards, >> Andrey. >> >> Dennis Sosnoski wrote: >> >> >>> Hi Andrey, >>> >>> It looks like there's a problem in the simpleType reference handling >>> with the Axis2 JiBX unwrapped code generation. This is something I >>> haven't tried before, but I'll look into it. In the meantime, it'd be >>> good if you could report this as an issue in the Axis2 Jira at >>> https://issues.apache.org/jira/browse/AXIS2 >>> >>> - Dennis >>> >>> Dennis M. Sosnoski >>> SOA and Web Services in Java >>> Training and Consulting >>> http://www.sosnoski.com - http://www.sosnoski.co.nz >>> Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117 >>> >>> >>> >>> Andrey A. Chujko wrote: >>> >>> >>>> Hi all, >>>> >>>> I have a detached enum definition. >>>> >>>> ... >>>> <s:element name="GetProducs"> >>>> <s:complexType> >>>> <s:sequence> >>>> <s:element minOccurs="0" maxOccurs="1" name="guid" type="s:string" /> >>>> <s:element minOccurs="1" maxOccurs="1" name="id" type="s:int" /> >>>> <s:element minOccurs="1" maxOccurs="1" name="abc" type="tns:ABCEnum" >>>> /> >>>> </s:sequence> >>>> </s:complexType> >>>> </s:element> >>>> <s:simpleType name="ABCEnum"> >>>> <s:restriction base="s:string"> >>>> <s:enumeration value="AAA" /> >>>> <s:enumeration value="BBB" /> >>>> <s:enumeration value="CCC" /> >>>> </s:restriction> >>>> </s:simpleType> >>>> ... >>>> >>>> >>>> [echo] Running WSDL2Java task >>>> [mkdir] Created dir: /home/zzz/proj/client/gen >>>> [java] Exception in thread "main" >>>> org.apache.axis2.wsdl.codegen.CodeGenerationException: >>>> java.lang.RuntimeException: Cannot unwrap element >>>> {http://an.ns.com/}GetProducs: no format definition found for type >>>> {http://an.ns.com/}ABCEnum (used by element {http://an.ns.com/}abc) >>>> [java] at >>>> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:256) >>>> [java] at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:32) >>>> [java] at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21) >>>> [java] Caused by: java.lang.RuntimeException: Cannot unwrap element >>>> {http://an.ns.com/}GetProducs: no format definition found for type >>>> {http://an.ns.com/}ABCEnum (used by element {http://an.ns.com/}abc) >>>> [java] at >>>> org.apache.axis2.jibx.CodeGenerationUtility.unwrapMessage(CodeGenerationUtility.java:780) >>>> [java] at >>>> org.apache.axis2.jibx.CodeGenerationUtility.engage(CodeGenerationUtility.java:382) >>>> [java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native >>>> Method) >>>> [java] at >>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) >>>> [java] at >>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) >>>> [java] at java.lang.reflect.Method.invoke(Method.java:585) >>>> [java] at >>>> org.apache.axis2.wsdl.codegen.extension.JiBXExtension.engage(JiBXExtension.java:74) >>>> [java] at >>>> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:209) >>>> [java] ... 2 more >>>> >>>> Could you please advice me how can I solve this issue? >>>> >>>> Thanks in advance, >>>> Andrey. >>>> >>>> >>>> ------------------------------------------------------------------------- >>>> This SF.net email is sponsored by DB2 Express >>>> Download DB2 Express C - the FREE version of DB2 express and take >>>> control of your XML. No limits. Just data. Click to get it now. >>>> http://sourceforge.net/powerbar/db2/ >>>> _______________________________________________ >>>> jibx-users mailing list >>>> [email protected] >>>> https://lists.sourceforge.net/lists/listinfo/jibx-users >>>> >>>> >>>> >>>> >>> ------------------------------------------------------------------------- >>> This SF.net email is sponsored by DB2 Express >>> Download DB2 Express C - the FREE version of DB2 express and take >>> control of your XML. No limits. Just data. Click to get it now. >>> http://sourceforge.net/powerbar/db2/ >>> >>> >> ------------------------------------------------------------------------- >> This SF.net email is sponsored by DB2 Express >> Download DB2 Express C - the FREE version of DB2 express and take >> control of your XML. No limits. Just data. Click to get it now. >> http://sourceforge.net/powerbar/db2/ >> _______________________________________________ >> jibx-users mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/jibx-users >> >> > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. > Still grepping through log files to find problems? Stop. > Now Search log events and configuration files using AJAX and a browser. > Download your FREE copy of Splunk now >> http://get.splunk.com/ > _______________________________________________ > jibx-users mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/jibx-users > > ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ jibx-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jibx-users
