You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by di...@apache.org on 2006/10/30 07:17:17 UTC

svn commit: r469076 - in /webservices/axis2/branches/java/1_1/modules/xmlbeans: src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java test-resources/BookQuote.wsdl test-resources/BookQuote2.wsdl

Author: dims
Date: Sun Oct 29 22:17:16 2006
New Revision: 469076

URL: http://svn.apache.org/viewvc?view=rev&rev=469076
Log:
src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java

Modified:
    webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
    webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
    webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl

Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java?view=diff&rev=469076&r1=469075&r2=469076
==============================================================================
--- webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java (original)
+++ webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java Sun Oct 29 22:17:16 2006
@@ -180,11 +180,19 @@
             cgconfig.putProperty(Constants.PLAIN_BASE_64_PROPERTY_KEY,
                     findPlainBase64Types(sts));
 
+            SchemaTypeSystem internal = XmlBeans.getBuiltinTypeSystem();
+            SchemaType[] schemaTypes = internal.globalTypes();
+            for (int j = 0; j < schemaTypes.length; j++) {
+                mapper.addTypeMappingName(schemaTypes[j].getName(),
+                        schemaTypes[j].getFullJavaName());
+
+            }
+
             //get the schematypes and add the document types to the type mapper
-            SchemaType[] schemaType = sts.documentTypes();
-            for (int j = 0; j < schemaType.length; j++) {
-                mapper.addTypeMappingName(schemaType[j].getDocumentElementName(),
-                        schemaType[j].getFullJavaName());
+            schemaTypes = sts.documentTypes();
+            for (int j = 0; j < schemaTypes.length; j++) {
+                mapper.addTypeMappingName(schemaTypes[j].getDocumentElementName(),
+                        schemaTypes[j].getFullJavaName());
 
             }
 

Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl?view=diff&rev=469076&r1=469075&r2=469076
==============================================================================
--- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl (original)
+++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl Sun Oct 29 22:17:16 2006
@@ -1,53 +1,53 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
-    <message name="BookQuote_getBookPrice">
-        <part name="isbn" type="xsd:anyType"/>
-        <part name="number" type="xsd:int"/>
-    </message>
-    <message name="BookQuote_getBookPriceResponse">
-        <part name="result" type="xsd:anyType"/>
-    </message>
-    <message name="InvalidIsbnFault">
-        <part name="message" type="xsd:anyType"/>
-    </message>
-    <portType name="BookQuote">
-        <operation name="getBookPrice">
-            <input message="mh:BookQuote_getBookPrice"/>
-            <output message="mh:BookQuote_getBookPriceResponse"/>
-            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
-        </operation>
-        <operation name="getBookPriceNonRobust">
-            <input message="mh:BookQuote_getBookPrice"/>
-            <output message="mh:BookQuote_getBookPriceResponse"/>
-        </operation>
-    </portType>
-
-    <binding name="BookQuoteBinding" type="mh:BookQuote">
-        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
-        <operation name="getBookPrice">
-            <soap:operation soapAction="myAction"/>
-            <input>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </input>
-            <output>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </output>
-        </operation>
-
-        <operation name="getBookPriceNonRobust">
-            <soap:operation soapAction="myAction2"/>
-            <input>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </input>
-            <output>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </output>
-        </operation>
-    </binding>
-
-    <service name="BookQuoteService">
-        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
-            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
-        </port>
-    </service>
+	<message name="BookQuote_getBookPrice">
+		<part name="isbn" type="xsd:anyType"/>
+		<part name="number" type="xsd:int"/>
+	</message>
+	<message name="BookQuote_getBookPriceResponse">
+		<part name="result" type="xsd:anyType"/>
+	</message>
+	<message name="InvalidIsbnFault">
+		<part name="message" type="xsd:anyType"/>
+	</message>
+	<portType name="BookQuote">
+		<operation name="getBookPrice">
+			<input message="mh:BookQuote_getBookPrice"/>
+			<output message="mh:BookQuote_getBookPriceResponse"/>
+			<fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
+		</operation>
+		<operation name="getBookPriceNonRobust">
+			<input message="mh:BookQuote_getBookPrice"/>
+			<output message="mh:BookQuote_getBookPriceResponse"/>
+		</operation>
+	</portType>
+	<binding name="BookQuoteBinding" type="mh:BookQuote">
+		<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+		<operation name="getBookPrice">
+			<soap:operation soapAction="myAction"/>
+			<input>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</input>
+			<output>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</output>
+			<fault name="InvalidIsbnFault">
+				<soap:fault name="InvalidIsbnFault" use="literal"/>
+			</fault>	
+		</operation>
+		<operation name="getBookPriceNonRobust">
+			<soap:operation soapAction="myAction2"/>
+			<input>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</input>
+			<output>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</output>
+		</operation>
+	</binding>
+	<service name="BookQuoteService">
+		<port name="BookQuotePort" binding="mh:BookQuoteBinding">
+			<soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
+		</port>
+	</service>
 </definitions>

Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl?view=diff&rev=469076&r1=469075&r2=469076
==============================================================================
--- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl (original)
+++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl Sun Oct 29 22:17:16 2006
@@ -1,53 +1,53 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
-    <message name="BookQuote_getBookPrice">
-        <part name="isbn" type="xsd:string"/>
-        <part name="number" type="xsd:int"/>
-    </message>
-    <message name="BookQuote_getBookPriceResponse">
-        <part name="result" type="xsd:string"/>
-    </message>
-    <message name="InvalidIsbnFault">
-        <part name="message" type="xsd:string"/>
-    </message>
-    <portType name="BookQuote">
-        <operation name="getBookPrice">
-            <input message="mh:BookQuote_getBookPrice"/>
-            <output message="mh:BookQuote_getBookPriceResponse"/>
-            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
-        </operation>
-        <operation name="getBookPriceNonRobust">
-            <input message="mh:BookQuote_getBookPrice"/>
-            <output message="mh:BookQuote_getBookPriceResponse"/>
-        </operation>
-    </portType>
-
-    <binding name="BookQuoteBinding" type="mh:BookQuote">
-        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
-        <operation name="getBookPrice">
-            <soap:operation soapAction="myAction"/>
-            <input>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </input>
-            <output>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </output>
-        </operation>
-
-        <operation name="getBookPriceNonRobust">
-            <soap:operation soapAction="myAction2"/>
-            <input>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </input>
-            <output>
-                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
-            </output>
-        </operation>
-    </binding>
-
-    <service name="BookQuoteService">
-        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
-            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
-        </port>
-    </service>
+	<message name="BookQuote_getBookPrice">
+		<part name="isbn" type="xsd:string"/>
+		<part name="number" type="xsd:int"/>
+	</message>
+	<message name="BookQuote_getBookPriceResponse">
+		<part name="result" type="xsd:string"/>
+	</message>
+	<message name="InvalidIsbnFault">
+		<part name="message" type="xsd:string"/>
+	</message>
+	<portType name="BookQuote">
+		<operation name="getBookPrice">
+			<input message="mh:BookQuote_getBookPrice"/>
+			<output message="mh:BookQuote_getBookPriceResponse"/>
+			<fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
+		</operation>
+		<operation name="getBookPriceNonRobust">
+			<input message="mh:BookQuote_getBookPrice"/>
+			<output message="mh:BookQuote_getBookPriceResponse"/>
+		</operation>
+	</portType>
+	<binding name="BookQuoteBinding" type="mh:BookQuote">
+		<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+		<operation name="getBookPrice">
+			<soap:operation soapAction="myAction"/>
+			<input>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</input>
+			<output>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</output>
+			<fault name="InvalidIsbnFault">
+				<soap:fault name="InvalidIsbnFault" use="literal"/>
+			</fault>	
+		</operation>
+		<operation name="getBookPriceNonRobust">
+			<soap:operation soapAction="myAction2"/>
+			<input>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</input>
+			<output>
+				<soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
+			</output>
+		</operation>
+	</binding>
+	<service name="BookQuoteService">
+		<port name="BookQuotePort" binding="mh:BookQuoteBinding">
+			<soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
+		</port>
+	</service>
 </definitions>



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Re: svn commit: r469076 - in /webservices/axis2/branches/java/1_1/modules/xmlbeans: src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java test-resources/BookQuote.wsdl test-resources/BookQuote2.wsdl

Posted by Davanum Srinivas <da...@gmail.com>.
Sorry about the bad commit comment. It should be.

- Fix the binding/operation/fault for both the book*.wsdl
- Add built-in types of xmlbeans to the typemapping.

thanks,
dims

On 10/30/06, dims@apache.org <di...@apache.org> wrote:
> Author: dims
> Date: Sun Oct 29 22:17:16 2006
> New Revision: 469076
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=469076
> Log:
> src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
>
> Modified:
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java Sun Oct 29 22:17:16 2006
> @@ -180,11 +180,19 @@
>              cgconfig.putProperty(Constants.PLAIN_BASE_64_PROPERTY_KEY,
>                      findPlainBase64Types(sts));
>
> +            SchemaTypeSystem internal = XmlBeans.getBuiltinTypeSystem();
> +            SchemaType[] schemaTypes = internal.globalTypes();
> +            for (int j = 0; j < schemaTypes.length; j++) {
> +                mapper.addTypeMappingName(schemaTypes[j].getName(),
> +                        schemaTypes[j].getFullJavaName());
> +
> +            }
> +
>              //get the schematypes and add the document types to the type mapper
> -            SchemaType[] schemaType = sts.documentTypes();
> -            for (int j = 0; j < schemaType.length; j++) {
> -                mapper.addTypeMappingName(schemaType[j].getDocumentElementName(),
> -                        schemaType[j].getFullJavaName());
> +            schemaTypes = sts.documentTypes();
> +            for (int j = 0; j < schemaTypes.length; j++) {
> +                mapper.addTypeMappingName(schemaTypes[j].getDocumentElementName(),
> +                        schemaTypes[j].getFullJavaName());
>
>              }
>
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl Sun Oct 29 22:17:16 2006
> @@ -1,53 +1,53 @@
>  <?xml version="1.0" encoding="UTF-8"?>
>  <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
> -    <message name="BookQuote_getBookPrice">
> -        <part name="isbn" type="xsd:anyType"/>
> -        <part name="number" type="xsd:int"/>
> -    </message>
> -    <message name="BookQuote_getBookPriceResponse">
> -        <part name="result" type="xsd:anyType"/>
> -    </message>
> -    <message name="InvalidIsbnFault">
> -        <part name="message" type="xsd:anyType"/>
> -    </message>
> -    <portType name="BookQuote">
> -        <operation name="getBookPrice">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> -        </operation>
> -        <operation name="getBookPriceNonRobust">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -        </operation>
> -    </portType>
> -
> -    <binding name="BookQuoteBinding" type="mh:BookQuote">
> -        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> -        <operation name="getBookPrice">
> -            <soap:operation soapAction="myAction"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -
> -        <operation name="getBookPriceNonRobust">
> -            <soap:operation soapAction="myAction2"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -    </binding>
> -
> -    <service name="BookQuoteService">
> -        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> -            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> -        </port>
> -    </service>
> +       <message name="BookQuote_getBookPrice">
> +               <part name="isbn" type="xsd:anyType"/>
> +               <part name="number" type="xsd:int"/>
> +       </message>
> +       <message name="BookQuote_getBookPriceResponse">
> +               <part name="result" type="xsd:anyType"/>
> +       </message>
> +       <message name="InvalidIsbnFault">
> +               <part name="message" type="xsd:anyType"/>
> +       </message>
> +       <portType name="BookQuote">
> +               <operation name="getBookPrice">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +                       <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +               </operation>
> +       </portType>
> +       <binding name="BookQuoteBinding" type="mh:BookQuote">
> +               <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> +               <operation name="getBookPrice">
> +                       <soap:operation soapAction="myAction"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +                       <fault name="InvalidIsbnFault">
> +                               <soap:fault name="InvalidIsbnFault" use="literal"/>
> +                       </fault>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <soap:operation soapAction="myAction2"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +               </operation>
> +       </binding>
> +       <service name="BookQuoteService">
> +               <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> +                       <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> +               </port>
> +       </service>
>  </definitions>
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl Sun Oct 29 22:17:16 2006
> @@ -1,53 +1,53 @@
>  <?xml version="1.0" encoding="UTF-8"?>
>  <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
> -    <message name="BookQuote_getBookPrice">
> -        <part name="isbn" type="xsd:string"/>
> -        <part name="number" type="xsd:int"/>
> -    </message>
> -    <message name="BookQuote_getBookPriceResponse">
> -        <part name="result" type="xsd:string"/>
> -    </message>
> -    <message name="InvalidIsbnFault">
> -        <part name="message" type="xsd:string"/>
> -    </message>
> -    <portType name="BookQuote">
> -        <operation name="getBookPrice">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> -        </operation>
> -        <operation name="getBookPriceNonRobust">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -        </operation>
> -    </portType>
> -
> -    <binding name="BookQuoteBinding" type="mh:BookQuote">
> -        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> -        <operation name="getBookPrice">
> -            <soap:operation soapAction="myAction"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -
> -        <operation name="getBookPriceNonRobust">
> -            <soap:operation soapAction="myAction2"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -    </binding>
> -
> -    <service name="BookQuoteService">
> -        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> -            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> -        </port>
> -    </service>
> +       <message name="BookQuote_getBookPrice">
> +               <part name="isbn" type="xsd:string"/>
> +               <part name="number" type="xsd:int"/>
> +       </message>
> +       <message name="BookQuote_getBookPriceResponse">
> +               <part name="result" type="xsd:string"/>
> +       </message>
> +       <message name="InvalidIsbnFault">
> +               <part name="message" type="xsd:string"/>
> +       </message>
> +       <portType name="BookQuote">
> +               <operation name="getBookPrice">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +                       <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +               </operation>
> +       </portType>
> +       <binding name="BookQuoteBinding" type="mh:BookQuote">
> +               <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> +               <operation name="getBookPrice">
> +                       <soap:operation soapAction="myAction"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +                       <fault name="InvalidIsbnFault">
> +                               <soap:fault name="InvalidIsbnFault" use="literal"/>
> +                       </fault>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <soap:operation soapAction="myAction2"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +               </operation>
> +       </binding>
> +       <service name="BookQuoteService">
> +               <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> +                       <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> +               </port>
> +       </service>
>  </definitions>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-cvs-help@ws.apache.org
>
>


-- 
Davanum Srinivas : http://www.wso2.net (Oxygen for Web Service Developers)

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Re: svn commit: r469076 - in /webservices/axis2/branches/java/1_1/modules/xmlbeans: src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java test-resources/BookQuote.wsdl test-resources/BookQuote2.wsdl

Posted by Davanum Srinivas <da...@gmail.com>.
Sorry about the bad commit comment. It should be.

- Fix the binding/operation/fault for both the book*.wsdl
- Add built-in types of xmlbeans to the typemapping.

thanks,
dims

On 10/30/06, dims@apache.org <di...@apache.org> wrote:
> Author: dims
> Date: Sun Oct 29 22:17:16 2006
> New Revision: 469076
>
> URL: http://svn.apache.org/viewvc?view=rev&rev=469076
> Log:
> src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
>
> Modified:
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
>     webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/src/org/apache/axis2/xmlbeans/CodeGenerationUtility.java Sun Oct 29 22:17:16 2006
> @@ -180,11 +180,19 @@
>              cgconfig.putProperty(Constants.PLAIN_BASE_64_PROPERTY_KEY,
>                      findPlainBase64Types(sts));
>
> +            SchemaTypeSystem internal = XmlBeans.getBuiltinTypeSystem();
> +            SchemaType[] schemaTypes = internal.globalTypes();
> +            for (int j = 0; j < schemaTypes.length; j++) {
> +                mapper.addTypeMappingName(schemaTypes[j].getName(),
> +                        schemaTypes[j].getFullJavaName());
> +
> +            }
> +
>              //get the schematypes and add the document types to the type mapper
> -            SchemaType[] schemaType = sts.documentTypes();
> -            for (int j = 0; j < schemaType.length; j++) {
> -                mapper.addTypeMappingName(schemaType[j].getDocumentElementName(),
> -                        schemaType[j].getFullJavaName());
> +            schemaTypes = sts.documentTypes();
> +            for (int j = 0; j < schemaTypes.length; j++) {
> +                mapper.addTypeMappingName(schemaTypes[j].getDocumentElementName(),
> +                        schemaTypes[j].getFullJavaName());
>
>              }
>
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote.wsdl Sun Oct 29 22:17:16 2006
> @@ -1,53 +1,53 @@
>  <?xml version="1.0" encoding="UTF-8"?>
>  <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
> -    <message name="BookQuote_getBookPrice">
> -        <part name="isbn" type="xsd:anyType"/>
> -        <part name="number" type="xsd:int"/>
> -    </message>
> -    <message name="BookQuote_getBookPriceResponse">
> -        <part name="result" type="xsd:anyType"/>
> -    </message>
> -    <message name="InvalidIsbnFault">
> -        <part name="message" type="xsd:anyType"/>
> -    </message>
> -    <portType name="BookQuote">
> -        <operation name="getBookPrice">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> -        </operation>
> -        <operation name="getBookPriceNonRobust">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -        </operation>
> -    </portType>
> -
> -    <binding name="BookQuoteBinding" type="mh:BookQuote">
> -        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> -        <operation name="getBookPrice">
> -            <soap:operation soapAction="myAction"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -
> -        <operation name="getBookPriceNonRobust">
> -            <soap:operation soapAction="myAction2"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -    </binding>
> -
> -    <service name="BookQuoteService">
> -        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> -            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> -        </port>
> -    </service>
> +       <message name="BookQuote_getBookPrice">
> +               <part name="isbn" type="xsd:anyType"/>
> +               <part name="number" type="xsd:int"/>
> +       </message>
> +       <message name="BookQuote_getBookPriceResponse">
> +               <part name="result" type="xsd:anyType"/>
> +       </message>
> +       <message name="InvalidIsbnFault">
> +               <part name="message" type="xsd:anyType"/>
> +       </message>
> +       <portType name="BookQuote">
> +               <operation name="getBookPrice">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +                       <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +               </operation>
> +       </portType>
> +       <binding name="BookQuoteBinding" type="mh:BookQuote">
> +               <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> +               <operation name="getBookPrice">
> +                       <soap:operation soapAction="myAction"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +                       <fault name="InvalidIsbnFault">
> +                               <soap:fault name="InvalidIsbnFault" use="literal"/>
> +                       </fault>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <soap:operation soapAction="myAction2"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +               </operation>
> +       </binding>
> +       <service name="BookQuoteService">
> +               <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> +                       <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> +               </port>
> +       </service>
>  </definitions>
>
> Modified: webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl
> URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl?view=diff&rev=469076&r1=469075&r2=469076
> ==============================================================================
> --- webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl (original)
> +++ webservices/axis2/branches/java/1_1/modules/xmlbeans/test-resources/BookQuote2.wsdl Sun Oct 29 22:17:16 2006
> @@ -1,53 +1,53 @@
>  <?xml version="1.0" encoding="UTF-8"?>
>  <definitions xmlns:mh="http://www.Monson-Haefel.com/jwsbook/BookQuote" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote" name="BookQuote">
> -    <message name="BookQuote_getBookPrice">
> -        <part name="isbn" type="xsd:string"/>
> -        <part name="number" type="xsd:int"/>
> -    </message>
> -    <message name="BookQuote_getBookPriceResponse">
> -        <part name="result" type="xsd:string"/>
> -    </message>
> -    <message name="InvalidIsbnFault">
> -        <part name="message" type="xsd:string"/>
> -    </message>
> -    <portType name="BookQuote">
> -        <operation name="getBookPrice">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -            <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> -        </operation>
> -        <operation name="getBookPriceNonRobust">
> -            <input message="mh:BookQuote_getBookPrice"/>
> -            <output message="mh:BookQuote_getBookPriceResponse"/>
> -        </operation>
> -    </portType>
> -
> -    <binding name="BookQuoteBinding" type="mh:BookQuote">
> -        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> -        <operation name="getBookPrice">
> -            <soap:operation soapAction="myAction"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -
> -        <operation name="getBookPriceNonRobust">
> -            <soap:operation soapAction="myAction2"/>
> -            <input>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </input>
> -            <output>
> -                <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> -            </output>
> -        </operation>
> -    </binding>
> -
> -    <service name="BookQuoteService">
> -        <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> -            <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> -        </port>
> -    </service>
> +       <message name="BookQuote_getBookPrice">
> +               <part name="isbn" type="xsd:string"/>
> +               <part name="number" type="xsd:int"/>
> +       </message>
> +       <message name="BookQuote_getBookPriceResponse">
> +               <part name="result" type="xsd:string"/>
> +       </message>
> +       <message name="InvalidIsbnFault">
> +               <part name="message" type="xsd:string"/>
> +       </message>
> +       <portType name="BookQuote">
> +               <operation name="getBookPrice">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +                       <fault name="InvalidIsbnFault" message="mh:InvalidIsbnFault"/>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <input message="mh:BookQuote_getBookPrice"/>
> +                       <output message="mh:BookQuote_getBookPriceResponse"/>
> +               </operation>
> +       </portType>
> +       <binding name="BookQuoteBinding" type="mh:BookQuote">
> +               <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
> +               <operation name="getBookPrice">
> +                       <soap:operation soapAction="myAction"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +                       <fault name="InvalidIsbnFault">
> +                               <soap:fault name="InvalidIsbnFault" use="literal"/>
> +                       </fault>
> +               </operation>
> +               <operation name="getBookPriceNonRobust">
> +                       <soap:operation soapAction="myAction2"/>
> +                       <input>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </input>
> +                       <output>
> +                               <soap:body use="literal" namespace="http://www.Monson-Haefel.com/jwsbook/BookQuote/BookQuote"/>
> +                       </output>
> +               </operation>
> +       </binding>
> +       <service name="BookQuoteService">
> +               <port name="BookQuotePort" binding="mh:BookQuoteBinding">
> +                       <soap:address location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
> +               </port>
> +       </service>
>  </definitions>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-cvs-help@ws.apache.org
>
>


-- 
Davanum Srinivas : http://www.wso2.net (Oxygen for Web Service Developers)

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org