diff options
Diffstat (limited to 'sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources')
8 files changed, 0 insertions, 324 deletions
diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype-metadata.xml b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype-metadata.xml deleted file mode 100644 index 1e1c124869..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype-metadata.xml +++ /dev/null @@ -1,49 +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. ---> -<archetype-descriptor name="myproject"> - <fileSets> - <fileSet filtered="true" packaged="true" encoding="UTF-8"> - <directory>src/main/java</directory> - <includes> - <include>**/*.java</include> - </includes> - </fileSet> - <fileSet filtered="true" packaged="true" encoding="UTF-8"> - <directory>src/test/java</directory> - <includes> - <include>**/*.java</include> - </includes> - </fileSet> - <fileSet filtered="true" encoding="UTF-8"> - <directory>src/main/resources</directory> - <includes> - <include>**/*.xml</include> - <include>**/*.composite</include> - </includes> - </fileSet> - <fileSet filtered="true" encoding="UTF-8"> - <directory>src/test/resources</directory> - <includes> - <include>**/*.xml</include> - <include>**/*.composite</include> - </includes> - </fileSet> - </fileSets> -</archetype-descriptor>
\ No newline at end of file diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype.xml b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype.xml deleted file mode 100644 index 6e0591fbfe..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/META-INF/maven/archetype.xml +++ /dev/null @@ -1,22 +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. ---> -<archetype> - <id>tuscany-contribution-jar</id> -</archetype>
\ No newline at end of file diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/pom.xml b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/pom.xml deleted file mode 100644 index 2cbcbd1a38..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/pom.xml +++ /dev/null @@ -1,87 +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 xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> - <modelVersion>4.0.0</modelVersion> - - <groupId>${groupId}</groupId> - <artifactId>${artifactId}</artifactId> - <version>${version}</version> - <packaging>jar</packaging> - - <name>${artifactId}</name> - - <properties> - <tuscany.version>2.0-Beta3</tuscany.version> - <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> - </properties> - - <dependencies> - - <dependency> - <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-sca-api</artifactId> - <version>${tuscany.version}</version> - <scope>provided</scope> - </dependency> - - <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> - <version>4.8.1</version> - <scope>test</scope> - </dependency> - - <dependency> - <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-base-runtime</artifactId> - <version>${tuscany.version}</version> - <scope>test</scope> - </dependency> - - </dependencies> - - <build> - <defaultGoal>install</defaultGoal> - <finalName>${artifactId}</finalName> - - <plugins> - <plugin> - <groupId>org.apache.tuscany.sca</groupId> - <artifactId>tuscany-maven-plugin</artifactId> - <version>${tuscany.version}</version> - </plugin> - - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-compiler-plugin</artifactId> - <version>2.3.2</version> - <configuration> - <source>1.6</source> - <target>1.6</target> - <optimise>true</optimise> - <debug>true</debug> - </configuration> - </plugin> - </plugins> - - </build> - -</project> diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/Helloworld.java b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/Helloworld.java deleted file mode 100644 index 68f91f67cd..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/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 ${package}; - -import org.oasisopen.sca.annotation.Remotable; - -@Remotable -public interface Helloworld { - - String sayHello(String name); - -} diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/HelloworldImpl.java b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/HelloworldImpl.java deleted file mode 100644 index f5af4c7366..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/java/HelloworldImpl.java +++ /dev/null @@ -1,36 +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 ${package}; - -import org.oasisopen.sca.annotation.Init; -import org.oasisopen.sca.annotation.Scope; -import org.oasisopen.sca.annotation.EagerInit; - -@Scope("COMPOSITE") @EagerInit -public class HelloworldImpl implements Helloworld { - - public String sayHello(String name) { - return "Hello " + name; - } - - @Init - public void init() { - System.out.println(sayHello("world")); - } -} diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/META-INF/sca-contribution.xml b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/META-INF/sca-contribution.xml deleted file mode 100644 index d2e633d3d8..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/META-INF/sca-contribution.xml +++ /dev/null @@ -1,25 +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://${package}"> - - <deployable composite="sample:${artifactId}" /> - -</contribution> diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/helloworld.composite b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/helloworld.composite deleted file mode 100644 index 35970f63ca..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/main/resources/helloworld.composite +++ /dev/null @@ -1,29 +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" - xmlns:tuscany="http://tuscany.apache.org/xmlns/sca/1.1" - targetNamespace="http://${package}" - name="${artifactId}"> - - <component name="HelloworldComponent"> - <implementation.java class="${package}.HelloworldImpl"/> - </component> - -</composite> diff --git a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/test/java/HelloworldTestCase.java b/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/test/java/HelloworldTestCase.java deleted file mode 100644 index c98112cb93..0000000000 --- a/sca-java-2.x/tags/2.0-Beta3-RC2/maven/archetypes/contribution-jar/src/main/resources/archetype-resources/src/test/java/HelloworldTestCase.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 ${package}; - -import org.junit.Assert; - -import org.apache.tuscany.sca.Node; -import org.apache.tuscany.sca.TuscanyRuntime; -import org.junit.Test; -import org.oasisopen.sca.NoSuchServiceException; - -public class HelloworldTestCase { - - @Test - public void testSayHello() throws NoSuchServiceException { - - // Run the SCA composite in a Tuscany runtime - Node node = TuscanyRuntime.runComposite("helloworld.composite", "target/classes"); - try { - - // Get the Helloworld service proxy - Helloworld helloworld = node.getService(Helloworld.class, "HelloworldComponent"); - - // test that it works as expected - Assert.assertEquals("Hello Amelia", helloworld.sayHello("Amelia")); - - } finally { - // Stop the Tuscany runtime Node - node.stop(); - } - } -} |