geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r125375 - in geronimo/trunk/modules: assembly/src/plan axis axis-builder axis-builder/src axis-builder/src/java axis-builder/src/java/org axis-builder/src/java/org/apache axis-builder/src/java/org/apache/geronimo axis-builder/src/java/org/apache/geronimo/axis axis-builder/src/java/org/apache/geronimo/axis/builder axis-builder/src/test axis-builder/src/test-resources axis-builder/src/test-resources/interop axis-builder/src/test/org axis-builder/src/test/org/apache axis-builder/src/test/org/apache/geronimo axis-builder/src/test/org/apache/geronimo/axis axis-builder/src/test/org/apache/geronimo/axis/builder axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote axis-builder/src/test/org/apache/geronimo/axis/builder/interop axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types axis-builder/src/test/org/apache/geronimo/axis/builder/mock axis/src/etc/META-INF axis/src/java/org/apache/geronimo/axis/client axis/src/test/org/apache/geronimo/axis axis/src/test/org/apache/geronimo/axis/preconditions client-builder/src/java/org/apache/geronimo/client/builder client-builder/src/test/org/apache/geronimo/client/builder connector-builder/src/test/org/apache/geronimo/connector/deployment j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment j2ee-schema jetty-builder/src/java/org/apache/geronimo/jetty/deployment jetty-builder/src/test/org/apache/geronimo/jetty/deployment naming-builder/src/java/org/apache/geronimo/naming/deployment
Date Sun, 16 Jan 2005 23:20:48 GMT
Author: djencks
Date: Sun Jan 16 15:20:45 2005
New Revision: 125375

URL: http://svn.apache.org/viewcvs?view=rev&rev=125375
Log:
Initial implementation of service references using axis and cglib proxies.  Only handles extremely simple types in rpc encoded form. Enable external ws test using axis-builder properties flag: requires patched axis for serialized proxy to work.
Added:
   geronimo/trunk/modules/axis-builder/
   geronimo/trunk/modules/axis-builder/LICENSE.txt
   geronimo/trunk/modules/axis-builder/NOTICE.txt
   geronimo/trunk/modules/axis-builder/geronimo-axis-builder.iml
   geronimo/trunk/modules/axis-builder/maven.xml
   geronimo/trunk/modules/axis-builder/project.properties
   geronimo/trunk/modules/axis-builder/project.xml
   geronimo/trunk/modules/axis-builder/src/
   geronimo/trunk/modules/axis-builder/src/java/
   geronimo/trunk/modules/axis-builder/src/java/org/
   geronimo/trunk/modules/axis-builder/src/java/org/apache/
   geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/
   geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/
   geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/builder/
   geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/builder/AxisBuilder.java
   geronimo/trunk/modules/axis-builder/src/test/
   geronimo/trunk/modules/axis-builder/src/test-resources/
   geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.wsdl
   geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.xml
   geronimo/trunk/modules/axis-builder/src/test-resources/interop/
   geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop-jaxrpcmapping.xml
   geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop.wsdl
   geronimo/trunk/modules/axis-builder/src/test/org/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/ServiceRefTest.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuote.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuoteService.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/InvalidIsbnException.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropLab.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTest2PortType.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTestPortType.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPArrayStruct.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStruct.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStructStruct.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPort.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPortImpl.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockSEIFactory.java
   geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockService.java
   geronimo/trunk/modules/axis/src/etc/META-INF/geronimo-service.xml
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpoint.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpointWrapper.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/NoOverrideCallbackFilter.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/OperationInfo.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactory.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactoryImpl.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SerializableNoOp.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceEndpointMethodInterceptor.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceImpl.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceMethodInterceptor.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceRefAddr.java
   geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/TypeMappingInfo.java
   geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/ServiceReferenceBuilder.java
Modified:
   geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml
   geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml
   geronimo/trunk/modules/axis/maven.xml
   geronimo/trunk/modules/axis/project.xml
   geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
   geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
   geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
   geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java
   geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java
   geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java
   geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
   geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
   geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java
   geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
   geronimo/trunk/modules/j2ee-schema/maven.xml
   geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java
   geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
   geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java

Modified: geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml?view=diff&rev=125375&p1=geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml&r1=125374&p2=geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml&r2=125375
==============================================================================
--- geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml	(original)
+++ geronimo/trunk/modules/assembly/src/plan/j2ee-deployer-plan.xml	Sun Jan 16 15:20:45 2005
@@ -114,7 +114,13 @@
     </dependency>
     <dependency>
          <uri>geronimo/jars/geronimo-client-${geronimo_version}.jar</uri>
-     </dependency>
+    </dependency>
+    <dependency>
+         <uri>geronimo/jars/geronimo-axis-${geronimo_version}.jar</uri>
+    </dependency>
+    <dependency>
+         <uri>geronimo/jars/geronimo-axis-builder-${geronimo_version}.jar</uri>
+    </dependency>
 
 
 
@@ -143,7 +149,8 @@
         <reference name="ConnectorConfigBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=ConnectorBuilder</reference>
         <reference name="ResourceReferenceBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=ConnectorBuilder</reference>
         <reference name="AppClientConfigBuilder">geronimo.server:name=AppClientBuilder,J2EEModule=org/apache/geronimo/J2EEDeployer,*</reference>
-    </gbean>
+        <reference name="ServiceReferenceBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=WebServiceBuilder</reference>
+        </gbean>
 
     <gbean namePart="SecurityService" class="org.apache.geronimo.security.SecurityServiceImpl">
         <attribute name="policyConfigurationFactory" type="java.lang.String">org.apache.geronimo.security.jacc.GeronimoPolicyConfigurationFactory</attribute>
@@ -234,8 +241,12 @@
         <reference name="EJBReferenceBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=GBean,name=ClientEJBReferenceBuilder</reference>
         <reference name="ConnectorModuleBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=ConnectorBuilder</reference>
         <reference name="ResourceReferenceBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=ConnectorBuilder</reference>
+        <reference name="ServiceReferenceBuilder">geronimo.server:J2EEApplication=null,J2EEModule=org/apache/geronimo/J2EEDeployer,J2EEServer=geronimo,j2eeType=ModuleBuilder,name=WebServiceBuilder</reference>
         <reference name="Store">geronimo.server:j2eeType=ConfigurationStore,*</reference>
         <reference name="Repository">*:name=Repository,*</reference>
+    </gbean>
+
+    <gbean namePart="WebServiceBuilder" type="ModuleBuilder" class="org.apache.geronimo.axis.builder.AxisBuilder">
     </gbean>
 
 <!--    <gbean name="openejb.CORBA:type=Compiler,vendor=Ant" class="org.openejb.corba.compiler.AntCompiler"/>-->

Modified: geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml?view=diff&rev=125375&p1=geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml&r1=125374&p2=geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml&r2=125375
==============================================================================
--- geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml	(original)
+++ geronimo/trunk/modules/assembly/src/plan/j2ee-runtime-deployer-plan.xml	Sun Jan 16 15:20:45 2005
@@ -60,12 +60,15 @@
     <dependency>
         <uri>xmlbeans/jars/xbean-apache-${xmlbeans_version}.jar</uri>
     </dependency>
- 
+    <dependency>
+         <uri>geronimo/jars/geronimo-axis-builder-${geronimo_version}.jar</uri>
+    </dependency>
+
 
     <!-- deployer gbeans -->
     <gbean namePart="Deployer" type="Deployer" class="org.apache.geronimo.deployment.Deployer">
-        <reference name="Builders">geronimo.deployer:j2eeType=ConfigBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="Store">geronimo.system:j2eeType=ConfigurationStore,*</reference>
+        <reference name="Builders">geronimo.server:j2eeType=ConfigBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="Store">geronimo.server:j2eeType=ConfigurationStore,*</reference>
     </gbean>
 
     <gbean namePart="ServiceBuilder" type="ConfigBuilder" class="org.apache.geronimo.deployment.service.ServiceConfigBuilder">
@@ -82,20 +85,21 @@
         <attribute name="transactionalTimerObjectName" type="javax.management.ObjectName">geronimo.server:name=TransactionalThreadPooledTimer,*</attribute>
         <attribute name="nonTransactionalTimerObjectName" type="javax.management.ObjectName">geronimo.server:name=NonTransactionalThreadPooledTimer,*</attribute>
         <reference name="Repository">*:name=Repository,*</reference>
-        <reference name="EJBConfigBuilder">geronimo.deployer:name=EJBBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="EJBReferenceBuilder">geronimo.deployer:name=EJBBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="WebConfigBuilder">geronimo.deployer:name=WebBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="ConnectorConfigBuilder">geronimo.deployer:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="ResourceReferenceBuilder">geronimo.deployer:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="AppClientConfigBuilder">geronimo.deployer:name=AppClientBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="EJBConfigBuilder">geronimo.server:name=EJBBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="EJBReferenceBuilder">geronimo.server:name=EJBBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="WebConfigBuilder">geronimo.server:name=WebBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ConnectorConfigBuilder">geronimo.server:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ResourceReferenceBuilder">geronimo.server:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="AppClientConfigBuilder">geronimo.server:name=AppClientBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ServiceReferenceBuilder">geronimo.server:name=WebServiceBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
     </gbean>
 
     <gbean namePart="WebBuilder" type="ModuleBuilder" class="org.apache.geronimo.jetty.deployment.JettyModuleBuilder">
         <attribute name="defaultParentId">org/apache/geronimo/Server</attribute>
         <attribute name="defaultSessionTimeoutSeconds">1800</attribute>
         <attribute name="defaultWelcomeFiles">index.html,index.htm,index.jsp</attribute>
-        <attribute name="jettyContainerObjectName">geronimo.server:name=JettyWebContainer</attribute>
-        <attribute name="defaultServlets">geronimo.deployer:j2eeType=DefaultServlet,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</attribute>
+        <attribute name="jettyContainerObjectName">geronimo.server:name=JettyWebContainer,*</attribute>
+        <attribute name="defaultServlets">geronimo.server:j2eeType=DefaultServlet,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</attribute>
         <reference name="Repository">*:name=Repository,*</reference>
     </gbean>
 
@@ -146,15 +150,18 @@
     <gbean namePart="AppClientBuilder" type="ModuleBuilder" class="org.apache.geronimo.client.builder.AppClientModuleBuilder">
         <attribute name="defaultClientParentId">org/apache/geronimo/Client</attribute>
         <attribute name="defaultServerParentId">org/apache/geronimo/Server</attribute>
-        <attribute name="transactionContextManagerObjectName" type="javax.management.ObjectName">geronimo.client:name=TransactionContextManager,*</attribute>
-        <attribute name="connectionTrackerObjectName" type="javax.management.ObjectName">geronimo.client:name=ConnectionTracker,*</attribute>
-        <reference name="EJBReferenceBuilder">geronimo.deployer:name=ClientEJBReferenceBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="ConnectorModuleBuilder">geronimo.deployer:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="ResourceReferenceBuilder">geronimo.deployer:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
-        <reference name="Store">*:j2eeType=ConfigurationStore</reference>
+        <attribute name="transactionContextManagerObjectName" type="javax.management.ObjectName">geronimo.server:name=TransactionContextManager,*</attribute>
+        <attribute name="connectionTrackerObjectName" type="javax.management.ObjectName">geronimo.server:name=ConnectionTracker,*</attribute>
+        <reference name="EJBReferenceBuilder">geronimo.server:name=ClientEJBReferenceBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ConnectorModuleBuilder">geronimo.server:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ResourceReferenceBuilder">geronimo.server:name=ConnectorBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="ServiceReferenceBuilder">geronimo.server:name=WebServiceBuilder,J2EEModule=org/apache/geronimo/RuntimeDeployer,*</reference>
+        <reference name="Store">*:j2eeType=ConfigurationStore,*</reference>
         <reference name="Repository">*:name=Repository,*</reference>
     </gbean>
 
+    <gbean namePart="WebServiceBuilder" type="ModuleBuilder" class="org.apache.geronimo.axis.builder.AxisBuilder">
+    </gbean>
 <!--    <gbean name="openejb.CORBA:type=Compiler,vendor=Ant" class="org.openejb.corba.compiler.AntCompiler"/>-->
 <!---->
 <!--    <gbean name="openejb.CORBA:type=SkeletonGenerator,vendor=OpenORB" class="org.openejb.corba.compiler.OpenORBSkeletonGenerator">-->

Added: geronimo/trunk/modules/axis-builder/LICENSE.txt
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/LICENSE.txt?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/LICENSE.txt	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,203 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+

Added: geronimo/trunk/modules/axis-builder/NOTICE.txt
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/NOTICE.txt?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/NOTICE.txt	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,3 @@
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).
+

Added: geronimo/trunk/modules/axis-builder/geronimo-axis-builder.iml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/geronimo-axis-builder.iml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/geronimo-axis-builder.iml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,118 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module version="4" relativePaths="false" type="JAVA_MODULE">
+  <component name="ModuleRootManager" />
+  <component name="NewModuleRootManager">
+    <output url="file://$MODULE_DIR$/target/classes" />
+    <output-test url="file://$MODULE_DIR$/target/test-classes" />
+    <content url="file://$MODULE_DIR$">
+      <sourceFolder url="file://$MODULE_DIR$/src/java" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/test" isTestSource="true" />
+      <sourceFolder url="file://$MODULE_DIR$/target/xmlbeans" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/target/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/target/test-classes" />
+    </content>
+    <orderEntry type="jdk" jdkName="java version &quot;1.4.2_05&quot;" />
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module" module-name="geronimo-xmlbeans-plugin" />
+    <orderEntry type="module" module-name="openejb-core" />
+    <orderEntry type="module-library">
+      <library name="xbean-apache">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/xmlbeans/jars/xbean-apache-1.0-DEV.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module" module-name="geronimo-common" />
+    <orderEntry type="module" module-name="geronimo-core" />
+    <orderEntry type="module" module-name="geronimo-deployment" />
+    <orderEntry type="module" module-name="geronimo-j2ee" />
+    <orderEntry type="module" module-name="geronimo-j2ee-builder" />
+    <orderEntry type="module" module-name="geronimo-j2ee-schema" />
+    <orderEntry type="module" module-name="geronimo-kernel" />
+    <orderEntry type="module" module-name="geronimo-naming" />
+    <orderEntry type="module" module-name="geronimo-naming-builder" />
+    <orderEntry type="module" module-name="geronimo-system" />
+    <orderEntry type="module" module-name="geronimo-service-builder" />
+    <orderEntry type="module" module-name="geronimo-transaction" />
+    <orderEntry type="module" module-name="geronimo-spec-jta" />
+    <orderEntry type="module-library">
+      <library name="cglib-full">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/cglib/jars/cglib-full-2.0.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library name="commons-logging">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/commons-logging/jars/commons-logging-1.0.4.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library name="log4j">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/log4j/jars/log4j-1.2.8.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library name="mx4j">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/mx4j/jars/mx4j-2.0.1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library name="junit">
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/junit/jars/junit-3.8.1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module" module-name="geronimo-axis" />
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/axis/jars/axis-1.2-RC1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES>
+          <root url="file:///Users/david/java/axis/axis/ws-axis/java/src" />
+        </SOURCES>
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/axis/jars/axis-jaxrpc-1.2-RC1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar:///Users/david/.maven/repository/axis/jars/axis-wsdl4j-1.2-RC1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntryProperties />
+  </component>
+</module>
+

Added: geronimo/trunk/modules/axis-builder/maven.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/maven.xml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/maven.xml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+
+    Copyright 2004 The Apache Software Foundation
+
+    Licensed under the Apache License, Version 2.0 (the "License");
+    you may not use this file except in compliance with the License.
+    You may obtain a copy of the License at
+  
+       http://www.apache.org/licenses/LICENSE-2.0
+  
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+  
+
+<!-- $Rev: 46019 $ $Date: 2004-09-14 02:56:06 -0700 (Tue, 14 Sep 2004) $ -->
+
+<project default="default"
+    xmlns:j="jelly:core"
+    xmlns:ant="jelly:ant"
+    xmlns:maven="jelly:maven"
+    >
+
+ <!--   <preGoal  name="java:compile">
+        <attainGoal name="axis:axis"/>
+    </preGoal>
+-->
+</project>

Added: geronimo/trunk/modules/axis-builder/project.properties
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/project.properties?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/project.properties	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,12 @@
+##
+## $Rev: 46019 $ $Date: 2004-09-14 02:56:06 -0700 (Tue, 14 Sep 2004) $
+##
+
+maven.repo.remote=http://www.openejb.org/maven, http://www.ibiblio.org/maven
+
+maven.eclipse.classpath.include=target/xmlbeans
+maven.idea.generated.source=xmlbeans
+
+maven.junit.sysproperties=geronimo.run.external.webservicetest
+#Set to true to run test against bea's web service interop server.
+#geronimo.run.external.webservicetest=true
\ No newline at end of file

