geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r509806 - in /geronimo/server/trunk/modules/geronimo-axis2: ./ src/test/java/org/apache/geronimo/axis2/ src/test/java/org/apache/geronimo/axis2/testdata/ src/test/java/org/apache/hello_control/ src/test/java/org/apache/hello_control/types/ ...
Date Tue, 20 Feb 2007 23:28:56 GMT
Author: dims
Date: Tue Feb 20 15:28:54 2007
New Revision: 509806

URL: http://svn.apache.org/viewvc?view=rev&rev=509806
Log:
Fix for GERONIMO-2852 - Test Case to Axis2WebServiceContainer

Added:
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2AbstractTestCase.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Request.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Response.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2WebServiceContainerTest.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/HelloWorld.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/ObjectFactory.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHello.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHelloResponse.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/package-info.java
    geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit.wsdl
    geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit_request.xml
Modified:
    geronimo/server/trunk/modules/geronimo-axis2/pom.xml

Modified: geronimo/server/trunk/modules/geronimo-axis2/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/pom.xml?view=diff&rev=509806&r1=509805&r2=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/pom.xml (original)
+++ geronimo/server/trunk/modules/geronimo-axis2/pom.xml Tue Feb 20 15:28:54 2007
@@ -81,6 +81,32 @@
                     </execution>
                 </executions>
             </plugin>
