summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/samples/getting-started
diff options
context:
space:
mode:
authorkelvingoodson <kelvingoodson@13f79535-47bb-0310-9956-ffa450edef68>2010-09-25 16:39:14 +0000
committerkelvingoodson <kelvingoodson@13f79535-47bb-0310-9956-ffa450edef68>2010-09-25 16:39:14 +0000
commitac02c9a6079922760e4cb134d7ebd587476533b4 (patch)
tree42c2d52bccc7e7feec91d4c7a3279b948a3cbc9a /sca-java-2.x/trunk/samples/getting-started
parent4a1e461b82c8a632a319ec797bff4bac2845177d (diff)
TUSCANY-3677 getting-started clearup
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1001264 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/samples/getting-started')
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/pom.xml67
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateService.java29
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateServiceImpl.java37
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/Helloworld.java28
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldClientImpl.java48
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldImpl.java34
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/META-INF/sca-contribution.xml23
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-client-context.xml37
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-context.xml30
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld.composite36
-rw-r--r--sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/test/java/sample/HelloworldTestCase.java33
11 files changed, 0 insertions, 402 deletions
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/pom.xml b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/pom.xml
deleted file mode 100644
index b8cb765c38..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/pom.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-<?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.
--->
-<project>
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-samples</artifactId>
- <version>2.0-SNAPSHOT</version>
- <relativePath>../pom.xml</relativePath>
- </parent>
-
- <artifactId>sample-helloworld-spring</artifactId>
- <name>Apache Tuscany SCA Sample HelloWorld using Spring</name>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-sca-api</artifactId>
- <version>2.0-SNAPSHOT</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>4.8.1</version>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
- <build>
- <finalName>${artifactId}</finalName>
- <plugins>
-
- <!-- plugin to support using mvn tuscany:run to run this contribution -->
- <plugin>
- <groupId>org.apache.tuscany.maven.plugins</groupId>
- <artifactId>maven-tuscany-plugin</artifactId>
- <version>2.0-SNAPSHOT</version>
- <dependencies>
- <dependency>
- <groupId>org.apache.tuscany.sca.shades</groupId>
- <artifactId>tuscany-spring</artifactId>
- <version>2.0-SNAPSHOT</version>
- </dependency>
- </dependencies>
- </plugin>
-
- </plugins>
- </build>
-</project>
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateService.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateService.java
deleted file mode 100644
index 7c50d66a9c..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateService.java
+++ /dev/null
@@ -1,29 +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 sample;
-
-import java.util.Date;
-
-/**
- *
- */
-public interface DateService {
- Date getDate();
-}
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateServiceImpl.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateServiceImpl.java
deleted file mode 100644
index 64bdd86f7c..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/DateServiceImpl.java
+++ /dev/null
@@ -1,37 +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 sample;
-
-import java.util.Date;
-
-import org.oasisopen.sca.annotation.Service;
-
-/**
- *
- */
-@Service(DateService.class)
-public class DateServiceImpl implements DateService {
-
- public Date getDate() {
- System.out.println("DateServiceImpl.getDate()");
- return new Date();
- }
-
-}
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/Helloworld.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/Helloworld.java
deleted file mode 100644
index f4e8c50448..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/Helloworld.java
+++ /dev/null
@@ -1,28 +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 sample;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Helloworld {
-
- String sayHello(String name);
-
-}
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldClientImpl.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldClientImpl.java
deleted file mode 100644
index a01aad9d88..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldClientImpl.java
+++ /dev/null
@@ -1,48 +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 sample;
-
-import org.oasisopen.sca.annotation.Reference;
-
-public class HelloworldClientImpl implements Helloworld {
- private Helloworld helloworld;
-
- // SCA reference
- @Reference(required = false)
- private DateService dateService;
-
- public HelloworldClientImpl() {
- System.out.println("HelloworldClientImpl()");
- }
-
- public String sayHello(String name) {
- System.out.println("HelloworldClientImpl.sayHello(" + name + ")");
- if (dateService == null) {
- return "Hello " + name;
- }
- return "[" + dateService.getDate() + "] " + helloworld.sayHello(name);
- }
-
- // Setter for spring injection
- public void setHelloworld(Helloworld helloworld) {
- System.out.println("Injected with " + helloworld);
- this.helloworld = helloworld;
- }
-
-}
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldImpl.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldImpl.java
deleted file mode 100644
index 125c333ddc..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/java/sample/HelloworldImpl.java
+++ /dev/null
@@ -1,34 +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 sample;
-
-
-public class HelloworldImpl implements Helloworld {
-
- public HelloworldImpl() {
- super();
- System.out.println("HelloworldImpl()");
- }
-
- public String sayHello(String name) {
- System.out.println("HelloworldImpl.sayHello(" + name + ")");
- return "Hello " + name;
- }
-
-}
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/META-INF/sca-contribution.xml b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/META-INF/sca-contribution.xml
deleted file mode 100644
index 552d100638..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/META-INF/sca-contribution.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?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.
--->
-<contribution xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- xmlns:sample="http://sample">
- <deployable composite="sample:helloworld"/>
-</contribution> \ No newline at end of file
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-client-context.xml b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-client-context.xml
deleted file mode 100644
index 0e30cfa582..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-client-context.xml
+++ /dev/null
@@ -1,37 +0,0 @@
-<?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.
--->
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:sca="http://www.springframework.org/schema/sca"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
- http://www.springframework.org/schema/sca http://www.osoa.org/xmlns/sca/1.0/spring-sca.xsd">
-
- <bean id="HelloworldClientBean" class="sample.HelloworldClientImpl">
- <property name="helloworld">
- <ref bean="HelloworldBean"/>
- </property>
- </bean>
-
- <!--
- <sca:reference name="dateService" type="sample.DateService"/>
- -->
-
-</beans> \ No newline at end of file
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-context.xml b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-context.xml
deleted file mode 100644
index 9ecd09974e..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld-context.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?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.
--->
-<beans xmlns="http://www.springframework.org/schema/beans"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:sca="http://www.springframework.org/schema/sca"
- xsi:schemaLocation="
- http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
- http://www.springframework.org/schema/sca http://www.osoa.org/xmlns/sca/1.0/spring-sca.xsd">
-
- <bean id="HelloworldBean" class="sample.HelloworldImpl">
- </bean>
-
-</beans> \ No newline at end of file
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld.composite b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld.composite
deleted file mode 100644
index 6d356758ae..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/main/resources/helloworld.composite
+++ /dev/null
@@ -1,36 +0,0 @@
-<?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.
--->
-<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- targetNamespace="http://sample"
- xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.1"
- name="helloworld">
-
- <component name="HelloworldClientComponent">
- <implementation.spring location="helloworld-client-context.xml"/>
- <service name="HelloworldClientBean">
- <tuscany:binding.jsonrpc/>
- </service>
- <reference name="dateService" target="DateServiceComponent"/>
- </component>
-
- <component name="DateServiceComponent">
- <implementation.java class="sample.DateServiceImpl"/>
- </component>
-</composite>
diff --git a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/test/java/sample/HelloworldTestCase.java b/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/test/java/sample/HelloworldTestCase.java
deleted file mode 100644
index 7e679ec0e9..0000000000
--- a/sca-java-2.x/trunk/samples/getting-started/contributions/contribution-helloworld-spring/src/test/java/sample/HelloworldTestCase.java
+++ /dev/null
@@ -1,33 +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 sample;
-
-import static org.junit.Assert.assertEquals;
-
-import org.junit.Test;
-
-public class HelloworldTestCase {
-
- @Test
- public void testSayHello() {
- HelloworldImpl helloworld = new HelloworldImpl();
- assertEquals("Hello Petra", helloworld.sayHello("Petra"));
- }
-
-}