Added: geronimo/trunk/modules/axis-builder/project.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/project.xml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/project.xml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,258 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+
+    Copyright 2003-2004 The Apache Software Foundation
+
+    Licensed under the Apache License, Version 2.0 (the "License");
+    you may not use this file except in compliance with the License.
+    You may obtain a copy of the License at
+  
+       http://www.apache.org/licenses/LICENSE-2.0
+  
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+  
+<!-- $Rev: 46019 $ $Date: 2004-09-14 02:56:06 -0700 (Tue, 14 Sep 2004) $ -->
+
+<project>
+    <pomVersion>3</pomVersion>
+    <extend>../../etc/project.xml</extend>
+
+    <!-- ===================== -->
+    <!-- Module Identification -->
+    <!-- ===================== -->
+
+    <name>Geronimo :: Axis :: Builder</name>
+    <id>geronimo-axis-builder</id>
+    <shortDescription>Geronimo Axis Builder</shortDescription>
+    <description>Geronimo Axis Builder</description>
+    <url>http://incubator.apache.org/projects/geronimo/axis-builder/</url>
+    <siteDirectory>/www/incubator.apache.org/projects/geronimo/axis-builder</siteDirectory>
+    <distributionDirectory>/www/incubator.apache.org/projects/geronimo/builds/axis-builder</distributionDirectory>
+
+    <package>org.apache.geronimo.axis.builder</package>
+
+    <!-- ============ -->
+    <!-- Dependencies -->
+    <!-- ============ -->
+
+    <dependencies>
+
+        <dependency>
+            <groupId>maven-plugins</groupId>
+            <artifactId>maven-axis-plugin</artifactId>
+            <version>0.5</version>
+            <type>plugin</type>
+        </dependency>
+
+
+        <dependency>
+            <groupId>openejb</groupId>
+            <artifactId>openejb-core</artifactId>
+            <version>${openejb_version}</version>
+        </dependency>
+
+        <!-- needed for xmlbeans runtime-->
+        <dependency>
+            <groupId>xmlbeans</groupId>
+            <artifactId>xbean-apache</artifactId>
+            <version>${xmlbeans_version}</version>
+        </dependency>
+
+        <!-- Module Dependencies -->
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-axis</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-common</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-connector-builder</artifactId>
+            <version>${pom.currentVersion}</version>
+            <properties>
+                <xmlbeans>true</xmlbeans>
+            </properties>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-core</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-deployment</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-j2ee</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-j2ee-builder</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-j2ee-schema</artifactId>
+            <version>${pom.currentVersion}</version>
+            <properties>
+                <xmlbeans>true</xmlbeans>
+            </properties>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-kernel</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-naming</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-naming-builder</artifactId>
+            <version>${pom.currentVersion}</version>
+            <properties>
+                <xmlbeans>true</xmlbeans>
+            </properties>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-system</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-service-builder</artifactId>
+            <version>${pom.currentVersion}</version>
+            <properties>
+                <xmlbeans>true</xmlbeans>
+            </properties>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo</groupId>
+            <artifactId>geronimo-transaction</artifactId>
+            <version>${pom.currentVersion}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>geronimo-spec</groupId>
+            <artifactId>geronimo-spec-jta</artifactId>
+            <version>${geronimo_spec_jta_version}</version>
+        </dependency>
+
+        <!-- Thirdparty -->
+
+        <dependency>
+            <groupId>cglib</groupId>
+            <artifactId>cglib-full</artifactId>
+            <version>${cglib_version}</version>
+            <url>http://cglib.sf.net/</url>
+        </dependency>
+
+        <dependency>
+            <groupId>commons-logging</groupId>
+            <artifactId>commons-logging</artifactId>
+            <version>${commons_logging_version}</version>
+            <url>http://jakarta.apache.org/commons/logging/</url>
+        </dependency>
+
+        <dependency>
+            <groupId>log4j</groupId>
+            <artifactId>log4j</artifactId>
+            <version>${log4j_version}</version>
+            <url>http://jakarta.apache.org/log4j</url>
+        </dependency>
+
+        <dependency>
+            <groupId>mx4j</groupId>
+            <artifactId>mx4j</artifactId>
+            <version>${mx4j_version}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>axis</groupId>
+            <artifactId>axis-jaxrpc</artifactId>
+            <version>${axis_jaxrpc_version}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>axis</groupId>
+            <artifactId>axis</artifactId>
+            <version>${axis_version}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>axis</groupId>
+            <artifactId>commons-discovery</artifactId>
+            <version>${axis_commons_discovery_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>axis</groupId>
+            <artifactId>axis-saaj</artifactId>
+            <version>${axis_saaj_version}</version>
+        </dependency>
+        <dependency>
+            <groupId>axis</groupId>
+            <artifactId>axis-wsdl4j</artifactId>
+            <version>${axis_wsdl4j_version}</version>
+        </dependency>
+
+    </dependencies>
+
+    <build>
+        <resources>
+            <resource>
+                <directory>${basedir}/src/etc</directory>
+            </resource>
+            <resource>
+                <directory>${basedir}/target/xmlbeans</directory>
+                <includes>schema/**</includes>
+            </resource>
+        </resources>
+        <unitTest>
+            <includes>
+                <include>**/*Test.java</include>
+            </includes>
+            <excludes>
+                <exclude>**/Abstract*.java</exclude>
+            </excludes>
+            <resources>
+                <resource>
+                    <directory>${basedir}/src/schema</directory>
+                    <includes>
+                        <include>*.xsd</include>
+                    </includes>
+                </resource>
+                <resource>
+                    <directory>${basedir}/src/test-resources</directory>
+                </resource>
+            </resources>
+        </unitTest>
+    </build>
+</project>

Added: geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/builder/AxisBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/builder/AxisBuilder.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/java/org/apache/geronimo/axis/builder/AxisBuilder.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,446 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder;
+
+import java.beans.Introspector;
+import java.io.IOException;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import javax.naming.Reference;
+import javax.wsdl.Binding;
+import javax.wsdl.BindingInput;
+import javax.wsdl.BindingOperation;
+import javax.wsdl.Definition;
+import javax.wsdl.Message;
+import javax.wsdl.Operation;
+import javax.wsdl.Part;
+import javax.wsdl.Port;
+import javax.wsdl.PortType;
+import javax.wsdl.WSDLException;
+import javax.wsdl.extensions.ExtensibilityElement;
+import javax.wsdl.extensions.soap.SOAPAddress;
+import javax.wsdl.extensions.soap.SOAPBinding;
+import javax.wsdl.extensions.soap.SOAPBody;
+import javax.wsdl.extensions.soap.SOAPOperation;
+import javax.wsdl.factory.WSDLFactory;
+import javax.wsdl.xml.WSDLReader;
+import javax.xml.namespace.QName;
+
+import net.sf.cglib.core.DefaultGeneratorStrategy;
+import net.sf.cglib.core.Signature;
+import net.sf.cglib.proxy.Callback;
+import net.sf.cglib.proxy.Enhancer;
+import net.sf.cglib.proxy.MethodInterceptor;
+import net.sf.cglib.proxy.MethodProxy;
+import net.sf.cglib.proxy.NoOp;
+import net.sf.cglib.reflect.FastClass;
+import net.sf.cglib.reflect.FastConstructor;
+import org.apache.axis.client.Service;
+import org.apache.axis.description.OperationDesc;
+import org.apache.axis.description.ParameterDesc;
+import org.apache.axis.enum.Style;
+import org.apache.axis.enum.Use;
+import org.apache.axis.soap.SOAPConstants;
+import org.apache.geronimo.axis.client.GenericServiceEndpoint;
+import org.apache.geronimo.axis.client.GenericServiceEndpointWrapper;
+import org.apache.geronimo.axis.client.OperationInfo;
+import org.apache.geronimo.axis.client.SEIFactory;
+import org.apache.geronimo.axis.client.SEIFactoryImpl;
+import org.apache.geronimo.axis.client.ServiceEndpointMethodInterceptor;
+import org.apache.geronimo.axis.client.ServiceImpl;
+import org.apache.geronimo.axis.client.ServiceMethodInterceptor;
+import org.apache.geronimo.axis.client.ServiceRefAddr;
+import org.apache.geronimo.axis.client.SerializableNoOp;
+import org.apache.geronimo.axis.client.NoOverrideCallbackFilter;
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.deployment.DeploymentContext;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
+import org.apache.geronimo.naming.reference.RefAddrContentObjectFactory;
+import org.apache.geronimo.xbeans.j2ee.JavaWsdlMappingDocument;
+import org.apache.geronimo.xbeans.j2ee.JavaWsdlMappingType;
+import org.apache.geronimo.gbean.GBeanInfo;
+import org.apache.geronimo.gbean.GBeanInfoBuilder;
+import org.apache.xmlbeans.XmlException;
+import org.objectweb.asm.Type;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class AxisBuilder implements ServiceReferenceBuilder {
+    private static final Class[] SERVICE_CONSTRUCTOR_TYPES = new Class[]{Map.class};
+
+    private static final URI ENHANCED_LOCATION = URI.create("cglib");
+    private static final SOAPConstants SOAP_VERSION = SOAPConstants.SOAP11_CONSTANTS;
+
+    public Reference createServiceReference(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+
+        Enhancer enhancer = new Enhancer();
+        enhancer.setClassLoader(classLoader);
+        enhancer.setSuperclass(ServiceImpl.class);
+        enhancer.setInterfaces(new Class[]{serviceInterface});
+        enhancer.setCallbackFilter(new NoOverrideCallbackFilter(Service.class));
+        enhancer.setCallbackTypes(new Class[]{NoOp.class, MethodInterceptor.class});
+        enhancer.setUseFactory(false);
+        ByteArrayRetrievingGeneratorStrategy strategy = new ByteArrayRetrievingGeneratorStrategy();
+        enhancer.setStrategy(strategy);
+        Class enhanced = enhancer.createClass();
+
+        saveClass(deploymentContext, enhanced.getName(), strategy.getClassBytes());
+        ServiceRefAddr refAddr = new ServiceRefAddr(enhanced, null, null);
+
+        Reference ref = new Reference(null, RefAddrContentObjectFactory.class.getName(), null);
+        ref.add(refAddr);
+
+        return ref;
+    }
+
+    public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+        URL wsdlURL = classLoader.getResource(wsdlURI.toString());
+        WSDLFactory wsdlFactory = null;
+        try {
+            wsdlFactory = WSDLFactory.newInstance();
+        } catch (WSDLException e) {
+            throw new DeploymentException("Could not create WSDLFactory", e);
+        }
+        WSDLReader wsdlReader = wsdlFactory.newWSDLReader();
+        Definition definition = null;
+        try {
+            definition = wsdlReader.readWSDL(wsdlURL.toString());
+        } catch (WSDLException e) {
+            throw new DeploymentException("Failed to read wsdl document", e);
+        }
+
+        URL jaxrpcMappingURL = classLoader.getResource(jaxrpcMappingURI.toString());
+        JavaWsdlMappingDocument mappingDocument = null;
+        try {
+            mappingDocument = JavaWsdlMappingDocument.Factory.parse(jaxrpcMappingURL);
+        } catch (XmlException e) {
+            throw new DeploymentException("Could not parse jaxrpc mapping document", e);
+        } catch (IOException e) {
+            throw new DeploymentException("Could not read jaxrpc mapping document", e);
+        }
+        JavaWsdlMappingType mapping = mappingDocument.getJavaWsdlMapping();
+
+        return createService(serviceInterface, definition, mapping, serviceQName, SOAP_VERSION, deploymentContext, classLoader);
+    }
+
+    public javax.xml.rpc.Service createService(Class serviceInterface, Definition definition, JavaWsdlMappingType mapping, QName serviceQName, SOAPConstants soapVersion, DeploymentContext context, ClassLoader classloader) throws DeploymentException {
+        Map seiFactoryMap = new HashMap();
+        ServiceImpl serviceInstance = createService(serviceInterface, seiFactoryMap, context, classloader);
+        buildSEIFactoryMap(serviceInterface, definition, mapping, serviceQName, soapVersion, seiFactoryMap, serviceInstance, context, classloader);
+        return serviceInstance;
+    }
+
+    public ServiceImpl createService(Class serviceInterface, Map seiFactoryMap, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+
+        Callback callback = new ServiceMethodInterceptor(seiFactoryMap);
+        Callback[] methodInterceptors = new Callback[]{SerializableNoOp.INSTANCE, callback};
+
+        Enhancer enhancer = new Enhancer();
+        enhancer.setClassLoader(classLoader);
+        enhancer.setSuperclass(ServiceImpl.class);
+        enhancer.setInterfaces(new Class[]{serviceInterface});
+        enhancer.setCallbackFilter(new NoOverrideCallbackFilter(Service.class));
+        enhancer.setCallbackTypes(new Class[]{NoOp.class, MethodInterceptor.class});
+        enhancer.setUseFactory(false);
+        ByteArrayRetrievingGeneratorStrategy strategy = new ByteArrayRetrievingGeneratorStrategy();
+        enhancer.setStrategy(strategy);
+        Class serviceClass = enhancer.createClass();
+
+        saveClass(deploymentContext, serviceClass.getName(), strategy.getClassBytes());
+        Enhancer.registerCallbacks(serviceClass, methodInterceptors);
+        FastConstructor constructor = FastClass.create(serviceClass).getConstructor(SERVICE_CONSTRUCTOR_TYPES);
+        try {
+            return (ServiceImpl) constructor.newInstance(new Object[]{seiFactoryMap});
+        } catch (InvocationTargetException e) {
+            throw new DeploymentException("Could not construct service instance", e.getTargetException());
+        }
+    }
+
+    public Map buildSEIFactoryMap(Class serviceInterface, Definition definition, JavaWsdlMappingType mapping, QName serviceQName, SOAPConstants soapVersion, Map seiFactoryMap, ServiceImpl serviceImpl, DeploymentContext context, ClassLoader classloader) throws DeploymentException {
+
+        //find the service we are working with
+        javax.wsdl.Service service = definition.getService(serviceQName);
+        if (service == null) {
+                throw new DeploymentException("No service wsdl for supplied service interface");
+        }
+
+        Map wsdlPortMap = service.getPorts();
+
+        for (Iterator iterator = wsdlPortMap.entrySet().iterator(); iterator.hasNext();) {
+            Map.Entry entry = (Map.Entry) iterator.next();
+            String portName = (String) entry.getKey();
+            Port port = (Port) entry.getValue();
+            Class serviceEndpointInterface = getServiceEndpointInterface(serviceInterface, port);
+            Class enhancedServiceEndpointClass = enhanceServiceEndpointInterface(classloader, serviceEndpointInterface, context);
+
+            SOAPAddress soapAddress = (SOAPAddress) getExtensibilityElement(SOAPAddress.class, port.getExtensibilityElements());
+            String locationURIString = soapAddress.getLocationURI();
+            URL location = null;
+            try {
+                location = new URL(locationURIString);
+            } catch (MalformedURLException e) {
+                throw new DeploymentException("Could not construct web service location URL from " + locationURIString);
+            }
+
+            Binding binding = port.getBinding();
+            SOAPBinding soapBinding = (SOAPBinding) getExtensibilityElement(SOAPBinding.class, binding.getExtensibilityElements());
+//            String transportURI = soapBinding.getTransportURI();
+            String portStyleString = soapBinding.getStyle();
+            Style portStyle = Style.getStyle(portStyleString);
+            PortType portType = binding.getPortType();
+            //port type corresponds to SEI
+            List operations = portType.getOperations();
+            OperationInfo[] operationInfos = new OperationInfo[FastClass.create(enhancedServiceEndpointClass).getMaxIndex() + 1];
+            for (Iterator ops = operations.iterator(); ops.hasNext();) {
+                Operation operation = (Operation) ops.next();
+                Method method = getMethodForOperation(enhancedServiceEndpointClass, operation);
+                BindingOperation bindingOperation = binding.getBindingOperation(operation.getName(), operation.getInput().getName(), operation.getOutput().getName());
+                OperationInfo operationInfo = buildOperationInfo(method, bindingOperation, portStyle, soapVersion);
+                int methodIndex = getSuperIndex(enhancedServiceEndpointClass, method);
+                operationInfos[methodIndex] = operationInfo;
+            }
+            List typeMappings = new ArrayList();
+            SEIFactory seiFactory = createSEIFactory(enhancedServiceEndpointClass, serviceImpl, typeMappings, location, operationInfos, context, classloader);
+            seiFactoryMap.put(portName, seiFactory);
+        }
+        return seiFactoryMap;
+    }
+
+    private Method getMethodForOperation(Class enhancedServiceEndpointClass, Operation operation) throws DeploymentException {
+        Method[] methods = enhancedServiceEndpointClass.getMethods();
+        String opName = operation.getName();
+        Method found = null;
+        for (int i = 0; i < methods.length; i++) {
+            Method method = methods[i];
+            if (method.getName().equals(opName)) {
+                if (found != null) {
+                    throw new DeploymentException("Overloaded methods NYI");
+                }
+                found = method;
+            }
+        }
+        if (found == null) {
+            throw new DeploymentException("No method found for operation named " + opName );
+        }
+        return found;
+    }
+
+    private Class getServiceEndpointInterface(Class serviceInterface, Port port) throws DeploymentException {
+        Method[] methods = serviceInterface.getMethods();
+        String methodName = "get" + port.getName();
+        String serviceEndpointInterfaceShortName = port.getBinding().getPortType().getQName().getLocalPart();
+        for (int i = 0; i < methods.length; i++) {
+            Method method = methods[i];
+            if (method.getName().equals(methodName)) {
+                Class serviceEndpointInterface = method.getReturnType();
+                String longName = serviceEndpointInterface.getName();
+                String name = longName.substring(longName.lastIndexOf('.') + 1);
+                if (!name.equals(serviceEndpointInterfaceShortName) &&
+                       !Introspector.decapitalize(name).equals(serviceEndpointInterfaceShortName)) {
+                    throw new DeploymentException("unexpected name for service endpoint interface, expected ending: " + serviceEndpointInterfaceShortName + ", found " + serviceEndpointInterface.getName());
+                }
+                return serviceEndpointInterface;
+            }
+        }
+        throw new DeploymentException("Could not find service endpoint interface for port named " + port.getName());
+    }
+
+    private ExtensibilityElement getExtensibilityElement(Class clazz, List extensibilityElements) throws DeploymentException {
+        for (Iterator iterator = extensibilityElements.iterator(); iterator.hasNext();) {
+            ExtensibilityElement extensibilityElement = (ExtensibilityElement) iterator.next();
+            if (clazz.isAssignableFrom(extensibilityElement.getClass())) {
+                return extensibilityElement;
+            }
+        }
+        throw new DeploymentException("No element of class " + clazz.getName() + " found");
+    }
+
+//    private String getNamespaceFromPackage(String packageName, JavaWsdlMappingType mapping) throws DeploymentException {
+//        PackageMappingType[] packageMappings = mapping.getPackageMappingArray();
+//        for (int i = 0; i < packageMappings.length; i++) {
+//            PackageMappingType packageMapping = packageMappings[i];
+//            if (packageName.equals(packageMapping.getPackageType().getStringValue().trim())) {
+//                return packageMapping.getNamespaceURI().getStringValue().trim();
+//            }
+//        }
+//        throw new DeploymentException("Package " + packageName + " was not mapped in jaxrpc mapping file");
+//    }
+
+    public SEIFactory createSEIFactory(Class enhancedServiceEndpointClass, ServiceImpl serviceImpl, List typeMappings, URL location, OperationInfo[] operationInfos, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+
+        SEIFactory factory = new SEIFactoryImpl(enhancedServiceEndpointClass, operationInfos, serviceImpl, typeMappings, location);
+        return factory;
+    }
+
+    public Class enhanceServiceEndpointInterface(ClassLoader classLoader, Class serviceEndpointInterface, DeploymentContext deploymentContext) throws DeploymentException {
+        Enhancer enhancer = new Enhancer();
+        enhancer.setClassLoader(classLoader);
+        enhancer.setSuperclass(GenericServiceEndpointWrapper.class);
+        enhancer.setInterfaces(new Class[]{serviceEndpointInterface});
+        enhancer.setCallbackFilter(new NoOverrideCallbackFilter(GenericServiceEndpointWrapper.class));
+        enhancer.setCallbackTypes(new Class[]{NoOp.class, MethodInterceptor.class});
+        enhancer.setUseFactory(false);
+        ByteArrayRetrievingGeneratorStrategy strategy = new ByteArrayRetrievingGeneratorStrategy();
+        enhancer.setStrategy(strategy);
+        Class serviceEndpointClass = enhancer.createClass();
+
+        saveClass(deploymentContext, serviceEndpointClass.getName(), strategy.getClassBytes());
+        return serviceEndpointClass;
+    }
+
+    public OperationInfo buildOperationInfo(Method method, BindingOperation bindingOperation, Style defaultStyle, SOAPConstants soapVersion) throws DeploymentException {
+        Operation operation = bindingOperation.getOperation();
+        String operationName = operation.getName();
+        List order = operation.getParameterOrdering();
+        List parameterList = new ArrayList();
+
+        QName returnType = null;
+        QName returnQName = null;
+
+        Message inputMessage = operation.getInput().getMessage();
+        Message outputMessage = operation.getOutput().getMessage();
+
+        if (order == null || order.size() == 0) {
+            if (outputMessage != null && outputMessage.getParts().size() > 1) {
+//                throw new DeploymentException("We don't handle multiple out params unless you supply the parameter order!");
+                System.out.println("We don't handle multiple out params unless you supply the parameter order!");
+                return null;
+            }
+            Class[] methodParamTypes = method.getParameterTypes();
+            Map inputParts = inputMessage.getParts();
+            if (methodParamTypes.length != inputParts.size()) {
+                throw new DeploymentException("mismatch in parameter counts: method has " + methodParamTypes.length + " whereas the input message has " + inputParts.size());
+            }
+            int i = 0;
+            for (Iterator parts = inputParts.entrySet().iterator(); parts.hasNext();) {
+                //TODO HOW IS THIS SUPPOSED TO WORK????? is the map ordered?
+                Map.Entry entry = (Map.Entry) parts.next();
+                String partName = (String) entry.getKey();
+                Part part = (Part) entry.getValue();
+                QName name = new QName("", partName);
+                byte mode = ParameterDesc.IN;
+                QName typeQName = part.getTypeName() == null ? part.getElementName() : part.getTypeName();
+                Class javaClass = methodParamTypes[i++];
+                //TODO where do the inHeader and outHeader come from?
+                ParameterDesc parameter = new ParameterDesc(name, mode, typeQName, javaClass, false, false);
+                parameterList.add(parameter);
+            }
+            if (outputMessage != null && outputMessage.getParts().size() == 1) {
+                //TODO this might be wrong
+                returnQName = outputMessage.getQName();
+                Part part = (Part)outputMessage.getParts().values().iterator().next();
+                returnType = part.getTypeName() == null? part.getElementName(): part.getTypeName();
+            }
+        } else {
+            //todo fix this
+//            throw new DeploymentException("specified parameter order NYI");
+            System.out.println("specified parameter order NYI");
+            return null;
+        }
+        ParameterDesc[] parameterDescs = (ParameterDesc[]) parameterList.toArray(new ParameterDesc[parameterList.size()]);
+        OperationDesc operationDesc = new OperationDesc(operationName, parameterDescs, returnQName);
+        operationDesc.setReturnType(returnType);
+        Class returnClass = method.getReturnType();
+        operationDesc.setReturnClass(returnClass);
+
+        SOAPOperation soapOperation = (SOAPOperation) getExtensibilityElement(SOAPOperation.class, bindingOperation.getExtensibilityElements());
+        String soapActionURI = soapOperation.getSoapActionURI();
+        String styleString = soapOperation.getStyle();
+        Style style = Style.getStyle(styleString, defaultStyle);
+        BindingInput bindingInput = bindingOperation.getBindingInput();
+        SOAPBody soapBody = (SOAPBody) getExtensibilityElement(SOAPBody.class, bindingInput.getExtensibilityElements());
+        String useString = soapBody.getUse();
+        Use use = Use.getUse(useString);
+        operationDesc.setStyle(style);
+        operationDesc.setUse(use);
+        //TODO add faults
+//        TFault[] faults = tOperation.getFaultArray();
+//        for (int i = 0; i < faults.length; i++) {
+//            TFault fault = faults[i];
+//            QName faultQName = new QName("", fault.getName());
+//            String className = ;
+//            QName faultTypeQName = ;
+//            boolean isComplex = ;
+//            FaultDesc faultDesc = new FaultDesc(faultQName, className, faultTypeQName, isComplex)
+//        }
+        boolean usesSOAPAction = (soapActionURI != null);
+        QName operationQName = new QName("", operation.getName());
+
+        OperationInfo operationInfo = new OperationInfo(operationDesc, usesSOAPAction, soapActionURI, soapVersion, operationQName);
+        return operationInfo;
+    }
+
+    //from openejb MethodHelper
+    public static int getSuperIndex(Class proxyType, Method method) {
+        Signature signature = new Signature(method.getName(), Type.getReturnType(method), Type.getArgumentTypes(method));
+        MethodProxy methodProxy = MethodProxy.find(proxyType, signature);
+        if (methodProxy != null) {
+            return methodProxy.getSuperIndex();
+        }
+        return -1;
+    }
+
+
+
+    private void saveClass(DeploymentContext deploymentContext, String className, byte[] classBytes) throws DeploymentException {
+        try {
+            deploymentContext.addClass(ENHANCED_LOCATION, className, classBytes);
+        } catch (IOException e) {
+            throw new DeploymentException("Could not save enhanced class bytes", e);
+        } catch (URISyntaxException e) {
+            throw new DeploymentException("Could not construct URI for class file", e);
+        }
+    }
+
+    private static class ByteArrayRetrievingGeneratorStrategy extends DefaultGeneratorStrategy {
+
+        private byte[] classBytes;
+
+        public byte[] transform(byte[] b) {
+            classBytes = b;
+            return b;
+        }
+
+        public byte[] getClassBytes() {
+            return classBytes;
+        }
+    }
+
+    public static final GBeanInfo GBEAN_INFO;
+
+    static {
+        GBeanInfoBuilder infoBuilder = new GBeanInfoBuilder(AxisBuilder.class);
+        infoBuilder.addInterface(ServiceReferenceBuilder.class);
+
+        GBEAN_INFO = infoBuilder.getBeanInfo();
+    }
+
+    public static GBeanInfo getGBeanInfo() {
+        return GBEAN_INFO;
+    }
+
+}