+            <plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-antrun-plugin</artifactId>
+				<version>1.1</version>
+				<executions>
+					<execution>
+						<id>gen-ts</id>
+						<phase>generate-sources</phase>
+						<configuration>
+							<tasks>
+								<echo>Generating java from test_service_doc_lit.wsdl</echo>
+								<property name="schema.generated.src.dir" value="src/test/java"/>
+								
+								<java classname="com.sun.tools.xjc.Driver" fork="true">
+										<classpath refid="maven.runtime.classpath"/>
+										<classpath location="${compiled.classes.dir}"/>
+									<arg line="-d ${schema.generated.src.dir} -quiet -wsdl src/test/resources/test_service_doc_lit.wsdl"/>
+								</java>
+							</tasks>
+						</configuration>
+						<goals>
+							<goal>run</goal>
+						</goals>
+					</execution>
+				</executions>
+            </plugin>
         </plugins>
     </build>
 </project>

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2AbstractTestCase.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2AbstractTestCase.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2AbstractTestCase.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2AbstractTestCase.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,57 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You 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.axis2;
+
+import java.io.File;
+
+import org.apache.geronimo.testsupport.TestSupport;
+
+public abstract class Axis2AbstractTestCase
+    extends TestSupport
+{
+    protected String testDir = "src/main/test/";
+    protected String sampleDir = "src/main/test/samples/";
+    protected String outDir = "target/generated/samples/";
+    protected String tempDir = "target/generated/temp";
+    
+    /**
+     * Constructor.
+     */
+    public Axis2AbstractTestCase(String testName) {
+        super(testName);
+        
+        testDir = new File(BASEDIR, testDir).getAbsolutePath();
+        sampleDir = new File(BASEDIR, sampleDir).getAbsolutePath();
+        outDir = new File(BASEDIR, outDir).getAbsolutePath();
+        tempDir = new File(BASEDIR, tempDir).getAbsolutePath();
+    }
+
+    /**
+     * Get test input file.
+     *
+     * @param path Path to test input file.
+     */
+    public String getTestFile(String path) {
+        return new File(BASEDIR, path).getAbsolutePath();
+    }
+
+    public void testDummy() throws Exception {
+        //to allow commenting out all tests in a test case
+    }
+}
+

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Request.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Request.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Request.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Request.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,110 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You 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.axis2;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URI;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.geronimo.webservices.WebServiceContainer;
+
+class Axis2Request implements WebServiceContainer.Request {
+	private int contentLength;
+
+	private String contentType;
+
+	private InputStream in;
+
+	private int method;
+
+	private Map parameters;
+
+	private URI uri;
+
+	private Map headers;
+
+	private Map attributes;
+
+	private String remoteAddress;
+
+	/**
+	 * 
+	 */
+	public Axis2Request(int contentLength, String contentType, InputStream in,
+			int method, Map parameters, URI uri, Map headers,
+			String remoteAddress) {
+		this.contentType = contentType;
+		this.in = in;
+		this.method = method;
+		this.parameters = parameters;
+		this.uri = uri;
+		this.headers = headers;
+		this.attributes = new HashMap();
+		this.remoteAddress = remoteAddress;
+	}
+
+	public int getContentLength() {
+		return contentLength;
+	}
+
+	public String getContentType() {
+		return contentType;
+	}
+
+	public String getHeader(String name) {
+		return (String) headers.get(name);
+	}
+
+	public InputStream getInputStream() throws IOException {
+		return in;
+	}
+
+	public int getMethod() {
+		return method;
+	}
+
+	public String getParameter(String name) {
+		return (String) parameters.get(name);
+	}
+
+	public Map getParameters() {
+		return parameters;
+	}
+
+	public URI getURI() {
+		return uri;
+	}
+
+	public Object getAttribute(String name) {
+		return attributes.get(name);
+	}
+
+	public void setAttribute(String name, Object value) {
+		attributes.put(name, value);
+	}
+
+	public String getRemoteAddr() {
+		return remoteAddress;
+	}
+
+	public String getContextPath() {
+		return "/axis2";
+	}
+
+}

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Response.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Response.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Response.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2Response.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,196 @@
+/**
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You 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.axis2;
+
+import java.io.OutputStream;
+import java.net.URL;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.geronimo.webservices.WebServiceContainer;
+
+class Axis2Response implements WebServiceContainer.Response {
+	private int contentLength;
+
+	private String contentType;
+
+	private String host;
+
+	private OutputStream out;
+
+	private int method;
+
+	private Map parameters;
+
+	private String path;
+
+	private URL uri;
+
+	private int port;
+
+	private Map headers;
+
+	private int statusCode;
+
+	private String statusMessage;
+
+	/**
+	 * 
+	 */
+	public Axis2Response(String contentType, String host, String path, URL uri,
+			int port, OutputStream out) {
+		this.contentType = contentType;
+		this.host = host;
+		this.parameters = new HashMap();
+		this.path = path;
+		this.uri = uri;
+		this.port = port;
+		this.headers = new HashMap();
+		this.out = out;
+	}
+
+	public int getContentLength() {
+		return contentLength;
+	}
+
+	public String getHeader(String name) {
+		return (String) headers.get(name);
+	}
+
+	public String getHost() {
+		return host;
+	}
+
+	public OutputStream getOutputStream() {
+		return out;
+	}
+
+	public int getMethod() {
+		return method;
+	}
+
+	public String getParameter(String name) {
+		return (String) parameters.get(name);
+	}
+
+	public Map getParameters() {
+		return parameters;
+	}
+
+	public String getPath() {
+		return path;
+	}
+
+	public int getPort() {
+		return port;
+	}
+
+	public URL getURI() {
+		return uri;
+	}
+
+	/**
+	 * @return
+	 */
+	public String getContentType() {
+		return contentType;
+	}
+
+	/**
+	 * @return
+	 */
+	public URL getUri() {
+		return uri;
+	}
+
+	/**
+	 * @param i
+	 */
+	public void setContentLength(int i) {
+		contentLength = i;
+	}
+
+	/**
+	 * @param string
+	 */
+	public void setContentType(String string) {
+		contentType = string;
+	}
+
+	/**
+	 * @param string
+	 */
+	public void setHost(String string) {
+		host = string;
+	}
+
+	/**
+	 * @param i
+	 */
+	public void setMethod(int i) {
+		method = i;
+	}
+
+	/**
+	 * @param map
+	 */
+	public void setParameters(Map map) {
+		parameters = map;
+	}
+
+	/**
+	 * @param string
+	 */
+	public void setPath(String string) {
+		path = string;
+	}
+
+	/**
+	 * @param i
+	 */
+	public void setPort(int i) {
+		port = i;
+	}
+
+	/**
+	 * @param url
+	 */
+	public void setUri(URL url) {
+		uri = url;
+	}
+
+	public int getStatusCode() {
+		return statusCode;
+	}
+
+	public void setStatusCode(int code) {
+		statusCode = code;
+	}
+
+	public void setStatusMessage(String responseString) {
+		statusMessage = responseString;
+	}
+
+	public void flushBuffer() throws java.io.IOException {
+	}
+
+	public void setHeader(String name, String value) {
+		headers.put(name, value);
+	}
+
+}
+

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2WebServiceContainerTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2WebServiceContainerTest.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2WebServiceContainerTest.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/Axis2WebServiceContainerTest.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,103 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You 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.axis2;
+
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URI;
+import java.util.HashMap;
+
+import javax.wsdl.Definition;
+import javax.wsdl.factory.WSDLFactory;
+import javax.wsdl.xml.WSDLReader;
+
+import org.apache.geronimo.webservices.WebServiceContainer.Request;
+
+public class Axis2WebServiceContainerTest extends Axis2AbstractTestCase {
+    public Axis2WebServiceContainerTest(String testName) {
+        super(testName);
+    }
+
+    public void testInvokeWithWSDLDocLit() throws Exception {
+    	testInvokeWithWSDL("test_service_doc_lit_request.xml", "test_service_doc_lit.wsdl");
+    }
+    
+    //TODO:
+    public void testInvokeWithWSDLRPCLit() throws Exception {
+    }
+    
+    private void testInvokeWithWSDL(String requestFile, String wsdlFile) throws Exception
{
+    	ClassLoader cl = Thread.currentThread().getContextClassLoader();
+    	InputStream in = cl.getResourceAsStream(requestFile);
+
+    	PortInfo portInfo = new PortInfo();
+    	portInfo.setLocation("servlet");
+    	File file = new File(getTestFile("src/test/resources/"+wsdlFile));
+    	portInfo.setWsdlDefinition(readWSDL(file.toURL().toString()));
+    	
+    	try {
+            Axis2Request req = new Axis2Request(504,
+                    "text/xml; charset=utf-8",
+                    in,
+                    Request.POST,
+                    new HashMap(),
+                    new URI("/axis2/servlet"),
+                    new HashMap(),
+                    "127.0.0.1");
+            
+            ByteArrayOutputStream out = new ByteArrayOutputStream();
+            Axis2Response res = new Axis2Response("text/xml; charset=utf-8", "127.0.0.1",
null, null, 8080, out);
+            
+            String endpointClassName = "org.apache.geronimo.axis2.testdata.HelloWorld";
+            
+            Axis2WebServiceContainer container = new Axis2WebServiceContainer(portInfo, endpointClassName,
cl , null, null);
+            container.invoke(req, res);
+
+            out.flush();
+     
+        } catch(Exception ex){
+        	throw new Exception(ex.toString());
+        }finally {
+            if (in != null) {
+                try {
+                    in.close();
+                } catch (IOException ignore) {
+                    // ignore
+                }
+            }
+        }
+    }
+    
+    private Definition readWSDL(String url) throws Exception{
+    	WSDLFactory factory = WSDLFactory.newInstance();
+		WSDLReader reader = factory.newWSDLReader();
+		reader.setFeature("javax.wsdl.importDocuments", true);
+		reader.setFeature("javax.wsdl.verbose", false);
+		Definition wsdlDefinition = reader.readWSDL(url);
+		return wsdlDefinition;
+    }
+
+    protected void setUp() throws Exception {
+    }
+
+    protected void tearDown() throws Exception {
+    }
+    
+}
+

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/HelloWorld.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/HelloWorld.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/HelloWorld.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/geronimo/axis2/testdata/HelloWorld.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,29 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You 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.axis2.testdata;
+
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+@WebService(name="HelloWorld")
+public class HelloWorld {
+
+	@WebMethod
+	public String sayHello(String me){
+		return "Hello "+me;
+	}
+}

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/ObjectFactory.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/ObjectFactory.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/ObjectFactory.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/ObjectFactory.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,55 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation,
v2.0.2-b01-fcs 
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>

