From 539451c7e13d98504e6f3368d892406494ca711d Mon Sep 17 00:00:00 2001 From: lresende Date: Fri, 13 Nov 2009 01:23:07 +0000 Subject: Removing obsolete release candidate tags git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@835693 13f79535-47bb-0310-9956-ffa450edef68 --- .../ws/axis2/itests/mtom/FileTransferClient.java | 57 ---------- .../itests/mtom/FileTransferMTOMTestCase.java | 122 --------------------- .../ws/axis2/itests/mtom/FileTransferService.java | 46 -------- .../itests/mtom/FileTransferServiceClient.java | 42 ------- .../axis2/itests/mtom/FileTransferServiceImpl.java | 57 ---------- .../binding/ws/axis2/itests/mtom/MyException.java | 26 ----- .../ws/axis2/itests/mtom/MyExceptionAdapter.java | 31 ------ .../ws/axis2/itests/mtom/MyExceptionImpl.java | 26 ----- 8 files changed, 407 deletions(-) delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferClient.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferMTOMTestCase.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferService.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceClient.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceImpl.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyException.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionAdapter.java delete mode 100644 sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionImpl.java (limited to 'sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom') diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferClient.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferClient.java deleted file mode 100644 index cf5e4947d6..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferClient.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import javax.activation.DataHandler; -import org.osoa.sca.annotations.Reference; -import org.osoa.sca.annotations.Service; -import java.awt.Image; -import org.apache.axiom.om.OMElement; -import javax.xml.transform.Source; - -/** - * This client program shows how to create an SCA runtime, start it, - * locate the FileTransfer service and invoke it. - */ -@Service(FileTransferServiceClient.class) -public class FileTransferClient implements FileTransferServiceClient { - - @Reference - public FileTransferService fileTransferService; - - public String uploadImageFileForward (Image attachment) throws Exception { - return fileTransferService.uploadImageFile(attachment); - } - - public String uploadSourceFileForward (Source attachment) throws Exception { - return fileTransferService.uploadSourceFile(attachment); - } - - public String uploadDataHandlerFileForward (DataHandler attachment) throws Exception { - return fileTransferService.uploadDataHandlerFile(attachment); - } - - public String uploadOMElementFileForward (OMElement attachment) throws Exception { - return fileTransferService.uploadOMElementFile(attachment); - } - - public String sendMyExceptionForward (MyException attachment) throws Exception { - return fileTransferService.sendMyException(attachment); - } -} diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferMTOMTestCase.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferMTOMTestCase.java deleted file mode 100644 index 35bf6888e3..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferMTOMTestCase.java +++ /dev/null @@ -1,122 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import javax.activation.DataHandler; -import javax.activation.FileDataSource; -import java.awt.Image; - -import javax.xml.namespace.QName; -import javax.xml.transform.Source; -import org.apache.axiom.om.OMAbstractFactory; -import org.apache.axiom.om.OMElement; -import org.apache.axiom.om.OMText; -import javax.xml.transform.dom.DOMSource; -import org.apache.axiom.om.OMFactory; -import java.awt.image.BufferedImage; - -import junit.framework.TestCase; -import org.apache.tuscany.sca.host.embedded.SCADomain; -import org.apache.tuscany.sca.binding.ws.axis2.itests.mtom.FileTransferServiceClient; -import org.apache.tuscany.sca.databinding.xml.String2Node; -import org.junit.AfterClass; -import org.junit.BeforeClass; -import org.junit.Test; - -public class FileTransferMTOMTestCase extends TestCase { - - private SCADomain domain; - private FileTransferServiceClient filetransfer; - - /** - * Runs once before the tests - */ - @BeforeClass - protected void setUp() throws Exception { - domain = SCADomain.newInstance("org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/filetransferservice.composite"); - filetransfer = domain.getService(FileTransferServiceClient.class, "FileTransferClientComponent"); - } - - /** - * Runs once after the tests - */ - @AfterClass - protected void tearDown() throws Exception { - domain.close(); - } - - @Test - public void testImageFileTransfer() throws Exception { - try { - Image image = new BufferedImage(80, 24, BufferedImage.TYPE_INT_RGB); - assertEquals("File uploaded Sucessfully", filetransfer.uploadImageFileForward(image)); - } catch (Exception ex){ - ex.printStackTrace(); - } - } - - @Test - public void testSourceFileTransfer() throws Exception { - try { - String xml = "ABC"; - Source source = new DOMSource(new String2Node().transform(xml, null)); - assertEquals("File uploaded Sucessfully", filetransfer.uploadSourceFileForward(source)); - } catch (Exception ex){ - ex.printStackTrace(); - } - } - - @Test - public void testDataHandlerFileTransfer() throws Exception { - try { - // For testing purpose lets try uploading LICENSE file. - DataHandler dataHandler = new DataHandler(new FileDataSource("./LICENSE")); - assertEquals("File uploaded Sucessfully", filetransfer.uploadDataHandlerFileForward(dataHandler)); - } catch (Exception ex){ - ex.printStackTrace(); - } - } - - @Test - public void testOMElementFileTransfer() throws Exception { - try { - OMFactory factory = OMAbstractFactory.getOMFactory(); - OMElement imageElement = factory.createOMElement(new QName("image")); - - DataHandler dataHandler = new DataHandler(new FileDataSource("./LICENSE")); - - OMText textData = factory.createOMText(dataHandler, true); - imageElement.addChild(textData); - assertEquals("File uploaded Sucessfully", filetransfer.uploadOMElementFileForward(imageElement)); - } catch (Exception ex){ - ex.printStackTrace(); - } - } - - @Test - public void testSendMyException() throws Exception { - try { - MyException exp = new MyExceptionImpl(); - assertEquals("File uploaded Sucessfully", filetransfer.sendMyExceptionForward(exp)); - } catch (Exception ex){ - ex.printStackTrace(); - } - } -} diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferService.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferService.java deleted file mode 100644 index ab7fc9c43a..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferService.java +++ /dev/null @@ -1,46 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import org.osoa.sca.annotations.Remotable; -import javax.activation.DataHandler; -import java.awt.Image; -import javax.xml.transform.Source; -import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; -import org.apache.axiom.om.OMElement; - -/** - * This is the business interface of the MTOM FileTransfer service. - */ -@Remotable -public interface FileTransferService { - - public String uploadImageFile(Image attachment) throws Exception; - - public String uploadSourceFile(Source attachment) throws Exception; - - public String uploadDataHandlerFile(DataHandler attachment) throws Exception; - - public String uploadOMElementFile(OMElement attachment) throws Exception; - - //This method uses an user defined interface MyException as parameter type. - public String sendMyException(@XmlJavaTypeAdapter(MyExceptionAdapter.class) MyException attachment) - throws Exception; -} - diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceClient.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceClient.java deleted file mode 100644 index 5fc95441b0..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceClient.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import javax.activation.DataHandler; -import java.awt.Image; -import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; -import javax.xml.transform.Source; -import org.apache.axiom.om.OMElement; - -/** - * This is the client interface of the File Transfer service. - */ -public interface FileTransferServiceClient { - - public String uploadImageFileForward (Image attachment) throws Exception; - - public String uploadSourceFileForward (Source attachment) throws Exception; - - public String uploadDataHandlerFileForward (DataHandler attachment) throws Exception; - - public String uploadOMElementFileForward (OMElement attachment) throws Exception; - - public String sendMyExceptionForward (MyException attachment) throws Exception; -} - diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceImpl.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceImpl.java deleted file mode 100644 index cc757e5e33..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/FileTransferServiceImpl.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import org.osoa.sca.annotations.Service; -import javax.activation.DataHandler; -import java.awt.Image; -import javax.xml.transform.Source; -import org.apache.axiom.om.OMElement; - -/** - * This class implements the HelloWorld service. - */ -@Service(interfaces={FileTransferService.class}) -public class FileTransferServiceImpl implements FileTransferService { - - public String uploadImageFile(Image attachment) throws Exception { - System.out.println("Content type = " + attachment.toString()); - return "File uploaded Sucessfully"; - } - - public String uploadSourceFile(Source attachment) throws Exception { - System.out.println("Content type = " + attachment.toString()); - return "File uploaded Sucessfully"; - } - - public String uploadDataHandlerFile(DataHandler attachment) throws Exception { - System.out.println("Content type = " + attachment.toString()); - return "File uploaded Sucessfully"; - } - - public String uploadOMElementFile(OMElement attachment) throws Exception { - System.out.println("Content type = " + attachment.toString()); - return "File uploaded Sucessfully"; - } - - public String sendMyException(MyException attachment) throws Exception { - System.out.println("Content type = " + attachment.toString()); - return "File uploaded Sucessfully"; - } -} diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyException.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyException.java deleted file mode 100644 index 5ecc22572b..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyException.java +++ /dev/null @@ -1,26 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -//@XmlJavaTypeAdapter(MyExceptionAdapter.class) -public interface MyException { - - public String getMessage(); - -} diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionAdapter.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionAdapter.java deleted file mode 100644 index 4c4e8a3fcf..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionAdapter.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -import javax.xml.bind.annotation.adapters.XmlAdapter; - -public class MyExceptionAdapter extends XmlAdapter { - public MyException unmarshal(MyExceptionImpl v) { - return v; - } - - public MyExceptionImpl marshal(MyException v) { - return (MyExceptionImpl)v; - } -} diff --git a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionImpl.java b/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionImpl.java deleted file mode 100644 index 1bd9b9b1a0..0000000000 --- a/sca-java-1.x/tags/1.5.1-RC4/modules/binding-ws-axis2/src/test/java/org/apache/tuscany/sca/binding/ws/axis2/itests/mtom/MyExceptionImpl.java +++ /dev/null @@ -1,26 +0,0 @@ -/* - * 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.tuscany.sca.binding.ws.axis2.itests.mtom; - -public class MyExceptionImpl extends Exception implements MyException { - - public String getMessage() { - return "good job......"; - } -} -- cgit v1.2.3