Added: geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.wsdl
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.wsdl?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.wsdl	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<definitions name="BookQuote"
+	targetNamespace="http://www.Monson-Haefel.com/jwsbook/BookQuote"
+	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/">
+	
+	<message name="BookQuote_getBookPrice">
+		<part name="isbn" type="xsd:string"/>
+	</message>
+	<message name="BookQuote_getBookPriceResponse">
+		<part name="result" type="xsd:float"/>
+	</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>
+	</portType>
+	<binding name="BookQuoteBinding" type="mh:BookQuote">
+		<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
+		<operation name="getBookPrice">
+			<soap:operation soapAction=""/>
+			<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>
+	</binding>
+	<service name="BookQuoteService">
+		<port name="BookQuotePort" binding="mh:BookQuoteBinding">
+			<soap:address 
+			location="http://www.Monson-Haefel.com/jwsbook/BookQuoteService"/>
+		</port>
+	</service>
+</definitions>
\ No newline at end of file

Added: geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.xml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test-resources/BookQuote.xml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<java-wsdl-mapping
+	xmlns="http://java.sun.com/xml/ns/j2ee"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+	http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd"
+	version="1.1">
+	<package-mapping>
+		<package-type>org.apache.geronimo.axis.builder.bookquote</package-type>
+		<namespaceURI>
+			http://www.Monson-Haefel.com/jwsbook/BookQuote
+		</namespaceURI>
+	</package-mapping>
+</java-wsdl-mapping>
\ No newline at end of file

Added: geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop-jaxrpcmapping.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop-jaxrpcmapping.xml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop-jaxrpcmapping.xml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<java-wsdl-mapping
+	xmlns="http://java.sun.com/xml/ns/j2ee"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
+	http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd"
+	version="1.1">
+	<package-mapping>
+		<package-type>org.apache.geronimo.axis.builder.interop</package-type>
+		<namespaceURI>http://tempuri.org/4s4c/1/3/wsdl/def/interopLab</namespaceURI>
+	</package-mapping>
+	<package-mapping>
+		<package-type>org.apache.geronimo.axis.builder.interop.types</package-type>
+		<namespaceURI>http://tempuri.org/4s4c/1/3/wsdl/types/</namespaceURI>
+	</package-mapping>
+</java-wsdl-mapping>
\ No newline at end of file