+// Any modifications to this file will be lost upon recompilation of the source schema. 
+// Generated on: 2007.02.20 at 06:26:22 PM EST 
+//
+
+
+package org.apache.hello_control.types;
+
+import javax.xml.bind.annotation.XmlRegistry;
+
+
+/**
+ * This object contains factory methods for each 
+ * Java content interface and Java element interface 
+ * generated in the org.apache.hello_control.types package. 
+ * <p>An ObjectFactory allows you to programatically 
+ * construct new instances of the Java representation 
+ * for XML content. The Java representation of XML 
+ * content can consist of schema derived interfaces 
+ * and classes representing the binding of schema 
+ * type definitions, element declarations and model 
+ * groups.  Factory methods for each of these are 
+ * provided in this class.
+ * 
+ */
+@XmlRegistry
+public class ObjectFactory {
+
+
+    /**
+     * Create a new ObjectFactory that can be used to create new instances of schema derived
classes for package: org.apache.hello_control.types
+     * 
+     */
+    public ObjectFactory() {
+    }
+
+    /**
+     * Create an instance of {@link SayHelloResponse }
+     * 
+     */
+    public SayHelloResponse createSayHelloResponse() {
+        return new SayHelloResponse();
+    }
+
+    /**
+     * Create an instance of {@link SayHello }
+     * 
+     */
+    public SayHello createSayHello() {
+        return new SayHello();
+    }
+
+}

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHello.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHello.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHello.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHello.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,71 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation,
v2.0.2-b01-fcs 
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>

