Author: rfeng
Date: Thu Oct 5 17:34:29 2006
New Revision: 453442
URL: http://svn.apache.org/viewvc?view=rev&rev=453442
Log:
Add helloworld ws async
Added:
incubator/tuscany/java/samples/sca/helloworldws-async/
incubator/tuscany/java/samples/sca/helloworldws-async/.ruleset
incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml (with props)
incubator/tuscany/java/samples/sca/helloworldws-async/readme.htm
incubator/tuscany/java/samples/sca/helloworldws-async/setup.bat
incubator/tuscany/java/samples/sca/helloworldws-async/src/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
(with props)
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
(with props)
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
(with props)
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/META-INF/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/META-INF/LICENSE.txt
(with props)
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/META-INF/NOTICE
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/META-INF/README.txt
(with props)
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/META-INF/sca/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/wsdl/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/resources/wsdl/helloworld.wsdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/sca/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/sca/default.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/binding.axis2.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/databinding.axiom.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/databinding.sdo.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/interface.wsdl.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/META-INF/tuscany/webapp.scdl
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/WEB-INF/
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/webapp/WEB-INF/web.xml
(with props)
Added: incubator/tuscany/java/samples/sca/helloworldws-async/.ruleset
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/.ruleset?view=auto&rev=453442
==============================================================================
--- incubator/tuscany/java/samples/sca/helloworldws-async/.ruleset (added)
+++ incubator/tuscany/java/samples/sca/helloworldws-async/.ruleset Thu Oct 5
17:34:29 2006
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ruleset name="pmd-eclipse">
+ <description>PMD Plugin preferences rule set</description>
+
+
+ <rule ref="rulesets/basic.xml/BooleanInstantiation"/>
+ <rule ref="rulesets/basic.xml/CollapsibleIfStatements"/>
+ <rule ref="rulesets/basic.xml/DoubleCheckedLocking"/>
+<!--<rule ref="rulesets/basic.xml/EmptyCatchBlock"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptyFinallyBlock"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptyIfStmt"/>-->
+ <rule ref="rulesets/basic.xml/EmptyStatementNotInLoop"/>
+<!--<rule ref="rulesets/basic.xml/EmptyStaticInitializer"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptySwitchStatements"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptySynchronizedBlock"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptyTryBlock"/>-->
+<!--<rule ref="rulesets/basic.xml/EmptyWhileStmt"/>-->
+ <rule ref="rulesets/basic.xml/ForLoopShouldBeWhileLoop"/>
+ <rule ref="rulesets/basic.xml/JumbledIncrementer"/>
+<!--<rule ref="rulesets/basic.xml/OverrideBothEqualsAndHashcode"/>-->
+ <rule ref="rulesets/basic.xml/ReturnFromFinallyBlock"/>
+ <rule ref="rulesets/basic.xml/UnconditionalIfStatement"/>
+ <rule ref="rulesets/basic.xml/UnnecessaryConversionTemporary"/>
+ <rule ref="rulesets/basic.xml/UnnecessaryFinalModifier"/>
+ <rule ref="rulesets/basic.xml/UnnecessaryReturn"/>
+<!--<rule ref="rulesets/basic.xml/UselessOverridingMethod"/>-->
+
+<!--<rule ref="rulesets/braces.xml/ForLoopsMustUseBraces"/>-->
+<!--<rule ref="rulesets/braces.xml/IfElseStmtsMustUseBraces"/>-->
+<!--<rule ref="rulesets/braces.xml/IfStmtsMustUseBraces"/>-->
+<!--<rule ref="rulesets/braces.xml/WhileLoopsMustUseBraces"/>-->
+
+<!--<rule ref="rulesets/clone.xml/CloneMethodMustImplementCloneable"/>-->
+<!--<rule ref="rulesets/clone.xml/CloneThrowsCloneNotSupportedException"/>-->
+<!--<rule ref="rulesets/clone.xml/ProperCloneImplementation"/>-->
+
+<!--<rule ref="rulesets/codesize.xml/CyclomaticComplexity"/>-->
+<!--<rule ref="rulesets/codesize.xml/ExcessiveClassLength"/>-->
+<!--<rule ref="rulesets/codesize.xml/ExcessiveMethodLength"/>-->
+<!--<rule ref="rulesets/codesize.xml/ExcessiveParameterList"/>-->
+<!--<rule ref="rulesets/codesize.xml/ExcessivePublicCount"/>-->
+<!--<rule ref="rulesets/codesize.xml/TooManyFields"/>-->
+
+<rule ref="rulesets/controversial.xml/AssignmentInOperand"/>
+<!--<rule ref="rulesets/controversial.xml/AtLeastOneConstructor"/>-->
+<!--<rule ref="rulesets/controversial.xml/CallSuperInConstructor"/>-->
+<!--<rule ref="rulesets/controversial.xml/DontImportSun"/>-->
+<!--<rule ref="rulesets/controversial.xml/NullAssignment"/>-->
+<!--<rule ref="rulesets/controversial.xml/OnlyOneReturn"/>-->
+<!--<rule ref="rulesets/controversial.xml/SingularField"/>-->
+<!--<rule ref="rulesets/controversial.xml/SuspiciousOctalEscape"/>-->
+<!--<rule ref="rulesets/controversial.xml/UnnecessaryConstructor"/>-->
+<rule ref="rulesets/controversial.xml/UnnecessaryParentheses"/>
+<!--<rule ref="rulesets/controversial.xml/UnusedModifier"/>-->
+
+<!--<rule ref="rulesets/coupling.xml/CouplingBetweenObjects"/>-->
+<!--<rule ref="rulesets/coupling.xml/ExcessiveImports"/>-->
+<!--<rule ref="rulesets/coupling.xml/LooseCoupling"/>-->
+
+<!--<rule ref="rulesets/design.xml/AbstractClassWithoutAbstractMethod"/>-->
+<!--<rule ref="rulesets/design.xml/AccessorClassGeneration"/>-->
+<!--<rule ref="rulesets/design.xml/AssignmentToNonFinalStatic"/>-->
+<!--<rule ref="rulesets/design.xml/AvoidDeeplyNestedIfStmts"/>-->
+<!--<rule ref="rulesets/design.xml/AvoidInstanceofChecksInCatchClause"/>-->
+<rule ref="rulesets/design.xml/AvoidProtectedFieldInFinalClass"/>
+<!--<rule ref="rulesets/design.xml/AvoidReassigningParameters"/>-->
+<!--<rule ref="rulesets/design.xml/AvoidSynchronizedAtMethodLevel"/>-->
+<!--<rule ref="rulesets/design.xml/BadComparison"/>-->
+<!--<rule ref="rulesets/design.xml/CloseConnection"/>-->
+<!--<rule ref="rulesets/design.xml/CompareObjectsWithEquals"/>-->
+<!--<rule ref="rulesets/design.xml/ConfusingTernary"/>-->
+<rule ref="rulesets/design.xml/ConstructorCallsOverridableMethod"/>
+<!--<rule ref="rulesets/design.xml/DefaultLabelNotLastInSwitchStmt"/>-->
+<!--<rule ref="rulesets/design.xml/FinalFieldCouldBeStatic"/>-->
+<rule ref="rulesets/design.xml/IdempotentOperations"/>
+<!--<rule ref="rulesets/design.xml/ImmutableField"/>-->
+<!--<rule ref="rulesets/design.xml/InstantiationToGetClass"/>-->
+<!--<rule ref="rulesets/design.xml/MissingBreakInSwitch"/>-->
+<!--<rule
ref="rulesets/design.xml/MissingStaticMethodInNonInstantiatableClass"/>-->
+<!--<rule ref="rulesets/design.xml/NonCaseLabelInSwitchStatement"/>-->
+<!--<rule ref="rulesets/design.xml/NonStaticInitializer"/>-->
+<rule ref="rulesets/design.xml/OptimizableToArrayCall"/>
+<rule ref="rulesets/design.xml/PositionLiteralsFirstInComparisons"/>
+<rule ref="rulesets/design.xml/SimplifyBooleanExpressions"/>
+<rule ref="rulesets/design.xml/SimplifyBooleanReturns"/>
+<rule ref="rulesets/design.xml/SimplifyConditional"/>
+<!--<rule ref="rulesets/design.xml/SwitchDensity"/>-->
+<!--<rule ref="rulesets/design.xml/SwitchStmtsShouldHaveDefault"/>-->
+<!--<rule ref="rulesets/design.xml/UnnecessaryLocalBeforeReturn"/>-->
+<!--<rule ref="rulesets/design.xml/UseLocaleWithCaseConversions"/>-->
+<!--<rule ref="rulesets/design.xml/UseNotifyAllInsteadOfNotify"/>-->
+<!--<rule ref="rulesets/design.xml/UseSingleton"/>-->
+
+<!--<rule ref="rulesets/finalizers.xml/EmptyFinalizer"/>-->
+<!--<rule ref="rulesets/finalizers.xml/FinalizeOnlyCallsSuperFinalize"/>-->
+<!--<rule ref="rulesets/finalizers.xml/FinalizeOverloaded"/>-->
+<!--<rule ref="rulesets/finalizers.xml/FinalizeDoesNotCallSuperFinalize"/>-->
+<!--<rule ref="rulesets/finalizers.xml/FinalizeShouldBeProtected"/>-->
+<!--<rule ref="rulesets/finalizers.xml/AvoidCallingFinalize"/>-->
+
+<!--<rule ref="rulesets/imports.xml/DuplicateImports"/>-->
+<!--<rule ref="rulesets/imports.xml/DontImportJavaLang"/>-->
+<!--<rule ref="rulesets/imports.xml/UnusedImports"/>-->
+<!--<rule ref="rulesets/imports.xml/ImportFromSamePackage"/>-->
+
+<!--<rule ref="rulesets/javabeans.xml/BeanMembersShouldSerialize"/>-->
+<!--<rule ref="rulesets/javabeans.xml/MissingSerialVersionUID"/>-->
+
+<!--<rule ref="rulesets/junit.xml/JUnitStaticSuite"/>-->
+<!--<rule ref="rulesets/junit.xml/JUnitSpelling"/>-->
+<!--<rule ref="rulesets/junit.xml/JUnitAssertionsShouldIncludeMessage"/>-->
+<!--<rule ref="rulesets/junit.xml/JUnitTestsShouldIncludeAssert"/>-->
+<!--<rule ref="rulesets/junit.xml/TestClassWithoutTestCases"/>-->
+<!--<rule ref="rulesets/junit.xml/UnnecessaryBooleanAssertion"/>-->
+<!--<rule ref="rulesets/junit.xml/UseAssertEqualsInsteadOfAssertTrue"/>-->
+<!--<rule ref="rulesets/junit.xml/UseAssertSameInsteadOfAssertTrue"/>-->
+
+ <!--<rule ref="rulesets/logging-java.xml/AvoidPrintStackTrace"/>-->
+ <!--<rule ref="rulesets/logging-java.xml/LoggerIsNotStaticFinal"/>-->
+ <!--<rule ref="rulesets/logging-java.xml/MoreThanOneLogger"/>-->
+ <!--<rule ref="rulesets/logging-java.xml/LoggerIsNotStaticFinal"/>-->
+ <!--<rule ref="rulesets/logging-java.xml/LogBlockWithoutIf"/>-->
+ <!--<rule ref="rulesets/logging-java.xml/SystemPrintln"/>-->
+ <!--<rule
ref="rulesets/logging-jakarta-commons.xml/UseCorrectExceptionLogging"/>-->
+ <!--<rule ref="rulesets/logging-jakarta-commons.xml/ProperLogger"/>-->
+
+ <!--<rule ref="rulesets/naming.xml/ShortVariable"/>-->
+ <!--<rule ref="rulesets/naming.xml/LongVariable"/>-->
+ <!--<rule ref="rulesets/naming.xml/ShortMethodName"/>-->
+ <!--<rule ref="rulesets/naming.xml/VariableNamingConventions"/>-->
+ <!--<rule ref="rulesets/naming.xml/MethodNamingConventions"/>-->
+ <!--<rule ref="rulesets/naming.xml/ClassNamingConventions"/>-->
+ <!--<rule ref="rulesets/naming.xml/AbstractNaming"/>-->
+ <!--<rule ref="rulesets/naming.xml/AvoidDollarSigns"/>-->
+ <!--<rule ref="rulesets/naming.xml/MethodWithSameNameAsEnclosingClass"/>-->
+ <!--<rule ref="rulesets/naming.xml/SuspiciousHashcodeMethodName"/>-->
+ <!--<rule ref="rulesets/naming.xml/SuspiciousConstantFieldName"/>-->
+ <!--<rule ref="rulesets/naming.xml/AvoidFieldNameMatchingTypeName"/>-->
+ <!--<rule ref="rulesets/naming.xml/AvoidFieldNameMatchingMethodName"/>-->
+ <!--<rule
ref="rulesets/naming.xml/AvoidNonConstructorMethodsWithClassName"/>-->
+ <!--<rule ref="rulesets/naming.xml/NoPackage"/>-->
+ <!--<rule ref="rulesets/naming.xml/PackageCase"/>-->
+
+ <!--<rule ref="rulesets/optimizations.xml/LocalVariableCouldBeFinal"/>-->
+ <!--<rule ref="rulesets/optimizations.xml/MethodArgumentCouldBeFinal"/>-->
+ <!--<rule
ref="rulesets/optimizations.xml/AvoidInstantiatingObjectsInLoops"/>-->
+ <!--<rule ref="rulesets/optimizations.xml/UseArrayListInsteadOfVector"/>-->
+ <!--<rule ref="rulesets/optimizations.xml/SimplifyStartsWith"/>-->
+ <!--<rule
ref="rulesets/optimizations.xml/UseStringBufferForStringAppends"/>-->
+
+ <!--<rule ref="rulesets/strictexception.xml/AvoidCatchingThrowable"/>-->
+ <!--<rule
ref="rulesets/strictexception.xml/SignatureDeclareThrowsException"/>-->
+ <!--<rule ref="rulesets/strictexception.xml/ExceptionAsFlowControl"/>-->
+ <!--<rule ref="rulesets/strictexception.xml/AvoidCatchingNPE"/>-->
+ <!--<rule
ref="rulesets/strictexception.xml/AvoidThrowingRawExceptionTypes"/>-->
+ <!--<rule
ref="rulesets/strictexception.xml/AvoidThrowingNullPointerException"/>-->
+
+ <!--<rule ref="rulesets/strings.xml/AvoidDuplicateLiterals"/>-->
+ <!--<rule ref="rulesets/strings.xml/StringInstantiation"/>-->
+ <!--<rule ref="rulesets/strings.xml/StringToString"/>-->
+ <!--<rule
ref="rulesets/strings.xml/AvoidConcatenatingNonLiteralsInStringBuffer"/>-->
+ <!--<rule ref="rulesets/strings.xml/UnnecessaryCaseChange"/>-->
+
+ <!--<rule ref="rulesets/sunsecure.xml/MethodReturnsInternalArray"/>-->
+ <!--<rule ref="rulesets/sunsecure.xml/ArrayIsStoredDirectly"/>-->
+
+ <rule ref="rulesets/unusedcode.xml/UnusedLocalVariable"/>
+ <rule ref="rulesets/unusedcode.xml/UnusedPrivateField"/>
+ <rule ref="rulesets/unusedcode.xml/UnusedPrivateMethod"/>
+ <!--<rule ref="rulesets/unusedcode.xml/UnusedFormalParameter"/>-->
+
+</ruleset>
Added: incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml?view=auto&rev=453442
==============================================================================
--- incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml (added)
+++ incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml Thu Oct 5
17:34:29 2006
@@ -0,0 +1,130 @@
+<?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>
+ <parent>
+ <groupId>org.apache.tuscany.samples.sca</groupId>
+ <artifactId>parent</artifactId>
+ <version>1.0-incubator-M2-SNAPSHOT</version>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>sample-helloworldws-async</artifactId>
+ <packaging>war</packaging>
+ <name>Tuscany HelloWorld Web Service Sample</name>
+ <description>A sample HelloWorld Async Web Service.</description>
+
+ <properties>
+ <ws.type>axis2</ws.type>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.osoa</groupId>
+ <artifactId>sca-api-r0.95</artifactId>
+ <version>1.0-incubator-M2-SNAPSHOT</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.kernel</groupId>
+ <artifactId>tuscany-api</artifactId>
+ <version>${pom.version}</version>
+ <scope>compile</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+
+ <dependency>
+ <groupId>commonj</groupId>
+ <artifactId>sdo-api-r2.0.1</artifactId>
+ <version>1.0-incubator-M2-SNAPSHOT</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.kernel</groupId>
+ <artifactId>core</artifactId>
+ <version>${pom.version}</version>
+ <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>2.4</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.services.bindings</groupId>
+ <artifactId>axis2</artifactId>
+ <version>${pom.version}</version>
+ <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.services.databinding</groupId>
+ <artifactId>databinding-axiom</artifactId>
+ <version>${pom.version}</version>
+ <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.runtime</groupId>
+ <artifactId>webapp</artifactId>
+ <version>${pom.version}</version>
+ <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tuscany.sca.runtime</groupId>
+ <artifactId>webapp-host</artifactId>
+ <version>${pom.version}</version>
+ <scope>runtime</scope> <!-- runtime is need for webapp integration
to include jar -->
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-api</artifactId>
+ <version>1.1</version>
+ <scope>compile</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.ws.commons.axiom</groupId>
+ <artifactId>axiom-impl</artifactId>
+ <version>1.1</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>3.8.1</version>
+ <scope>test</scope>
+ </dependency>
+
+ </dependencies>
+
+ <build>
+ <finalName>sample-helloworldws-1.0-incubator-M2-SNAPSHOT</finalName>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.tuscany.sca.plugins</groupId>
+ <artifactId>tuscany-war-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>tuscany-war</id>
+ <goals>
+ <goal>tuscany-war</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/tuscany/java/samples/sca/helloworldws-async/pom.xml
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added: incubator/tuscany/java/samples/sca/helloworldws-async/readme.htm
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/readme.htm?view=auto&rev=453442
==============================================================================
--- incubator/tuscany/java/samples/sca/helloworldws-async/readme.htm (added)
+++ incubator/tuscany/java/samples/sca/helloworldws-async/readme.htm Thu Oct 5
17:34:29 2006
@@ -0,0 +1,48 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html><head><!-- Copyright (c) 2005 The Apache Software Foundation or its
licensors, as applicable. Licensed under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or
agreed to in writing, software distributed under the License is distributed on
an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
or implied. See the License for the specific language governing permissions and
limitations under the License. -->
+<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"><meta
http-equiv="Content-Style-Type" content="text/css"><title>Tuscany
+Hello World Web Service Sample</title><!-- LINK rel="stylesheet"
href="ait.css" type="text/css" --><!-- maven -->
+<style type="text/css" media="all">
[EMAIL PROTECTED] url("../../../../css/maven-base.css");
[EMAIL PROTECTED] url("../../../../css/maven-theme.css");
[EMAIL PROTECTED] url("../../../../css/site.css");
+</style><link rel="stylesheet" href="./css/print.css" type="text/css"
media="print"><!-- end maven --></head>
+<body><h2>Tuscany
+Hello World WS Sample</h2>
+<h3>Overview</h3>
+<p>The Tuscany hello world ws sample shows using the Tuscany SCA
+runtime in a Tomcat environment providing a web
+service.</p>
+<h3>Location</h3>
+This sample is located in the samples\sca\helloworldws
+directory.<br>
+<h3>Setup</h3>
+Set up your server as described in the <a href="../../../GettingStarted.htm"
target="_blank">Tomcat
+Setup</a>. If you are not using the pre-configured Tomcat server from
the binary distribution, you will need to add
+ <span style="font-weight: bold;">sample-helloworldws-incubating-M1.war</span>
+to your Tomcat's webapp directory.
+<h3>Running</h3>
+This service can be invoked by the Tuscany SCA <a target="_blank"
href="../helloworldwsclient/readme.htm">helloworldwsclient</a> or <a
target="_blank" href="../helloworldjsclient/readme.htm">helloworldjsclient</a>
+sample.<br>
+<h3>Code Overview</h3>
+The source files are physically organized as shown below:<br>
+<table style="text-align: left; width: 100%;" border="1" cellpadding="2"
cellspacing="2"><tbody><tr><td>
+<pre>+---main<br> +---resources<br> ¦ ¦ sca.module<br>
¦ ¦<br> ¦ +---wsdl<br> ¦
helloworld.wsdl<br> ¦<br> +---webapp<br> +---WEB-INF<br>
web.xml<br></pre></td></tr></tbody></table>
+<br><br><table style="text-align: left; width: 100%; height: 154px;"
border="0" cellpadding="2" cellspacing="2"><tbody>
+<tr><td style="vertical-align: top; height: 62px;">sca.module</td>
+<td style="height: 62px;">Defines the SCA module,
+entryPoint and component. Defines for the HelloWorldServiceComponent
+component and the Java class that implements the component For the
+entryPoint it defines WSDL for the service, the Java interface provided
+by the service, and wires the service to
+the HelloWorldServiceComponent</td>
+</tr><tr>
+<td>helloworld.wsdl</td>
+<td>WSDL for the service.</td>
+</tr><tr><td>web.xml</td>
+<td>Standard J2EE web application's web.xml</td>
+</tr></tbody></table>
+<p>You may have noticed that there is no Java source for this
+components implementation. There reason is this sample reuses
+the code from the helloworld sample to implement the service.
+</p></body></html>
Added: incubator/tuscany/java/samples/sca/helloworldws-async/setup.bat
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/setup.bat?view=auto&rev=453442
==============================================================================
--- incubator/tuscany/java/samples/sca/helloworldws-async/setup.bat (added)
+++ incubator/tuscany/java/samples/sca/helloworldws-async/setup.bat Thu Oct 5
17:34:29 2006
@@ -0,0 +1,16 @@
[EMAIL PROTECTED] off
+pushd target
+jar -xf ..\apache-tomcat-5.5.17.zip
+popd
+copy target\sample-helloworldws-1.0-SNAPSHOT.war
target\apache-tomcat-5.5.17\webapps
+rem pushd target\apache-tomcat-5.5.17\webapps
+rem md sample-helloworldws-1.0-SNAPSHOT
+rem cd sample-helloworldws-1.0-SNAPSHOT
+rem jar -xf ..\sample-helloworldws-1.0-SNAPSHOT.war
+pushd target\apache-tomcat-5.5.17\shared
+rem jar -xf
"%USERPROFILE%\.m2\repository\org\apache\tuscany\web\1.0-SNAPSHOT\web-1.0-SNAPSHOT-bin.zip"
+jar -xf
"%USERPROFILE%\.m2\repository\org\apache\tuscany\web\1.0-SNAPSHOT\web-1.0-SNAPSHOT-bin.zip"
+popd
+rem hack
+mkdir target\apache-tomcat-5.5.17\shared\extension
+copy target\apache-tomcat-5.5.17\shared\lib\axis2-1.0-SNAPSHOT.jar
target\apache-tomcat-5.5.17\shared\extension
Added:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java?view=auto&rev=453442
==============================================================================
---
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
(added)
+++
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
Thu Oct 5 17:34:29 2006
@@ -0,0 +1,27 @@
+/*
+ * 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 helloworld;
+
+import org.osoa.sca.annotations.Remotable;
+
[EMAIL PROTECTED]
+public interface HelloWorldCallback {
+
+ public void getGreetingsCallback(String getGreetingsReturn);
+}
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldCallback.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java?view=auto&rev=453442
==============================================================================
---
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
(added)
+++
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
Thu Oct 5 17:34:29 2006
@@ -0,0 +1,63 @@
+/*
+ * 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 helloworld;
+
+import org.osoa.sca.annotations.Callback;
+import org.osoa.sca.annotations.Scope;
+import org.osoa.sca.annotations.Service;
+
+import commonj.sdo.DataObject;
+
+/**
+ * This class implements the HelloWorld service.
+ */
[EMAIL PROTECTED](HelloWorldService.class)
[EMAIL PROTECTED]("MODULE")
+public class HelloWorldImpl implements HelloWorldService {
+
+ private HelloWorldCallback helloWorldCallback;
+
+ @Callback
+ void setHelloWorldCallback(HelloWorldCallback helloWorldCallback) {
+ System.err.println("injecting @callback");
+ this.helloWorldCallback = helloWorldCallback;
+ }
+
+ public String getGreetings(String name) {
+ System.err.println("In getGreetings, returning greeting");
+ return "Hola " + name;
+ }
+
+ public String getGreetings1(DataObject name) {
+ String firstName = name.getString("firstName");
+ String lastName = name.getString("lastName");
+ return "Hi " + firstName + " " + lastName;
+ }
+
+ public void getGreetingsWithCallback(String name) {
+ //System.err.println("In getGreetingsWithCallback, invoking callback");
+ System.err.println("In getGreetingsWithCallback, invoking callback: "
+ helloWorldCallback);
+ try {
+ helloWorldCallback.getGreetingsCallback("Alo " + name);
+ } catch(Throwable t) {
+ t.printStackTrace();
+ }
+ System.err.println("In getGreetingsWithCallback, invoked callback");
+ }
+}
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldImpl.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
Added:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
URL:
http://svn.apache.org/viewvc/incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java?view=auto&rev=453442
==============================================================================
---
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
(added)
+++
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
Thu Oct 5 17:34:29 2006
@@ -0,0 +1,43 @@
+/*
+ * 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 helloworld;
+
+import org.apache.tuscany.api.annotation.DataType;
+import org.osoa.sca.annotations.Callback;
+import org.osoa.sca.annotations.Remotable;
+import org.osoa.sca.annotations.Service;
+
+import commonj.sdo.DataObject;
+
+/**
+ * This is the business interface of the HelloWorld greetings service.
+ */
[EMAIL PROTECTED]
[EMAIL PROTECTED]
[EMAIL PROTECTED](HelloWorldCallback.class)
+public interface HelloWorldService {
+
+ public String getGreetings(String name);
+ @DataType(name="commonj.sdo.DataObject")
+ public String getGreetings1(DataObject name);
+
+ public void getGreetingsWithCallback(String name);
+
+}
+
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange:
incubator/tuscany/java/samples/sca/helloworldws-async/src/main/java/helloworld/HelloWorldService.java
------------------------------------------------------------------------------
svn:keywords = Rev Date
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]