Added: geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop.wsdl
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop.wsdl?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test-resources/interop/interop.wsdl	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,825 @@
+<?xml version='1.0'?>
+<definitions name='interopLab'
+    targetNamespace='http://tempuri.org/4s4c/1/3/wsdl/def/interopLab'
+    xmlns='http://schemas.xmlsoap.org/wsdl/'
+    xmlns:xsd='http://www.w3.org/2001/XMLSchema'
+    xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
+    xmlns:soap-enc='http://schemas.xmlsoap.org/soap/encoding/'
+    xmlns:tns='http://tempuri.org/4s4c/1/3/wsdl/def/interopLab'
+    xmlns:mstk2='http://schemas.microsoft.com/soap-toolkit/wsdl-extension'
+    xmlns:w='http://schemas.xmlsoap.org/wsdl/'
+    xmlns:ns1='http://tempuri.org/4s4c/1/3/wsdl/types/'
+    >
+    <types>
+        <schema targetNamespace="http://tempuri.org/4s4c/1/3/wsdl/types/" xmlns="http://www.w3.org/2001/XMLSchema">
+            <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
+            <complexType name="ArrayOfstring">
+                <complexContent>
+                    <restriction base="soap-enc:Array">
+                        <attribute ref="soap-enc:arrayType" w:arrayType="xsd:string[]"/>
+                    </restriction>
+                </complexContent>
+            </complexType>
+            <complexType name="ArrayOfint">
+                <complexContent>
+                    <restriction base="soap-enc:Array">
+                        <attribute ref="soap-enc:arrayType" w:arrayType="xsd:int[]"/>
+                    </restriction>
+                </complexContent>
+            </complexType>
+            <complexType name="ArrayOffloat">
+                <complexContent>
+                    <restriction base="soap-enc:Array">
+                        <attribute ref="soap-enc:arrayType" w:arrayType="xsd:float[]"/>
+                    </restriction>
+                </complexContent>
+            </complexType>
+            <complexType name="SOAPStruct">
+                <all>
+                    <element name="varString" type="xsd:string"/>
+                    <element name="varInt" type="xsd:int"/>
+                    <element name="varFloat" type="xsd:float"/>
+                </all>
+            </complexType>
+            <complexType name="ArrayOfSOAPStruct">
+                <complexContent>
+                    <restriction base="soap-enc:Array">
+                        <attribute ref="soap-enc:arrayType" w:arrayType="ns1:SOAPStruct[]"/>
+                    </restriction>
+                </complexContent>
+            </complexType>
+            <complexType name="SOAPStructStruct">
+                <all>
+                    <element name="varString" type="xsd:string"/>
+                    <element name="varInt" type="xsd:int"/>
+                    <element name="varFloat" type="xsd:float"/>
+                    <element name="varStruct" type="ns1:SOAPStruct"/>
+                </all>
+            </complexType>
+            <complexType name="SOAPArrayStruct">
+                <all>
+                    <element name="varString" type="xsd:string"/>
+                    <element name="varInt" type="xsd:int"/>
+                    <element name="varFloat" type="xsd:float"/>
+                    <element name="varArray" type="ns1:ArrayOfstring"/>
+                </all>
+            </complexType>
+        </schema>
+    </types>
+    <message name="echoVoidRequest"/>
+    <message name="echoVoidResponse"/>
+    <message name="echoStringRequest">
+        <part name="inputString" type="xsd:string"/>
+    </message>
+    <message name="echoStringResponse">
+        <part name="outputString" type="xsd:string"/>
+    </message>
+    <message name="echoStringArrayRequest">
+        <part name="inputStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoStringArrayResponse">
+        <part name="outputStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoIntegerRequest">
+        <part name="inputInteger" type="xsd:int"/>
+    </message>
+    <message name="echoIntegerResponse">
+        <part name="outputInteger" type="xsd:int"/>
+    </message>
+    <message name="echoIntegerArrayRequest">
+        <part name="inputIntegerArray" type="ns1:ArrayOfint"/>
+    </message>
+    <message name="echoIntegerArrayResponse">
+        <part name="outputIntegerArray" type="ns1:ArrayOfint"/>
+    </message>
+    <message name="echoFloatRequest">
+        <part name="inputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoFloatResponse">
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoFloatArrayRequest">
+        <part name="inputFloatArray" type="ns1:ArrayOffloat"/>
+    </message>
+    <message name="echoFloatArrayResponse">
+        <part name="outputFloatArray" type="ns1:ArrayOffloat"/>
+    </message>
+    <message name="echoStructRequest">
+        <part name="inputStruct" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echoStructResponse">
+        <part name="outputStruct" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echoStructArrayRequest">
+        <part name="inputStructArray" type="ns1:ArrayOfSOAPStruct"/>
+    </message>
+    <message name="echoStructArrayResponse">
+        <part name="outputStructArray" type="ns1:ArrayOfSOAPStruct"/>
+    </message>
+    <message name="echoDateRequest">
+        <part name="inputDate" type="xsd:dateTime"/>
+    </message>
+    <message name="echoDateResponse">
+        <part name="outputDate" type="xsd:dateTime"/>
+    </message>
+    <message name="echoBase64Request">
+        <part name="inputBase64" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoBase64Response">
+        <part name="outputBase64" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoBooleanRequest">
+        <part name="inputBoolean" type="xsd:boolean"/>
+    </message>
+    <message name="echoBooleanResponse">
+        <part name="return" type="xsd:boolean"/>
+    </message>
+    <message name="echoDecimalRequest">
+        <part name="inputDecimal" type="xsd:decimal"/>
+    </message>
+    <message name="echoDecimalResponse">
+        <part name="return" type="xsd:decimal"/>
+    </message>
+    <message name="echoHexBinaryRequest">
+        <part name="inputHexBinary" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoHexBinaryResponse">
+        <part name="return" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoStructAsSimpleTypesRequest">
+        <part name="inputStruct" type="ns1:SOAPStruct"/>
+        <part name="outputString" type="xsd:string"/>
+        <part name="outputInteger" type="xsd:int"/>
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoStructAsSimpleTypesResponse">
+        <part name="outputString" type="xsd:string"/>
+        <part name="outputInteger" type="xsd:int"/>
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoSimpleTypesAsStructRequest">
+        <part name="inputString" type="xsd:string"/>
+        <part name="inputInteger" type="xsd:int"/>
+        <part name="inputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoSimpleTypesAsStructResponse">
+        <part name="return" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echo2DStringArrayRequest">
+        <part name="input2DStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echo2DStringArrayResponse">
+        <part name="return" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoNestedStructRequest">
+        <part name="inputStruct" type="ns1:SOAPStructStruct"/>
+    </message>
+    <message name="echoNestedStructResponse">
+        <part name="return" type="ns1:SOAPStructStruct"/>
+    </message>
+    <message name="echoNestedArrayRequest">
+        <part name="inputStruct" type="ns1:SOAPArrayStruct"/>
+    </message>
+    <message name="echoNestedArrayResponse">
+        <part name="return" type="ns1:SOAPArrayStruct"/>
+    </message>
+    <message name="echoVoidRequestA"/>
+    <message name="echoVoidResponseA"/>
+    <message name="echoStringRequestA">
+        <part name="inputString" type="xsd:string"/>
+    </message>
+    <message name="echoStringResponseA">
+        <part name="outputString" type="xsd:string"/>
+    </message>
+    <message name="echoStringArrayRequestA">
+        <part name="inputStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoStringArrayResponseA">
+        <part name="outputStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoIntegerRequestA">
+        <part name="inputInteger" type="xsd:int"/>
+    </message>
+    <message name="echoIntegerResponseA">
+        <part name="outputInteger" type="xsd:int"/>
+    </message>
+    <message name="echoIntegerArrayRequestA">
+        <part name="inputIntegerArray" type="ns1:ArrayOfint"/>
+    </message>
+    <message name="echoIntegerArrayResponseA">
+        <part name="outputIntegerArray" type="ns1:ArrayOfint"/>
+    </message>
+    <message name="echoFloatRequestA">
+        <part name="inputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoFloatResponseA">
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoFloatArrayRequestA">
+        <part name="inputFloatArray" type="ns1:ArrayOffloat"/>
+    </message>
+    <message name="echoFloatArrayResponseA">
+        <part name="outputFloatArray" type="ns1:ArrayOffloat"/>
+    </message>
+    <message name="echoStructRequestA">
+        <part name="inputStruct" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echoStructResponseA">
+        <part name="outputStruct" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echoStructArrayRequestA">
+        <part name="inputStructArray" type="ns1:ArrayOfSOAPStruct"/>
+    </message>
+    <message name="echoStructArrayResponseA">
+        <part name="outputStructArray" type="ns1:ArrayOfSOAPStruct"/>
+    </message>
+    <message name="echoDateRequestA">
+        <part name="inputDate" type="xsd:dateTime"/>
+    </message>
+    <message name="echoDateResponseA">
+        <part name="outputDate" type="xsd:dateTime"/>
+    </message>
+    <message name="echoBase64RequestA">
+        <part name="inputBase64" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoBase64ResponseA">
+        <part name="outputBase64" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoBooleanRequestA">
+        <part name="inputBoolean" type="xsd:boolean"/>
+    </message>
+    <message name="echoBooleanResponseA">
+        <part name="return" type="xsd:boolean"/>
+    </message>
+    <message name="echoDecimalRequestA">
+        <part name="inputDecimal" type="xsd:decimal"/>
+    </message>
+    <message name="echoDecimalResponseA">
+        <part name="return" type="xsd:decimal"/>
+    </message>
+    <message name="echoHexBinaryRequestA">
+        <part name="inputHexBinary" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoHexBinaryResponseA">
+        <part name="return" type="xsd:base64Binary"/>
+    </message>
+    <message name="echoStructAsSimpleTypesRequestA">
+        <part name="inputStruct" type="ns1:SOAPStruct"/>
+        <part name="outputString" type="xsd:string"/>
+        <part name="outputInteger" type="xsd:int"/>
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoStructAsSimpleTypesResponseA">
+        <part name="outputString" type="xsd:string"/>
+        <part name="outputInteger" type="xsd:int"/>
+        <part name="outputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoSimpleTypesAsStructRequestA">
+        <part name="inputString" type="xsd:string"/>
+        <part name="inputInteger" type="xsd:int"/>
+        <part name="inputFloat" type="xsd:float"/>
+    </message>
+    <message name="echoSimpleTypesAsStructResponseA">
+        <part name="return" type="ns1:SOAPStruct"/>
+    </message>
+    <message name="echo2DStringArrayRequestA">
+        <part name="input2DStringArray" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echo2DStringArrayResponseA">
+        <part name="return" type="ns1:ArrayOfstring"/>
+    </message>
+    <message name="echoNestedStructRequestA">
+        <part name="inputStruct" type="ns1:SOAPStructStruct"/>
+    </message>
+    <message name="echoNestedStructResponseA">
+        <part name="return" type="ns1:SOAPStructStruct"/>
+    </message>
+    <message name="echoNestedArrayRequestA">
+        <part name="inputStruct" type="ns1:SOAPArrayStruct"/>
+    </message>
+    <message name="echoNestedArrayResponseA">
+        <part name="return" type="ns1:SOAPArrayStruct"/>
+    </message>
+    <portType name="interopTest2PortType">
+        <operation name="echoVoid">
+            <input message="tns:echoVoidRequest"/>
+            <output message="tns:echoVoidResponse"/>
+        </operation>
+        <operation name="echoString">
+            <input message="tns:echoStringRequest"/>
+            <output message="tns:echoStringResponse"/>
+        </operation>
+        <operation name="echoStringArray">
+            <input message="tns:echoStringArrayRequest"/>
+            <output message="tns:echoStringArrayResponse"/>
+        </operation>
+        <operation name="echoInteger">
+            <input message="tns:echoIntegerRequest"/>
+            <output message="tns:echoIntegerResponse"/>
+        </operation>
+        <operation name="echoIntegerArray">
+            <input message="tns:echoIntegerArrayRequest"/>
+            <output message="tns:echoIntegerArrayResponse"/>
+        </operation>
+        <operation name="echoFloat">
+            <input message="tns:echoFloatRequest"/>
+            <output message="tns:echoFloatResponse"/>
+        </operation>
+        <operation name="echoFloatArray">
+            <input message="tns:echoFloatArrayRequest"/>
+            <output message="tns:echoFloatArrayResponse"/>
+        </operation>
+        <operation name="echoStruct">
+            <input message="tns:echoStructRequest"/>
+            <output message="tns:echoStructResponse"/>
+        </operation>
+        <operation name="echoStructArray">
+            <input message="tns:echoStructArrayRequest"/>
+            <output message="tns:echoStructArrayResponse"/>
+        </operation>
+        <operation name="echoDate">
+            <input message="tns:echoDateRequest"/>
+            <output message="tns:echoDateResponse"/>
+        </operation>
+        <operation name="echoBase64">
+            <input message="tns:echoBase64Request"/>
+            <output message="tns:echoBase64Response"/>
+        </operation>
+        <operation name="echoBoolean">
+            <input message="tns:echoBooleanRequest"/>
+            <output message="tns:echoBooleanResponse"/>
+        </operation>
+        <operation name="echoDecimal">
+            <input message="tns:echoDecimalRequest"/>
+            <output message="tns:echoDecimalResponse"/>
+        </operation>
+        <operation name="echoHexBinary">
+            <input message="tns:echoHexBinaryRequest"/>
+            <output message="tns:echoHexBinaryResponse"/>
+        </operation>
+        <operation name="echoStructAsSimpleTypes">
+            <input message="tns:echoStructAsSimpleTypesRequest"/>
+            <output message="tns:echoStructAsSimpleTypesResponse"/>
+        </operation>
+        <operation name="echoSimpleTypesAsStruct">
+            <input message="tns:echoSimpleTypesAsStructRequest"/>
+            <output message="tns:echoSimpleTypesAsStructResponse"/>
+        </operation>
+        <operation name="echo2DStringArray">
+            <input message="tns:echo2DStringArrayRequest"/>
+            <output message="tns:echo2DStringArrayResponse"/>
+        </operation>
+        <operation name="echoNestedStruct">
+            <input message="tns:echoNestedStructRequest"/>
+            <output message="tns:echoNestedStructResponse"/>
+        </operation>
+        <operation name="echoNestedArray">
+            <input message="tns:echoNestedArrayRequest"/>
+            <output message="tns:echoNestedArrayResponse"/>
+        </operation>
+    </portType>
+    <portType name="interopTestPortType">
+        <operation name="echoVoid">
+            <input message="tns:echoVoidRequestA"/>
+            <output message="tns:echoVoidResponseA"/>
+        </operation>
+        <operation name="echoString">
+            <input message="tns:echoStringRequestA"/>
+            <output message="tns:echoStringResponseA"/>
+        </operation>
+        <operation name="echoStringArray">
+            <input message="tns:echoStringArrayRequestA"/>
+            <output message="tns:echoStringArrayResponseA"/>
+        </operation>
+        <operation name="echoInteger">
+            <input message="tns:echoIntegerRequestA"/>
+            <output message="tns:echoIntegerResponseA"/>
+        </operation>
+        <operation name="echoIntegerArray">
+            <input message="tns:echoIntegerArrayRequestA"/>
+            <output message="tns:echoIntegerArrayResponseA"/>
+        </operation>
+        <operation name="echoFloat">
+            <input message="tns:echoFloatRequestA"/>
+            <output message="tns:echoFloatResponseA"/>
+        </operation>
+        <operation name="echoFloatArray">
+            <input message="tns:echoFloatArrayRequestA"/>
+            <output message="tns:echoFloatArrayResponseA"/>
+        </operation>
+        <operation name="echoStruct">
+            <input message="tns:echoStructRequestA"/>
+            <output message="tns:echoStructResponseA"/>
+        </operation>
+        <operation name="echoStructArray">
+            <input message="tns:echoStructArrayRequestA"/>
+            <output message="tns:echoStructArrayResponseA"/>
+        </operation>
+        <operation name="echoDate">
+            <input message="tns:echoDateRequestA"/>
+            <output message="tns:echoDateResponseA"/>
+        </operation>
+        <operation name="echoBase64">
+            <input message="tns:echoBase64RequestA"/>
+            <output message="tns:echoBase64ResponseA"/>
+        </operation>
+        <operation name="echoBoolean">
+            <input message="tns:echoBooleanRequestA"/>
+            <output message="tns:echoBooleanResponseA"/>
+        </operation>
+        <operation name="echoDecimal">
+            <input message="tns:echoDecimalRequestA"/>
+            <output message="tns:echoDecimalResponseA"/>
+        </operation>
+        <operation name="echoHexBinary">
+            <input message="tns:echoHexBinaryRequestA"/>
+            <output message="tns:echoHexBinaryResponseA"/>
+        </operation>
+        <operation name="echoStructAsSimpleTypes">
+            <input message="tns:echoStructAsSimpleTypesRequestA"/>
+            <output message="tns:echoStructAsSimpleTypesResponseA"/>
+        </operation>
+        <operation name="echoSimpleTypesAsStruct">
+            <input message="tns:echoSimpleTypesAsStructRequestA"/>
+            <output message="tns:echoSimpleTypesAsStructResponseA"/>
+        </operation>
+        <operation name="echo2DStringArray">
+            <input message="tns:echo2DStringArrayRequestA"/>
+            <output message="tns:echo2DStringArrayResponseA"/>
+        </operation>
+        <operation name="echoNestedStruct">
+            <input message="tns:echoNestedStructRequestA"/>
+            <output message="tns:echoNestedStructResponseA"/>
+        </operation>
+        <operation name="echoNestedArray">
+            <input message="tns:echoNestedArrayRequestA"/>
+            <output message="tns:echoNestedArrayResponseA"/>
+        </operation>
+    </portType>
+    <binding name="interopTest2Binding" type="tns:interopTest2PortType">
+        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+        <mstk2:binding preferredEncoding='UTF-8'/>
+        <operation name="echoVoid">
+            <soap:operation soapAction="http://soapinterop.org/#echoVoid"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoString">
+            <soap:operation soapAction="http://soapinterop.org/#echoString"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStringArray">
+            <soap:operation soapAction="http://soapinterop.org/#echoStringArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoInteger">
+            <soap:operation soapAction="http://soapinterop.org/#echoInteger"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoIntegerArray">
+            <soap:operation soapAction="http://soapinterop.org/#echoIntegerArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoFloat">
+            <soap:operation soapAction="http://soapinterop.org/#echoFloat"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoFloatArray">
+            <soap:operation soapAction="http://soapinterop.org/#echoFloatArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStruct">
+            <soap:operation soapAction="http://soapinterop.org/#echoStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStructArray">
+            <soap:operation soapAction="http://soapinterop.org/#echoStructArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoDate">
+            <soap:operation soapAction="http://soapinterop.org/#echoDate"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoBase64">
+            <soap:operation soapAction="http://soapinterop.org/#echoBase64"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoBoolean">
+            <soap:operation soapAction="http://soapinterop.org/#echoBoolean"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoDecimal">
+            <soap:operation soapAction="http://soapinterop.org/#echoDecimal"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoHexBinary">
+            <soap:operation soapAction="http://soapinterop.org/#echoHexBinary"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStructAsSimpleTypes">
+            <soap:operation soapAction="http://soapinterop.org/#echoStructAsSimpleTypes"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoSimpleTypesAsStruct">
+            <soap:operation soapAction="http://soapinterop.org/#echoSimpleTypesAsStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echo2DStringArray">
+            <soap:operation soapAction="http://soapinterop.org/#echo2DStringArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoNestedStruct">
+            <soap:operation soapAction="http://soapinterop.org/#echoNestedStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoNestedArray">
+            <soap:operation soapAction="http://soapinterop.org/#echoNestedArray"/>
+            <input>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="http://soapinterop.org/" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+    </binding>
+    <binding name="interopTestBinding" type="tns:interopTestPortType">
+        <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+        <mstk2:binding preferredEncoding='UTF-8'/>
+        <operation name="echoVoid">
+            <soap:operation soapAction="urn:xmethodsInterop#echoVoid"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoString">
+            <soap:operation soapAction="urn:xmethodsInterop#echoString"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStringArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echoStringArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoInteger">
+            <soap:operation soapAction="urn:xmethodsInterop#echoInteger"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoIntegerArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echoIntegerArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoFloat">
+            <soap:operation soapAction="urn:xmethodsInterop#echoFloat"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoFloatArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echoFloatArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStruct">
+            <soap:operation soapAction="urn:xmethodsInterop#echoStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStructArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echoStructArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoDate">
+            <soap:operation soapAction="urn:xmethodsInterop#echoDate"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoBase64">
+            <soap:operation soapAction="urn:xmethodsInterop#echoBase64"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoBoolean">
+            <soap:operation soapAction="urn:xmethodsInterop#echoBoolean"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoDecimal">
+            <soap:operation soapAction="urn:xmethodsInterop#echoDecimal"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoHexBinary">
+            <soap:operation soapAction="urn:xmethodsInterop#echoHexBinary"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoStructAsSimpleTypes">
+            <soap:operation soapAction="urn:xmethodsInterop#echoStructAsSimpleTypes"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoSimpleTypesAsStruct">
+            <soap:operation soapAction="urn:xmethodsInterop#echoSimpleTypesAsStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echo2DStringArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echo2DStringArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoNestedStruct">
+            <soap:operation soapAction="urn:xmethodsInterop#echoNestedStruct"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+        <operation name="echoNestedArray">
+            <soap:operation soapAction="urn:xmethodsInterop#echoNestedArray"/>
+            <input>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </input>
+            <output>
+                <soap:body use="encoded" namespace="urn:xmethodsInterop" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
+            </output>
+        </operation>
+    </binding>
+    <service name="interopLab">
+        <port name="interopTest2Port" binding="tns:interopTest2Binding">
+            <!-- use with tcpmon to see what's happening -->
+<!--            <soap:address location="http://127.0.0.1:8080/base/SoapInteropBaseService"/>-->
+            <soap:address location="http://webservice.bea.com:7001/base/SoapInteropBaseService"/>
+            <!-- this one wasn't up when I tried -->
+            <!--    <soap:address location="http://soap.4s4c.com/ilab/soap.asp"/>-->
+        </port>
+        <port name="interopTestPort" binding="tns:interopTestBinding">
+            <!-- use with tcpmon to see what's happening -->
+<!--            <soap:address location="http://127.0.0.1:8080/base/SoapInteropBaseService"/>-->
+                <soap:address location="http://webservice.bea.com:7001/base/SoapInteropBaseService"/>
+            <!-- this one wasn't up when I tried -->
+            <!--    <soap:address location="http://soap.4s4c.com/ilab/soap.asp"/>-->
+        </port>
+    </service>
+</definitions>
\ No newline at end of file

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/ServiceRefTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/ServiceRefTest.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/ServiceRefTest.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,373 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder;
+
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.ObjectInputStream;
+import java.io.ObjectOutputStream;
+import java.io.ObjectStreamClass;
+import java.io.Serializable;
+import java.lang.reflect.Method;
+import java.net.URI;
+import java.net.URL;
+import java.net.URLClassLoader;
+import java.rmi.Remote;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import javax.naming.RefAddr;
+import javax.naming.Reference;
+import javax.wsdl.Binding;
+import javax.wsdl.BindingInput;
+import javax.wsdl.BindingOperation;
+import javax.wsdl.BindingOutput;
+import javax.wsdl.Definition;
+import javax.wsdl.Input;
+import javax.wsdl.Message;
+import javax.wsdl.Operation;
+import javax.wsdl.OperationType;
+import javax.wsdl.Output;
+import javax.wsdl.Part;
+import javax.wsdl.Port;
+import javax.wsdl.PortType;
+import javax.wsdl.WSDLException;
+import javax.wsdl.extensions.ExtensionRegistry;
+import javax.wsdl.extensions.soap.SOAPAddress;
+import javax.wsdl.extensions.soap.SOAPBinding;
+import javax.wsdl.extensions.soap.SOAPBody;
+import javax.wsdl.extensions.soap.SOAPOperation;
+import javax.wsdl.factory.WSDLFactory;
+import javax.wsdl.xml.WSDLReader;
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Service;
+
+import junit.framework.TestCase;
+import org.apache.axis.enum.Style;
+import org.apache.axis.soap.SOAPConstants;
+import org.apache.geronimo.axis.builder.bookquote.BookQuote;
+import org.apache.geronimo.axis.builder.bookquote.BookQuoteService;
+import org.apache.geronimo.axis.builder.interop.InteropLab;
+import org.apache.geronimo.axis.builder.interop.InteropTestPortType;
+import org.apache.geronimo.axis.builder.mock.MockPort;
+import org.apache.geronimo.axis.builder.mock.MockSEIFactory;
+import org.apache.geronimo.axis.builder.mock.MockService;
+import org.apache.geronimo.axis.client.OperationInfo;
+import org.apache.geronimo.axis.client.SEIFactory;
+import org.apache.geronimo.axis.client.ServiceImpl;
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.deployment.DeploymentContext;
+import org.apache.geronimo.kernel.config.ConfigurationModuleType;
+import org.apache.geronimo.xbeans.j2ee.JavaWsdlMappingDocument;
+import org.apache.geronimo.xbeans.j2ee.JavaWsdlMappingType;
+import org.apache.geronimo.xbeans.j2ee.PackageMappingType;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class ServiceRefTest extends TestCase {
+    private static final File basedir = new File(System.getProperty("basedir", System.getProperty("user.dir")));
+
+    public final static String NAMESPACE = "http://geronimo.apache.org/axis/mock";
+    private File tmpbasedir;
+    private URI configID = URI.create("test");
+    private DeploymentContext context;
+    private ClassLoader isolatedCl = new URLClassLoader(new URL[0], this.getClass().getClassLoader());
+    private final String operationName = "doMockOperation";
+
+    private boolean runExternalWSTest;
+
+    protected void setUp() throws Exception {
+        tmpbasedir = File.createTempFile("car", "tmp");
+        tmpbasedir.delete();
+        tmpbasedir.mkdirs();
+        context = new DeploymentContext(tmpbasedir, configID, ConfigurationModuleType.CAR, null, null);
+
+        runExternalWSTest = System.getProperty("geronimo.run.external.webservicetest", "false").equals("true");
+    }
+
+    protected void tearDown() throws Exception {
+        recursiveDelete(tmpbasedir);
+    }
+
+    public void testServiceRefCreation() throws Exception {
+        AxisBuilder builder = new AxisBuilder();
+
+        Reference ref = builder.createServiceReference(MockService.class, null, null, null, null, null, context, isolatedCl);
+        RefAddr refAddr = ref.get(0);
+        Object instance = refAddr.getContent();
+        assertTrue(instance instanceof Service);
+
+        ClassLoader cl = context.getClassLoader(null);
+        Class loadedType = cl.loadClass(instance.getClass().getName());
+        assertTrue(Service.class.isAssignableFrom(loadedType));
+        assertTrue(instance.getClass() != loadedType);
+    }
+
+    public void testServiceProxy() throws Exception {
+        //construct the SEI proxy
+        Map portMap = new HashMap();
+        portMap.put("MockPort", new MockSEIFactory());
+        AxisBuilder builder = new AxisBuilder();
+        org.apache.axis.client.Service delegate = new org.apache.axis.client.Service();
+        Service service = builder.createService(MockService.class, portMap, context, isolatedCl);
+        assertTrue(service instanceof MockService);
+        MockService mockService = (MockService) service;
+        MockPort mockPort = mockService.getMockPort();
+        assertNotNull(mockPort);
+    }
+
+    public void testServiceEndpointProxy() throws Exception {
+        AxisBuilder builder = new AxisBuilder();
+
+        ServiceImpl serviceInstance = new ServiceImpl(null);
+        List typeMappings = new ArrayList();
+
+        URL location = new URL("http://geronimo.apache.org/ws");
+
+        OperationInfo op = buildOperationInfoForMockOperation(builder);
+        OperationInfo[] operationInfos = new OperationInfo[]{op};
+        Class serviceEndpointClass = builder.enhanceServiceEndpointInterface(isolatedCl, MockPort.class, context);
+        SEIFactory serviceInterfaceFactory = builder.createSEIFactory(serviceEndpointClass, serviceInstance, typeMappings, location, operationInfos, context, isolatedCl);
+        assertNotNull(serviceInterfaceFactory);
+        Remote serviceInterface = serviceInterfaceFactory.createServiceEndpoint();
+        assertTrue(serviceInterface instanceof MockPort);
+//        MockPort mockServiceInterface = (MockPort) serviceInterface;
+//        mockServiceInterface.doMockOperation(null);
+    }
+
+    public void testBuildOperationInfo() throws Exception {
+        AxisBuilder builder = new AxisBuilder();
+        OperationInfo operationInfo = buildOperationInfoForMockOperation(builder);
+        assertNotNull(operationInfo);
+    }
+
+    public void testBuildFullServiceProxy() throws Exception {
+        Definition definition = buildDefinition();
+        JavaWsdlMappingType mapping = buildLightweightMappingType();
+        QName serviceQName = new QName(NAMESPACE, "MockService");
+        AxisBuilder builder = new AxisBuilder();
+        Object proxy = builder.createService(MockService.class, definition, mapping, serviceQName, SOAPConstants.SOAP11_CONSTANTS, context, isolatedCl);
+        assertNotNull(proxy);
+        assertTrue(proxy instanceof MockService);
+        MockPort mockPort = ((MockService) proxy).getMockPort();
+        assertNotNull(mockPort);
+    }
+
+    public void testBuildBookQuoteProxy() throws Exception {
+        File wsdl = new File(basedir, "src/test-resources/BookQuote.wsdl");
+        WSDLFactory factory = WSDLFactory.newInstance();
+        WSDLReader reader = factory.newWSDLReader();
+        Definition definition = reader.readWSDL(wsdl.toURI().toString());
+        File jaxrpcMapping = new File(basedir, "src/test-resources/BookQuote.xml");
+        JavaWsdlMappingDocument mappingDocument = JavaWsdlMappingDocument.Factory.parse(jaxrpcMapping);
+        JavaWsdlMappingType mapping = mappingDocument.getJavaWsdlMapping();
+        QName serviceQName = new QName("http://www.Monson-Haefel.com/jwsbook/BookQuote", "BookQuoteService");
+        AxisBuilder builder = new AxisBuilder();
+        Object proxy = builder.createService(BookQuoteService.class, definition, mapping, serviceQName, SOAPConstants.SOAP11_CONSTANTS, context, isolatedCl);
+        assertNotNull(proxy);
+        assertTrue(proxy instanceof BookQuoteService);
+        BookQuote bookQuote = ((BookQuoteService) proxy).getBookQuotePort();
+        assertNotNull(bookQuote);
+    }
+
+    public void testBuildInteropProxy() throws Exception {
+        File wsdl = new File(basedir, "src/test-resources/interop/interop.wsdl");
+        WSDLFactory factory = WSDLFactory.newInstance();
+        WSDLReader reader = factory.newWSDLReader();
+        Definition definition = reader.readWSDL(wsdl.toURI().toString());
+        File jaxrpcMapping = new File(basedir, "src/test-resources/interop/interop-jaxrpcmapping.xml");
+        JavaWsdlMappingDocument mappingDocument = JavaWsdlMappingDocument.Factory.parse(jaxrpcMapping);
+        JavaWsdlMappingType mapping = mappingDocument.getJavaWsdlMapping();
+        QName serviceQName = new QName("http://tempuri.org/4s4c/1/3/wsdl/def/interopLab", "interopLab");
+        AxisBuilder builder = new AxisBuilder();
+        Object proxy = builder.createService(InteropLab.class, definition, mapping, serviceQName, SOAPConstants.SOAP11_CONSTANTS, context, isolatedCl);
+        assertNotNull(proxy);
+        assertTrue(proxy instanceof InteropLab);
+        InteropTestPortType interopTestPort = ((InteropLab) proxy).getinteropTestPort();
+        assertNotNull(interopTestPort);
+        if (runExternalWSTest) {
+            System.out.println("Running external ws test");
+            int result = interopTestPort.echoInteger(1);
+            assertEquals(result, 1);
+        } else {
+            System.out.println("Skipping external ws test");
+        }
+    }
+
+    public void testBuildInteropProxyFromURIs() throws Exception {
+        File wsdldir = new File(basedir, "src/test-resources/interop");
+        ClassLoader cl = new URLClassLoader(new URL[]{wsdldir.toURL()}, isolatedCl);
+        URI wsdlURI = new URI("interop.wsdl");
+        URI jaxrpcmappingURI = new URI("interop-jaxrpcmapping.xml");
+        QName serviceQName = new QName("http://tempuri.org/4s4c/1/3/wsdl/def/interopLab", "interopLab");
+        AxisBuilder builder = new AxisBuilder();
+        Map portComponentRefMap = null;
+        List handlers = null;
+        Object proxy = builder.createService(InteropLab.class, wsdlURI, jaxrpcmappingURI, serviceQName, portComponentRefMap, handlers, context, cl);
+        assertNotNull(proxy);
+        ClassLoader contextCl = context.getClassLoader(null);
+        proxy = reserialize(proxy, contextCl);
+        assertTrue(proxy instanceof InteropLab);
+        InteropTestPortType interopTestPort = ((InteropLab) proxy).getinteropTestPort();
+        assertNotNull(interopTestPort);
+        if (runExternalWSTest) {
+            System.out.println("Running external ws test");
+            int result = interopTestPort.echoInteger(1);
+            assertEquals(result, 1);
+        } else {
+            System.out.println("Skipping external ws test");
+        }
+    }
+
+    private Object reserialize(Object object, ClassLoader cl) throws Exception {
+        if (!(object instanceof Serializable)) {
+            fail("object is not serializable, " + object);
+        }
+
+        ByteArrayOutputStream baos = new ByteArrayOutputStream();
+        ObjectOutputStream oos = new ObjectOutputStream(baos);
+        oos.writeObject(object);
+        oos.flush();
+        byte[] bytes = baos.toByteArray();
+        ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
+        ObjectInputStream ois = new ConfigInputStream(bais, cl);
+        Object result = ois.readObject();
+        return result;
+    }
+
+    private static class ConfigInputStream extends ObjectInputStream {
+        private final ClassLoader cl;
+
+        public ConfigInputStream(InputStream in, ClassLoader cl) throws IOException {
+            super(in);
+            this.cl = cl;
+        }
+
+        protected Class resolveClass(ObjectStreamClass desc) throws IOException, ClassNotFoundException {
+            try {
+                return cl.loadClass(desc.getName());
+            } catch (ClassNotFoundException e) {
+                // let the parent try
+                return super.resolveClass(desc);
+            }
+        }
+    }
+
+    private OperationInfo buildOperationInfoForMockOperation(AxisBuilder builder) throws NoSuchMethodException, DeploymentException, WSDLException {
+        Class portClass = MockPort.class;
+        Method method = portClass.getDeclaredMethod("doMockOperation", new Class[]{String.class});
+        WSDLFactory factory = WSDLFactory.newInstance();
+        Definition definition = factory.newDefinition();
+        ExtensionRegistry extensionRegistry = factory.newPopulatedExtensionRegistry();
+        BindingOperation bindingOperation = buildBindingOperation(definition, extensionRegistry);
+
+        Style defaultStyle = Style.DOCUMENT;
+
+        OperationInfo operationInfo = builder.buildOperationInfo(method, bindingOperation, defaultStyle, SOAPConstants.SOAP11_CONSTANTS);
+        return operationInfo;
+    }
+
+    private Definition buildDefinition() throws WSDLException {
+        WSDLFactory factory = WSDLFactory.newInstance();
+        Definition definition = factory.newDefinition();
+        ExtensionRegistry extensionRegistry = factory.newPopulatedExtensionRegistry();
+        BindingOperation bindingOperation = buildBindingOperation(definition, extensionRegistry);
+        Binding binding = definition.createBinding();
+        binding.setQName(new QName(NAMESPACE, "MockPortBinding"));
+        //add soap:binding
+        SOAPBinding soapBinding = (SOAPBinding) extensionRegistry.createExtension(Binding.class, new QName("http://schemas.xmlsoap.org/wsdl/soap/", "binding"));
+        soapBinding.setTransportURI("http://schemas.xmlsoap.org/soap/http");
+        soapBinding.setStyle("rpc");
+        binding.addExtensibilityElement(soapBinding);
+        binding.addBindingOperation(bindingOperation);
+        PortType portType = definition.createPortType();
+        portType.setQName(new QName(NAMESPACE, "MockPort"));
+        portType.addOperation(bindingOperation.getOperation());
+        binding.setPortType(portType);
+        Port port = definition.createPort();
+        port.setName("MockPort");
+        //add soap:address
+        SOAPAddress soapAddress = (SOAPAddress) extensionRegistry.createExtension(Port.class, new QName("http://schemas.xmlsoap.org/wsdl/soap/", "address"));
+        soapAddress.setLocationURI("http://127.0.0.1:8080/foo");
+        port.addExtensibilityElement(soapAddress);
+        port.setBinding(binding);
+        javax.wsdl.Service service = definition.createService();
+        service.setQName(new QName(NAMESPACE, "MockService"));
+        service.addPort(port);
+        definition.addService(service);
+        return definition;
+    }
+
+    private BindingOperation buildBindingOperation(Definition definition, ExtensionRegistry extensionRegistry) throws WSDLException {
+        Operation operation = definition.createOperation();
+        operation.setName(operationName);
+        operation.setStyle(OperationType.REQUEST_RESPONSE);
+        Input input = definition.createInput();
+        Message inputMessage = definition.createMessage();
+        Part inputPart = definition.createPart();
+        inputPart.setName("string");
+        inputPart.setTypeName(new QName("http://www.w3.org/2001/XMLSchema", "string"));
+        inputMessage.addPart(inputPart);
+        operation.setInput(input);
+        input.setMessage(inputMessage);
+        Output output = definition.createOutput();
+        Message outputMessage = definition.createMessage();
+        operation.setOutput(output);
+        output.setMessage(outputMessage);
+        BindingOperation bindingOperation = definition.createBindingOperation();
+        SOAPOperation soapOperation = (SOAPOperation) extensionRegistry.createExtension(BindingOperation.class, new QName("http://schemas.xmlsoap.org/wsdl/soap/", "operation"));
+        soapOperation.setSoapActionURI("actionURI");
+        soapOperation.setStyle("rpc");
+        bindingOperation.addExtensibilityElement(soapOperation);
+        bindingOperation.setOperation(operation);
+        bindingOperation.setName(operation.getName());
+        BindingInput bindingInput = definition.createBindingInput();
+        SOAPBody inputBody = (SOAPBody) extensionRegistry.createExtension(BindingInput.class, new QName("http://schemas.xmlsoap.org/wsdl/soap/", "body"));
+        inputBody.setUse("encoded");
+        bindingInput.addExtensibilityElement(inputBody);
+        bindingOperation.setBindingInput(bindingInput);
+        BindingOutput bindingOutput = definition.createBindingOutput();
+        bindingOutput.addExtensibilityElement(inputBody);
+        bindingOperation.setBindingOutput(bindingOutput);
+        return bindingOperation;
+    }
+
+    private JavaWsdlMappingType buildLightweightMappingType() {
+        JavaWsdlMappingType mapping = JavaWsdlMappingType.Factory.newInstance();
+        PackageMappingType packageMapping = mapping.addNewPackageMapping();
+        packageMapping.addNewNamespaceURI().setStringValue(NAMESPACE);
+        packageMapping.addNewPackageType().setStringValue("org.apache.geronimo.axis.builder.mock");
+        return mapping;
+    }
+
+
+    private void recursiveDelete(File file) {
+        if (file.isDirectory()) {
+            File[] files = file.listFiles();
+            for (int i = 0; i < files.length; i++) {
+                recursiveDelete(files[i]);
+            }
+        }
+        file.delete();
+    }
+
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuote.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuote.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuote.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,12 @@
+/**
+ * BookQuote.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis 1.2RC1 Sep 29, 2004 (08:29:40 EDT) WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.bookquote;
+
+public interface BookQuote extends java.rmi.Remote {
+    public float getBookPrice(java.lang.String isbn) throws java.rmi.RemoteException, InvalidIsbnException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuoteService.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuoteService.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/BookQuoteService.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,16 @@
+/**
+ * BookQuoteService.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis 1.2RC1 Sep 29, 2004 (08:29:40 EDT) WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.bookquote;
+
+public interface BookQuoteService extends javax.xml.rpc.Service {
+//    public java.lang.String getBookQuotePortAddress();
+
+    public BookQuote getBookQuotePort() throws javax.xml.rpc.ServiceException;
+
+//    public BookQuote getBookQuotePort(java.net.URL portAddress) throws javax.xml.rpc.ServiceException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/InvalidIsbnException.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/InvalidIsbnException.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/bookquote/InvalidIsbnException.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,29 @@
+/**
+ * InvalidIsbnException.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis 1.2RC1 Sep 29, 2004 (08:29:40 EDT) WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.bookquote;
+
+public class InvalidIsbnException extends org.apache.axis.AxisFault {
+    public java.lang.String message;
+    public java.lang.String getMessage() {
+        return this.message;
+    }
+
+    public InvalidIsbnException() {
+    }
+
+      public InvalidIsbnException(java.lang.String message) {
+        this.message = message;
+    }
+
+    /**
+     * Writes the exception data to the faultDetails
+     */
+    public void writeDetails(javax.xml.namespace.QName qname, org.apache.axis.encoding.SerializationContext context) throws java.io.IOException {
+        context.serialize(qname, null, message);
+    }
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropLab.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropLab.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropLab.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,21 @@
+/**
+ * InteropLab.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop;
+
+public interface InteropLab extends javax.xml.rpc.Service {
+//    public java.lang.String getinteropTestPortAddress();
+
+    public org.apache.geronimo.axis.builder.interop.InteropTestPortType getinteropTestPort() throws javax.xml.rpc.ServiceException;
+
+//    public org.apache.geronimo.axis.builder.interop.InteropTestPortType getinteropTestPort(java.net.URL portAddress) throws javax.xml.rpc.ServiceException;
+//    public java.lang.String getinteropTest2PortAddress();
+
+    public org.apache.geronimo.axis.builder.interop.InteropTest2PortType getinteropTest2Port() throws javax.xml.rpc.ServiceException;
+
+//    public org.apache.geronimo.axis.builder.interop.InteropTest2PortType getinteropTest2Port(java.net.URL portAddress) throws javax.xml.rpc.ServiceException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTest2PortType.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTest2PortType.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTest2PortType.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,30 @@
+/**
+ * InteropTest2PortType.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop;
+
+public interface InteropTest2PortType extends java.rmi.Remote {
+    public void echoVoid() throws java.rmi.RemoteException;
+    public java.lang.String echoString(java.lang.String inputString) throws java.rmi.RemoteException;
+    public java.lang.String[] echoStringArray(java.lang.String[] inputStringArray) throws java.rmi.RemoteException;
+    public int echoInteger(int inputInteger) throws java.rmi.RemoteException;
+    public int[] echoIntegerArray(int[] inputIntegerArray) throws java.rmi.RemoteException;
+    public float echoFloat(float inputFloat) throws java.rmi.RemoteException;
+    public float[] echoFloatArray(float[] inputFloatArray) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct echoStruct(org.apache.geronimo.axis.builder.interop.types.SOAPStruct inputStruct) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct[] echoStructArray(org.apache.geronimo.axis.builder.interop.types.SOAPStruct[] inputStructArray) throws java.rmi.RemoteException;
+    public java.util.Calendar echoDate(java.util.Calendar inputDate) throws java.rmi.RemoteException;
+    public byte[] echoBase64(byte[] inputBase64) throws java.rmi.RemoteException;
+    public boolean echoBoolean(boolean inputBoolean) throws java.rmi.RemoteException;
+    public java.math.BigDecimal echoDecimal(java.math.BigDecimal inputDecimal) throws java.rmi.RemoteException;
+    public byte[] echoHexBinary(byte[] inputHexBinary) throws java.rmi.RemoteException;
+    public void echoStructAsSimpleTypes(org.apache.geronimo.axis.builder.interop.types.SOAPStruct inputStruct, javax.xml.rpc.holders.StringHolder outputString, javax.xml.rpc.holders.IntHolder outputInteger, javax.xml.rpc.holders.FloatHolder outputFloat) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct echoSimpleTypesAsStruct(java.lang.String inputString, int inputInteger, float inputFloat) throws java.rmi.RemoteException;
+    public java.lang.String[] echo2DStringArray(java.lang.String[] input2DStringArray) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStructStruct echoNestedStruct(org.apache.geronimo.axis.builder.interop.types.SOAPStructStruct inputStruct) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPArrayStruct echoNestedArray(org.apache.geronimo.axis.builder.interop.types.SOAPArrayStruct inputStruct) throws java.rmi.RemoteException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTestPortType.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTestPortType.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/InteropTestPortType.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,30 @@
+/**
+ * InteropTestPortType.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop;
+
+public interface InteropTestPortType extends java.rmi.Remote {
+    public void echoVoid() throws java.rmi.RemoteException;
+    public java.lang.String echoString(java.lang.String inputString) throws java.rmi.RemoteException;
+    public java.lang.String[] echoStringArray(java.lang.String[] inputStringArray) throws java.rmi.RemoteException;
+    public int echoInteger(int inputInteger) throws java.rmi.RemoteException;
+    public int[] echoIntegerArray(int[] inputIntegerArray) throws java.rmi.RemoteException;
+    public float echoFloat(float inputFloat) throws java.rmi.RemoteException;
+    public float[] echoFloatArray(float[] inputFloatArray) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct echoStruct(org.apache.geronimo.axis.builder.interop.types.SOAPStruct inputStruct) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct[] echoStructArray(org.apache.geronimo.axis.builder.interop.types.SOAPStruct[] inputStructArray) throws java.rmi.RemoteException;
+    public java.util.Calendar echoDate(java.util.Calendar inputDate) throws java.rmi.RemoteException;
+    public byte[] echoBase64(byte[] inputBase64) throws java.rmi.RemoteException;
+    public boolean echoBoolean(boolean inputBoolean) throws java.rmi.RemoteException;
+    public java.math.BigDecimal echoDecimal(java.math.BigDecimal inputDecimal) throws java.rmi.RemoteException;
+    public byte[] echoHexBinary(byte[] inputHexBinary) throws java.rmi.RemoteException;
+    public void echoStructAsSimpleTypes(org.apache.geronimo.axis.builder.interop.types.SOAPStruct inputStruct, javax.xml.rpc.holders.StringHolder outputString, javax.xml.rpc.holders.IntHolder outputInteger, javax.xml.rpc.holders.FloatHolder outputFloat) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct echoSimpleTypesAsStruct(java.lang.String inputString, int inputInteger, float inputFloat) throws java.rmi.RemoteException;
+    public java.lang.String[] echo2DStringArray(java.lang.String[] input2DStringArray) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStructStruct echoNestedStruct(org.apache.geronimo.axis.builder.interop.types.SOAPStructStruct inputStruct) throws java.rmi.RemoteException;
+    public org.apache.geronimo.axis.builder.interop.types.SOAPArrayStruct echoNestedArray(org.apache.geronimo.axis.builder.interop.types.SOAPArrayStruct inputStruct) throws java.rmi.RemoteException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPArrayStruct.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPArrayStruct.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPArrayStruct.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,161 @@
+/**
+ * SOAPArrayStruct.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop.types;
+
+public class SOAPArrayStruct  implements java.io.Serializable {
+    private java.lang.String varString;
+    private int varInt;
+    private float varFloat;
+    private java.lang.String[] varArray;
+
+    public SOAPArrayStruct() {
+    }
+
+    public java.lang.String getVarString() {
+        return varString;
+    }
+
+    public void setVarString(java.lang.String varString) {
+        this.varString = varString;
+    }
+
+    public int getVarInt() {
+        return varInt;
+    }
+
+    public void setVarInt(int varInt) {
+        this.varInt = varInt;
+    }
+
+    public float getVarFloat() {
+        return varFloat;
+    }
+
+    public void setVarFloat(float varFloat) {
+        this.varFloat = varFloat;
+    }
+
+    public java.lang.String[] getVarArray() {
+        return varArray;
+    }
+
+    public void setVarArray(java.lang.String[] varArray) {
+        this.varArray = varArray;
+    }
+
+    private java.lang.Object __equalsCalc = null;
+    public synchronized boolean equals(java.lang.Object obj) {
+        if (!(obj instanceof SOAPArrayStruct)) return false;
+        SOAPArrayStruct other = (SOAPArrayStruct) obj;
+        if (obj == null) return false;
+        if (this == obj) return true;
+        if (__equalsCalc != null) {
+            return (__equalsCalc == obj);
+        }
+        __equalsCalc = obj;
+        boolean _equals;
+        _equals = true && 
+            ((this.varString==null && other.getVarString()==null) || 
+             (this.varString!=null &&
+              this.varString.equals(other.getVarString()))) &&
+            this.varInt == other.getVarInt() &&
+            this.varFloat == other.getVarFloat() &&
+            ((this.varArray==null && other.getVarArray()==null) || 
+             (this.varArray!=null &&
+              java.util.Arrays.equals(this.varArray, other.getVarArray())));
+        __equalsCalc = null;
+        return _equals;
+    }
+
+    private boolean __hashCodeCalc = false;
+    public synchronized int hashCode() {
+        if (__hashCodeCalc) {
+            return 0;
+        }
+        __hashCodeCalc = true;
+        int _hashCode = 1;
+        if (getVarString() != null) {
+            _hashCode += getVarString().hashCode();
+        }
+        _hashCode += getVarInt();
+        _hashCode += new Float(getVarFloat()).hashCode();
+        if (getVarArray() != null) {
+            for (int i=0;
+                 i<java.lang.reflect.Array.getLength(getVarArray());
+                 i++) {
+                java.lang.Object obj = java.lang.reflect.Array.get(getVarArray(), i);
+                if (obj != null &&
+                    !obj.getClass().isArray()) {
+                    _hashCode += obj.hashCode();
+                }
+            }
+        }
+        __hashCodeCalc = false;
+        return _hashCode;
+    }
+
+    // Type metadata
+    private static org.apache.axis.description.TypeDesc typeDesc =
+        new org.apache.axis.description.TypeDesc(SOAPArrayStruct.class);
+
+    static {
+        typeDesc.setXmlType(new javax.xml.namespace.QName("http://tempuri.org/4s4c/1/3/wsdl/types/", "SOAPArrayStruct"));
+        org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varString");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varString"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varInt");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varInt"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "int"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varFloat");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varFloat"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "float"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varArray");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varArray"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
+        typeDesc.addFieldDesc(elemField);
+    }
+
+    /**
+     * Return type metadata object
+     */
+    public static org.apache.axis.description.TypeDesc getTypeDesc() {
+        return typeDesc;
+    }
+
+    /**
+     * Get Custom Serializer
+     */
+    public static org.apache.axis.encoding.Serializer getSerializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanSerializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+    /**
+     * Get Custom Deserializer
+     */
+    public static org.apache.axis.encoding.Deserializer getDeserializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanDeserializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStruct.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStruct.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStruct.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,133 @@
+/**
+ * SOAPStruct.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop.types;
+
+public class SOAPStruct  implements java.io.Serializable {
+    private java.lang.String varString;
+    private int varInt;
+    private float varFloat;
+
+    public SOAPStruct() {
+    }
+
+    public java.lang.String getVarString() {
+        return varString;
+    }
+
+    public void setVarString(java.lang.String varString) {
+        this.varString = varString;
+    }
+
+    public int getVarInt() {
+        return varInt;
+    }
+
+    public void setVarInt(int varInt) {
+        this.varInt = varInt;
+    }
+
+    public float getVarFloat() {
+        return varFloat;
+    }
+
+    public void setVarFloat(float varFloat) {
+        this.varFloat = varFloat;
+    }
+
+    private java.lang.Object __equalsCalc = null;
+    public synchronized boolean equals(java.lang.Object obj) {
+        if (!(obj instanceof SOAPStruct)) return false;
+        SOAPStruct other = (SOAPStruct) obj;
+        if (obj == null) return false;
+        if (this == obj) return true;
+        if (__equalsCalc != null) {
+            return (__equalsCalc == obj);
+        }
+        __equalsCalc = obj;
+        boolean _equals;
+        _equals = true && 
+            ((this.varString==null && other.getVarString()==null) || 
+             (this.varString!=null &&
+              this.varString.equals(other.getVarString()))) &&
+            this.varInt == other.getVarInt() &&
+            this.varFloat == other.getVarFloat();
+        __equalsCalc = null;
+        return _equals;
+    }
+
+    private boolean __hashCodeCalc = false;
+    public synchronized int hashCode() {
+        if (__hashCodeCalc) {
+            return 0;
+        }
+        __hashCodeCalc = true;
+        int _hashCode = 1;
+        if (getVarString() != null) {
+            _hashCode += getVarString().hashCode();
+        }
+        _hashCode += getVarInt();
+        _hashCode += new Float(getVarFloat()).hashCode();
+        __hashCodeCalc = false;
+        return _hashCode;
+    }
+
+    // Type metadata
+    private static org.apache.axis.description.TypeDesc typeDesc =
+        new org.apache.axis.description.TypeDesc(SOAPStruct.class);
+
+    static {
+        typeDesc.setXmlType(new javax.xml.namespace.QName("http://tempuri.org/4s4c/1/3/wsdl/types/", "SOAPStruct"));
+        org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varString");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varString"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varInt");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varInt"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "int"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varFloat");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varFloat"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "float"));
+        typeDesc.addFieldDesc(elemField);
+    }
+
+    /**
+     * Return type metadata object
+     */
+    public static org.apache.axis.description.TypeDesc getTypeDesc() {
+        return typeDesc;
+    }
+
+    /**
+     * Get Custom Serializer
+     */
+    public static org.apache.axis.encoding.Serializer getSerializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanSerializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+    /**
+     * Get Custom Deserializer
+     */
+    public static org.apache.axis.encoding.Deserializer getDeserializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanDeserializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStructStruct.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStructStruct.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/interop/types/SOAPStructStruct.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,153 @@
+/**
+ * SOAPStructStruct.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis WSDL2Java emitter.
+ */
+
+package org.apache.geronimo.axis.builder.interop.types;
+
+public class SOAPStructStruct  implements java.io.Serializable {
+    private java.lang.String varString;
+    private int varInt;
+    private float varFloat;
+    private org.apache.geronimo.axis.builder.interop.types.SOAPStruct varStruct;
+
+    public SOAPStructStruct() {
+    }
+
+    public java.lang.String getVarString() {
+        return varString;
+    }
+
+    public void setVarString(java.lang.String varString) {
+        this.varString = varString;
+    }
+
+    public int getVarInt() {
+        return varInt;
+    }
+
+    public void setVarInt(int varInt) {
+        this.varInt = varInt;
+    }
+
+    public float getVarFloat() {
+        return varFloat;
+    }
+
+    public void setVarFloat(float varFloat) {
+        this.varFloat = varFloat;
+    }
+
+    public org.apache.geronimo.axis.builder.interop.types.SOAPStruct getVarStruct() {
+        return varStruct;
+    }
+
+    public void setVarStruct(org.apache.geronimo.axis.builder.interop.types.SOAPStruct varStruct) {
+        this.varStruct = varStruct;
+    }
+
+    private java.lang.Object __equalsCalc = null;
+    public synchronized boolean equals(java.lang.Object obj) {
+        if (!(obj instanceof SOAPStructStruct)) return false;
+        SOAPStructStruct other = (SOAPStructStruct) obj;
+        if (obj == null) return false;
+        if (this == obj) return true;
+        if (__equalsCalc != null) {
+            return (__equalsCalc == obj);
+        }
+        __equalsCalc = obj;
+        boolean _equals;
+        _equals = true && 
+            ((this.varString==null && other.getVarString()==null) || 
+             (this.varString!=null &&
+              this.varString.equals(other.getVarString()))) &&
+            this.varInt == other.getVarInt() &&
+            this.varFloat == other.getVarFloat() &&
+            ((this.varStruct==null && other.getVarStruct()==null) || 
+             (this.varStruct!=null &&
+              this.varStruct.equals(other.getVarStruct())));
+        __equalsCalc = null;
+        return _equals;
+    }
+
+    private boolean __hashCodeCalc = false;
+    public synchronized int hashCode() {
+        if (__hashCodeCalc) {
+            return 0;
+        }
+        __hashCodeCalc = true;
+        int _hashCode = 1;
+        if (getVarString() != null) {
+            _hashCode += getVarString().hashCode();
+        }
+        _hashCode += getVarInt();
+        _hashCode += new Float(getVarFloat()).hashCode();
+        if (getVarStruct() != null) {
+            _hashCode += getVarStruct().hashCode();
+        }
+        __hashCodeCalc = false;
+        return _hashCode;
+    }
+
+    // Type metadata
+    private static org.apache.axis.description.TypeDesc typeDesc =
+        new org.apache.axis.description.TypeDesc(SOAPStructStruct.class);
+
+    static {
+        typeDesc.setXmlType(new javax.xml.namespace.QName("http://tempuri.org/4s4c/1/3/wsdl/types/", "SOAPStructStruct"));
+        org.apache.axis.description.ElementDesc elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varString");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varString"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varInt");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varInt"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "int"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varFloat");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varFloat"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "float"));
+        typeDesc.addFieldDesc(elemField);
+        elemField = new org.apache.axis.description.ElementDesc();
+        elemField.setFieldName("varStruct");
+        elemField.setXmlName(new javax.xml.namespace.QName("", "varStruct"));
+        elemField.setXmlType(new javax.xml.namespace.QName("http://tempuri.org/4s4c/1/3/wsdl/types/", "SOAPStruct"));
+        typeDesc.addFieldDesc(elemField);
+    }
+
+    /**
+     * Return type metadata object
+     */
+    public static org.apache.axis.description.TypeDesc getTypeDesc() {
+        return typeDesc;
+    }
+
+    /**
+     * Get Custom Serializer
+     */
+    public static org.apache.axis.encoding.Serializer getSerializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanSerializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+    /**
+     * Get Custom Deserializer
+     */
+    public static org.apache.axis.encoding.Deserializer getDeserializer(
+           java.lang.String mechType, 
+           java.lang.Class _javaType,  
+           javax.xml.namespace.QName _xmlType) {
+        return 
+          new  org.apache.axis.encoding.ser.BeanDeserializer(
+            _javaType, _xmlType, typeDesc);
+    }
+
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPort.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPort.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPort.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,28 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder.mock;
+
+import java.rmi.Remote;
+import java.rmi.RemoteException;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public interface MockPort extends Remote {
+
+    void doMockOperation(String string) throws RemoteException;
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPortImpl.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPortImpl.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockPortImpl.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,34 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder.mock;
+
+import java.rmi.Remote;
+import java.rmi.RemoteException;
+import javax.xml.rpc.Service;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class MockPortImpl implements MockPort {
+    
+    public MockPortImpl() {
+    }
+
+    public void doMockOperation(String string) throws RemoteException {
+
+    }
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockSEIFactory.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockSEIFactory.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockSEIFactory.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,32 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder.mock;
+
+import java.rmi.Remote;
+
+import javax.xml.rpc.Service;
+
+import org.apache.geronimo.axis.client.SEIFactory;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class MockSEIFactory implements SEIFactory {
+    public Remote createServiceEndpoint() {
+        return new MockPortImpl();
+    }
+}

Added: geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockService.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockService.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis-builder/src/test/org/apache/geronimo/axis/builder/mock/MockService.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,28 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.builder.mock;
+
+import javax.xml.rpc.Service;
+import javax.xml.rpc.ServiceException;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public interface MockService extends Service {
+
+    MockPort getMockPort()throws ServiceException; 
+}

Modified: geronimo/trunk/modules/axis/maven.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/maven.xml?view=diff&rev=125375&p1=geronimo/trunk/modules/axis/maven.xml&r1=125374&p2=geronimo/trunk/modules/axis/maven.xml&r2=125375
==============================================================================
--- geronimo/trunk/modules/axis/maven.xml	(original)
+++ geronimo/trunk/modules/axis/maven.xml	Sun Jan 16 15:20:45 2005
@@ -15,7 +15,7 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-<project default="jar"
+<project default="default"
     xmlns:j="jelly:core"
     xmlns:maven="jelly:maven"
     xmlns:deploy="deploy"
@@ -60,18 +60,19 @@
                 <taskdef name="ews" classname="org.apache.geronimo.ews.ws4j2ee.utils.EWSTask">
                     <classpath refid="maven.dependency.classpath"/>
                 </taskdef>
-                <ews outDir="target/generated/samples/echo-jar" module="target/samples/echo.jar">
+ <!--               <ews outDir="target/generated/samples/echo-jar" module="target/samples/echo.jar">
                     <ant:classpath refid="maven.dependency.classpath"/>
                 </ews>
                 <ews outDir="target/generated/samples/echo-war" module="target/samples/echo.war">
                     <ant:classpath refid="maven.dependency.classpath"/>
                 </ews>
-
+-->
                 <!-- The following ant task cause the build to break
                      if building with JAVA 5.  The JAVA 5 'enum' reserved
                  word is used in the source code being compiled. 
                  The generated ANT file might need to pass the
                  -source 1.4 option to the java compiler -->
+<!--
                 <ant:ant antfile="build.xml"
                     inheritall="true"
                     inheritrefs="true"
@@ -80,6 +81,7 @@
                     inheritall="true"
                     inheritrefs="true"
                     dir="target/generated/samples/echo-war"/>
+-->
             </j:jelly>
         </j:if>
     </preGoal>

Modified: geronimo/trunk/modules/axis/project.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/project.xml?view=diff&rev=125375&p1=geronimo/trunk/modules/axis/project.xml&r1=125374&p2=geronimo/trunk/modules/axis/project.xml&r2=125375
==============================================================================
--- geronimo/trunk/modules/axis/project.xml	(original)
+++ geronimo/trunk/modules/axis/project.xml	Sun Jan 16 15:20:45 2005
@@ -353,12 +353,14 @@
     <!-- Build Specification -->
     <!-- =================== -->
     <build>
+<!--
         <resources>
             <resource>
                 <directory>${basedir}/target/xmlbeans</directory>
                 <includes>schema/**</includes>
             </resource>
         </resources>
+-->
         <unitTest>
             <includes>
 	            <include>**/**Test.java</include>

Added: geronimo/trunk/modules/axis/src/etc/META-INF/geronimo-service.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/etc/META-INF/geronimo-service.xml?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/etc/META-INF/geronimo-service.xml	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+    Copyright 2004 The Apache Software Foundation
+
+    Licensed under the Apache License, Version 2.0 (the "License");
+    you may not use this file except in compliance with the License.
+    You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+
+<!--dependencies for jetty-->
+<service xmlns="http://geronimo.apache.org/xml/ns/deployment">
+
+    <dependency>
+        <uri>axis/jars/axis-${axis_version}.jar</uri>
+    </dependency>
+    <dependency>
+        <uri>axis/jars/axis-jaxrpc-${axis_jaxrpc_version}.jar</uri>
+    </dependency>
+    <dependency>
+        <uri>axis/jars/axis-saaj-${axis_saaj_version}.jar</uri>
+    </dependency>
+    <dependency>
+        <uri>axis/jars/axis-wsdl4j-${axis_wsdl4j_version}.jar</uri>
+    </dependency>
+    <dependency>
+        <uri>axis/jars/commons-discovery-${axis_commons_discovery_version}.jar</uri>
+    </dependency>
+    <dependency>
+        <uri>ews/jars/ews-${ews_version}.jar</uri>
+    </dependency>
+
+</service>
\ No newline at end of file

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpoint.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpoint.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpoint.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,103 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.net.URL;
+import java.util.Iterator;
+import java.util.List;
+
+import org.apache.axis.AxisFault;
+import org.apache.axis.NoEndPointException;
+import org.apache.axis.client.Call;
+import org.apache.axis.client.Service;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class GenericServiceEndpoint extends org.apache.axis.client.Stub {
+
+    private final List typeMappings;
+
+    public GenericServiceEndpoint(Service service, List typeMappings, URL location) {
+        this.service = service;
+        this.typeMappings = typeMappings;
+        cachedEndpoint = location;
+    }
+
+    Call createCall() throws java.rmi.RemoteException {
+        try {
+            org.apache.axis.client.Call _call =
+                    (org.apache.axis.client.Call) service.createCall();
+            if (super.maintainSessionSet) {
+                _call.setMaintainSession(super.maintainSession);
+            }
+            if (super.cachedUsername != null) {
+                _call.setUsername(super.cachedUsername);
+            }
+            if (super.cachedPassword != null) {
+                _call.setPassword(super.cachedPassword);
+            }
+            if (super.cachedEndpoint != null) {
+                _call.setTargetEndpointAddress(super.cachedEndpoint);
+            }
+            if (super.cachedTimeout != null) {
+                _call.setTimeout(super.cachedTimeout);
+            }
+            if (super.cachedPortName != null) {
+                _call.setPortName(super.cachedPortName);
+            }
+            java.util.Enumeration keys = super.cachedProperties.keys();
+            while (keys.hasMoreElements()) {
+                java.lang.String key = (java.lang.String) keys.nextElement();
+                _call.setProperty(key, super.cachedProperties.get(key));
+            }
+            // All the type mapping information is registered
+            // when the first call is made.
+            // The type mapping information is actually registered in
+            // the TypeMappingRegistry of the service, which
+            // is the reason why registration is only needed for the first call.
+            //TODO figure out if this can be done during deployment!
+            synchronized (this) {
+                if (firstCall()) {
+                    // must set encoding style before registering serializers
+                    //TODO these constants probably need to be parameters of GSE.
+                    _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
+                    _call.setEncodingStyle(org.apache.axis.Constants.URI_SOAP11_ENC);
+                    for (Iterator iterator = typeMappings.iterator(); iterator.hasNext();) {
+                        TypeMappingInfo info = (TypeMappingInfo) iterator.next();
+                        _call.registerTypeMapping(info.getClazz(), info.getqName(), info.getSerializerClass(), info.getDeserializerClass(), false);
+                    }
+                }
+            }
+            return _call;
+        } catch (java.lang.Throwable t) {
+            throw new org.apache.axis.AxisFault("Failure trying to get the Call object", t);
+        }
+    }
+
+    void checkCachedEndpoint() throws NoEndPointException {
+        if (cachedEndpoint == null) {
+            throw new NoEndPointException();
+        }
+    }
+
+    void setUpCall(Call call) throws AxisFault {
+        setRequestHeaders(call);
+        setAttachments(call);
+    }
+
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpointWrapper.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpointWrapper.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/GenericServiceEndpointWrapper.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,143 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.util.Iterator;
+import java.io.Serializable;
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Stub;
+
+import org.apache.axis.message.SOAPHeaderElement;
+import org.apache.axis.client.Call;
+import org.apache.axis.AxisFault;
+import org.apache.axis.NoEndPointException;
+
+/**
+ * this gets enhanced to be the proxy.
+ * @version $Rev:  $ $Date:  $
+ */
+public class GenericServiceEndpointWrapper implements Stub, Serializable {
+    private final GenericServiceEndpoint genericServiceEndpoint;
+
+    public GenericServiceEndpointWrapper(GenericServiceEndpoint genericServiceEndpoint) {
+        this.genericServiceEndpoint = genericServiceEndpoint;
+    }
+
+    public void _setProperty(String s, Object o) {
+        genericServiceEndpoint._setProperty(s, o);
+    }
+
+    public Object _getProperty(String s) {
+        return genericServiceEndpoint._getProperty(s);
+    }
+
+    public Object removeProperty(String s) {
+        return genericServiceEndpoint.removeProperty(s);
+    }
+
+    public Iterator _getPropertyNames() {
+        return genericServiceEndpoint._getPropertyNames();
+    }
+
+    public void setUsername(String s) {
+        genericServiceEndpoint.setUsername(s);
+    }
+
+    public String getUsername() {
+        return genericServiceEndpoint.getUsername();
+    }
+
+    public void setPassword(String s) {
+        genericServiceEndpoint.setPassword(s);
+    }
+
+    public String getPassword() {
+        return genericServiceEndpoint.getPassword();
+    }
+
+    public int getTimeout() {
+        return genericServiceEndpoint.getTimeout();
+    }
+
+    public void setTimeout(int i) {
+        genericServiceEndpoint.setTimeout(i);
+    }
+
+    public QName getPortName() {
+        return genericServiceEndpoint.getPortName();
+    }
+
+    public void setPortName(QName qName) {
+        genericServiceEndpoint.setPortName(qName);
+    }
+
+    public void setPortName(String s) {
+        genericServiceEndpoint.setPortName(s);
+    }
+
+    public void setMaintainSession(boolean b) {
+        genericServiceEndpoint.setMaintainSession(b);
+    }
+
+    public void setHeader(String s, String s1, Object o) {
+        genericServiceEndpoint.setHeader(s, s1, o);
+    }
+
+    public void setHeader(SOAPHeaderElement soapHeaderElement) {
+        genericServiceEndpoint.setHeader(soapHeaderElement);
+    }
+
+    public void extractAttachments(Call call) {
+        genericServiceEndpoint.extractAttachments(call);
+    }
+
+    public void addAttachment(Object o) {
+        genericServiceEndpoint.addAttachment(o);
+    }
+
+    public SOAPHeaderElement getHeader(String s, String s1) {
+        return genericServiceEndpoint.getHeader(s, s1);
+    }
+
+    public SOAPHeaderElement getResponseHeader(String s, String s1) {
+        return genericServiceEndpoint.getResponseHeader(s, s1);
+    }
+
+    public SOAPHeaderElement[] getHeaders() {
+        return genericServiceEndpoint.getHeaders();
+    }
+
+    public SOAPHeaderElement[] getResponseHeaders() {
+        return genericServiceEndpoint.getResponseHeaders();
+    }
+
+    public Object[] getAttachments() {
+        return genericServiceEndpoint.getAttachments();
+    }
+
+    public void clearHeaders() {
+        genericServiceEndpoint.clearHeaders();
+    }
+
+    public void clearAttachments() {
+        genericServiceEndpoint.clearAttachments();
+    }
+
+    void checkCachedEndpoint() throws NoEndPointException {
+        genericServiceEndpoint.checkCachedEndpoint();
+    }
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/NoOverrideCallbackFilter.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/NoOverrideCallbackFilter.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/NoOverrideCallbackFilter.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,52 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
+
+import net.sf.cglib.proxy.CallbackFilter;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class NoOverrideCallbackFilter implements CallbackFilter {
+    private Class superClass;
+
+    public NoOverrideCallbackFilter(Class superClass) {
+        this.superClass = superClass;
+    }
+
+    public int accept(Method method) {
+        // we don't intercept non-public methods like finalize
+        if (!Modifier.isPublic(method.getModifiers())) {
+            return 0;
+        }
+
+        if (method.getName().equals("remove") && Modifier.isAbstract(method.getModifiers())) {
+            return 1;
+        }
+
+        try {
+            // if the super class defined this method don't intercept
+            superClass.getMethod(method.getName(), method.getParameterTypes());
+            return 0;
+        } catch (Throwable e) {
+            return 1;
+        }
+    }
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/OperationInfo.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/OperationInfo.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/OperationInfo.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,73 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.io.Serializable;
+
+import javax.xml.namespace.QName;
+
+import org.apache.axis.description.OperationDesc;
+import org.apache.axis.client.Call;
+import org.apache.axis.soap.SOAPConstants;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class OperationInfo implements Serializable {
+
+    private final OperationDesc operationDesc;
+    private final boolean useSOAPAction;
+    private final String soapActionURI;
+    private final SOAPConstants soapVersion;
+    private final QName operationName;
+
+    public OperationInfo(OperationDesc operationDesc, boolean useSOAPAction, String soapActionURI, SOAPConstants soapVersion, QName operationName) {
+        this.operationDesc = operationDesc;
+        this.useSOAPAction = useSOAPAction;
+        this.soapActionURI = soapActionURI;
+        this.soapVersion = soapVersion;
+        this.operationName = operationName;
+    }
+
+    public OperationDesc getOperationDesc() {
+        return operationDesc;
+    }
+
+    public boolean isUseSOAPAction() {
+        return useSOAPAction;
+    }
+
+    public String getSoapActionURI() {
+        return soapActionURI;
+    }
+
+    public SOAPConstants getSoapVersion() {
+        return soapVersion;
+    }
+
+    public QName getOperationName() {
+        return operationName;
+    }
+
+    public void prepareCall(Call call) {
+        call.setOperation(operationDesc);
+        call.setUseSOAPAction(useSOAPAction);
+        call.setSOAPActionURI(soapActionURI);
+        call.setSOAPVersion(soapVersion);
+        call.setOperationName(operationName);
+    }
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactory.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactory.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactory.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,30 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.rmi.Remote;
+import javax.xml.rpc.Service;
+import javax.xml.rpc.ServiceException;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public interface SEIFactory {
+
+    Remote createServiceEndpoint() throws ServiceException;
+    
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactoryImpl.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactoryImpl.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SEIFactoryImpl.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,72 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.lang.reflect.InvocationTargetException;
+import java.rmi.Remote;
+import java.io.Serializable;
+import java.io.ObjectStreamException;
+import java.util.List;
+import java.net.URL;
+import javax.xml.rpc.ServiceException;
+
+import net.sf.cglib.proxy.Callback;
+import net.sf.cglib.proxy.Enhancer;
+import net.sf.cglib.reflect.FastConstructor;
+import net.sf.cglib.reflect.FastClass;
+import org.apache.axis.client.Service;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class SEIFactoryImpl implements SEIFactory, Serializable {
+    private static final Class[] SERVICE_ENDPOINT_CONSTRUCTOR_TYPES = new Class[]{GenericServiceEndpoint.class};
+
+    private final Class serviceEndpointClass;
+    private final OperationInfo[] operationInfos;
+    private transient final FastConstructor constructor;
+    private final ServiceImpl serviceImpl;
+    private final List typeMappings;
+    private final URL location;
+
+    public SEIFactoryImpl(Class serviceEndpointClass, OperationInfo[] operationInfos, ServiceImpl serviceImpl, List typeMappings, URL location) {
+        this.serviceEndpointClass = serviceEndpointClass;
+        this.operationInfos = operationInfos;
+        this.constructor = FastClass.create(serviceEndpointClass).getConstructor(SERVICE_ENDPOINT_CONSTRUCTOR_TYPES);
+        this.serviceImpl = serviceImpl;
+        this.typeMappings = typeMappings;
+        this.location = location;
+    }
+
+    public Remote createServiceEndpoint() throws ServiceException {
+        Service service = serviceImpl.getService();
+        GenericServiceEndpoint serviceEndpoint = new GenericServiceEndpoint(service, typeMappings, location);
+        Callback callback = new ServiceEndpointMethodInterceptor(serviceEndpoint, operationInfos);
+        Callback[] callbacks = new Callback[]{SerializableNoOp.INSTANCE, callback};
+        Enhancer.registerCallbacks(serviceEndpointClass, callbacks);
+        try {
+            return (Remote) constructor.newInstance(new Object[]{serviceEndpoint});
+        } catch (InvocationTargetException e) {
+            e.getTargetException().printStackTrace();
+            throw new ServiceException("Could not construct service instance", e.getTargetException());
+        }
+    }
+
+    private Object readResolve() throws ObjectStreamException {
+        return new SEIFactoryImpl(serviceEndpointClass, operationInfos, serviceImpl, typeMappings, location);
+    }
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SerializableNoOp.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SerializableNoOp.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/SerializableNoOp.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,30 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.io.Serializable;
+
+import net.sf.cglib.proxy.NoOp;
+
+/**
+ * Serializable version of the cglib NoOp.
+ * @version $Rev:  $ $Date:  $
+ */
+public class SerializableNoOp implements NoOp, Serializable {
+
+    public static final NoOp INSTANCE = new SerializableNoOp() {} ;
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceEndpointMethodInterceptor.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceEndpointMethodInterceptor.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceEndpointMethodInterceptor.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,68 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.lang.reflect.Method;
+import java.io.Serializable;
+
+import net.sf.cglib.proxy.MethodInterceptor;
+import net.sf.cglib.proxy.MethodProxy;
+import org.apache.axis.client.Call;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class ServiceEndpointMethodInterceptor implements MethodInterceptor{
+
+    private final GenericServiceEndpoint stub;
+    private final OperationInfo[] operations;
+
+    public ServiceEndpointMethodInterceptor(GenericServiceEndpoint stub, OperationInfo[] operations) {
+        this.stub = stub;
+        this.operations = operations;
+    }
+
+    public Object intercept(Object o, Method method, Object[] objects, MethodProxy methodProxy) throws Throwable {
+        int index = methodProxy.getSuperIndex();
+        OperationInfo operationInfo = operations[index];
+        if (operationInfo == null) {
+            throw new RuntimeException("Operation not mapped: " + method.getName());
+        }
+        stub.checkCachedEndpoint();
+
+        Call call = stub.createCall();
+
+        operationInfo.prepareCall(call);
+
+        stub.setUpCall(call);
+        java.lang.Object response = call.invoke(objects);
+
+        if (response instanceof java.rmi.RemoteException) {
+            throw (java.rmi.RemoteException)response;
+        }
+        else {
+            stub.extractAttachments(call);
+            Class returnType = operationInfo.getOperationDesc().getReturnClass();
+            if (response == null || returnType.isAssignableFrom(response.getClass())) {
+                return response;
+            } else {
+                return org.apache.axis.utils.JavaUtils.convert(response, returnType);
+            }
+        }
+    }
+
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceImpl.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceImpl.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceImpl.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,130 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.Serializable;
+import java.net.URL;
+import java.rmi.Remote;
+import java.util.Iterator;
+import java.util.Map;
+import javax.xml.namespace.QName;
+import javax.xml.rpc.Call;
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.encoding.TypeMappingRegistry;
+import javax.xml.rpc.handler.HandlerRegistry;
+
+import org.apache.axis.client.Service;
+
+
+/**
+ * @version $Rev$ $Date$
+ */
+public class ServiceImpl implements javax.xml.rpc.Service, Serializable {
+
+    private transient Service delegate;
+    private final Map portToImplementationMap;
+
+    public ServiceImpl(Map portToImplementationMap) {
+        this.portToImplementationMap = portToImplementationMap;
+        this.delegate = new Service();
+    }
+
+    public Remote getPort(QName qName, Class portClass) throws ServiceException {
+        if (qName != null) {
+            String portName = qName.getLocalPart();
+            Remote port = internalGetPort(portName);
+            if (port != null) {
+                return port;
+            }
+        }
+        String fqcn = portClass.getName();
+        String portName = fqcn.substring(fqcn.lastIndexOf('.'));
+        Remote port = internalGetPort(portName);
+        if (port != null) {
+            return port;
+        }
+        return delegate.getPort(qName, portClass);
+    }
+
+    public Remote getPort(Class portClass) throws ServiceException {
+        String fqcn = portClass.getName();
+        String portName = fqcn.substring(fqcn.lastIndexOf('.'));
+        Remote port = internalGetPort(portName);
+        if (port != null) {
+            return port;
+        }
+        return delegate.getPort(portClass);
+    }
+
+    public Call[] getCalls(QName qName) throws ServiceException {
+        return delegate.getCalls(qName);
+    }
+
+    public Call createCall(QName qName) throws ServiceException {
+        return delegate.createCall(qName);
+    }
+
+    public Call createCall(QName qName, QName qName1) throws ServiceException {
+        return delegate.createCall(qName,  qName1);
+    }
+
+    public Call createCall(QName qName, String s) throws ServiceException {
+        return delegate.createCall(qName, s);
+    }
+
+    public Call createCall() throws ServiceException {
+        return delegate.createCall();
+    }
+
+    public QName getServiceName() {
+        return delegate.getServiceName();
+    }
+
+    public Iterator getPorts() throws ServiceException {
+        return portToImplementationMap.values().iterator();
+    }
+
+    public URL getWSDLDocumentLocation() {
+        return delegate.getWSDLDocumentLocation();
+    }
+
+    public TypeMappingRegistry getTypeMappingRegistry() {
+        return delegate.getTypeMappingRegistry();
+    }
+
+    public HandlerRegistry getHandlerRegistry() {
+        return delegate.getHandlerRegistry();
+    }
+
+    Remote internalGetPort(String portName) throws ServiceException {
+        if (portToImplementationMap.containsKey(portName)) {
+            return (Remote) portToImplementationMap.get(portName);
+        }
+        return null;
+    }
+
+    private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
+        in.defaultReadObject();
+        delegate = new Service();
+    }
+
+    Service getService() {
+        return delegate;
+    }
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceMethodInterceptor.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceMethodInterceptor.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceMethodInterceptor.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,54 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.lang.reflect.Method;
+import java.util.Map;
+import java.io.Serializable;
+
+import javax.xml.rpc.ServiceException;
+import javax.xml.rpc.Service;
+
+import net.sf.cglib.proxy.MethodInterceptor;
+import net.sf.cglib.proxy.MethodProxy;
+
+/**
+ * @version $Rev$ $Date$
+ */
+public class ServiceMethodInterceptor implements MethodInterceptor, Serializable {
+
+    private final Map seiFactoryMap;
+
+    public ServiceMethodInterceptor(Map seiFactoryMap) {
+        this.seiFactoryMap = seiFactoryMap;
+    }
+
+    public Object intercept(Object o, Method method, Object[] objects, MethodProxy methodProxy) throws Throwable {
+        if (objects.length == 0) {
+            String methodName = method.getName();
+            if (methodName.startsWith("get")) {
+                String portName = methodName.substring(3);
+                SEIFactory seiFactory = (SEIFactory) seiFactoryMap.get(portName);
+                if (seiFactory != null) {
+                    return seiFactory.createServiceEndpoint();
+                }
+            }
+        }
+        throw new ServiceException("Unrecognized method name or argument list: " + method.getName());
+    }
+
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceRefAddr.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceRefAddr.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/ServiceRefAddr.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,66 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
+import java.lang.reflect.InvocationTargetException;
+import java.util.Map;
+import javax.naming.RefAddr;
+
+import net.sf.cglib.proxy.Callback;
+import net.sf.cglib.proxy.CallbackFilter;
+import net.sf.cglib.proxy.Enhancer;
+import net.sf.cglib.proxy.MethodInterceptor;
+import net.sf.cglib.reflect.FastConstructor;
+import net.sf.cglib.reflect.FastClass;
+import org.apache.axis.client.Service;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class ServiceRefAddr extends RefAddr {
+
+    private final static String TYPE = "org.apache.geronimo.axis.ServiceRefType";
+    private final static Class[] CONSTRUCTOR_TYPES = new Class[] {Map.class};
+
+    private final Class serviceClass;
+    private final Callback[] methodInterceptors;
+    private final Map ports;
+    //THIS IS NOT SERIALIZABLE!
+    private final FastConstructor constructor;
+
+    public ServiceRefAddr(Class serviceClass, MethodInterceptor methodInterceptor, Map ports) {
+        super(TYPE);
+        this.serviceClass = serviceClass;
+        this.methodInterceptors = new Callback[] {SerializableNoOp.INSTANCE,  methodInterceptor};
+        this.ports = ports;
+        this.constructor = FastClass.create(serviceClass).getConstructor(CONSTRUCTOR_TYPES);
+    }
+
+    public Object getContent() {
+        try {
+            Enhancer.registerCallbacks(serviceClass, methodInterceptors);
+            Object serviceInstance =  constructor.newInstance(new Object[] {ports});
+            return serviceInstance;
+        } catch (InvocationTargetException e) {
+            throw new RuntimeException("Could not create instance", e);
+        }
+    }
+
+
+}

Added: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/TypeMappingInfo.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/TypeMappingInfo.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/client/TypeMappingInfo.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,54 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.axis.client;
+
+import java.io.Serializable;
+import javax.xml.namespace.QName;
+
+/**
+ * @version $Rev:  $ $Date:  $
+ */
+public class TypeMappingInfo implements Serializable {
+
+    private final Class clazz;
+    private final QName qName;
+    private final Class serializerClass;
+    private final Class deserializerClass;
+
+    public TypeMappingInfo(Class clazz, QName qName, Class serializerClass, Class deserializerClass) {
+        this.clazz = clazz;
+        this.qName = qName;
+        this.serializerClass = serializerClass;
+        this.deserializerClass = deserializerClass;
+    }
+
+    public Class getClazz() {
+        return clazz;
+    }
+
+    public QName getqName() {
+        return qName;
+    }
+
+    public Class getSerializerClass() {
+        return serializerClass;
+    }
+
+    public Class getDeserializerClass() {
+        return deserializerClass;
+    }
+}

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java&r1=125374&p2=geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java	(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AbstractWebServiceTest.java	Sun Jan 16 15:20:45 2005
@@ -143,6 +143,7 @@
                         null,
                         TestingUtils.RESOURCE_REFERANCE_BUILDER,
                         null,
+                        null,
                         null);
         return earConfigBuilder;
     }

Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java&r1=125374&p2=geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java	(original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/preconditions/DynamicEJBDeploymentTest.java	Sun Jan 16 15:20:45 2005
@@ -89,10 +89,11 @@
                         null,
                         resourceReferenceBuilder,
                         null,
+                        null,
                         null);
 
         
-            ObjectName config = TestingUtils.installAndStartEJB(jarFile,AxisGeronimoConstants.STORE,earConfigBuilder,kernel);
+//            ObjectName config = TestingUtils.installAndStartEJB(jarFile,AxisGeronimoConstants.STORE,earConfigBuilder,kernel);
             
 //            ObjectName ejbname = new ObjectName("test:name=ejbwsGBean");
 //            GBeanMBean ejbBean = new GBeanMBean(EJBWSGBean.getGBeanInfo());

Modified: geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java?view=diff&rev=125375&p1=geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java&r1=125374&p2=geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java	(original)
+++ geronimo/trunk/modules/client-builder/src/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java	Sun Jan 16 15:20:45 2005
@@ -52,6 +52,7 @@
 import org.apache.geronimo.j2ee.deployment.ModuleBuilder;
 import org.apache.geronimo.j2ee.deployment.RefContext;
 import org.apache.geronimo.j2ee.deployment.ResourceReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
 import org.apache.geronimo.j2ee.management.impl.J2EEAppClientModuleImpl;
@@ -91,6 +92,7 @@
     private final EJBReferenceBuilder ejbReferenceBuilder;
     private final ModuleBuilder connectorModuleBuilder;
     private final ResourceReferenceBuilder resourceReferenceBuilder;
+    private final ServiceReferenceBuilder serviceReferenceBuilder;
 
     public AppClientModuleBuilder(URI defaultClientParentId,
                                   URI defaultServerParentId,
@@ -99,6 +101,7 @@
                                   EJBReferenceBuilder ejbReferenceBuilder,
                                   ModuleBuilder connectorModuleBuilder,
                                   ResourceReferenceBuilder resourceReferenceBuilder,
+                                  ServiceReferenceBuilder serviceReferenceBuilder,
                                   ConfigurationStore store,
                                   Repository repository,
                                   Kernel kernel) {
@@ -112,6 +115,7 @@
         this.ejbReferenceBuilder = ejbReferenceBuilder;
         this.connectorModuleBuilder = connectorModuleBuilder;
         this.resourceReferenceBuilder = resourceReferenceBuilder;
+        this.serviceReferenceBuilder = serviceReferenceBuilder;
     }
 
     public Module createModule(File plan, JarFile moduleFile) throws DeploymentException {
@@ -343,7 +347,7 @@
                             connectionTrackerObjectName,
                             null,
                             null,
-                            RefContext.derivedClientRefContext(earContext.getRefContext(), ejbReferenceBuilder, resourceReferenceBuilder));
+                            RefContext.derivedClientRefContext(earContext.getRefContext(), ejbReferenceBuilder, resourceReferenceBuilder, serviceReferenceBuilder));
                 } catch (Exception e) {
                     throw new DeploymentException("Could not create a deployment context for the app client", e);
                 }
@@ -546,6 +550,7 @@
                 appClient.getResourceRefArray(), geronimoAppClient.getResourceRefArray(),
                 appClient.getResourceEnvRefArray(), geronimoAppClient.getResourceEnvRefArray(),
                 appClient.getMessageDestinationRefArray(),
+                appClient.getServiceRefArray(),
                 cl);
 
     }
@@ -582,6 +587,7 @@
         infoBuilder.addReference("EJBReferenceBuilder", EJBReferenceBuilder.class);
         infoBuilder.addReference("ConnectorModuleBuilder", ModuleBuilder.class);
         infoBuilder.addReference("ResourceReferenceBuilder", ResourceReferenceBuilder.class);
+        infoBuilder.addReference("ServiceReferenceBuilder", ServiceReferenceBuilder.class);
         infoBuilder.addReference("Store", ConfigurationStore.class);
         infoBuilder.addReference("Repository", Repository.class);
 
@@ -596,6 +602,7 @@
                                                 "EJBReferenceBuilder",
                                                 "ConnectorModuleBuilder",
                                                 "ResourceReferenceBuilder",
+                                                "ServiceReferenceBuilder",
                                                 "Store",
                                                 "Repository",
                                                 "kernel"});

Modified: geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java&r1=125374&p2=geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java	(original)
+++ geronimo/trunk/modules/client-builder/src/test/org/apache/geronimo/client/builder/PlanParsingTest.java	Sun Jan 16 15:20:45 2005
@@ -12,7 +12,7 @@
  */
 public class PlanParsingTest extends TestCase {
 
-    private AppClientModuleBuilder builder = new AppClientModuleBuilder(null, null, null, null,null, null, null, null, null, null);
+    private AppClientModuleBuilder builder = new AppClientModuleBuilder(null, null, null, null,null, null, null, null, null, null, null);
     File basedir = new File(System.getProperty("basedir", "."));
 
     public void testResourceRef() throws Exception {

Modified: geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java&r1=125374&p2=geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java	(original)
+++ geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_0ConfigBuilderTest.java	Sun Jan 16 15:20:45 2005
@@ -32,13 +32,16 @@
 import java.util.Collections;
 import java.util.List;
 import java.util.Set;
+import java.util.Map;
 import java.util.jar.JarFile;
 import javax.management.ObjectName;
 import javax.sql.DataSource;
+import javax.xml.namespace.QName;
 
 import junit.framework.TestCase;
 import org.apache.geronimo.common.DeploymentException;
 import org.apache.geronimo.deployment.util.DeploymentUtil;
+import org.apache.geronimo.deployment.DeploymentContext;
 import org.apache.geronimo.gbean.GBeanData;
 import org.apache.geronimo.gbean.jmx.GBeanMBean;
 import org.apache.geronimo.j2ee.deployment.EARConfigBuilder;
@@ -46,6 +49,7 @@
 import org.apache.geronimo.j2ee.deployment.Module;
 import org.apache.geronimo.j2ee.deployment.ModuleBuilder;
 import org.apache.geronimo.j2ee.deployment.RefContext;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContextImpl;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
@@ -200,7 +204,14 @@
                     connectionTrackerName,
                     null,
                     null,
-                    new RefContext(null, moduleBuilder));
+                    new RefContext(null,
+                            moduleBuilder,
+                            new ServiceReferenceBuilder() {
+                        //it could return a Service or a Reference, we don't care
+                        public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+                            return null;
+                        }
+                    }));
 
             action.install(moduleBuilder, earContext, module);
             earContext.getClassLoader(null);
@@ -225,7 +236,7 @@
         JarFile rarFile = null;
         try {
             rarFile = DeploymentUtil.createJarFile(new File(basedir, "target/test-ear-noger.ear"));
-            EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, null, connectionTrackerName, null, null, null, null, null, null, new ConnectorModuleBuilder(defaultParentId, defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes, defaultXATransactionCaching, defaultXAThreadCaching, null, kernel), null, null, kernel);
+            EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, null, connectionTrackerName, null, null, null, null, null, null, new ConnectorModuleBuilder(defaultParentId, defaultMaxSize, defaultMinSize, defaultBlockingTimeoutMilliseconds, defaultidleTimeoutMinutes, defaultXATransactionCaching, defaultXAThreadCaching, null, kernel), null, null, null, kernel);
             File tempDir = null;
             try {
                 tempDir = DeploymentUtil.createTempDir();

Modified: geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java&r1=125374&p2=geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java	(original)
+++ geronimo/trunk/modules/connector-builder/src/test/org/apache/geronimo/connector/deployment/RAR_1_5ConfigBuilderTest.java	Sun Jan 16 15:20:45 2005
@@ -34,15 +34,18 @@
 import java.util.Set;
 import javax.management.ObjectName;
 import javax.sql.DataSource;
+import javax.xml.namespace.QName;
 
 import junit.framework.TestCase;
 import org.apache.geronimo.deployment.util.DeploymentUtil;
+import org.apache.geronimo.deployment.DeploymentContext;
 import org.apache.geronimo.gbean.GBeanData;
 import org.apache.geronimo.gbean.GBeanInfo;
 import org.apache.geronimo.j2ee.deployment.EARContext;
 import org.apache.geronimo.j2ee.deployment.Module;
 import org.apache.geronimo.j2ee.deployment.ModuleBuilder;
 import org.apache.geronimo.j2ee.deployment.RefContext;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContextImpl;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
@@ -53,6 +56,7 @@
 import org.apache.geronimo.xbeans.geronimo.GerConnectorDocument;
 import org.apache.geronimo.xbeans.j2ee.ConnectorDocument;
 import org.apache.geronimo.schema.SchemaConversionUtils;
+import org.apache.geronimo.common.DeploymentException;
 import org.apache.xmlbeans.XmlOptions;
 import org.tranql.sql.jdbc.JDBCUtil;
 
@@ -122,10 +126,6 @@
     
     private void executeTestBuildModule(InstallAction action) throws Exception {
         J2eeContext j2eeContext = new J2eeContextImpl("test.domain", "testServer", "null", "org/apache/geronimo/j2ee/deployment/test", null, null);
-//        String j2eeDomainName = "geronimo.server";
-//        String j2eeServerName = "TestGeronimoServer";
-//        String j2eeApplicationName = "null";
-//        String j2eeModuleName = "org/apache/geronimo/j2ee/deployment/test";
         String resourceAdapterName = "testRA";
         ObjectName connectionTrackerName = new ObjectName("geronimo.connector:service=ConnectionTracker");
 
@@ -156,7 +156,14 @@
                     connectionTrackerName,
                     null,
                     null,
-                    new RefContext(null, null));
+                    new RefContext(null,
+                            moduleBuilder, 
+                            new ServiceReferenceBuilder() {
+                         //it could return a Service or a Reference, we don't care
+                         public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+                             return null;
+                         }
+                     }));
 
             action.install(moduleBuilder, earContext, module);
             earContext.getClassLoader(null);

Modified: geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java?view=diff&rev=125375&p1=geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java&r1=125374&p2=geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java	(original)
+++ geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java	Sun Jan 16 15:20:45 2005
@@ -76,6 +76,7 @@
     private final ModuleBuilder appClientConfigBuilder;
     private final EJBReferenceBuilder ejbReferenceBuilder;
     private final ResourceReferenceBuilder resourceReferenceBuilder;
+    private final ServiceReferenceBuilder serviceReferenceBuilder;
 
     private final URI defaultParentId;
     private final String j2eeServerName;
@@ -87,7 +88,7 @@
     private final ObjectName nonTransactionalTimerObjectName;
 
 
-    public EARConfigBuilder(URI defaultParentId, ObjectName j2eeServer, ObjectName transactionContextManagerObjectName, ObjectName connectionTrackerObjectName, ObjectName transactionalTimerObjectName, ObjectName nonTransactionalTimerObjectName, Repository repository, ModuleBuilder ejbConfigBuilder, EJBReferenceBuilder ejbReferenceBuilder, ModuleBuilder webConfigBuilder, ModuleBuilder connectorConfigBuilder, ResourceReferenceBuilder resourceReferenceBuilder, ModuleBuilder appClientConfigBuilder, Kernel kernel) {
+    public EARConfigBuilder(URI defaultParentId, ObjectName j2eeServer, ObjectName transactionContextManagerObjectName, ObjectName connectionTrackerObjectName, ObjectName transactionalTimerObjectName, ObjectName nonTransactionalTimerObjectName, Repository repository, ModuleBuilder ejbConfigBuilder, EJBReferenceBuilder ejbReferenceBuilder, ModuleBuilder webConfigBuilder, ModuleBuilder connectorConfigBuilder, ResourceReferenceBuilder resourceReferenceBuilder, ModuleBuilder appClientConfigBuilder, ServiceReferenceBuilder serviceReferenceBuilder, Kernel kernel) {
         this.kernel = kernel;
         this.repository = repository;
         this.defaultParentId = defaultParentId;
@@ -101,6 +102,7 @@
         this.webConfigBuilder = webConfigBuilder;
         this.connectorConfigBuilder = connectorConfigBuilder;
         this.appClientConfigBuilder = appClientConfigBuilder;
+        this.serviceReferenceBuilder = serviceReferenceBuilder;
         this.transactionContextManagerObjectName = transactionContextManagerObjectName;
         this.connectionTrackerObjectName = connectionTrackerObjectName;
         this.transactionalTimerObjectName = transactionalTimerObjectName;
@@ -287,7 +289,7 @@
                         connectionTrackerObjectName,
                         transactionalTimerObjectName,
                         nonTransactionalTimerObjectName,
-                        new RefContext(ejbReferenceBuilder, resourceReferenceBuilder));
+                        new RefContext(ejbReferenceBuilder, resourceReferenceBuilder, serviceReferenceBuilder));
             } catch (MalformedObjectNameException e) {
                 throw new DeploymentException(e);
             }