+// Any modifications to this file will be lost upon recompilation of the source schema. 
+// Generated on: 2007.02.20 at 06:26:22 PM EST 
+//
+
+
+package org.apache.hello_control.types;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for anonymous complex type.
+ * 
+ * <p>The following schema fragment specifies the expected content contained within
this class.
+ * 
+ * <pre>
+ * &lt;complexType>
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;sequence>
+ *         &lt;element name="requestType" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *       &lt;/sequence>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ * 
+ * 
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "", propOrder = {
+    "requestType"
+})
+@XmlRootElement(name = "sayHello")
+public class SayHello {
+
+    @XmlElement(required = true)
+    protected String requestType;
+
+    /**
+     * Gets the value of the requestType property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getRequestType() {
+        return requestType;
+    }
+
+    /**
+     * Sets the value of the requestType property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setRequestType(String value) {
+        this.requestType = value;
+    }
+
+}

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHelloResponse.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHelloResponse.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHelloResponse.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/SayHelloResponse.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,71 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation,
v2.0.2-b01-fcs 
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>

+// Any modifications to this file will be lost upon recompilation of the source schema. 
+// Generated on: 2007.02.20 at 06:26:22 PM EST 
+//
+
+
+package org.apache.hello_control.types;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+
+/**
+ * <p>Java class for anonymous complex type.
+ * 
+ * <p>The following schema fragment specifies the expected content contained within
this class.
+ * 
+ * <pre>
+ * &lt;complexType>
+ *   &lt;complexContent>
+ *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ *       &lt;sequence>
+ *         &lt;element name="responseType" type="{http://www.w3.org/2001/XMLSchema}string"/>
+ *       &lt;/sequence>
+ *     &lt;/restriction>
+ *   &lt;/complexContent>
+ * &lt;/complexType>
+ * </pre>
+ * 
+ * 
+ */
+@XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "", propOrder = {
+    "responseType"
+})
+@XmlRootElement(name = "sayHelloResponse")
+public class SayHelloResponse {
+
+    @XmlElement(required = true)
+    protected String responseType;
+
+    /**
+     * Gets the value of the responseType property.
+     * 
+     * @return
+     *     possible object is
+     *     {@link String }
+     *     
+     */
+    public String getResponseType() {
+        return responseType;
+    }
+
+    /**
+     * Sets the value of the responseType property.
+     * 
+     * @param value
+     *     allowed object is
+     *     {@link String }
+     *     
+     */
+    public void setResponseType(String value) {
+        this.responseType = value;
+    }
+
+}

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/package-info.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/package-info.java?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/package-info.java
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/java/org/apache/hello_control/types/package-info.java
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,9 @@
+//
+// This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation,
v2.0.2-b01-fcs 
+// See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a>

