DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7557>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7557

when using simpleType, wsdd type mapping is not interpreted correctly

           Summary: when using simpleType, wsdd type mapping is not
                    interpreted correctly
           Product: Axis
           Version: beta-1
          Platform: Other
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: Basic Architecture
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


in my schema definition i use my own simple types to wrap arround schema 
tpes like long, etc. 
wsdl2java generates type mappings for each of these simple types: 
e.g. customerID to java:long : 
        qname="ns:customerID" 
        type="java:long" 

whith this i get an ClassNotFoundException in 
org.apache.axis.deployment.wsdd.WSDDTypeMapping, method 
getLanguageSpecificType(), line 230 which is rethrown 
as WSDDException in org.apache.axis.deployment.wsdd.WSDDService, method 
deployTypeMapping, line 405 
I get this when calling the service the fisrt time 

the problem seems to be that method  getLanguageSpecificType() 
tries to load a Class even if typeQName.getLocalPart() contains the name 
of a primitive java type. 

as a workarround i inserted the following coding into method 
getLanguageSpecificType() at line 229: 

            java.util.Map primitiveTypes = new java.util.HashMap(); 
            primitiveTypes.put("boolean", boolean.class ); 
            primitiveTypes.put("double", double.class ); 
            primitiveTypes.put("float", float.class ); 
            primitiveTypes.put("int", int.class ); 
            primitiveTypes.put("long", long.class ); 
            primitiveTypes.put("short", short.class ); 
            primitiveTypes.put("byte", byte.class ); 
            Class primClass = 
in my schema definition i use my own simple types to wrap arround schema 
tpes like long, etc. 
wsdl2java generates type mappings for each of these simple types: 
e.g. customerID to java:long : 
        qname="ns:customerID" 
        type="java:long" 

whith this i get an ClassNotFoundException in 
org.apache.axis.deployment.wsdd.WSDDTypeMapping, method 
getLanguageSpecificType(), line 230 which is rethrown 
as WSDDException in org.apache.axis.deployment.wsdd.WSDDService, method 
deployTypeMapping, line 405 
I get this when calling the service the fisrt time 

the problem seems to be that method  getLanguageSpecificType() 
tries to load a Class even if typeQName.getLocalPart() contains the name 
of a primitive java type. 

as a workarround i inserted the following coding into method 
getLanguageSpecificType() at line 229: 

            java.util.Map primitiveTypes = new java.util.HashMap(); 
            primitiveTypes.put("boolean", boolean.class ); 
            primitiveTypes.put("double", double.class ); 
            primitiveTypes.put("float", float.class ); 
            primitiveTypes.put("int", int.class ); 
            primitiveTypes.put("long", long.class ); 
            primitiveTypes.put("short", short.class ); 
            primitiveTypes.put("byte", byte.class ); 
            Class primClass = 
               (Class) primitiveTypes.get( typeQName.getLocalPart() ); 
            if ( primClass != null ) { 
                return primClass; 
            } 

with this workarround it works

the wsdl i currently use is very complex, because it imports serveral schema 
definition files ( not wsdl files ), so i didn't attach it.
if you need an wsdl-example pls. email me. i will try to reproduce the error 
then with a simpler example, because i think the problem is not the schema 
includes but the use of simple types as wrappers to other sinple types like 
xsd:long

Reply via email to