@@ -534,6 +536,7 @@
         infoFactory.addReference("ConnectorConfigBuilder", ModuleBuilder.class);
         infoFactory.addReference("ResourceReferenceBuilder", ResourceReferenceBuilder.class);
         infoFactory.addReference("AppClientConfigBuilder", ModuleBuilder.class);
+        infoFactory.addReference("ServiceReferenceBuilder", ServiceReferenceBuilder.class);
 
         infoFactory.addAttribute("kernel", Kernel.class, false);
 
@@ -553,6 +556,7 @@
             "ConnectorConfigBuilder",
             "ResourceReferenceBuilder",
             "AppClientConfigBuilder",
+            "ServiceReferenceBuilder",
             "kernel"
         });
 

Modified: geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java?view=diff&rev=125375&p1=geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java&r1=125374&p2=geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java	(original)
+++ geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/RefContext.java	Sun Jan 16 15:20:45 2005
@@ -20,10 +20,12 @@
 import java.net.URISyntaxException;
 import java.util.HashMap;
 import java.util.Map;
+import java.util.List;
 
 import javax.management.MalformedObjectNameException;
 import javax.management.ObjectName;
 import javax.naming.Reference;
+import javax.xml.namespace.QName;
 
 import org.apache.geronimo.common.DeploymentException;
 import org.apache.geronimo.common.AmbiguousEJBRefException;