+// Any modifications to this file will be lost upon recompilation of the source schema. 
+// Generated on: 2007.02.20 at 06:26:22 PM EST 
+//
+
+@javax.xml.bind.annotation.XmlSchema(namespace = "http://apache.org/hello_control/types",
elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
+package org.apache.hello_control.types;

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit.wsdl
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit.wsdl?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit.wsdl
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit.wsdl
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you 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.
+-->
+<wsdl:definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
+    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+    xmlns:tns="http://apache.org/hello_control"
+    xmlns:x1="http://apache.org/hello_control/types"
+    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+    targetNamespace="http://apache.org/hello_control" name="HelloWorld">
+    <wsdl:types>
+        <schema targetNamespace="http://apache.org/hello_control/types" 
+            xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
+            <element name="sayHello">
+                <complexType>
+                    <sequence>
+                        <element name="requestType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            <element name="sayHelloResponse">
+                <complexType>
+                    <sequence>
+                        <element name="responseType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>            
+        </schema>
+    </wsdl:types>
+   
+    <wsdl:message name="sayHelloRequest">
+        <wsdl:part element="x1:sayHello" name="in"/>
+    </wsdl:message>
+    <wsdl:message name="sayHelloResponse">
+        <wsdl:part element="x1:sayHelloResponse" name="out"/>
+    </wsdl:message>
+        
+    <wsdl:portType name="Hello">
+        <wsdl:operation name="sayHello">
+            <wsdl:input message="tns:sayHelloRequest" name="sayHelloRequest"/>
+            <wsdl:output message="tns:sayHelloResponse" name="sayHelloResponse"/>
+        </wsdl:operation>
+    </wsdl:portType>
+
+    <wsdl:binding name="HelloSOAPBinding" type="tns:Hello">
+        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+        <wsdl:operation name="sayHello">
+            <soap:operation soapAction="" style="document"/>
+            <wsdl:input name="sayHelloRequest">
+                <soap:body use="literal"/>
+            </wsdl:input>
+            <wsdl:output name="sayHelloResponse">
+                <soap:body use="literal"/>
+            </wsdl:output>
+        </wsdl:operation>
+    </wsdl:binding>
+  
+    <wsdl:service name="HelloService">
+        <wsdl:port binding="tns:HelloSOAPBinding" name="HelloPort">
+            <soap:address location="http://localhost:8080/SoapContext/HelloPort"/>
+            <wswa:UsingAddressing xmlns:wswa="http://www.w3.org/2005/08/addressing/wsdl"/>
+        </wsdl:port>
+    </wsdl:service>
+    
+</wsdl:definitions>
+

Added: geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit_request.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit_request.xml?view=auto&rev=509806
==============================================================================
--- geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit_request.xml
(added)
+++ geronimo/server/trunk/modules/geronimo-axis2/src/test/resources/test_service_doc_lit_request.xml
Tue Feb 20 15:28:54 2007
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you 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.
+-->
+<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
+   <soap:Body>
+     <sayHello xmlns="http://apache.org/hello_control/types">
+       <requestType>World</requestType>
+     </sayHello>
+   </soap:Body>
+</soap:Envelope>



Mime
View raw message