@@ -32,6 +34,7 @@
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
 import org.apache.geronimo.gbean.GBeanData;
+import org.apache.geronimo.deployment.DeploymentContext;
 
 /**
  * @version $Rev: 46019 $ $Date: 2004-09-14 02:56:06 -0700 (Tue, 14 Sep 2004) $
@@ -40,6 +43,7 @@
 
     private final EJBReferenceBuilder ejbReferenceBuilder;
     private final ResourceReferenceBuilder resourceReferenceBuilder;
+    private final ServiceReferenceBuilder serviceReferenceBuilder;
 
     private final Map ejbRemoteIndex;
     private final Map ejbLocalIndex;
@@ -52,9 +56,10 @@
     private final Map resourceModuleDataMap;
 
 
-    public RefContext(EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder) {
+    public RefContext(EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder, ServiceReferenceBuilder serviceReferenceBuilder) {
         assert ejbReferenceBuilder != null: "ejbReferenceBuilder is null";
         assert resourceReferenceBuilder != null: "resourceReferenceBuilder is null";
+        assert serviceReferenceBuilder != null: "serviceReferenceBuilder is null";
 
         ejbRemoteIndex = new HashMap();
         ejbLocalIndex = new HashMap();
@@ -65,19 +70,21 @@
         resourceModuleDataMap = new HashMap();
         this.ejbReferenceBuilder = ejbReferenceBuilder;
         this.resourceReferenceBuilder = resourceReferenceBuilder;
+        this.serviceReferenceBuilder = serviceReferenceBuilder;
     }
 
-    public static RefContext derivedClientRefContext(RefContext refContext, EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder) {
-        return new RefContext(refContext, ejbReferenceBuilder, resourceReferenceBuilder);
+    public static RefContext derivedClientRefContext(RefContext refContext, EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder, ServiceReferenceBuilder serviceReferenceBuilder) {
+        return new RefContext(refContext, ejbReferenceBuilder, resourceReferenceBuilder, serviceReferenceBuilder);
     }
 
-    private RefContext(RefContext refContext, EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder) {
+    private RefContext(RefContext refContext, EJBReferenceBuilder ejbReferenceBuilder, ResourceReferenceBuilder resourceReferenceBuilder, ServiceReferenceBuilder serviceReferenceBuilder) {
         assert ejbReferenceBuilder != null: "ejbReferenceBuilder is null";
         assert resourceReferenceBuilder != null: "resourceReferenceBuilder is null";
         assert refContext != null: "ejbRefContext is null";
 
         this.ejbReferenceBuilder = ejbReferenceBuilder;
         this.resourceReferenceBuilder = resourceReferenceBuilder;
+        this.serviceReferenceBuilder = serviceReferenceBuilder;
         this.ejbRemoteIndex = refContext.ejbRemoteIndex;
         this.ejbLocalIndex = new HashMap();//no local ejb refs
         this.ejbInterfaceIndex = refContext.ejbInterfaceIndex;
@@ -276,6 +283,10 @@
             ObjectName containerName = resourceReferenceBuilder.locateResourceName(query);
             return containerName.getCanonicalName();
         }
+    }
+
+    public Object getServiceReference(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+        return serviceReferenceBuilder.createService(serviceInterface, wsdlURI, jaxrpcMappingURI, serviceQName, portComponentRefMap, handlers, deploymentContext, classLoader);
     }
 
     private String getContainerId(URI module, String ejbLink, Map references) throws AmbiguousEJBRefException, UnknownEJBRefException {

Added: geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/ServiceReferenceBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/ServiceReferenceBuilder.java?view=auto&rev=125375
==============================================================================
--- (empty file)
+++ geronimo/trunk/modules/j2ee-builder/src/java/org/apache/geronimo/j2ee/deployment/ServiceReferenceBuilder.java	Sun Jan 16 15:20:45 2005
@@ -0,0 +1,37 @@
+/**
+ *
+ * Copyright 2003-2004 The Apache Software Foundation
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.geronimo.j2ee.deployment;
+
+import java.net.URI;
+import java.util.Map;
+import java.util.List;
+import javax.naming.Reference;
+import javax.xml.namespace.QName;
+
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.deployment.DeploymentContext;
+
+/**
+ * @version $Rev$ $Date$
+ */
+public interface ServiceReferenceBuilder {
+
+    //it could return a Service or a Reference, we don't care
+    Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException;
+
+    //TODO a locate port method for links.
+}

Modified: geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java&r1=125374&p2=geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java	(original)
+++ geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EARConfigBuilderTest.java	Sun Jan 16 15:20:45 2005
@@ -41,7 +41,8 @@
     private static MockWARConfigBuilder webConfigBuilder = new MockWARConfigBuilder();
     private static MockConnectorConfigBuilder connectorConfigBuilder = new MockConnectorConfigBuilder();
     private static ResourceReferenceBuilder resourceReferenceBuilder = null;
-    private static ModuleBuilder appClientConfigBuilder;
+    private static ModuleBuilder appClientConfigBuilder = null;
+    private static ServiceReferenceBuilder serviceReferenceBuilder = null;
 
     private static final String j2eeServerName = "someDomain";
     private static final ObjectName j2eeServer = JMXUtil.getObjectName(j2eeServerName + ":j2eeType=J2EEServer,name=J2EEServerName");
@@ -207,7 +208,7 @@
     }
 
     public void testBuildConfiguration() throws Exception {
-        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, webConfigBuilder, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, null);
+        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, webConfigBuilder, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, serviceReferenceBuilder, null);
 
         File tempDir = null;
         try {
@@ -220,7 +221,7 @@
     }
 
     public void testNoEJBDeployer() throws Exception {
-        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, null, null, webConfigBuilder, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, null);
+        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, null, null, webConfigBuilder, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, serviceReferenceBuilder, null);
 
         File tempDir = null;
         try {
@@ -236,7 +237,7 @@
     }
 
     public void testNoWARDeployer() throws Exception {
-        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, null, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, null);
+        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, null, connectorConfigBuilder, resourceReferenceBuilder, appClientConfigBuilder, serviceReferenceBuilder, null);
 
         File tempDir = null;
         try {
@@ -252,7 +253,7 @@
     }
 
     public void testNoConnectorDeployer() throws Exception {
-        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, webConfigBuilder, null, resourceReferenceBuilder, appClientConfigBuilder, null);
+        EARConfigBuilder configBuilder = new EARConfigBuilder(defaultParentId, j2eeServer, transactionManagerObjectName, connectionTrackerObjectName, transactionalTimerObjectName, nonTransactionalTimerObjectName, null, ejbConfigBuilder, null, webConfigBuilder, null, resourceReferenceBuilder, appClientConfigBuilder, serviceReferenceBuilder, null);
 
         File tempDir = null;
         try {

Modified: geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java&r1=125374&p2=geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java	(original)
+++ geronimo/trunk/modules/j2ee-builder/src/test/org/apache/geronimo/j2ee/deployment/EJBRefContextTest.java	Sun Jan 16 15:20:45 2005
@@ -17,8 +17,11 @@
 package org.apache.geronimo.j2ee.deployment;
 
 import java.net.URI;
+import java.util.Map;
+import java.util.List;
 import javax.naming.Reference;
 import javax.management.ObjectName;
+import javax.xml.namespace.QName;
 
 import junit.framework.TestCase;
 import org.apache.geronimo.common.DeploymentException;
@@ -26,6 +29,7 @@
 import org.apache.geronimo.common.UnknownEJBRefException;
 import org.apache.geronimo.common.UnresolvedEJBRefException;
 import org.apache.geronimo.gbean.GBeanData;
+import org.apache.geronimo.deployment.DeploymentContext;
 
 /**
  * @version $Rev$ $Date$
@@ -194,6 +198,11 @@
             public GBeanData locateConnectionFactoryInfo(ObjectName resourceAdapterModuleName, String connectionFactoryInterfaceName) throws DeploymentException {
                 return null;
             }
+        }, new ServiceReferenceBuilder() {
+            //it could return a Service or a Reference, we don't care
+            public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+                return null;
+            }
         });
 
         refContext.addEJBRemoteId(coffee, "peaberry", coffee_peaberry, true, "CoffeeHome", "CoffeeRemote");
@@ -213,7 +222,7 @@
     }
 
     private void assertReferenceEqual(String expected, Reference reference) {
-        FakeReference fakeReference = (FakeReference)reference;
+        FakeReference fakeReference = (FakeReference) reference;
         String containerId = null;
         if (fakeReference != null) {
             containerId = fakeReference.containerId;

Modified: geronimo/trunk/modules/j2ee-schema/maven.xml
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/j2ee-schema/maven.xml?view=diff&rev=125375&p1=geronimo/trunk/modules/j2ee-schema/maven.xml&r1=125374&p2=geronimo/trunk/modules/j2ee-schema/maven.xml&r2=125375
==============================================================================
--- geronimo/trunk/modules/j2ee-schema/maven.xml	(original)
+++ geronimo/trunk/modules/j2ee-schema/maven.xml	Sun Jan 16 15:20:45 2005
@@ -28,7 +28,7 @@
     <preGoal name="java:compile">
         <xmlbeans:schema2java
             sourcedir="${basedir}/src"
-            sourceschema="j2ee_1_4schema/application_1_4.xsd,j2ee_1_3schema/connector_1_0.xsd,j2ee_1_4schema/j2ee_1_4.xsd,j2ee_1_4schema/connector_1_5.xsd,j2ee_1_4schema/ejb-jar_2_1.xsd,j2ee_1_4schema/web-app_2_4.xsd,j2ee_1_4schema/application-client_1_4.xsd"
+            sourceschema="j2ee_1_4schema/application_1_4.xsd,j2ee_1_3schema/connector_1_0.xsd,j2ee_1_4schema/j2ee_1_4.xsd,j2ee_1_4schema/connector_1_5.xsd,j2ee_1_4schema/ejb-jar_2_1.xsd,j2ee_1_4schema/web-app_2_4.xsd,j2ee_1_4schema/application-client_1_4.xsd,j2ee_1_4schema/j2ee_jaxrpc_mapping_1_1.xsd"
             xmlconfigs="${basedir}/src/conf/xmlconfig.xml"
             targetdir="${basedir}/target/xmlbeans"
             cataloglocation="${basedir}/src/catalog/resolver-catalog.xml"/>

Modified: geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java?view=diff&rev=125375&p1=geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java&r1=125374&p2=geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java	(original)
+++ geronimo/trunk/modules/jetty-builder/src/java/org/apache/geronimo/jetty/deployment/JettyModuleBuilder.java	Sun Jan 16 15:20:45 2005
@@ -977,6 +977,7 @@
                 webApp.getResourceRefArray(), jettyWebApp.getResourceRefArray(),
                 webApp.getResourceEnvRefArray(), jettyWebApp.getResourceEnvRefArray(),
                 webApp.getMessageDestinationRefArray(),
+                webApp.getServiceRefArray(),
                 cl);
     }
 

Modified: geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java?view=diff&rev=125375&p1=geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java&r1=125374&p2=geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java	(original)
+++ geronimo/trunk/modules/jetty-builder/src/test/org/apache/geronimo/jetty/deployment/JettyModuleBuilderTest.java	Sun Jan 16 15:20:45 2005
@@ -22,19 +22,24 @@
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Set;
+import java.util.Map;
+import java.util.List;
 import javax.management.ObjectName;
 import javax.naming.Reference;
+import javax.xml.namespace.QName;
 
 import junit.framework.TestCase;
 import org.apache.geronimo.common.DeploymentException;
 import org.apache.geronimo.connector.outbound.connectiontracking.ConnectionTrackingCoordinator;
 import org.apache.geronimo.deployment.util.UnpackedJarFile;
+import org.apache.geronimo.deployment.DeploymentContext;
 import org.apache.geronimo.gbean.GBeanData;
 import org.apache.geronimo.j2ee.deployment.EARContext;
 import org.apache.geronimo.j2ee.deployment.EJBReferenceBuilder;
 import org.apache.geronimo.j2ee.deployment.Module;
 import org.apache.geronimo.j2ee.deployment.RefContext;
 import org.apache.geronimo.j2ee.deployment.ResourceReferenceBuilder;
+import org.apache.geronimo.j2ee.deployment.ServiceReferenceBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContextImpl;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
@@ -131,8 +136,13 @@
                             public GBeanData locateConnectionFactoryInfo(ObjectName resourceAdapterModuleName, String connectionFactoryInterfaceName) throws DeploymentException {
                                 return null;
                             }
-                        }
-                ));
+                        },
+                         new ServiceReferenceBuilder() {
+                             //it could return a Service or a Reference, we don't care
+                             public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlers, DeploymentContext deploymentContext, ClassLoader classLoader) throws DeploymentException {
+                                 return null;
+                             }
+                         }));
         builder.initContext(earContext, module, cl);
         builder.addGBeans(earContext, module, cl);
         earContext.close();

Modified: geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java
Url: http://svn.apache.org/viewcvs/geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java?view=diff&rev=125375&p1=geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java&r1=125374&p2=geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java&r2=125375
==============================================================================
--- geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java	(original)
+++ geronimo/trunk/modules/naming-builder/src/java/org/apache/geronimo/naming/deployment/ENCConfigBuilder.java	Sun Jan 16 15:20:45 2005
@@ -19,39 +19,46 @@
 
 import java.net.MalformedURLException;
 import java.net.URI;
+import java.net.URISyntaxException;
 import java.net.URL;
+import java.util.Arrays;
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
 import java.util.Map;
 import java.util.Set;
-import java.util.Iterator;
 import javax.management.MalformedObjectNameException;
 import javax.management.ObjectName;
 import javax.naming.NamingException;
 import javax.naming.Reference;
 import javax.transaction.UserTransaction;
+import javax.xml.namespace.QName;
 
 import org.apache.geronimo.common.DeploymentException;
 import org.apache.geronimo.j2ee.deployment.EARContext;
 import org.apache.geronimo.j2ee.deployment.RefContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.J2eeContext;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
+import org.apache.geronimo.kernel.Kernel;
 import org.apache.geronimo.naming.java.ComponentContextBuilder;
 import org.apache.geronimo.naming.java.ReadOnlyContext;
 import org.apache.geronimo.xbeans.geronimo.naming.GerEjbLocalRefType;
 import org.apache.geronimo.xbeans.geronimo.naming.GerEjbRefType;
+import org.apache.geronimo.xbeans.geronimo.naming.GerGbeanLocatorType;
 import org.apache.geronimo.xbeans.geronimo.naming.GerResourceEnvRefType;
 import org.apache.geronimo.xbeans.geronimo.naming.GerResourceRefType;
-import org.apache.geronimo.xbeans.geronimo.naming.GerGbeanLocatorType;
 import org.apache.geronimo.xbeans.j2ee.EjbLocalRefType;
 import org.apache.geronimo.xbeans.j2ee.EjbRefType;
 import org.apache.geronimo.xbeans.j2ee.EnvEntryType;
 import org.apache.geronimo.xbeans.j2ee.MessageDestinationRefType;
+import org.apache.geronimo.xbeans.j2ee.PortComponentRefType;
 import org.apache.geronimo.xbeans.j2ee.ResourceEnvRefType;
 import org.apache.geronimo.xbeans.j2ee.ResourceRefType;
+import org.apache.geronimo.xbeans.j2ee.ServiceRefHandlerType;
+import org.apache.geronimo.xbeans.j2ee.ServiceRefType;
 import org.apache.geronimo.xbeans.j2ee.XsdStringType;
-import org.apache.geronimo.kernel.Kernel;
 
 /**
  * @version $Rev$ $Date$
@@ -95,7 +102,7 @@
                     if (matches.size() != 1) {
                         throw new DeploymentException("No or ambiguous match for gbean link: " + linkName + " using query " + query + ", matches: " + matches);
                     }
-                    containerId = (ObjectName)matches.iterator().next();
+                    containerId = (ObjectName) matches.iterator().next();
                 }
             }
         } else if (gerGbeanLocator.isSetTargetName()) {
@@ -329,12 +336,12 @@
                     String containerId = null;
                     try {
                         containerId = NameFactory.getEjbComponentNameString(getStringValue(remoteRef.getDomain()),
-                                                    getStringValue(remoteRef.getServer()),
-                                                    getStringValue(remoteRef.getApplication()),
-                                                    getStringValue(remoteRef.getModule()),
-                                                    getStringValue(remoteRef.getName()),
-                                                    getStringValue(remoteRef.getType()),
-                                                    j2eeContext);
+                                getStringValue(remoteRef.getServer()),
+                                getStringValue(remoteRef.getApplication()),
+                                getStringValue(remoteRef.getModule()),
+                                getStringValue(remoteRef.getName()),
+                                getStringValue(remoteRef.getType()),
+                                j2eeContext);
                     } catch (MalformedObjectNameException e) {
                         throw new DeploymentException("Could not construct ejb object name: " + remoteRef.getName(), e);
                     }
@@ -386,12 +393,12 @@
                     String containerId = null;
                     try {
                         containerId = NameFactory.getEjbComponentNameString(getStringValue(localRef.getDomain()),
-                                                    getStringValue(localRef.getServer()),
-                                                    getStringValue(localRef.getApplication()),
-                                                    getStringValue(localRef.getModule()),
-                                                    getStringValue(localRef.getName()),
-                                                    getStringValue(localRef.getType()),
-                                                    j2eeContext);
+                                getStringValue(localRef.getServer()),
+                                getStringValue(localRef.getApplication()),
+                                getStringValue(localRef.getModule()),
+                                getStringValue(localRef.getName()),
+                                getStringValue(localRef.getType()),
+                                j2eeContext);
                     } catch (MalformedObjectNameException e) {
                         throw new DeploymentException("Could not construct ejb object name: " + localRef.getName(), e);
                     }
@@ -409,6 +416,67 @@
         }
     }
 
+    //TODO current implementation does not deal with portComponentRefs or handlers.
+    public static void addServiceRefs(EARContext earContext, URI uri, ServiceRefType[] serviceRefs, ClassLoader cl, ComponentContextBuilder builder) throws DeploymentException {
+        RefContext refContext = earContext.getRefContext();
+
+        for (int i = 0; i < serviceRefs.length; i++) {
+            ServiceRefType serviceRef = serviceRefs[i];
+            String name = getStringValue(serviceRef.getServiceRefName());
+            String serviceInterfaceName = getStringValue(serviceRef.getServiceInterface());
+            assureInterface(serviceInterfaceName, "javax.xml.rpc.Service", "[Web]Service", cl);
+            Class serviceInterface = null;
+            try {
+                serviceInterface = cl.loadClass(serviceInterfaceName);
+            } catch (ClassNotFoundException e) {
+                throw new DeploymentException("Could not load service interface class: " + serviceInterfaceName, e);
+            }
+            URI wsdlURI = null;
+            try {
+                wsdlURI = new URI(getStringValue(serviceRef.getWsdlFile().getStringValue()));
+            } catch (URISyntaxException e) {
+                throw new DeploymentException("could not construct wsdl uri from " + serviceRef.getWsdlFile().getStringValue(), e);
+            }
+            URI jaxrpcMappingURI = null;
+            try {
+                jaxrpcMappingURI = new URI(getStringValue(serviceRef.getJaxrpcMappingFile()));
+            } catch (URISyntaxException e) {
+                throw new DeploymentException("Could not construct jaxrpc mapping uri from " + serviceRef.getJaxrpcMappingFile(), e);
+            }
+            QName serviceQName = serviceRef.getServiceQname().getQNameValue();
+            Map portComponentRefMap = new HashMap();
+            PortComponentRefType[] portComponentRefs = serviceRef.getPortComponentRefArray();
+            if (portComponentRefs != null) {
+                for (int j = 0; j < portComponentRefs.length; j++) {
+                    PortComponentRefType portComponentRef = portComponentRefs[j];
+                    String portComponentLink = getStringValue(portComponentRef.getPortComponentLink());
+                    String serviceEndpointInterfaceType = getStringValue(portComponentRef.getServiceEndpointInterface());
+                    assureInterface(serviceEndpointInterfaceType, "javax.rmi.Remote", "ServiceEndpoint", cl);
+                    Class serviceEndpointClass;
+                    try {
+                        serviceEndpointClass = cl.loadClass(serviceEndpointInterfaceType);
+                    } catch (ClassNotFoundException e) {
+                        throw new DeploymentException("could not load service endpoint class " + serviceEndpointInterfaceType, e);
+                    }
+                    portComponentRefMap.put(serviceEndpointClass, portComponentLink);
+                }
+            }
+            //TODO this sucks, but the handlers aren't implemented yet anyway.
+            ServiceRefHandlerType[] handlerTypes = serviceRef.getHandlerArray();
+            List handlers = Arrays.asList(handlerTypes);
+
+            //we could get a Reference or the actual serializable Service back.
+            Object ref = refContext.getServiceReference(serviceInterface, wsdlURI, jaxrpcMappingURI, serviceQName, portComponentRefMap, handlers, earContext, cl);
+            try {
+                builder.bind(name, ref);
+            } catch (NamingException e) {
+                throw new DeploymentException("Invalid resource-ref definition for name: " + name, e);
+            }
+        }
+
+    }
+
+
     public static void assureEJBObjectInterface(String remote, ClassLoader cl) throws DeploymentException {
         assureInterface(remote, "javax.ejb.EJBObject", "Remote", cl);
     }
@@ -425,15 +493,15 @@
         assureInterface(localHome, "javax.ejb.EJBLocalHome", "LocalHome", cl);
     }
 
-    public static void assureInterface(String interfaceName, String superInterfaceName, String interfactType, ClassLoader cl) throws DeploymentException {
+    public static void assureInterface(String interfaceName, String superInterfaceName, String interfaceType, ClassLoader cl) throws DeploymentException {
         Class clazz = null;
         try {
             clazz = cl.loadClass(interfaceName);
         } catch (ClassNotFoundException e) {
-            throw new DeploymentException(interfactType + " interface class not found: " + interfaceName);
+            throw new DeploymentException(interfaceType + " interface class not found: " + interfaceName);
         }
         if (!clazz.isInterface()) {
-            throw new DeploymentException(interfactType + " interface is not an interface: " + interfaceName);
+            throw new DeploymentException(interfaceType + " interface is not an interface: " + interfaceName);
         }
         Class superInterface = null;
         try {
@@ -442,7 +510,7 @@
             throw new DeploymentException("Class " + superInterfaceName + " could not be loaded");
         }
         if (clazz.isAssignableFrom(superInterface)) {
-            throw new DeploymentException(interfactType + " interface does not extend " + superInterfaceName + ": " + interfaceName);
+            throw new DeploymentException(interfaceType + " interface does not extend " + superInterfaceName + ": " + interfaceName);
         }
     }
 
@@ -491,7 +559,7 @@
         builder.setApplicationManagedSecurityResources(applicationManagedSecurityResources);
     }
 
-    public static ReadOnlyContext buildComponentContext(EARContext earContext, URI uri, UserTransaction userTransaction, EnvEntryType[] envEntries, EjbRefType[] ejbRefs, GerEjbRefType[] gerEjbRefs, EjbLocalRefType[] ejbLocalRefs, GerEjbLocalRefType[] gerEjbLocalRef, ResourceRefType[] resourceRefs, GerResourceRefType[] gerResourceRef, ResourceEnvRefType[] resourceEnvRefs, GerResourceEnvRefType[] gerResourceEnvRef, MessageDestinationRefType[] messageDestinationRefs, ClassLoader cl) throws DeploymentException {
+    public static ReadOnlyContext buildComponentContext(EARContext earContext, URI uri, UserTransaction userTransaction, EnvEntryType[] envEntries, EjbRefType[] ejbRefs, GerEjbRefType[] gerEjbRefs, EjbLocalRefType[] ejbLocalRefs, GerEjbLocalRefType[] gerEjbLocalRef, ResourceRefType[] resourceRefs, GerResourceRefType[] gerResourceRef, ResourceEnvRefType[] resourceEnvRefs, GerResourceEnvRefType[] gerResourceEnvRef, MessageDestinationRefType[] messageDestinationRefs, ServiceRefType[] serviceRefs, ClassLoader cl) throws DeploymentException {
         ComponentContextBuilder builder = new ComponentContextBuilder();
 
         if (userTransaction != null) {
@@ -517,6 +585,8 @@
         addResourceEnvRefs(earContext, uri, resourceEnvRefs, mapResourceEnvRefs(gerResourceEnvRef), cl, builder);
 
         addMessageDestinationRefs(earContext, uri, messageDestinationRefs, cl, builder);
+
+        addServiceRefs(earContext, uri, serviceRefs, cl, builder);
 
         return builder.getContext();
     }

Mime
View raw message