From c7b50e47dd1dd51a4c1c83f92cd28845853bef90 Mon Sep 17 00:00:00 2001 From: lresende Date: Sat, 31 Jan 2009 08:59:12 +0000 Subject: Moving iTests that are not part of the main build to contrib git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@739528 13f79535-47bb-0310-9956-ffa450edef68 --- java/sca/contrib/itest/admin/README | 28 + java/sca/contrib/itest/admin/pom.xml | 60 + .../tuscany/sca/itest/admin/MyListService.java | 9 + .../sca/itest/admin/MyListServiceByYear.java | 8 + .../tuscany/sca/itest/admin/MyListServiceImpl.java | 69 + .../apache/tuscany/sca/itest/admin/MyLogger.java | 17 + .../apache/tuscany/sca/itest/admin/MyService.java | 9 + .../tuscany/sca/itest/admin/MyServiceByDate.java | 10 + .../tuscany/sca/itest/admin/MyServiceImpl.java | 113 ++ .../tuscany/sca/itest/admin/MyTotalService.java | 6 + .../sca/itest/admin/MyTotalServiceImpl.java | 74 + .../sca/itest/admin/SCAComponentService.java | 9 + .../admin/MySimpleServiceInRecursiveTestCase.java | 61 + .../sca/itest/admin/MySimpleServiceTestCase.java | 57 + .../sca/itest/admin/MyTotalServiceTestCase.java | 48 + .../test/resources/Iteration1Composite.composite | 43 + .../test/resources/Iteration3Composite.composite | 68 + .../src/test/resources/MySimpleService.composite | 59 + .../contrib/itest/binding-sca-jms/client/pom.xml | 63 + .../client/src/main/java/itest/MyClientImpl.java | 32 + .../client/src/main/java/itest/MyService.java | 28 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../client/src/main/resources/MyClient.composite | 29 + .../src/test/java/itest/MyClientTestCase.java | 39 + java/sca/contrib/itest/binding-sca-jms/pom.xml | 36 + .../contrib/itest/binding-sca-jms/service/pom.xml | 63 + .../service/src/main/java/itest/MyService.java | 28 + .../service/src/main/java/itest/MyServiceImpl.java | 28 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../service/src/main/resources/MyService.composite | 28 + .../src/test/java/itest/MyServiceTestCase.java | 34 + .../itest/bpel/helloworld-reference/pom.xml | 210 +++ .../src/test/java/greetings/GreetingsService.java | 31 + .../test/java/greetings/GreetingsServiceImpl.java | 33 + .../src/test/java/greetings/GreetingsTestCase.java | 60 + .../test/java/helloworld/HelloWorldService.java | 29 + .../java/helloworld/HelloWorldServiceImpl.java | 47 + .../test/java/helloworld/HelloWorldTestCase.java | 55 + .../test/resources/greetings/greetings.composite | 32 + .../src/test/resources/greetings/greetings.wsdl | 87 ++ .../src/test/resources/helloworld/deploy.xml | 35 + .../src/test/resources/helloworld/helloworld.bpel | 84 ++ .../resources/helloworld/helloworld.componentType | 36 + .../test/resources/helloworld/helloworld.composite | 36 + .../src/test/resources/helloworld/helloworld.wsdl | 82 ++ .../src/test/resources/log4j.properties | 36 + java/sca/contrib/itest/bpel/helloworld-ws/pom.xml | 176 +++ .../src/test/java/helloworld/HelloWorld.java | 45 + .../test/java/helloworld/HelloWorldTestCase.java | 64 + .../src/test/resources/helloworld/deploy.xml | 31 + .../src/test/resources/helloworld/helloworld.bpel | 66 + .../resources/helloworld/helloworld.componentType | 30 + .../test/resources/helloworld/helloworld.composite | 32 + .../src/test/resources/helloworld/helloworld.wsdl | 82 ++ .../src/test/resources/log4j.properties | 36 + java/sca/contrib/itest/bpel/helloworld/pom.xml | 162 +++ .../src/test/java/helloworld/HelloWorld.java | 45 + .../test/java/helloworld/HelloWorldTestCase.java | 63 + .../src/test/resources/helloworld/deploy.xml | 31 + .../src/test/resources/helloworld/helloworld.bpel | 66 + .../resources/helloworld/helloworld.componentType | 30 + .../test/resources/helloworld/helloworld.composite | 36 + .../src/test/resources/helloworld/helloworld.wsdl | 82 ++ .../helloworld/src/test/resources/log4j.properties | 36 + java/sca/contrib/itest/bpel/pom.xml | 37 + java/sca/contrib/itest/builder/pom.xml | 99 ++ .../tuscany/sca/itest/builder/ComponentDImpl.java | 45 + .../ComponentDReferenceMultiplicityImpl.java | 48 + .../tuscany/sca/itest/builder/ComponentEImpl.java | 36 + .../tuscany/sca/itest/builder/ComponentFImpl.java | 36 + .../apache/tuscany/sca/itest/builder/Service3.java | 33 + .../tuscany/sca/itest/builder/Service3a.java | 33 + .../scenario1/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario1/scenario1.composite | 45 + .../main/resources/scenario1/scenario1a.composite | 47 + .../scenario10/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario10/scenario10.composite | 62 + .../resources/scenario10/scenario10a.composite | 61 + .../src/main/resources/scenario10/service3.wsdl | 63 + .../scenario11/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario11/scenario11.composite | 59 + .../resources/scenario11/scenario11a.composite | 64 + .../src/main/resources/scenario11/service3.wsdl | 63 + .../scenario12/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario12/scenario12.composite | 58 + .../resources/scenario12/scenario12a.composite | 64 + .../scenario13/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario13/scenario13.composite | 58 + .../resources/scenario13/scenario13a.composite | 64 + .../scenario2/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario2/scenario2.composite | 45 + .../main/resources/scenario2/scenario2a.composite | 47 + .../scenario3/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario3/scenario3.composite | 44 + .../main/resources/scenario3/scenario3a.composite | 48 + .../scenario4/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario4/scenario4.composite | 44 + .../main/resources/scenario4/scenario4a.composite | 48 + .../scenario5/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario5/scenario5.composite | 46 + .../main/resources/scenario5/scenario5a.composite | 47 + .../src/main/resources/scenario5/scenarios.wsdl | 63 + .../scenario6/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario6/scenario6.composite | 47 + .../main/resources/scenario6/scenario6a.composite | 47 + .../src/main/resources/scenario6/scenarios.wsdl | 63 + .../scenario7/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario7/scenario7.composite | 45 + .../main/resources/scenario7/scenario7a.composite | 49 + .../src/main/resources/scenario7/scenarios.wsdl | 63 + .../scenario8/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario8/scenario8.composite | 44 + .../main/resources/scenario8/scenario8a.composite | 50 + .../src/main/resources/scenario8/scenarios.wsdl | 63 + .../scenario9/META-INF/sca-contribution.xml | 24 + .../main/resources/scenario9/scenario9.composite | 60 + .../main/resources/scenario9/scenario9a.composite | 61 + .../tuscany/sca/itest/builder/BuilderTestCase.java | 805 +++++++++++ .../builder/CompositeBuilderNonWiringImpl.java | 153 +++ .../sca/itest/builder/CustomCompositeBuilder.java | 207 +++ .../tuscany/sca/itest/builder/TestUtils.java | 203 +++ .../contrib/itest/callablereferences-ws/pom.xml | 59 + .../src/main/java/com/example/ExampleClient.java | 26 + .../main/java/com/example/ExampleClientImpl.java | 59 + .../src/main/java/com/example/ExampleService.java | 30 + .../main/java/com/example/ExampleServiceImpl.java | 33 + .../sca/itest/callablerefwsreturn/Alpha.java | 26 + .../sca/itest/callablerefwsreturn/AlphaImpl.java | 96 ++ .../sca/itest/callablerefwsreturn/Beta.java | 27 + .../sca/itest/callablerefwsreturn/BetaImpl.java | 46 + .../sca/itest/callablerefwsreturn/Gamma.java | 34 + .../sca/itest/callablerefwsreturn/GammaImpl.java | 49 + .../CallableReferenceWsReturnTest.composite | 54 + .../src/main/resources/example.composite | 40 + .../src/test/java/com/example/ExampleTestCase.java | 44 + .../CallableReferenceReturnTestCase.java | 49 + java/sca/contrib/itest/callablereferences/pom.xml | 81 ++ .../tuscany/sca/itest/callableref/AComponent.java | 39 + .../sca/itest/callableref/AComponentImpl.java | 114 ++ .../tuscany/sca/itest/callableref/BComponent.java | 30 + .../sca/itest/callableref/BComponentImpl.java | 38 + .../tuscany/sca/itest/callableref/CComponent.java | 27 + .../sca/itest/callableref/CComponentImpl.java | 30 + .../tuscany/sca/itest/callableref/DComponent.java | 30 + .../sca/itest/callableref/DComponentImpl.java | 65 + .../ConversationalService.java | 68 + .../ConversationalServiceImpl.java | 111 ++ .../tuscany/sca/itest/callablerefreturn/Alpha.java | 27 + .../sca/itest/callablerefreturn/AlphaImpl.java | 86 ++ .../tuscany/sca/itest/callablerefreturn/Beta.java | 28 + .../sca/itest/callablerefreturn/BetaImpl.java | 44 + .../tuscany/sca/itest/callablerefreturn/Gamma.java | 35 + .../sca/itest/callablerefreturn/GammaImpl.java | 47 + .../CallableReferenceConversationalTest.composite | 29 + .../CallableReferenceReturnTest.composite | 39 + .../main/resources/CallableReferenceTest.composite | 45 + .../src/main/resources/nodeA/CompositeA.composite | 46 + .../resources/nodeA/META-INF/sca-contribution.xml | 22 + .../src/main/resources/nodeB/CompositeB.composite | 43 + .../resources/nodeB/META-INF/sca-contribution.xml | 22 + .../CallableReferenceConversationalTestCase.java | 109 ++ .../CallableReferenceRemoteTestCase.java | 145 ++ .../CallableReferenceReturnTestCase.java | 48 + .../callableref/CallableReferenceTestCase.java | 83 ++ .../contribution-classes/build-jar.xml | 39 + .../contribution-classes/pom.xml | 203 +++ .../main/java/supplychain/customer/Customer.java | 35 + .../customer/JavaCustomerComponentImpl.java | 63 + .../illegal/JavaCustomerComponentImpl.java | 74 + .../retailer/JavaRetailerComponentImpl.java | 61 + .../main/java/supplychain/retailer/Retailer.java | 28 + .../shipper/JavaShipperComponentImpl.java | 52 + .../src/main/java/supplychain/shipper/Shipper.java | 28 + .../warehouse/JavaWarehouseComponentImpl.java | 47 + .../main/java/supplychain/warehouse/Warehouse.java | 28 + .../complete-supplychain-sca-contribution.xml | 26 + .../META-INF/customer-impl-sca-contribution.xml | 26 + .../customer-interface-sca-contribution.xml | 26 + .../META-INF/customer-sca-contribution.xml | 25 + .../META-INF/illegal-customer-sca-contribution.xml | 26 + .../illegal1-supplychain-sca-contribution.xml | 24 + .../illegal2-supplychain-sca-contribution.xml | 31 + .../META-INF/retailer-sca-contribution.xml | 25 + .../META-INF/shipper-sca-contribution.xml | 25 + .../META-INF/supplychain-sca-contribution.xml | 30 + .../META-INF/warehouse-sca-contribution.xml | 25 + .../supplychain/illegalsupplychain.composite | 48 + .../resources/supplychain/supplychain.composite | 48 + .../JavaWarehouseComponentImpl.componentType | 28 + .../contribution-test/pom.xml | 53 + .../test/contribution/ContributionTestCase.java | 373 +++++ .../tuscany/sca/test/contribution/SupplyChain.java | 231 ++++ .../TuscanyClassloadingTestCaseFIXME.java | 381 +++++ .../contrib/itest/contribution-classloader/pom.xml | 51 + .../export-composite/pom.xml | 67 + .../src/main/java/hello/Hello.java | 30 + .../src/main/java/hello/HelloImpl.java | 33 + .../main/resources/META-INF/sca-contribution.xml | 25 + .../src/main/resources/hello.composite | 31 + .../sca/test/contribution/HelloTestCase.java | 91 ++ .../contribution-import-export/export-java/pom.xml | 67 + .../main/java/helloworld/HelloWorldService.java | 30 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../helloworld/HelloWorldImpl.componentType | 30 + .../export-resource/pom.xml | 31 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../src/main/resources/ufservices/store.html | 27 + .../contribution-import-export/export-wsdl/pom.xml | 31 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../export-wsdl/src/main/resources/helloworld.wsdl | 76 + .../export-wsdl/src/main/resources/helloworld.xsd | 35 + .../import-composite/pom.xml | 73 + .../src/main/java/helloworld/HelloWorldImpl.java | 38 + .../src/main/java/helloworld/HelloWorldServer.java | 46 + .../main/java/helloworld/HelloWorldService.java | 30 + .../main/resources/META-INF/sca-contribution.xml | 27 + .../src/main/resources/helloworld.wsdl | 76 + .../src/main/resources/helloworld.xsd | 35 + .../src/main/resources/helloworldws.composite | 39 + .../contribution/HelloWorldServerTestCase.java | 126 ++ .../contribution-import-export/import-java/pom.xml | 73 + .../src/main/java/helloworld/HelloWorldImpl.java | 33 + .../main/resources/META-INF/sca-contribution.xml | 25 + .../src/main/resources/helloworldws.composite | 29 + .../contribution/HelloWorldServerTestCase.java | 127 ++ .../import-resource/pom.xml | 102 ++ .../main/resources/META-INF/sca-contribution.xml | 25 + .../src/main/resources/store.composite | 33 + .../sca/test/contribution/StoreTestCase.java | 129 ++ .../contribution-import-export/import-wsdl/pom.xml | 73 + .../src/main/java/helloworld/HelloWorldImpl.java | 33 + .../src/main/java/helloworld/HelloWorldServer.java | 46 + .../main/java/helloworld/HelloWorldService.java | 30 + .../main/resources/META-INF/sca-contribution.xml | 25 + .../src/main/resources/helloworldws.composite | 33 + .../contribution/HelloWorldServerTestCase.java | 137 ++ .../itest/contribution-import-export/pom.xml | 56 + .../contrib/itest/contribution-multiple/pom.xml | 51 + .../src/test/java/hello/Hello.java | 27 + .../src/test/java/hello/HelloImpl.java | 33 + .../src/test/java/helloworld/HelloWorldImpl.java | 38 + .../test/java/helloworld/HelloWorldService.java | 28 + .../java/test/ContributionCycleTestCaseFIXME.java | 121 ++ .../test/ContributionMultipleTestCaseFIXME.java | 131 ++ .../src/test/java/test/ContributionTestCase.java | 145 ++ .../META-INF/sca-contribution.xml | 26 + .../contribution-cycle-export/hello.composite | 31 + .../META-INF/sca-contribution.xml | 26 + .../helloworld_one.composite | 35 + .../META-INF/sca-contribution.xml | 25 + .../resources/contribution-export/hello.composite | 31 + .../META-INF/sca-contribution.xml | 26 + .../helloworld_one.composite | 35 + .../META-INF/sca-contribution.xml | 26 + .../helloworld_two.composite | 35 + java/sca/contrib/itest/contribution/pom.xml | 52 + .../src/main/java/calculator/AddService.java | 32 + .../src/main/java/calculator/AddServiceImpl.java | 30 + .../src/main/java/calculator/CalculatorClient.java | 46 + .../main/java/calculator/CalculatorService.java | 35 + .../java/calculator/CalculatorServiceImpl.java | 70 + .../src/main/java/calculator/DivideService.java | 32 + .../main/java/calculator/DivideServiceImpl.java | 30 + .../src/main/java/calculator/MultiplyService.java | 33 + .../main/java/calculator/MultiplyServiceImpl.java | 30 + .../src/main/java/calculator/SubtractService.java | 33 + .../main/java/calculator/SubtractServiceImpl.java | 30 + .../src/main/resources/ContributionTest.composite | 24 + .../main/resources/calculator/Calculator.composite | 51 + .../main/resources/calculator/sca-contribution.xml | 24 + .../contribution/ContributionServiceTestCase.java | 218 +++ .../resources/deployables/sample-calculator.jar | Bin 0 -> 26901 bytes .../resources/repository/sample-calculator.jar | Bin 0 -> 26901 bytes java/sca/contrib/itest/conversations-ws/pom.xml | 60 + .../itest/conversational/BusinessException.java | 41 + .../conversational/ConversationIdService.java | 29 + .../conversational/ConversationalCallback.java | 50 + .../itest/conversational/ConversationalClient.java | 50 + .../ConversationalReferenceClient.java | 36 + .../conversational/ConversationalService.java | 58 + ...ersationalServiceNonConversationalCallback.java | 59 + .../conversational/NonConversationalCallback.java | 42 + .../impl/ConversationAgeComponentImpl.java | 76 + .../impl/ConversationIdComponentImpl.java | 48 + .../impl/ConversationMaxIdleComponentImpl.java | 76 + .../impl/ConversationalClientStatefulImpl.java | 322 +++++ ...lientStatefulNonConversationalCallbackImpl.java | 311 +++++ .../impl/ConversationalClientStatelessImpl.java | 318 +++++ .../impl/ConversationalReferenceClientImpl.java | 43 + .../impl/ConversationalServiceRequestImpl.java | 124 ++ .../impl/ConversationalServiceStatefulImpl.java | 119 ++ ...rviceStatefulNonConversationalCallbackImpl.java | 118 ++ .../impl/ConversationalServiceStatelessImpl.java | 122 ++ .../ConversationalServiceStatelessScopeImpl.java | 94 ++ .../Conversational/META-INF/sca-contribution.xml | 22 + .../Conversational/conversational.composite | 169 +++ .../ConversationalServiceStateful.wsdl | 383 ++++++ .../META-INF/sca-contribution.xml | 22 + .../conversationalWSDL.composite | 46 + .../conversational/ConversationWSDLTestCase.java | 75 + .../NonConversationalCallbackTestCase.java | 198 +++ .../itest/conversational/RequestScopeTestCase.java | 209 +++ .../conversational/StatefulStatefulTestCase.java | 193 +++ .../conversational/StatefulStatelessTestCase.java | 193 +++ .../conversational/StatelessStatefulTestCase.java | 205 +++ .../conversational/StatelessStatelessTestCase.java | 192 +++ java/sca/contrib/itest/corba/pom.xml | 169 +++ .../sca/test/corba/ScenarioFiveTestCase.java | 51 + .../sca/test/corba/ScenarioFourTestCase.java | 149 ++ .../sca/test/corba/ScenarioOneTestCase.java | 371 +++++ .../sca/test/corba/ScenarioSixTestCase.java | 228 +++ .../sca/test/corba/ScenarioThreeTestCase.java | 130 ++ .../sca/test/corba/ScenarioTwoTestCase.java | 139 ++ .../tuscany/sca/test/corba/TestCorbaHost.java | 56 + .../test/corba/TestCorbaHostModuleActivator.java | 41 + .../sca/test/corba/generated/AnnotatedStruct.java | 43 + .../corba/generated/AnnotatedStructHelper.java | 97 ++ .../corba/generated/AnnotatedStructHolder.java | 57 + .../tuscany/sca/test/corba/generated/Color.java | 61 + .../sca/test/corba/generated/ColorHelper.java | 72 + .../sca/test/corba/generated/ColorHolder.java | 57 + .../sca/test/corba/generated/InnerStruct.java | 47 + .../test/corba/generated/InnerStructHelper.java | 112 ++ .../test/corba/generated/InnerStructHolder.java | 57 + .../sca/test/corba/generated/InnerUnion.java | 112 ++ .../sca/test/corba/generated/InnerUnionHelper.java | 106 ++ .../sca/test/corba/generated/InnerUnionHolder.java | 38 + .../test/corba/generated/LongSequenceHelper.java | 79 ++ .../test/corba/generated/LongSequenceHolder.java | 58 + .../sca/test/corba/generated/RichStruct.java | 47 + .../sca/test/corba/generated/RichStructHelper.java | 110 ++ .../sca/test/corba/generated/RichStructHolder.java | 57 + .../sca/test/corba/generated/RichUnion.java | 177 +++ .../sca/test/corba/generated/RichUnionHelper.java | 157 +++ .../sca/test/corba/generated/RichUnionHolder.java | 38 + .../sca/test/corba/generated/ScenarioOne.java | 32 + .../test/corba/generated/ScenarioOneHelper.java | 104 ++ .../test/corba/generated/ScenarioOneHolder.java | 57 + .../corba/generated/ScenarioOneOperations.java | 33 + .../sca/test/corba/generated/ScenarioSix.java | 32 + .../test/corba/generated/ScenarioSixHelper.java | 104 ++ .../test/corba/generated/ScenarioSixHolder.java | 57 + .../corba/generated/ScenarioSixOperations.java | 35 + .../sca/test/corba/generated/ScenarioTwo.java | 34 + .../test/corba/generated/ScenarioTwoHelper.java | 106 ++ .../test/corba/generated/ScenarioTwoHolder.java | 59 + .../corba/generated/ScenarioTwoOperations.java | 36 + .../test/corba/generated/StringArrayHelper.java | 95 ++ .../test/corba/generated/StringArrayHolder.java | 58 + .../test/corba/generated/StringSequenceHelper.java | 81 ++ .../test/corba/generated/StringSequenceHolder.java | 58 + .../corba/generated/TwoDimLongSequenceHelper.java | 83 ++ .../corba/generated/TwoDimLongSequenceHolder.java | 58 + .../test/corba/generated/UnexpectedException.java | 52 + .../corba/generated/UnexpectedExceptionHelper.java | 98 ++ .../corba/generated/UnexpectedExceptionHolder.java | 57 + .../sca/test/corba/generated/WrongColor.java | 55 + .../sca/test/corba/generated/WrongColorHelper.java | 105 ++ .../sca/test/corba/generated/WrongColorHolder.java | 57 + .../test/corba/generated/_ScenarioOneImplBase.java | 91 ++ .../sca/test/corba/generated/_ScenarioOneStub.java | 84 ++ .../test/corba/generated/_ScenarioSixImplBase.java | 105 ++ .../sca/test/corba/generated/_ScenarioSixStub.java | 119 ++ .../test/corba/generated/_ScenarioTwoImplBase.java | 93 ++ .../sca/test/corba/generated/_ScenarioTwoStub.java | 99 ++ .../tuscany/sca/test/corba/types/ScenarioFive.java | 33 + .../test/corba/types/ScenarioFiveComponent.java | 41 + .../sca/test/corba/types/ScenarioFiveImpl.java | 32 + .../tuscany/sca/test/corba/types/ScenarioFour.java | 38 + .../test/corba/types/ScenarioFourComponent.java | 41 + .../test/corba/types/ScenarioFourException.java | 41 + .../sca/test/corba/types/ScenarioFourImpl.java | 44 + .../sca/test/corba/types/ScenarioFourStruct.java | 40 + .../sca/test/corba/types/ScenarioOneComponent.java | 46 + .../sca/test/corba/types/ScenarioOneServant.java | 45 + .../sca/test/corba/types/ScenarioSixServant.java | 46 + .../sca/test/corba/types/ScenarioTwoServant.java | 42 + .../sca/test/corba/types/TAnnotatedStruct.java | 40 + .../tuscany/sca/test/corba/types/TColor.java | 62 + .../tuscany/sca/test/corba/types/TInnerStruct.java | 42 + .../tuscany/sca/test/corba/types/TInnerUnion.java | 59 + .../tuscany/sca/test/corba/types/TRichStruct.java | 42 + .../tuscany/sca/test/corba/types/TRichUnion.java | 95 ++ .../tuscany/sca/test/corba/types/TScenarioOne.java | 33 + .../test/corba/types/TScenarioOneComponent.java | 43 + .../sca/test/corba/types/TScenarioOneServant.java | 44 + .../tuscany/sca/test/corba/types/TScenarioSix.java | 37 + .../test/corba/types/TScenarioSixComponent.java | 41 + .../sca/test/corba/types/TScenarioSixServant.java | 42 + .../sca/test/corba/types/TScenarioThree.java | 42 + .../test/corba/types/TScenarioThreeComponent.java | 41 + .../test/corba/types/TScenarioThreeServant.java | 52 + .../tuscany/sca/test/corba/types/TScenarioTwo.java | 32 + .../test/corba/types/TScenarioTwoComponent.java | 41 + .../sca/test/corba/types/TScenarioTwoServant.java | 38 + .../org.apache.tuscany.sca.core.ModuleActivator | 18 + .../src/test/resources/ScenarioFive.composite | 41 + .../src/test/resources/ScenarioFour.composite | 56 + .../corba/src/test/resources/ScenarioOne.composite | 111 ++ .../corba/src/test/resources/ScenarioSix.composite | 41 + .../src/test/resources/ScenarioThree.composite | 43 + .../corba/src/test/resources/ScenarioTwo.composite | 43 + .../corba/src/test/resources/itest_scenario.idl | 110 ++ .../corba/src/test/resources/scenariofour.xsd | 31 + java/sca/contrib/itest/databindings/common/pom.xml | 126 ++ .../tuscany/sca/itest/generate/Generate.java | 181 +++ .../resources/generate/DatabindingTestCase.java.vm | 112 ++ .../src/main/resources/generate/Greeter.wsdl.vm | 103 ++ .../main/resources/generate/GreeterService.java.vm | 53 + .../generate/GreeterServiceClient.java.vm | 42 + .../generate/GreeterServiceClientImpl.java.vm | 65 + .../resources/generate/GreeterServiceImpl.java.vm | 55 + .../src/main/resources/generate/generate.xsd | 61 + .../common/src/main/resources/wsdl/Dummy.txt | 4 + .../common/src/main/resources/xsd/Annotation.xml | 24 + .../common/src/main/resources/xsd/Annotation.xsd | 38 + .../common/src/main/resources/xsd/Attribute.xml | 24 + .../common/src/main/resources/xsd/Attribute.xsd | 39 + .../src/main/resources/xsd/AttributeReference.xml | 24 + .../src/main/resources/xsd/AttributeReference.xsd | 40 + .../resources/xsd/AttributeWithDefaultValue.xml | 24 + .../resources/xsd/AttributeWithDefaultValue.xsd | 38 + .../main/resources/xsd/AttributeWithFixedValue.xml | 24 + .../main/resources/xsd/AttributeWithFixedValue.xsd | 38 + .../resources/xsd/AttributeWithSDOAliasName.xml | 24 + .../resources/xsd/AttributeWithSDOAliasName.xsd | 38 + .../resources/xsd/AttributeWithSDODataType.xml | 24 + .../resources/xsd/AttributeWithSDODataType.xsd | 38 + .../main/resources/xsd/AttributeWithSDOName.xml | 24 + .../main/resources/xsd/AttributeWithSDOName.xsd | 38 + ...ibuteWithSDOPropertySDOOppositePropertyType.xml | 24 + ...ibuteWithSDOPropertySDOOppositePropertyType.xsd | 38 + .../resources/xsd/AttributeWithSDOPropertyType.xml | 24 + .../resources/xsd/AttributeWithSDOPropertyType.xsd | 38 + .../main/resources/xsd/AttributeWithSDOString.xml | 24 + .../main/resources/xsd/AttributeWithSDOString.xsd | 38 + .../main/resources/xsd/BuiltInAnySimpleType.xml | 24 + .../main/resources/xsd/BuiltInAnySimpleType.xsd | 31 + .../src/main/resources/xsd/BuiltInAnyType.xml | 24 + .../src/main/resources/xsd/BuiltInAnyType.xsd | 31 + .../src/main/resources/xsd/BuiltInAnyURI.xml | 24 + .../src/main/resources/xsd/BuiltInAnyURI.xsd | 31 + .../src/main/resources/xsd/BuiltInBase64Binary.xml | 24 + .../src/main/resources/xsd/BuiltInBase64Binary.xsd | 31 + .../src/main/resources/xsd/BuiltInBoolean.xml | 27 + .../src/main/resources/xsd/BuiltInBoolean.xsd | 31 + .../common/src/main/resources/xsd/BuiltInByte.xml | 25 + .../common/src/main/resources/xsd/BuiltInByte.xsd | 31 + .../common/src/main/resources/xsd/BuiltInDate.xml | 24 + .../common/src/main/resources/xsd/BuiltInDate.xsd | 31 + .../src/main/resources/xsd/BuiltInDateTime.xml | 24 + .../src/main/resources/xsd/BuiltInDateTime.xsd | 31 + .../src/main/resources/xsd/BuiltInDecimal.xml | 23 + .../src/main/resources/xsd/BuiltInDecimal.xsd | 31 + .../src/main/resources/xsd/BuiltInDouble.xml | 25 + .../src/main/resources/xsd/BuiltInDouble.xsd | 31 + .../src/main/resources/xsd/BuiltInDuration.xml | 24 + .../src/main/resources/xsd/BuiltInDuration.xsd | 31 + .../common/src/main/resources/xsd/BuiltInFloat.xml | 24 + .../common/src/main/resources/xsd/BuiltInFloat.xsd | 31 + .../common/src/main/resources/xsd/BuiltInGDay.xml | 24 + .../common/src/main/resources/xsd/BuiltInGDay.xsd | 31 + .../src/main/resources/xsd/BuiltInGMonth.xml | 24 + .../src/main/resources/xsd/BuiltInGMonth.xsd | 31 + .../src/main/resources/xsd/BuiltInGMonthDay.xml | 24 + .../src/main/resources/xsd/BuiltInGMonthDay.xsd | 31 + .../common/src/main/resources/xsd/BuiltInGYear.xml | 24 + .../common/src/main/resources/xsd/BuiltInGYear.xsd | 31 + .../src/main/resources/xsd/BuiltInGYearMonth.xml | 24 + .../src/main/resources/xsd/BuiltInGYearMonth.xsd | 31 + .../src/main/resources/xsd/BuiltInHexBinary.xml | 24 + .../src/main/resources/xsd/BuiltInHexBinary.xsd | 31 + .../common/src/main/resources/xsd/BuiltInID.xml | 24 + .../common/src/main/resources/xsd/BuiltInID.xsd | 31 + .../common/src/main/resources/xsd/BuiltInIDREF.xml | 24 + .../common/src/main/resources/xsd/BuiltInIDREF.xsd | 31 + .../src/main/resources/xsd/BuiltInIDREFS.xml | 24 + .../src/main/resources/xsd/BuiltInIDREFS.xsd | 31 + .../common/src/main/resources/xsd/BuiltInInt.xml | 25 + .../common/src/main/resources/xsd/BuiltInInt.xsd | 31 + .../src/main/resources/xsd/BuiltInInteger.xml | 25 + .../src/main/resources/xsd/BuiltInInteger.xsd | 31 + .../src/main/resources/xsd/BuiltInLanguage.xml | 24 + .../src/main/resources/xsd/BuiltInLanguage.xsd | 31 + .../common/src/main/resources/xsd/BuiltInLong.xml | 25 + .../common/src/main/resources/xsd/BuiltInLong.xsd | 33 + .../src/main/resources/xsd/BuiltInNCName.xml | 24 + .../src/main/resources/xsd/BuiltInNCName.xsd | 31 + .../src/main/resources/xsd/BuiltInNMTOKEN.xml | 24 + .../src/main/resources/xsd/BuiltInNMTOKEN.xsd | 31 + .../src/main/resources/xsd/BuiltInNMTOKENS.xml | 24 + .../src/main/resources/xsd/BuiltInNMTOKENS.xsd | 31 + .../src/main/resources/xsd/BuiltInNOTATION.xml | 24 + .../src/main/resources/xsd/BuiltInNOTATION.xsd | 39 + .../common/src/main/resources/xsd/BuiltInName.xml | 24 + .../common/src/main/resources/xsd/BuiltInName.xsd | 31 + .../main/resources/xsd/BuiltInNegativeInteger.xml | 24 + .../main/resources/xsd/BuiltInNegativeInteger.xsd | 31 + .../resources/xsd/BuiltInNonNegativeInteger.xml | 24 + .../resources/xsd/BuiltInNonNegativeInteger.xsd | 31 + .../resources/xsd/BuiltInNonPositiveInteger.xml | 24 + .../resources/xsd/BuiltInNonPositiveInteger.xsd | 31 + .../main/resources/xsd/BuiltInNormalizedString.xml | 24 + .../main/resources/xsd/BuiltInNormalizedString.xsd | 31 + .../main/resources/xsd/BuiltInPositiveInteger.xml | 24 + .../main/resources/xsd/BuiltInPositiveInteger.xsd | 31 + .../common/src/main/resources/xsd/BuiltInQName.xml | 24 + .../common/src/main/resources/xsd/BuiltInQName.xsd | 31 + .../common/src/main/resources/xsd/BuiltInShort.xml | 25 + .../common/src/main/resources/xsd/BuiltInShort.xsd | 31 + .../src/main/resources/xsd/BuiltInString.xml | 24 + .../src/main/resources/xsd/BuiltInString.xsd | 31 + .../common/src/main/resources/xsd/BuiltInTime.xml | 24 + .../common/src/main/resources/xsd/BuiltInTime.xsd | 31 + .../common/src/main/resources/xsd/BuiltInToken.xml | 24 + .../common/src/main/resources/xsd/BuiltInToken.xsd | 31 + .../src/main/resources/xsd/BuiltInUnsignedByte.xml | 25 + .../src/main/resources/xsd/BuiltInUnsignedByte.xsd | 31 + .../src/main/resources/xsd/BuiltInUnsignedInt.xml | 25 + .../src/main/resources/xsd/BuiltInUnsignedInt.xsd | 31 + .../src/main/resources/xsd/BuiltInUnsignedLong.xml | 25 + .../src/main/resources/xsd/BuiltInUnsignedLong.xsd | 31 + .../main/resources/xsd/BuiltInUnsignedShort.xml | 25 + .../main/resources/xsd/BuiltInUnsignedShort.xsd | 31 + ...lexTypeComplexContentRestrictingComplexType.xml | 26 + ...lexTypeComplexContentRestrictingComplexType.xsd | 44 + .../xsd/ComplexTypeExtendingComplexType.xml | 27 + .../xsd/ComplexTypeExtendingComplexType.xsd | 43 + .../xsd/ComplexTypeExtendingSimpleType.xml | 24 + .../xsd/ComplexTypeExtendingSimpleType.xsd | 41 + ...plexTypeSimpleContentRestrictingComplexType.xml | 24 + ...plexTypeSimpleContentRestrictingComplexType.xsd | 41 + .../main/resources/xsd/ComplexTypeWithAbstract.xml | 27 + .../main/resources/xsd/ComplexTypeWithAbstract.xsd | 47 + .../main/resources/xsd/ComplexTypeWithCDATA.xml | 30 + .../main/resources/xsd/ComplexTypeWithCDATA.xsd | 39 + .../main/resources/xsd/ComplexTypeWithContent.xml | 26 + .../main/resources/xsd/ComplexTypeWithContent.xsd | 37 + .../main/resources/xsd/ComplexTypeWithMixed.xml | 29 + .../main/resources/xsd/ComplexTypeWithMixed.xsd | 39 + .../xsd/ComplexTypeWithOpenAttributes.xml | 24 + .../xsd/ComplexTypeWithOpenAttributes.xsd | 42 + .../resources/xsd/ComplexTypeWithOpenContent.xml | 31 + .../resources/xsd/ComplexTypeWithOpenContent.xsd | 39 + .../xsd/ComplexTypeWithOppositeProperty.xml | 30 + .../xsd/ComplexTypeWithOppositeProperty.xsd | 59 + .../resources/xsd/ComplexTypeWithSDOAliasName.xml | 26 + .../resources/xsd/ComplexTypeWithSDOAliasName.xsd | 38 + .../main/resources/xsd/ComplexTypeWithSDOName.xml | 26 + .../main/resources/xsd/ComplexTypeWithSDOName.xsd | 38 + .../resources/xsd/ComplexTypeWithSDOSequence.xml | 26 + .../resources/xsd/ComplexTypeWithSDOSequence.xsd | 40 + .../resources/xsd/ComplexTypeWithoutContent.xml | 24 + .../resources/xsd/ComplexTypeWithoutContent.xsd | 33 + .../main/resources/xsd/ComplexTypeWithoutName.xml | 26 + .../main/resources/xsd/ComplexTypeWithoutName.xsd | 39 + .../src/main/resources/xsd/DefaultNamespace.xml | 23 + .../src/main/resources/xsd/DefaultNamespace.xsd | 32 + .../common/src/main/resources/xsd/ElementInAll.xml | 27 + .../common/src/main/resources/xsd/ElementInAll.xsd | 40 + .../src/main/resources/xsd/ElementInChoice.xml | 25 + .../src/main/resources/xsd/ElementInChoice.xsd | 48 + .../xsd/ElementOfSDOChangeSummaryType.xml | 29 + .../xsd/ElementOfSDOChangeSummaryType.xsd | 34 + .../xsd/ElementOfSimpleTypeWithDefault.xml | 24 + .../xsd/ElementOfSimpleTypeWithDefault.xsd | 31 + .../resources/xsd/ElementOfSimpleTypeWithFixed.xml | 24 + .../resources/xsd/ElementOfSimpleTypeWithFixed.xsd | 31 + .../xsd/ElementOfSimpleTypeWithSDODataType.xml | 24 + .../xsd/ElementOfSimpleTypeWithSDODataType.xsd | 33 + ...mentOfSimpleTypeWithSDOOppositePropertyType.xml | 24 + ...mentOfSimpleTypeWithSDOOppositePropertyType.xsd | 33 + .../xsd/ElementOfSimpleTypeWithSDOPropertyType.xml | 24 + .../xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd | 32 + .../xsd/ElementOfSimpleTypeWithSDOString.xml | 24 + .../xsd/ElementOfSimpleTypeWithSDOString.xsd | 32 + .../resources/xsd/ElementSubstitutionGroupBase.xml | 40 + .../resources/xsd/ElementSubstitutionGroupBase.xsd | 52 + .../main/resources/xsd/ElementWithMaxOccurs.xml | 25 + .../main/resources/xsd/ElementWithMaxOccurs.xsd | 31 + .../src/main/resources/xsd/ElementWithNillable.xml | 24 + .../src/main/resources/xsd/ElementWithNillable.xsd | 31 + .../main/resources/xsd/ElementWithSDOAliasName.xml | 24 + .../main/resources/xsd/ElementWithSDOAliasName.xsd | 32 + .../src/main/resources/xsd/ElementWithSDOName.xml | 24 + .../src/main/resources/xsd/ElementWithSDOName.xsd | 32 + .../resources/xsd/GlobalElementComplexType.xml | 24 + .../resources/xsd/GlobalElementComplexType.xsd | 31 + .../main/resources/xsd/GlobalElementSimpleType.xml | 24 + .../main/resources/xsd/GlobalElementSimpleType.xsd | 26 + .../common/src/main/resources/xsd/Import.xml | 30 + .../common/src/main/resources/xsd/Import.xsd | 40 + .../src/main/resources/xsd/ImportedSchema.xsd | 33 + .../common/src/main/resources/xsd/Include.xml | 24 + .../common/src/main/resources/xsd/Include.xsd | 36 + .../common/src/main/resources/xsd/Interop.xsd | 138 ++ .../common/src/main/resources/xsd/Notation.xml | 24 + .../common/src/main/resources/xsd/Notation.xsd | 35 + .../common/src/main/resources/xsd/Person.xsd | 30 + .../src/main/resources/xsd/SDOJavaPackage.xml | 25 + .../src/main/resources/xsd/SDOJavaPackage.xsd | 39 + .../main/resources/xsd/SimpleTypeWithAbstract.xml | 24 + .../main/resources/xsd/SimpleTypeWithAbstract.xsd | 40 + .../xsd/SimpleTypeWithExtendedInstanceClass.xml | 24 + .../xsd/SimpleTypeWithExtendedInstanceClass.xsd | 36 + .../resources/xsd/SimpleTypeWithInstanceClass.xml | 24 + .../resources/xsd/SimpleTypeWithInstanceClass.xsd | 37 + .../src/main/resources/xsd/SimpleTypeWithList.xml | 24 + .../src/main/resources/xsd/SimpleTypeWithList.xsd | 37 + .../src/main/resources/xsd/SimpleTypeWithName.xml | 24 + .../src/main/resources/xsd/SimpleTypeWithName.xsd | 36 + .../main/resources/xsd/SimpleTypeWithSDOName.xml | 24 + .../main/resources/xsd/SimpleTypeWithSDOName.xsd | 37 + .../src/main/resources/xsd/SimpleTypeWithUnion.xml | 25 + .../src/main/resources/xsd/SimpleTypeWithUnion.xsd | 46 + .../main/resources/xsd/SimpleTypeWithoutName.xml | 26 + .../main/resources/xsd/SimpleTypeWithoutName.xsd | 38 + .../src/main/resources/xsd/TargetNamespace.xml | 24 + .../src/main/resources/xsd/TargetNamespace.xsd | 34 + .../common/src/main/resources/xsd/datagraph.xsd | 88 ++ .../common/src/main/resources/xsd/sdoJava.xsd | 88 ++ .../common/src/main/resources/xsd/sdoModel.xsd | 221 +++ .../sca/itest/generate/GenerateTestCase.java | 49 + java/sca/contrib/itest/databindings/config.png | Bin 0 -> 31222 bytes java/sca/contrib/itest/databindings/config.svg | 117 ++ .../sca/contrib/itest/databindings/databinding.png | Bin 0 -> 14106 bytes .../sca/contrib/itest/databindings/databinding.svg | 242 ++++ java/sca/contrib/itest/databindings/interop.png | Bin 0 -> 23179 bytes java/sca/contrib/itest/databindings/interop.svg | 352 +++++ .../sca/contrib/itest/databindings/interop/pom.xml | 223 +++ .../generate/InteropDatabindingTestCase.java.vm | 113 ++ .../main/resources/generate/JAXBGreeter.wsdl.vm | 103 ++ .../src/main/resources/generate/SDOGreeter.wsdl.vm | 103 ++ .../src/main/resources/generate/generate.xml | 159 +++ .../resources/generate/interopgreeter.composite.vm | 78 ++ .../itest/databindings/jaxb-bottom-up/pom.xml | 239 ++++ .../itest/databindings/jaxb/AClientService.java | 29 + .../sca/itest/databindings/jaxb/AService.java | 32 + .../tuscany/sca/itest/databindings/jaxb/Bean1.java | 63 + .../sca/itest/databindings/jaxb/Bean10.java | 25 + .../sca/itest/databindings/jaxb/Bean11.java | 25 + .../tuscany/sca/itest/databindings/jaxb/Bean2.java | 56 + .../tuscany/sca/itest/databindings/jaxb/Bean3.java | 56 + .../sca/itest/databindings/jaxb/Bean31.java | 56 + .../databindings/jaxb/GenericsLocalService.java | 42 + .../itest/databindings/jaxb/GenericsService.java | 30 + .../databindings/jaxb/GenericsServiceClient.java | 43 + .../databindings/jaxb/HelloLocalServiceSimple.java | 37 + .../databindings/jaxb/HelloServiceSimple.java | 29 + .../jaxb/HelloServiceSimpleClient.java | 38 + .../databindings/jaxb/PrimitivesLocalService.java | 47 + .../itest/databindings/jaxb/PrimitivesService.java | 29 + .../databindings/jaxb/PrimitivesServiceClient.java | 48 + .../jaxb/StandardTypesLocalService.java | 78 ++ .../databindings/jaxb/StandardTypesService.java | 30 + .../jaxb/StandardTypesServiceClient.java | 79 ++ .../databindings/jaxb/impl/AClientServiceImpl.java | 38 + .../itest/databindings/jaxb/impl/AServiceImpl.java | 33 + .../jaxb/impl/GenericsLocalServiceClientImpl.java | 77 ++ .../jaxb/impl/GenericsServiceClientImpl.java | 40 + .../jaxb/impl/GenericsServiceImpl.java | 69 + .../jaxb/impl/GenericsTransformer.java | 125 ++ .../impl/HelloLocalServiceSimpleClientImpl.java | 73 + .../jaxb/impl/HelloServiceSimpleClientImpl.java | 38 + .../jaxb/impl/HelloServiceSimpleImpl.java | 86 ++ .../impl/PrimitivesLocalServiceClientImpl.java | 138 ++ .../jaxb/impl/PrimitivesServiceClientImpl.java | 38 + .../jaxb/impl/PrimitivesServiceImpl.java | 151 ++ .../impl/StandardTypesLocalServiceClientImpl.java | 157 +++ .../jaxb/impl/StandardTypesServiceClientImpl.java | 38 + .../jaxb/impl/StandardTypesServiceImpl.java | 208 +++ .../jaxb/impl/StandardTypesTransformer.java | 144 ++ .../src/main/resources/aservice.wsdl | 127 ++ .../src/main/resources/doclitbarewsdl.composite | 37 + .../src/main/resources/generics-service.composite | 69 + .../src/main/resources/helloservice.composite | 65 + .../src/main/resources/primitivesservice.composite | 66 + .../resources/standard-types-service.composite | 66 + .../databindings/jaxb/DatabindingTestCase.java | 339 +++++ .../databindings/jaxb/DocLitBareWsdlTestCase.java | 67 + .../jaxb/GenericsDatabindingTestCase.java | 484 +++++++ .../jaxb/PrimitivesDatabindingTestCase.java | 776 +++++++++++ .../jaxb/StandardTypesDatabindingTestCase.java | 1438 +++++++++++++++++++ .../itest/databindings/jaxb-top-down/pom.xml | 194 +++ .../sca/itest/databindings/jaxb/HelloService.java | 42 + .../databindings/jaxb/HelloServiceClient.java | 41 + .../itest/databindings/jaxb/PrimitivesService.java | 51 + .../databindings/jaxb/PrimitivesServiceClient.java | 50 + .../databindings/jaxb/StandardTypesService.java | 84 ++ .../jaxb/StandardTypesServiceClient.java | 81 ++ .../jaxb/impl/HelloServiceClientImpl.java | 73 + .../databindings/jaxb/impl/HelloServiceImpl.java | 86 ++ .../jaxb/impl/PrimitivesServiceClientImpl.java | 139 ++ .../jaxb/impl/PrimitivesServiceImpl.java | 151 ++ .../jaxb/impl/StandardTypesServiceClientImpl.java | 159 +++ .../jaxb/impl/StandardTypesServiceImpl.java | 207 +++ .../jaxb/impl/StandardTypesTransformer.java | 142 ++ .../main/resources/wsdl/wrapped/hello-service.wsdl | 371 +++++ .../resources/wsdl/wrapped/helloservice.composite | 80 ++ .../resources/wsdl/wrapped/primitives-service.wsdl | 927 +++++++++++++ .../wsdl/wrapped/primitivesservice.composite | 80 ++ .../wsdl/wrapped/standard-types-service.composite | 80 ++ .../wsdl/wrapped/standard-types-service.wsdl | 1155 ++++++++++++++++ .../jaxb/topdown/DatabindingTestCase.java | 349 +++++ .../topdown/PrimitivesDatabindingTestCase.java | 848 ++++++++++++ .../topdown/StandardTypesDatabindingTestCase.java | 1450 ++++++++++++++++++++ .../sca/contrib/itest/databindings/jaxbgen/pom.xml | 262 ++++ .../src/main/resources/generate/generate.xml | 172 +++ .../jaxbgen/src/main/resources/greeter.composite | 49 + java/sca/contrib/itest/databindings/pom.xml | 47 + java/sca/contrib/itest/databindings/readme.html | 157 +++ java/sca/contrib/itest/databindings/sdogen/pom.xml | 251 ++++ .../src/main/resources/generate/generate.xml | 170 +++ .../main/resources/generate/greeter.composite.vm | 56 + .../sca/contrib/itest/definitions-multiple/pom.xml | 51 + .../src/main/java/calculator/AddService.java | 34 + .../src/main/java/calculator/AddServiceImpl.java | 35 + .../main/java/calculator/CalculatorService.java | 35 + .../java/calculator/CalculatorServiceImpl.java | 75 + .../src/main/java/calculator/DivideService.java | 33 + .../main/java/calculator/DivideServiceImpl.java | 35 + .../src/main/java/calculator/MultiplyService.java | 28 + .../main/java/calculator/MultiplyServiceImpl.java | 35 + .../src/main/java/calculator/PolicyQNames.java | 43 + .../src/main/java/calculator/SubtractService.java | 28 + .../main/java/calculator/SubtractServiceImpl.java | 35 + .../contrib3/META-INF/sca-contribution.xml | 22 + .../src/main/resources/contrib3/definitions.xml | 37 + .../sca/itest/MultipleDefinitionsTestCase.java | 72 + .../java/org/apache/tuscany/sca/itest/Policy.java | 33 + .../tuscany/sca/itest/TestPolicyProcessor.java | 83 ++ ...ca.contribution.processor.StAXArtifactProcessor | 19 + .../test/resources/contrib1/Calculator.composite | 61 + .../contrib1/META-INF/sca-contribution.xml | 22 + .../src/test/resources/contrib1/definitions.xml | 33 + .../resources/contrib1/definitions/definitions.xml | 49 + .../src/test/resources/contrib2/definitions.xml | 32 + java/sca/contrib/itest/domain/pom.xml | 100 ++ .../src/main/java/calculator/AddService.java | 31 + .../src/main/java/calculator/AddServiceImpl.java | 31 + .../main/java/calculator/AddServiceUpdateImpl.java | 31 + .../main/java/calculator/CalculatorService.java | 38 + .../java/calculator/CalculatorServiceImpl.java | 74 + .../src/main/java/calculator/DivideService.java | 28 + .../main/java/calculator/DivideServiceImpl.java | 30 + .../src/main/java/calculator/MultiplyService.java | 28 + .../main/java/calculator/MultiplyServiceImpl.java | 30 + .../src/main/java/calculator/SubtractService.java | 31 + .../main/java/calculator/SubtractServiceImpl.java | 31 + .../resources/contributionA/Calculator.composite | 44 + .../contributionA/META-INF/sca-contribution.xml | 24 + .../META-INF/sca-deployables/Calculator.composite | 45 + .../META-INF/sca-deployables/Calculator.composite | 32 + .../contributionDependent/Calculator.composite | 36 + .../META-INF/sca-contribution.xml | 24 + .../contributionPrimary/Calculator.composite | 57 + .../META-INF/sca-contribution.xml | 25 + .../sca/itest/domain/ContributionSPIsTestCase.java | 279 ++++ .../itest/exceptions-cross-binding-ws/pom.xml | 243 ++++ .../test/exceptions/impl/StockExchangeJaxB.java | 71 + .../sca/test/exceptions/impl/StockTraderSDO.java | 39 + .../test/exceptions/impl/StockTraderSDOImpl.java | 136 ++ .../sdohandgen/InvalidSymbolSDOException.java | 84 ++ .../sdohandgen/MarketClosedSDOException.java | 76 + .../exceptions/sdohandgen/StockExceptionTest.java | 45 + .../src/main/resources/ExceptionTest.composite | 23 + .../src/main/resources/intracomposite.composite | 42 + .../main/resources/wsdl/StockExceptionTest.wsdl | 148 ++ .../src/main/resources/xsd/StockExceptionTest.xsd | 65 + .../test/exceptions/IntraCompositeTestCase.java | 102 ++ .../contrib/itest/exceptions-cross-binding/pom.xml | 234 ++++ .../exceptions/impl/StockExceptionTestJAXB.java | 31 + .../test/exceptions/impl/StockExchangeJaxB.java | 76 + .../sca/test/exceptions/impl/StockTraderSDO.java | 37 + .../test/exceptions/impl/StockTraderSDOImpl.java | 119 ++ .../sdohandgen/InvalidSymbolSDOException.java | 84 ++ .../sdohandgen/MarketClosedSDOException.java | 75 + .../exceptions/sdohandgen/StockExceptionTest.java | 45 + .../src/main/resources/ExceptionTest.composite | 25 + .../src/main/resources/intracomposite.composite | 35 + .../resources/wsdl.sdo/StockExceptionTest.wsdl | 141 ++ .../main/resources/wsdl/StockExceptionTest.wsdl | 148 ++ .../src/main/resources/xsd/StockExceptionTest.xsd | 65 + .../test/exceptions/IntraCompositeTestCase.java | 93 ++ .../sca/contrib/itest/exceptions-simple-ws/pom.xml | 59 + .../main/java/com/example/BusinessException.java | 43 + .../java/com/example/BusinessExceptionMinimal.java | 28 + .../src/main/java/com/example/ExampleClient.java | 23 + .../main/java/com/example/ExampleClientImpl.java | 44 + .../java/com/example/ExampleClientMinimalImpl.java | 54 + .../src/main/java/com/example/ExampleService.java | 27 + .../main/java/com/example/ExampleServiceImpl.java | 26 + .../java/com/example/ExampleServiceMinimal.java | 28 + .../com/example/ExampleServiceMinimalImpl.java | 30 + .../src/main/resources/example.composite | 56 + .../src/main/resources/wsdl/ExampleService.wsdl | 126 ++ .../java/com/example/ExampleMinimalTestCase.java | 44 + .../src/test/java/com/example/ExampleTestCase.java | 44 + java/sca/contrib/itest/extended-api/pom.xml | 51 + .../tuscany/sca/test/extended/BasicService.java | 26 + .../tuscany/sca/test/extended/MathService.java | 25 + .../sca/test/extended/impl/BasicServiceImpl.java | 45 + .../sca/test/extended/impl/MathServiceImpl.java | 31 + .../src/main/resources/BasicService.composite | 29 + .../src/main/resources/MathService.composite | 29 + .../sca/test/extended/ServiceLocateTestCase.java | 73 + java/sca/contrib/itest/interop-soap-client/pom.xml | 126 ++ .../LoopbackInteropDocServiceComponentImpl.java | 46 + .../src/main/resources/default.composite | 35 + .../src/main/resources/wsdl/interopdoc.wsdl | 195 +++ .../interop/client/InteropDocClientTestCase.java | 144 ++ .../itest/interop-soap-round2-client/pom.xml | 124 ++ .../test/interop/client/InteropTestDocLit.java | 44 + .../src/main/resources/default.composite | 38 + .../src/main/resources/wsdl/interoptestdoclit.wsdl | 155 +++ .../interop/client/InteropTestDocLitTestCase.java | 133 ++ .../sca/contrib/itest/interop-soap-service/pom.xml | 134 ++ .../server/InteropDocServiceComponentImpl.java | 47 + .../src/main/resources/wsdl/interopdoc.wsdl | 180 +++ .../src/main/webapp/META-INF/sca/default.scdl | 42 + .../src/main/webapp/WEB-INF/web.xml | 51 + java/sca/contrib/itest/interop-soap-service/t.bat | 34 + java/sca/contrib/itest/jms-args/pom.xml | 92 ++ .../apache/tuscany/sca/binding/jms/ClientImpl.java | 41 + .../apache/tuscany/sca/binding/jms/MyService.java | 29 + .../tuscany/sca/binding/jms/ServiceImpl.java | 38 + .../jms-args/src/main/resources/jndi.properties | 38 + .../main/resources/selectors/selectors.composite | 39 + .../tuscany/sca/binding/jms/ArgsTestCase.java | 61 + java/sca/contrib/itest/jms-callbacks/pom.xml | 94 ++ .../apache/tuscany/sca/binding/jms/JMSClient.java | 28 + .../tuscany/sca/binding/jms/JMSClientImpl.java | 50 + .../apache/tuscany/sca/binding/jms/JMSService.java | 34 + .../sca/binding/jms/JMSServiceCallback.java | 32 + .../tuscany/sca/binding/jms/JMSServiceImpl.java | 47 + .../src/main/resources/jndi.properties | 39 + .../src/main/resources/simple/client.composite | 44 + .../src/main/resources/simple/tempq.composite | 50 + .../tuscany/sca/binding/jms/CallbackTestCase.java | 60 + .../sca/binding/jms/TempCallbackQTestCase.java | 63 + java/sca/contrib/itest/jms-definitions/pom.xml | 93 ++ .../tuscany/sca/binding/jms/OneWayClientImpl.java | 41 + .../tuscany/sca/binding/jms/OneWayService.java | 29 + .../tuscany/sca/binding/jms/OneWayServiceImpl.java | 34 + .../src/main/resources/definitions.xml | 29 + .../resources/definitions/definitions.composite | 39 + .../src/main/resources/jndi.properties | 38 + .../sca/binding/jms/DefinitionsTestCase.java | 61 + java/sca/contrib/itest/jms-format/pom.xml | 97 ++ .../jmsbytes/helloworld/HelloWorldReference.java | 32 + .../helloworld/HelloWorldReferenceImpl.java | 35 + .../jmsbytes/helloworld/HelloWorldService.java | 33 + .../jmsbytes/helloworld/HelloWorldServiceImpl.java | 33 + .../helloworld/HelloWorldReference.java | 33 + .../helloworld/HelloWorldReferenceImpl.java | 42 + .../jmsdelimited/helloworld/HelloWorldService.java | 35 + .../helloworld/HelloWorldServiceImpl.java | 36 + .../jmsmessage/helloworld/HelloWorldReference.java | 32 + .../helloworld/HelloWorldReferenceImpl.java | 41 + .../jmsmessage/helloworld/HelloWorldService.java | 34 + .../helloworld/HelloWorldServiceImpl.java | 51 + .../helloworld/HelloWorldServiceReferenceSide.java | 37 + .../jms/format/jmsmessage/helloworld/README | 3 + .../helloworld/HelloWorldReferenceImpl.java | 47 + .../jmstextxml/helloworld/HelloWorldService.java | 33 + .../helloworld/HelloWorldServiceImpl.java | 35 + .../jms/format/jmstextxml/helloworld/Person.java | 44 + .../main/resources/jmsbytes/helloworld.composite | 45 + .../resources/jmsdelimited/helloworld.composite | 44 + .../main/resources/jmsdelimited/helloworld.wsdl | 129 ++ .../main/resources/jmsmessage/helloworld.composite | 44 + .../src/main/resources/jmsmessage/helloworld.wsdl | 129 ++ .../main/resources/jmstextxml/helloworld.composite | 76 + .../src/main/resources/jmstextxml/helloworld.wsdl | 139 ++ .../src/main/resources/jmstextxml/messages.xml | 19 + .../jms-format/src/main/resources/jndi.properties | 39 + .../binding/jms/format/FormatJMSBytesTestCase.java | 64 + .../jms/format/FormatJMSDelimitedTestCase.java | 66 + .../jms/format/FormatJMSMessageTestCase.java | 64 + .../jms/format/FormatJMSTextXMLTestCase.java | 68 + java/sca/contrib/itest/jms-selectors/pom.xml | 93 ++ .../apache/tuscany/sca/binding/jms/ClientImpl.java | 41 + .../tuscany/sca/binding/jms/SelectorService.java | 29 + .../sca/binding/jms/SelectorServiceImpl1.java | 40 + .../sca/binding/jms/SelectorServiceImpl2.java | 38 + .../sca/binding/jms/SelectorServiceImpl3.java | 38 + .../src/main/resources/jndi.properties | 38 + .../main/resources/selectors/selectors.composite | 68 + .../tuscany/sca/binding/jms/SelectorsTestCase.java | 75 + java/sca/contrib/itest/jms/pom.xml | 97 ++ .../tuscany/sca/binding/jms/CheckedExcpetion.java | 28 + .../tuscany/sca/binding/jms/ExceptionService.java | 30 + .../sca/binding/jms/ExceptionServiceClient.java | 45 + .../sca/binding/jms/ExceptionServiceImpl.java | 32 + .../sca/binding/jms/HelloWorldClientImpl.java | 41 + .../tuscany/sca/binding/jms/HelloWorldService.java | 26 + .../sca/binding/jms/HelloWorldServiceImpl.java | 30 + .../apache/tuscany/sca/binding/jms/JMSClient.java | 28 + .../apache/tuscany/sca/binding/jms/MsgClient.java | 29 + .../tuscany/sca/binding/jms/MsgClientImpl.java | 38 + .../tuscany/sca/binding/jms/MsgClientService.java | 33 + .../apache/tuscany/sca/binding/jms/MsgService.java | 32 + .../tuscany/sca/binding/jms/MsgServiceImpl.java | 39 + .../tuscany/sca/binding/jms/OneWayClientImpl.java | 41 + .../sca/binding/jms/OneWayObjectService.java | 29 + .../sca/binding/jms/OneWayObjectServiceImpl.java | 34 + .../tuscany/sca/binding/jms/OneWayService.java | 29 + .../tuscany/sca/binding/jms/OneWayServiceImpl.java | 34 + .../sca/binding/jms/TestMessageProcessor.java | 57 + .../src/main/resources/defaults/client.composite | 33 + .../src/main/resources/defaults/service.composite | 30 + .../src/main/resources/dynamic/client.composite | 36 + .../src/main/resources/exceptions/client.composite | 33 + .../main/resources/exceptions/service.composite | 30 + .../src/main/resources/external/client.composite | 38 + .../src/main/resources/external/service.composite | 35 + .../itest/jms/src/main/resources/jndi.properties | 39 + .../main/resources/nonSCAclient/service.composite | 50 + .../main/resources/oneway/OneWayClient.composite | 35 + .../main/resources/oneway/OneWayService.composite | 32 + .../main/resources/policyHeaders/definitions.xml | 54 + .../policyHeaders/policyHeaders.composite | 46 + .../main/resources/properties/properties.composite | 55 + .../jms/src/main/resources/simple/client.composite | 38 + .../src/main/resources/simple/mpclient.composite | 38 + .../src/main/resources/simple/service.composite | 35 + .../src/main/resources/simple/uriclient.composite | 33 + .../tuscany/sca/binding/jms/DefaultsTestCase.java | 54 + .../sca/binding/jms/DynamicReplyQTestCase.java | 53 + .../sca/binding/jms/ExceptionsTestCase.java | 72 + .../sca/binding/jms/ExternalBrokerTestCase.java | 70 + .../sca/binding/jms/MessageProcessorTestCase.java | 58 + .../sca/binding/jms/NonSCAClientTestCase.java | 142 ++ .../tuscany/sca/binding/jms/OneWayTestCase.java | 58 + .../sca/binding/jms/PolicyHeadersTestCase.java | 97 ++ .../sca/binding/jms/PropertiesTestCase.java | 92 ++ .../tuscany/sca/binding/jms/RPCTestCase.java | 54 + .../tuscany/sca/binding/jms/URIRPCTestCase.java | 54 + java/sca/contrib/itest/large-sdo-ws/pom.xml | 141 ++ .../tuscany/sca/itest/trninq/TrnInqClient.java | 43 + .../tuscany/sca/itest/trninq/TrnInqService.java | 112 ++ .../tuscany/sca/itest/trninq/TrninqInterface.java | 38 + .../main/resources/META-INF/sca-contribution.xml | 23 + .../src/main/resources/trnInq.composite | 39 + .../src/main/resources/wsdl/IFX170_XSD.xsd | 146 ++ .../src/main/resources/wsdl/trninq.wsdl | 57 + .../test/java/trninq/TrnInqServiceTestCase.java | 87 ++ .../itest/late-reference-resolution/pom.xml | 126 ++ .../src/main/java/calculator/AddService.java | 31 + .../src/main/java/calculator/AddServiceImpl.java | 31 + .../main/java/calculator/CalculatorService.java | 35 + .../java/calculator/CalculatorServiceImpl.java | 74 + .../src/main/java/calculator/DivideService.java | 28 + .../main/java/calculator/DivideServiceImpl.java | 30 + .../src/main/java/calculator/MultiplyService.java | 28 + .../main/java/calculator/MultiplyServiceImpl.java | 30 + .../src/main/java/calculator/SubtractService.java | 31 + .../main/java/calculator/SubtractServiceImpl.java | 31 + ...ny.sca.endpointresolver.EndpointResolverFactory | 19 + .../src/main/resources/nodeA/Calculator.composite | 41 + .../resources/nodeA/META-INF/sca-contribution.xml | 24 + .../src/main/resources/nodeB/Calculator.composite | 32 + .../resources/nodeB/META-INF/sca-contribution.xml | 24 + .../src/main/resources/nodeC/Calculator.composite | 32 + .../resources/nodeC/META-INF/sca-contribution.xml | 24 + .../sca/BindingScaEndpointResolverFactoryImpl.java | 50 + .../sca/BindingScaEndpointResolverImpl.java | 72 + .../LateReferenceResolutionTestCase.java | 97 ++ .../src/test/java/calculator/TestRegistryImpl.java | 40 + java/sca/contrib/itest/oneway/build.xml | 127 ++ java/sca/contrib/itest/oneway/pom.xml | 59 + .../tuscany/sca/itest/oneway/OneWayClient.java | 40 + .../tuscany/sca/itest/oneway/OneWayService.java | 45 + .../sca/itest/oneway/impl/OneWayClientImpl.java | 63 + .../sca/itest/oneway/impl/OneWayServiceImpl.java | 67 + .../META-INF/sca-deployables/oneWay.composite | 58 + .../tuscany/sca/itest/oneway/OneWayTestCase.java | 235 ++++ .../contribution-classes-v2/build-bundles.xml | 39 + .../contribution-classes-v2/pom.xml | 211 +++ .../src/main/java/supplychain/OSGiBundleImpl.java | 121 ++ .../main/java/supplychain/customer/Customer.java | 33 + .../customer/JavaCustomerComponentImpl.java | 55 + .../customer/OSGiCustomerComponentImpl.java | 51 + .../supplychain/customer/OSGiCustomerImpl.java | 47 + .../retailer/JavaRetailerComponentImpl.java | 57 + .../retailer/OSGiRetailerComponentImpl.java | 46 + .../supplychain/retailer/OSGiRetailerImpl.java | 44 + .../main/java/supplychain/retailer/Retailer.java | 28 + .../shipper/JavaShipperComponentImpl.java | 52 + .../shipper/OSGiShipperComponentImpl.java | 45 + .../java/supplychain/shipper/OSGiShipperImpl.java | 42 + .../src/main/java/supplychain/shipper/Shipper.java | 28 + .../warehouse/JavaWarehouseComponentImpl.java | 51 + .../warehouse/OSGiWarehouseComponentImpl.java | 47 + .../supplychain/warehouse/OSGiWarehouseImpl.java | 44 + .../main/java/supplychain/warehouse/Warehouse.java | 28 + .../src/main/resources/Customer2V2.componentType | 28 + .../src/main/resources/CustomerV2.componentType | 28 + .../META-INF/customer-sca-contribution.xml | 32 + .../META-INF/retailer-sca-contribution.xml | 29 + .../META-INF/shipper-sca-contribution.xml | 27 + .../META-INF/supplychain-sca-contribution.xml | 24 + .../META-INF/warehouse-sca-contribution.xml | 28 + .../src/main/resources/RetailerV2.componentType | 28 + .../src/main/resources/ShipperV2.componentType | 28 + .../src/main/resources/WarehouseV2.componentType | 28 + .../src/main/resources/osgi/Customer.mf | 13 + .../src/main/resources/osgi/Customer2.mf | 13 + .../src/main/resources/osgi/Retailer.mf | 10 + .../src/main/resources/osgi/RetailerJar.mf | 1 + .../src/main/resources/osgi/Shipper.mf | 10 + .../src/main/resources/osgi/SupplyChain.mf | 13 + .../src/main/resources/osgi/Warehouse.mf | 10 + .../src/main/resources/supplychain.composite | 67 + .../contribution-classes/build-bundles.xml | 39 + .../osgi-contribution/contribution-classes/pom.xml | 212 +++ .../src/main/java/supplychain/OSGiBundleImpl.java | 121 ++ .../main/java/supplychain/customer/Customer.java | 33 + .../customer/JavaCustomerComponentImpl.java | 55 + .../customer/OSGiCustomerComponentImpl.java | 51 + .../supplychain/customer/OSGiCustomerImpl.java | 47 + .../retailer/JavaRetailerComponentImpl.java | 57 + .../retailer/OSGiRetailerComponentImpl.java | 46 + .../supplychain/retailer/OSGiRetailerImpl.java | 44 + .../main/java/supplychain/retailer/Retailer.java | 28 + .../shipper/JavaShipperComponentImpl.java | 52 + .../shipper/OSGiShipperComponentImpl.java | 45 + .../java/supplychain/shipper/OSGiShipperImpl.java | 42 + .../src/main/java/supplychain/shipper/Shipper.java | 28 + .../warehouse/JavaWarehouseComponentImpl.java | 51 + .../warehouse/OSGiWarehouseComponentImpl.java | 47 + .../supplychain/warehouse/OSGiWarehouseImpl.java | 44 + .../main/java/supplychain/warehouse/Warehouse.java | 28 + .../src/main/resources/Customer2V1.componentType | 28 + .../src/main/resources/CustomerV1.componentType | 28 + .../META-INF/customer-sca-contribution.xml | 30 + .../META-INF/retailer-sca-contribution.xml | 26 + .../META-INF/shipper-sca-contribution.xml | 26 + .../META-INF/supplychain-sca-contribution.xml | 24 + .../META-INF/warehouse-sca-contribution.xml | 26 + .../src/main/resources/RetailerV1.componentType | 28 + .../src/main/resources/ShipperV1.componentType | 28 + .../src/main/resources/WarehouseV1.componentType | 28 + .../src/main/resources/osgi/Customer.mf | 13 + .../src/main/resources/osgi/Customer2.mf | 13 + .../src/main/resources/osgi/Retailer.mf | 10 + .../src/main/resources/osgi/RetailerJar.mf | 1 + .../src/main/resources/osgi/Shipper.mf | 10 + .../src/main/resources/osgi/SupplyChain.mf | 13 + .../src/main/resources/osgi/Warehouse.mf | 10 + .../src/main/resources/supplychain.composite | 66 + .../osgi-contribution/contribution-test/pom.xml | 92 ++ .../sca/contribution/osgi/OSGiTestUtil.java | 73 + .../osgi/test/MixedContributionTestCase.java | 43 + .../osgi/test/NestedBundleTestCase.java | 182 +++ .../osgi/test/OSGiResolverTestCase.java | 257 ++++ .../osgi/test/SCAResolverTestCase.java | 240 ++++ .../resources/osgi/felix/felix.config.properties | 44 + java/sca/contrib/itest/osgi-contribution/pom.xml | 52 + .../itest/osgi-implementation/build-bundles.xml | 48 + java/sca/contrib/itest/osgi-implementation/pom.xml | 1220 ++++++++++++++++ .../java/callback/client/CallbackCallback.java | 33 + .../main/java/callback/client/CallbackClient.java | 31 + .../callback/client/JavaCallbackClientImpl.java | 141 ++ .../callback/client/OSGiCallbackClientImpl.java | 181 +++ .../java/callback/service/CallbackService.java | 39 + .../callback/service/JavaCallbackServiceImpl.java | 68 + .../callback/service/OSGiCallbackServiceImpl.java | 95 ++ .../client/ConversationalCallback.java | 50 + .../conversation/client/ConversationalClient.java | 51 + .../client/ConversationalClientActivator.java | 105 ++ .../client/ConversationalClientServiceFactory.java | 135 ++ .../client/ConversationalClientStatefulImpl.java | 254 ++++ .../client/ConversationalClientStatelessImpl.java | 253 ++++ .../ConversationalReferenceClient.java | 38 + .../ConversationalReferenceClientActivator.java | 66 + .../ConversationalReferenceClientImpl.java | 45 + .../service/ConversationalService.java | 65 + .../service/ConversationalServiceActivator.java | 76 + .../service/ConversationalServiceFactory.java | 52 + .../service/ConversationalServiceStatefulImpl.java | 121 ++ .../ConversationalServiceStatelessImpl.java | 127 ++ .../src/main/java/helloworld/Greetings.java | 36 + .../src/main/java/helloworld/HelloWorld.java | 29 + .../java/helloworld/JavaGreetingsComponent.java | 73 + .../java/helloworld/JavaHelloWorldComponent.java | 41 + .../main/java/helloworld/OSGiGreetingsImpl.java | 112 ++ .../main/java/helloworld/OSGiHelloWorldImpl.java | 81 ++ .../java/helloworld/sdo/HelloWorldService.java | 30 + .../helloworld/sdo/HelloWorldServiceComponent.java | 33 + .../helloworld/sdo/client/HelloWorldClient.java | 30 + .../sdo/client/HelloWorldClientComponent.java | 50 + .../src/main/java/helloworld/ws/HelloWorld.java | 29 + .../main/java/helloworld/ws/HelloWorldService.java | 28 + .../stockquote/OSGiStockQuoteComponentImpl.java | 86 ++ .../java/stockquote/OSGiStockQuoteFactoryImpl.java | 65 + .../main/java/stockquote/OSGiStockQuoteImpl.java | 119 ++ .../src/main/java/stockquote/StockQuote.java | 31 + .../src/main/java/supplychain/OSGiBundleImpl.java | 163 +++ .../main/java/supplychain/customer/Customer.java | 39 + .../customer/JavaCustomerComponentImpl.java | 88 ++ .../customer/OSGiCustomerComponentImpl.java | 106 ++ .../customer/OSGiCustomerFactoryImpl.java | 65 + .../supplychain/customer/OSGiCustomerImpl.java | 92 ++ .../OSGiCustomerWithQueryComponentImpl.java | 100 ++ .../customer/OSGiCustomerWithQueryImpl.java | 82 ++ .../OSGiStatelessCustomerComponentImpl.java | 30 + .../customer/OSGiStatelessCustomerImpl.java | 35 + .../customer/OSGiVersionedCustomerImpl.java | 98 ++ .../retailer/JavaRetailerComponentImpl.java | 67 + .../retailer/OSGiRetailerComponentImpl.java | 64 + .../supplychain/retailer/OSGiRetailerImpl.java | 58 + .../retailer/OSGiRetailerServiceImpl.java | 45 + .../OSGiRetailerWithQueryComponentImpl.java | 78 ++ .../retailer/OSGiRetailerWithQueryImpl.java | 64 + .../retailer/OSGiVersionedRetailerImpl.java | 75 + .../retailer/OSGiVersionedRetailerServiceImpl.java | 47 + .../main/java/supplychain/retailer/Retailer.java | 28 + .../java/supplychain/retailer/RetailerQuery.java | 28 + .../shipper/JavaShipperComponentImpl.java | 58 + .../shipper/OSGiShipperComponentImpl.java | 62 + .../shipper/OSGiShipperFactoryImpl.java | 78 ++ .../java/supplychain/shipper/OSGiShipperImpl.java | 57 + .../shipper/OSGiShipperServiceImpl.java | 43 + .../shipper/OSGiStatelessShipperComponentImpl.java | 30 + .../shipper/OSGiStatelessShipperServiceImpl.java | 35 + .../shipper/OSGiVersionedShipperImpl.java | 78 ++ .../shipper/OSGiVersionedShipperServiceImpl.java | 46 + .../src/main/java/supplychain/shipper/Shipper.java | 28 + .../warehouse/JavaWarehouseComponentImpl.java | 48 + .../JavaWarehouseWithQueryComponentImpl.java | 52 + .../warehouse/OSGiWarehouseComponentImpl.java | 57 + .../supplychain/warehouse/OSGiWarehouseImpl.java | 68 + .../warehouse/OSGiWarehouseServiceImpl.java | 62 + .../main/java/supplychain/warehouse/Warehouse.java | 28 + .../java/supplychain/warehouse/WarehouseQuery.java | 28 + .../callback/CallbackClient.componentType | 31 + .../callback/CallbackService.componentType | 27 + .../resources/callback/callback-test1.composite | 39 + .../resources/callback/callback-test2.composite | 41 + .../resources/callback/callback-test3.composite | 38 + .../ConversationalClient.componentType | 37 + .../ConversationalReferenceClient.componentType | 28 + .../ConversationalService.componentType | 29 + .../conversation/conversation-test.composite | 162 +++ .../main/resources/factory/Customer.componentType | 34 + .../main/resources/factory/Retailer.componentType | 29 + .../main/resources/factory/Shipper.componentType | 29 + .../main/resources/factory/Warehouse.componentType | 28 + .../resources/factory/ds/Customer.componentType | 34 + .../resources/factory/ds/Retailer.componentType | 29 + .../resources/factory/ds/Shipper.componentType | 29 + .../resources/factory/ds/Warehouse.componentType | 28 + .../resources/factory/ds/factory-ds-test.composite | 130 ++ .../main/resources/factory/factory-test.composite | 116 ++ .../resources/helloworld/Greetings.componentType | 30 + .../resources/helloworld/HelloWorld.componentType | 31 + .../resources/interfaces/Customer.componentType | 31 + .../resources/interfaces/Retailer.componentType | 35 + .../resources/interfaces/Shipper.componentType | 29 + .../resources/interfaces/Warehouse.componentType | 31 + .../resources/interfaces/ds/Customer.componentType | 31 + .../resources/interfaces/ds/Retailer.componentType | 35 + .../resources/interfaces/ds/Shipper.componentType | 29 + .../interfaces/ds/Warehouse.componentType | 31 + .../interfaces/ds/interfaces-ds-test.composite | 57 + .../resources/interfaces/interfaces-test.composite | 57 + .../main/resources/osgi/callback/CallbackClient.mf | 10 + .../resources/osgi/callback/CallbackService.mf | 10 + .../osgi/conversation/ConversationalClient.mf | 11 + .../conversation/ConversationalReferenceClient.mf | 11 + .../osgi/conversation/ConversationalService.mf | 11 + .../src/main/resources/osgi/factory/Customer.mf | 11 + .../src/main/resources/osgi/factory/Retailer.mf | 10 + .../src/main/resources/osgi/factory/Shipper.mf | 10 + .../src/main/resources/osgi/factory/ds/Customer.mf | 10 + .../main/resources/osgi/factory/ds/Customer.xml | 41 + .../src/main/resources/osgi/factory/ds/Retailer.mf | 11 + .../main/resources/osgi/factory/ds/Retailer1.xml | 32 + .../main/resources/osgi/factory/ds/Retailer2.xml | 32 + .../src/main/resources/osgi/factory/ds/Shipper.mf | 10 + .../main/resources/osgi/factory/ds/Shipper1.xml | 34 + .../main/resources/osgi/factory/ds/Shipper2.xml | 34 + .../main/resources/osgi/factory/ds/Warehouse.mf | 11 + .../main/resources/osgi/factory/ds/Warehouse.xml | 32 + .../src/main/resources/osgi/interfaces/Customer.mf | 11 + .../src/main/resources/osgi/interfaces/Retailer.mf | 10 + .../src/main/resources/osgi/interfaces/Shipper.mf | 10 + .../main/resources/osgi/interfaces/ds/Customer.mf | 10 + .../main/resources/osgi/interfaces/ds/Customer.xml | 43 + .../main/resources/osgi/interfaces/ds/Retailer.mf | 11 + .../main/resources/osgi/interfaces/ds/Retailer.xml | 39 + .../main/resources/osgi/interfaces/ds/Shipper.mf | 10 + .../main/resources/osgi/interfaces/ds/Shipper.xml | 34 + .../src/main/resources/osgi/passbyref/Greetings.mf | 11 + .../osgi/properties/ManagedStockQuoteFactory.mf | 11 + .../main/resources/osgi/properties/StockQuote.mf | 10 + .../resources/osgi/properties/StockQuoteFactory.mf | 11 + .../resources/osgi/properties/ds/StockQuote.mf | 12 + .../resources/osgi/properties/ds/StockQuote.xml | 27 + .../osgi/properties/ds/StockQuoteFactory.mf | 12 + .../osgi/properties/ds/StockQuoteFactory.xml | 27 + .../main/resources/osgi/sdo/ds/HelloWorldClient.mf | 14 + .../resources/osgi/sdo/ds/HelloWorldClient.xml | 33 + .../resources/osgi/sdo/ds/HelloWorldService.mf | 13 + .../resources/osgi/sdo/ds/HelloWorldService.xml | 25 + .../src/main/resources/osgi/services/Customer.mf | 11 + .../src/main/resources/osgi/services/Retailer.mf | 10 + .../src/main/resources/osgi/services/Shipper.mf | 10 + .../src/main/resources/osgi/services/Warehouse.mf | 10 + .../main/resources/osgi/services/ds/Customer.mf | 10 + .../main/resources/osgi/services/ds/Customer.xml | 41 + .../main/resources/osgi/services/ds/Retailer.mf | 11 + .../main/resources/osgi/services/ds/Retailer1.xml | 32 + .../main/resources/osgi/services/ds/Retailer2.xml | 32 + .../src/main/resources/osgi/services/ds/Shipper.mf | 10 + .../main/resources/osgi/services/ds/Shipper1.xml | 34 + .../main/resources/osgi/services/ds/Shipper2.xml | 34 + .../main/resources/osgi/services/ds/Warehouse.mf | 11 + .../main/resources/osgi/services/ds/Warehouse1.xml | 32 + .../main/resources/osgi/services/ds/Warehouse2.xml | 32 + .../src/main/resources/osgi/version/Customer1.mf | 11 + .../src/main/resources/osgi/version/Customer2.mf | 11 + .../src/main/resources/osgi/version/Retailer1.mf | 10 + .../src/main/resources/osgi/version/Retailer2.mf | 10 + .../src/main/resources/osgi/version/Shipper1.mf | 10 + .../src/main/resources/osgi/version/Shipper2.mf | 10 + .../src/main/resources/osgi/version/Warehouse1.mf | 10 + .../src/main/resources/osgi/version/Warehouse2.mf | 10 + .../main/resources/osgi/version/ds/Customer1.mf | 10 + .../main/resources/osgi/version/ds/Customer2.mf | 10 + .../main/resources/osgi/version/ds/CustomerV1.xml | 41 + .../main/resources/osgi/version/ds/CustomerV2.xml | 41 + .../main/resources/osgi/version/ds/Retailer1.mf | 11 + .../main/resources/osgi/version/ds/Retailer1V1.xml | 34 + .../main/resources/osgi/version/ds/Retailer1V2.xml | 34 + .../main/resources/osgi/version/ds/Retailer2.mf | 11 + .../main/resources/osgi/version/ds/Retailer2V1.xml | 33 + .../main/resources/osgi/version/ds/Retailer2V2.xml | 33 + .../src/main/resources/osgi/version/ds/Shipper1.mf | 10 + .../main/resources/osgi/version/ds/Shipper1V1.xml | 35 + .../main/resources/osgi/version/ds/Shipper1V2.xml | 35 + .../src/main/resources/osgi/version/ds/Shipper2.mf | 10 + .../main/resources/osgi/version/ds/Shipper2V1.xml | 35 + .../main/resources/osgi/version/ds/Shipper2V2.xml | 35 + .../main/resources/osgi/version/ds/Warehouse1.mf | 11 + .../resources/osgi/version/ds/Warehouse1V1.xml | 32 + .../resources/osgi/version/ds/Warehouse1V2.xml | 32 + .../main/resources/osgi/version/ds/Warehouse2.mf | 11 + .../resources/osgi/version/ds/Warehouse2V1.xml | 32 + .../resources/osgi/version/ds/Warehouse2V2.xml | 32 + .../src/main/resources/osgi/wiring/Customer.mf | 11 + .../src/main/resources/osgi/wiring/Retailer.mf | 10 + .../src/main/resources/osgi/wiring/Shipper.mf | 10 + .../src/main/resources/osgi/wiring/Warehouse.mf | 10 + .../src/main/resources/osgi/wiring/ds/Customer.mf | 10 + .../src/main/resources/osgi/wiring/ds/Customer.xml | 41 + .../src/main/resources/osgi/wiring/ds/Retailer.mf | 11 + .../main/resources/osgi/wiring/ds/Retailer1.xml | 33 + .../main/resources/osgi/wiring/ds/Retailer2.xml | 33 + .../src/main/resources/osgi/wiring/ds/Shipper.mf | 10 + .../src/main/resources/osgi/wiring/ds/Shipper1.xml | 35 + .../src/main/resources/osgi/wiring/ds/Shipper2.xml | 34 + .../src/main/resources/osgi/wiring/ds/Warehouse.mf | 11 + .../main/resources/osgi/wiring/ds/Warehouse1.xml | 33 + .../main/resources/osgi/wiring/ds/Warehouse2.xml | 33 + .../src/main/resources/osgi/ws/HelloWorld.mf | 12 + .../resources/passbyref/Greetings.componentType | 30 + .../resources/passbyref/passbyref-test.composite | 39 + .../resources/properties/StockQuote.componentType | 28 + .../properties/StockQuoteFactory.componentType | 28 + .../properties/ds/StockQuote.componentType | 28 + .../properties/ds/StockQuoteFactory.componentType | 28 + .../properties/ds/properties-ds-test.composite | 39 + .../properties/ds/properties2-ds-test.composite | 54 + .../resources/properties/properties-test.composite | 39 + .../properties/properties2-test.composite | 50 + .../sdo/ds/HelloWorldClient.componentType | 30 + .../sdo/ds/HelloWorldService.componentType | 25 + .../resources/sdo/ds/META-INF/sca-contribution.xml | 26 + .../src/main/resources/sdo/ds/helloworld.wsdl | 88 ++ .../main/resources/sdo/ds/helloworldsdo.composite | 47 + .../main/resources/services/Customer.componentType | 34 + .../main/resources/services/Retailer.componentType | 33 + .../main/resources/services/Shipper.componentType | 30 + .../resources/services/Warehouse.componentType | 28 + .../resources/services/ds/Customer.componentType | 34 + .../resources/services/ds/Retailer.componentType | 33 + .../resources/services/ds/Shipper.componentType | 30 + .../resources/services/ds/Warehouse.componentType | 28 + .../services/ds/services-ds-test.composite | 90 ++ .../resources/services/services-test.composite | 89 ++ .../resources/stockquote/StockQuote.componentType | 28 + .../main/resources/version/Customer1.componentType | 34 + .../main/resources/version/Customer2.componentType | 34 + .../main/resources/version/Retailer1.componentType | 33 + .../main/resources/version/Retailer2.componentType | 33 + .../main/resources/version/Shipper1.componentType | 30 + .../main/resources/version/Shipper2.componentType | 30 + .../resources/version/Warehouse1.componentType | 28 + .../resources/version/Warehouse2.componentType | 28 + .../resources/version/ds/Customer1.componentType | 34 + .../resources/version/ds/Customer2.componentType | 34 + .../resources/version/ds/Retailer1.componentType | 33 + .../resources/version/ds/Retailer2.componentType | 33 + .../resources/version/ds/Shipper1.componentType | 30 + .../resources/version/ds/Shipper2.componentType | 30 + .../resources/version/ds/Warehouse1.componentType | 28 + .../resources/version/ds/Warehouse2.componentType | 28 + .../resources/version/ds/version-ds-test.composite | 184 +++ .../main/resources/version/version-test.composite | 170 +++ .../main/resources/wiring/Customer.componentType | 34 + .../main/resources/wiring/Retailer.componentType | 29 + .../main/resources/wiring/Shipper.componentType | 29 + .../main/resources/wiring/Warehouse.componentType | 28 + .../resources/wiring/ds/Customer.componentType | 34 + .../resources/wiring/ds/Retailer.componentType | 29 + .../main/resources/wiring/ds/Shipper.componentType | 29 + .../resources/wiring/ds/Warehouse.componentType | 28 + .../resources/wiring/ds/wiring-ds-test1.composite | 136 ++ .../resources/wiring/ds/wiring-ds-test2.composite | 151 ++ .../main/resources/wiring/wiring-test1.composite | 127 ++ .../main/resources/wiring/wiring-test2.composite | 151 ++ .../src/main/resources/ws/HelloWorld.componentType | 31 + .../src/main/resources/ws/helloworld.wsdl | 80 ++ .../src/main/resources/ws/ws-helloworld.composite | 51 + .../src/test/java/callback/Callback1TestCase.java | 30 + .../src/test/java/callback/Callback2TestCase.java | 29 + .../src/test/java/callback/Callback3TestCase.java | 29 + .../src/test/java/callback/CallbackTestCase.java | 50 + .../java/conversation/ConversationTestCase.java | 325 +++++ .../helloworld/passbyref/PassByRefTestCase.java | 130 ++ .../src/test/java/helloworld/sdo/SdoTestCase.java | 95 ++ .../java/helloworld/ws/HelloWorldTestCase.java | 55 + .../test/java/supplychain/SupplyChainTestCase.java | 63 + .../supplychain/VersionedSupplyChainTestCase.java | 71 + .../supplychain/factory/DSFactoryTestCase.java | 32 + .../java/supplychain/factory/FactoryTestCase.java | 72 + .../interfaces/DSInterfacesTestCase.java | 32 + .../supplychain/interfaces/InterfacesTestCase.java | 32 + .../properties/DSProperties2TestCase.java | 31 + .../properties/DSPropertiesTestCase.java | 31 + .../properties/Properties2TestCase.java | 69 + .../supplychain/properties/PropertiesTestCase.java | 58 + .../supplychain/services/DSServicesTestCase.java | 32 + .../supplychain/services/ServicesTestCase.java | 32 + .../supplychain/version/DSVersionTestCase.java | 33 + .../java/supplychain/version/VersionTestCase.java | 33 + .../java/supplychain/wiring/DSWiring1TestCase.java | 33 + .../java/supplychain/wiring/DSWiring2TestCase.java | 33 + .../java/supplychain/wiring/Wiring1TestCase.java | 32 + .../java/supplychain/wiring/Wiring2TestCase.java | 32 + .../src/test/java/test/OSGiTestCase.java | 67 + .../src/test/java/util/OSGiTestUtil.java | 71 + .../resources/osgi/felix/felix.config.properties | 45 + .../itest/osgi-tuscany/osgi-tuscany-test/pom.xml | 99 ++ .../test/osgi/runtime/impl/EquinoxTestRuntime.java | 92 ++ .../test/osgi/runtime/impl/FelixTestRuntime.java | 163 +++ .../test/osgi/runtime/impl/OSGiTestRuntime.java | 163 +++ .../tuscany/sca/test/util/OSGiRuntimeLoader.java | 86 ++ .../tuscany/sca/test/util/TuscanyLoader.java | 136 ++ .../harness/OSGiTuscanyNonOSGiTestHarness.java | 109 ++ .../test/osgi/harness/OSGiTuscanyTestHarness.java | 243 ++++ .../CalculatorImplementationPoliciesTestCase.java | 61 + .../test/osgi/tuscany/CalculatorRmiTestCase.java | 62 + .../osgi/tuscany/CalculatorScriptTestCase.java | 63 + .../osgi/tuscany/CallbackWsClientTestCase.java | 61 + .../osgi/tuscany/CallbackWsServiceTestCase.java | 61 + .../tuscany/HelloworldWsServiceJmsTestCase.java | 61 + .../tuscany/HelloworldWsServiceSecureTestCase.java | 61 + .../osgi/tuscany/HelloworldWsServiceTestCase.java | 61 + .../test/osgi/tuscany/NonOSGiSamplesTestCase.java | 85 ++ .../test/osgi/tuscany/OSGiSupplyChainTestCase.java | 71 + .../osgi/tuscany/OSGiTuscanyRuntimeTestCase.java | 137 ++ .../tuscany/TuscanySampleExtensionsTestCase.java | 93 ++ .../TuscanySamplesUsingOldDomainTestCase.java | 80 ++ .../src/test/resources/META-INF/MANIFEST.MF | 14 + .../test/resources/felix/felix.config.properties | 45 + java/sca/contrib/itest/osgi-tuscany/pom.xml | 39 + .../osgi-tuscany/test-bundles/build-bundles.xml | 31 + .../itest/osgi-tuscany/test-bundles/pom.xml | 124 ++ .../java/supplychain/client/SupplyChainClient.java | 115 ++ .../main/java/supplychain/customer/Customer.java | 37 + .../customer/JavaCustomerComponentImpl.java | 61 + .../retailer/JavaRetailerComponentImpl.java | 59 + .../main/java/supplychain/retailer/Retailer.java | 28 + .../shipper/JavaShipperComponentImpl.java | 50 + .../src/main/java/supplychain/shipper/Shipper.java | 28 + .../warehouse/JavaWarehouseComponentImpl.java | 49 + .../main/java/supplychain/warehouse/Warehouse.java | 28 + .../src/main/resources/META-INF/SupplyChain.mf | 12 + .../main/resources/META-INF/SupplyChainClient.mf | 21 + .../main/resources/META-INF/sca-contribution.xml | 26 + .../resources/supplychain/supplychain.composite | 48 + .../main/resources/supplychain/ws/Customer.wsdl | 135 ++ .../resources/supplychain/ws/supplychain.composite | 55 + .../osgi-tuscany/tuscany-osgi-installer/pom.xml | 666 +++++++++ .../sca/installer/InstallerBundleActivator.java | 405 ++++++ .../itest/osgi-tuscany/tuscany-versioned/pom.xml | 639 +++++++++ .../itest/policy-security-basicauth/pom.xml | 113 ++ .../main/java/helloworld/HelloWorldClientImpl.java | 40 + .../main/java/helloworld/HelloWorldService.java | 30 + .../java/helloworld/HelloWorldServiceImpl.java | 46 + .../src/main/resources/definitions.xml | 44 + .../src/main/resources/helloworld.composite | 46 + .../tuscany/sca/itest/BasicAuthTestCase.java | 114 ++ .../contrib/itest/policy-security-jsr250/pom.xml | 75 + .../src/main/java/helloworld/HelloWorldImpl.java | 51 + .../main/java/helloworld/HelloWorldService.java | 38 + .../src/main/resources/definitions.xml | 29 + .../src/main/resources/helloworld.composite | 33 + .../sca/itest/PolicySecurityJSR250TestCase.java | 54 + .../contrib/itest/policy-security-token/pom.xml | 106 ++ .../main/java/helloworld/HelloWorldClientImpl.java | 42 + .../main/java/helloworld/HelloWorldService.java | 30 + .../java/helloworld/HelloWorldServiceImpl.java | 46 + .../src/main/resources/definitions.xml | 49 + .../src/main/resources/helloworld.composite | 56 + .../src/main/resources/jndi.properties | 39 + .../tuscany/sca/itest/TokenAuthTestCase.java | 115 ++ java/sca/contrib/itest/policy-security/pom.xml | 68 + .../src/main/java/helloworld/HelloWorldImpl.java | 33 + .../main/java/helloworld/HelloWorldService.java | 30 + .../src/main/resources/definitions.xml | 33 + .../src/main/resources/helloworld.composite | 34 + .../tuscany/sca/itest/PolicyIdentityTestCase.java | 54 + java/sca/contrib/itest/policy/pom.xml | 68 + .../src/main/java/calculator/AddService.java | 34 + .../src/main/java/calculator/AddServiceImpl.java | 35 + .../src/main/java/calculator/CalculatorClient.java | 69 + .../main/java/calculator/CalculatorService.java | 35 + .../java/calculator/CalculatorServiceImpl.java | 76 + .../src/main/java/calculator/DivideService.java | 33 + .../main/java/calculator/DivideServiceImpl.java | 35 + .../src/main/java/calculator/MultiplyService.java | 28 + .../main/java/calculator/MultiplyServiceImpl.java | 35 + .../src/main/java/calculator/PolicyQNames.java | 43 + .../src/main/java/calculator/SubtractService.java | 28 + .../main/java/calculator/SubtractServiceImpl.java | 35 + .../calculator/policy/TestImplPolicyHandler.java | 84 ++ .../calculator/policy/TestRefPolicyHandler.java | 61 + .../calculator/policy/TestSvcPolicyHandler.java | 61 + .../policy/src/main/resources/Calculator.composite | 66 + ...ca.contribution.processor.StAXArtifactProcessor | 19 + ...rg.apache.tuscany.sca.policy.util.PolicyHandler | 28 + .../policy/src/main/resources/definitions.xml | 147 ++ .../sca/itest/PoliciedCalculatorTestCase.java | 55 + .../java/org/apache/tuscany/sca/itest/Policy.java | 33 + .../tuscany/sca/itest/TestPolicyProcessor.java | 82 ++ .../itest/promotion-interface-missmatch/pom.xml | 59 + .../main/java/com/example/BusinessException.java | 43 + .../src/main/java/com/example/ExampleClient.java | 23 + .../main/java/com/example/ExampleClientImpl.java | 44 + .../src/main/java/com/example/ExampleService.java | 27 + .../main/java/com/example/ExampleServiceImpl.java | 26 + .../src/main/resources/example.composite | 50 + .../src/main/resources/wsdl/ExampleService.wsdl | 133 ++ .../main/resources/wsdl/ExampleServiceTypes.xsd | 45 + .../src/test/java/com/example/ExampleTestCase.java | 44 + java/sca/contrib/itest/recursive-ws/pom.xml | 87 ++ .../recursive-ws/src/main/java/policy/Target.java | 26 + .../src/main/java/policy/TargetClientImpl.java | 33 + .../src/main/java/policy/TargetServiceImpl.java | 29 + .../src/main/java/recursive/Composer.java | 26 + .../src/main/java/recursive/ComposerClient.java | 35 + .../main/java/recursive/ComposerClientImpl.java | 38 + .../src/main/java/recursive/ComposerImpl.java | 34 + .../src/main/java/recursive/ComposerServer.java | 35 + .../src/main/resources/Client.composite | 28 + .../src/main/resources/Inner.composite | 26 + .../src/main/resources/Outer.composite | 31 + .../bindingoverride/InnerComposite.composite | 36 + .../bindingoverride/OuterComposite.composite | 40 + .../policy/PolicyInnerComposite.composite | 37 + .../policy/PolicyOuterComposite.composite | 41 + .../src/main/resources/policy/definitions.xml | 39 + .../bindingoverride/BindingOverrideTestCase.java | 57 + .../src/test/java/policy/PolicyTestCase.java | 74 + .../java/recursive/ComposerClientTestCase.java | 68 + .../test/java/recursive/ComposerTestServer.java | 55 + java/sca/contrib/itest/recursive/pom.xml | 45 + .../src/main/java/circular/include/DemoClass.java | 27 + .../src/main/java/composite/CompositeClient.java | 42 + .../recursive/src/main/java/composite/Source.java | 24 + .../src/main/java/composite/SourceCallback.java | 24 + .../src/main/java/composite/SourceImpl.java | 55 + .../recursive/src/main/java/composite/Target.java | 30 + .../src/main/java/composite/TargetImpl.java | 41 + .../itest/recursive/src/main/java/foo/A.java | 28 + .../itest/recursive/src/main/java/foo/B.java | 36 + .../itest/recursive/src/main/java/foo/I.java | 23 + .../recursive/src/main/java/policy/Target.java | 26 + .../src/main/java/policy/TargetClientImpl.java | 33 + .../src/main/java/policy/TargetServiceImpl.java | 29 + .../src/main/java/sample/ComponentAImpl.java | 41 + .../src/main/java/sample/ComponentCImpl.java | 41 + .../src/main/java/sample/ComponentEImpl.java | 38 + .../src/main/java/sample/ComponentFImpl.java | 45 + .../recursive/src/main/java/sample/Service1.java | 27 + .../recursive/src/main/java/test/Aggregator.java | 27 + .../src/main/java/test/AggregatorImpl.java | 55 + .../src/main/java/test/InnerSourceImpl.java | 34 + .../src/main/java/test/OuterSourceImpl.java | 34 + .../itest/recursive/src/main/java/test/Source.java | 30 + .../src/main/java/test1/composite/Target.java | 23 + .../src/main/java/test1/composite/TargetOne.java | 29 + .../src/main/java/test1/composite/TargetTwo.java | 29 + .../src/main/resources/AComposite.composite | 30 + .../src/main/resources/BComposite.composite | 45 + .../src/main/resources/CComposite.composite | 44 + .../src/main/resources/Composite1.composite | 42 + .../src/main/resources/Composite2.composite | 43 + .../src/main/resources/Composite3.composite | 48 + .../src/main/resources/Demo1Composite.composite | 27 + .../src/main/resources/Demo2Composite.composite | 28 + .../recursive/src/main/resources/Inner.composite | 45 + .../src/main/resources/InnerComposite.composite | 41 + .../src/main/resources/InnerComposite2.composite | 33 + .../main/resources/META-INF/sca-contribution.xml | 24 + .../recursive/src/main/resources/Outer.composite | 39 + .../src/main/resources/OuterComposite.composite | 39 + .../itest/recursive/src/main/resources/foo/foo.png | Bin 0 -> 571816 bytes .../recursive/src/main/resources/foo/o1.composite | 31 + .../recursive/src/main/resources/foo/o2.composite | 31 + .../recursive/src/main/resources/foo/o3.composite | 35 + .../recursive/src/main/resources/foo/o4.composite | 37 + .../policy/PolicyInnerComposite.composite | 32 + .../policy/PolicyOuterComposite.composite | 35 + .../src/main/resources/policy/definitions.xml | 46 + .../main/resources/test1/InnerComposite.composite | 39 + .../main/resources/test1/OuterComposite.composite | 27 + .../circular/include/CircularIncludeTestCase.java | 39 + .../src/test/java/composite/CompositeTestCase.java | 51 + .../LocateServiceEmbeddedSCADomainTestCase.java | 113 ++ .../composite/LocateServiceSCADomainTestCase.java | 73 + .../recursive/src/test/java/foo/O2TestCase.java | 32 + .../recursive/src/test/java/foo/O4TestCase.java | 39 + .../src/test/java/policy/PolicyTestCase.java | 68 + .../itest/recursive/src/test/java/sample/C.java | 32 + .../recursive/src/test/java/sample/CImpl.java | 80 ++ .../src/test/java/sample/NestedTestCase.java | 96 ++ .../sample/RecursiveCompositeTestCaseFIXME.java | 53 + .../itest/recursive/src/test/java/sample/X.java | 32 + .../recursive/src/test/java/sample/XImpl.java | 37 + .../itest/recursive/src/test/java/sample/Y.java | 32 + .../recursive/src/test/java/sample/YImpl.java | 38 + .../src/test/java/test/InnerTestCase.java | 51 + .../src/test/java/test/OuterTestCase.java | 53 + .../test1/composite/CompositeClientTestCase.java | 62 + java/sca/contrib/itest/serialization/pom.xml | 66 + .../servicereference/ConversationalService.java | 81 ++ .../ConversationalServiceCallback.java | 37 + .../ConversationalServiceImpl.java | 141 ++ .../itest/servicereference/SCAManagedClient.java | 51 + .../servicereference/SCAManagedClientImpl.java | 115 ++ .../SCAManagedConversationalClient.java | 55 + .../SCAManagedConversationalClientImpl.java | 132 ++ .../itest/servicereference/StatelessService.java | 46 + .../servicereference/StatelessServiceCallback.java | 34 + .../servicereference/StatelessServiceImpl.java | 82 ++ .../utils/ServiceReferenceUtils.java | 127 ++ .../ServiceReferenceSerializationTest.composite | 45 + .../src/main/resources/nestedcomposite.composite | 33 + .../SerializeServiceReferenceTestCase.java | 145 ++ java/sca/contrib/itest/spring/pom.xml | 105 ++ .../java/bigbank/stockquote/StockQuoteImpl.java | 38 + .../java/bigbank/stockquote/StockQuoteService.java | 30 + .../src/main/java/calculator/AddService.java | 28 + .../src/main/java/calculator/AddServiceImpl.java | 35 + .../main/java/calculator/CalculatorService.java | 35 + .../java/calculator/CalculatorServiceImpl.java | 79 ++ .../src/main/java/calculator/DivideService.java | 28 + .../main/java/calculator/DivideServiceImpl.java | 35 + .../src/main/java/calculator/MultiplyService.java | 28 + .../main/java/calculator/MultiplyServiceImpl.java | 35 + .../src/main/java/calculator/SubtractService.java | 28 + .../main/java/calculator/SubtractServiceImpl.java | 35 + .../security/CalculatorCallbackHandler.java | 50 + .../java/calculator/security/JaasLoginModule.java | 178 +++ .../java/calculator/security/UserPrincipal.java | 66 + .../access/SCAApplicationContextProvider.java | 19 + .../spring/annotations/CalculatorServiceImpl.java | 131 ++ .../main/resources/CalculatorService-context.xml | 39 + .../sca/SpringDelegationHelloWorld-context.xml | 37 + .../META-INF/sca/SpringHelloWorld-context.xml | 31 + .../context-access/CalculatorService-context.xml | 45 + .../context-imports/CalculatorService-context.xml | 39 + .../sca/context-imports/SpringImport-context.xml | 29 + .../context-multiple/StockQuoteService-context.xml | 36 + .../sca/context-multiple/beanRefContext.xml | 34 + .../CalculatorService-context.xml | 39 + .../CalculatorService-context.xml | 41 + .../resources/context/access/Calculator.composite | 49 + .../resources/context/imports/Calculator.composite | 49 + .../context/multiple/StockQuote.composite | 35 + .../implementation/policies/Calculator.composite | 61 + .../implementation/policies/CalculatorJass.config | 3 + .../policies/CalculatorLogMessages.properties | 18 + .../implementation/policies/definitions.xml | 40 + .../spring/SpringDelegationHelloWorld.composite | 32 + .../sca/itest/spring/SpringHelloWorld.composite | 32 + .../spring/annotations/Calculator.composite | 60 + .../test/java/context/access/CalculatorClient.java | 60 + .../java/context/access/ContextAccessTestCase.java | 32 + .../java/context/imports/CalculatorClient.java | 54 + .../context/imports/ContextImportsTestCase.java | 32 + .../context/multiple/MultipleContextTestCase.java | 32 + .../java/context/multiple/StockQuoteServer.java | 51 + .../implementation/policies/CalculatorClient.java | 78 ++ .../policies/ImplementationPoliciesTestCase.java | 32 + .../itest/spring/AbstractHelloWorldTestCase.java | 40 + .../sca/itest/spring/AbstractSCATestCase.java | 51 + .../tuscany/sca/itest/spring/HelloWorld.java | 34 + .../tuscany/sca/itest/spring/HelloWorldProxy.java | 41 + .../spring/SpringDelegationHelloWorldTestCase.java | 31 + .../sca/itest/spring/SpringHelloWorldTestCase.java | 32 + .../sca/itest/spring/TestHelloWorldBean.java | 36 + .../itest/spring/TestHelloWorldDelegatorBean.java | 40 + .../java/spring/annotations/CalculatorClient.java | 65 + .../annotations/SpringAnnotationsTestCase.java | 32 + java/sca/contrib/itest/transaction/pom.xml | 91 ++ .../transaction/AccountNotFoundException.java | 36 + .../sca/itest/transaction/AccountService.java | 31 + .../sca/itest/transaction/AccountServiceImpl.java | 70 + .../transaction/CheckingAccountServiceImpl.java | 143 ++ .../sca/itest/transaction/OverDraftException.java | 36 + .../transaction/SavingsAccountServiceImpl.java | 133 ++ .../sca/itest/transaction/TransferService.java | 31 + .../sca/itest/transaction/TransferServiceImpl.java | 64 + .../src/main/resources/accounts.composite | 43 + .../transaction/src/main/resources/definitions.xml | 99 ++ .../src/main/resources/log4j.properties | 29 + .../transaction/ConcurrentXAResourceTestCase.java | 119 ++ .../sca/itest/transaction/TransactionTestCase.java | 53 + java/sca/contrib/itest/validation/pom.xml | 141 ++ .../main/java/binding/ejb/account/Customer.java | 35 + .../java/binding/ejb/account/CustomerImpl.java | 57 + .../java/binding/ejb/calculator/AddService.java | 27 + .../binding/ejb/calculator/AddServiceHome.java | 31 + .../main/java/binding/jms/HelloWorldService.java | 26 + .../java/binding/jms/HelloWorldServiceImpl.java | 27 + .../main/java/calculator/warning/AddService.java | 32 + .../java/calculator/warning/AddServiceImpl.java | 44 + .../warning/AddServiceImplWithServiceName.java | 46 + .../java/calculator/warning/CalculatorClient.java | 45 + .../java/calculator/warning/CalculatorService.java | 35 + .../calculator/warning/CalculatorServiceImpl.java | 70 + .../java/calculator/warning/DivideService.java | 28 + .../java/calculator/warning/DivideServiceImpl.java | 35 + .../java/calculator/warning/MultiplyService.java | 28 + .../calculator/warning/MultiplyServiceImpl.java | 35 + .../java/calculator/warning/PropertyService.java | 29 + .../calculator/warning/PropertyServiceImpl.java | 41 + .../java/calculator/warning/SubtractService.java | 28 + .../calculator/warning/SubtractServiceImpl.java | 35 + .../SubtractServiceImplWithServiceName.java | 38 + .../src/main/java/impl/java/AddService.java | 29 + .../src/main/java/impl/java/AddServiceImpl.java | 44 + .../src/main/java/impl/java/CalculatorClient.java | 45 + .../src/main/java/impl/java/CalculatorService.java | 35 + .../main/java/impl/java/CalculatorServiceImpl.java | 75 + .../src/main/java/impl/java/DivideService.java | 28 + .../src/main/java/impl/java/DivideServiceImpl.java | 35 + .../src/main/java/impl/java/MultiplyService.java | 28 + .../main/java/impl/java/MultiplyServiceImpl.java | 35 + .../src/main/java/impl/java/SubtractService.java | 28 + .../main/java/impl/java/SubtractServiceImpl.java | 35 + .../src/main/java/impl/spring/HelloWorld.java | 36 + .../src/main/java/impl/spring/HelloWorldProxy.java | 41 + .../main/java/impl/spring/TestHelloWorldBean.java | 36 + .../java/interfacejava/xml/CalculatorService.java | 35 + .../interfacejava/xml/CalculatorServiceImpl.java | 75 + .../Calculator.composite | 49 + .../DuplicateComponentName/Calculator.composite | 53 + .../Calculator.composite | 55 + .../dummyImplementation.composite | 31 + .../Calculator.composite | 56 + .../dummyImplementation.composite | 32 + .../DuplicatePropertyName/Calculator.composite | 51 + .../DuplicateReferenceName/Calculator.composite | 50 + .../META-INF/sca/SpringHelloWorld-context.xml | 31 + .../Calculator.composite | 53 + .../NoComponentImplementation/Calculator.composite | 52 + .../NoCompositeNamespace/Calculator.composite | 48 + .../NoMatchingBinding/Calculator.composite | 54 + .../PromotedReferenceNotFound/Calculator.composite | 51 + .../PromotedServiceNotFound/Calculator.composite | 51 + .../PropertyAttribute/Calculator.composite | 55 + .../CalculatorNullMustSupply.composite | 53 + .../CalculatorOverrideManyAttribute.composite | 54 + .../PropertyNotFound/Calculator.composite | 50 + .../Calculator.composite | 51 + .../Calculator.composite | 49 + .../Calculator.composite | 49 + .../ReferenceNotFound/Calculator.composite | 50 + .../ReferenceWithoutTargets/Calculator.composite | 49 + .../Calculator.composite | 54 + .../Calculator.composite | 54 + .../resources/XsdValidation/Calculator.composite | 51 + .../ContributionReadException/Calculator.composite | 53 + .../Calculator.composite | 53 + .../Calculator.composite | 54 + .../UnexpectedBindingElement/Calculator.composite | 55 + .../Calculator.composite | 54 + .../Calculator.composite | 54 + .../InvalidWsdlElementAttr/Calculator.composite | 58 + .../wsxml/MustUseWsdlBinding/Calculator.composite | 59 + .../wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl | 92 ++ .../helloworldwsjms.composite | 34 + .../wsxml/WsdlPortTypeDoesNotMatch/helloworld.wsdl | 92 ++ .../helloworldwsclient.composite | 45 + .../wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl | 92 ++ .../helloworldwsjms.composite | 34 + .../UnknownEJBSessionType/account.composite | 35 + .../bindingejb/UnknownEJBVersion/account.composite | 35 + .../DoesntProcessActivationSpec/service.composite | 36 + .../DoesntProcessDestinationType/service.composite | 35 + .../DoesntProcessHeaders/service.composite | 36 + .../DoesntProcessResourceAdapter/service.composite | 32 + .../service.composite | 35 + .../service.composite | 35 + .../service.composite | 35 + .../InvalidCorrelationScheme/service.composite | 35 + .../InvalidJMSDeliveryMode/service.composite | 36 + .../InvalidJMSPriority/service.composite | 36 + .../service.composite | 35 + .../MissingActivationSpecName/service.composite | 36 + .../MissingConnectionFactoryName/service.composite | 36 + .../service.composite | 36 + .../service.composite | 36 + .../MustStartWithSchema/service.composite | 36 + .../bindingjms/UnexpectedElement/service.composite | 38 + .../UnexpectedResponseElement/service.composite | 38 + .../bindingjms/UnknownTokenInURI/service.composite | 36 + .../AttributePackageMissing/Calculator.composite | 55 + .../AttributeNameSpaceMissing/Calculator.composite | 55 + .../AttributeURIMissing/Calculator.composite | 55 + .../META-INF/sca-contribution.xml | 24 + .../AttributeCompositeMissing/Calculator.composite | 53 + .../AttributeCompositeMissing/sca-contribution.xml | 24 + .../MultipleCompositeErrors/Calculator.composite | 53 + .../MultipleCompositeErrors/sca-contribution.xml | 31 + .../helloworld.composite | 29 + .../AttributeWithoutNamespace/helloworld.composite | 29 + .../impl/bpel/BPELProcessNotFound/deploy.xml | 30 + .../impl/bpel/BPELProcessNotFound/helloworld.bpel | 66 + .../BPELProcessNotFound/helloworld.componentType | 30 + .../bpel/BPELProcessNotFound/helloworld.composite | 29 + .../impl/bpel/BPELProcessNotFound/helloworld.wsdl | 82 ++ .../bpel/CannotResolveWSDLReference/deploy.xml | 30 + .../CannotResolveWSDLReference/helloworld.bpel | 66 + .../helloworld.componentType | 30 + .../helloworld.composite | 29 + .../impl/bpel/MyRolePartnerRoleNull/deploy.xml | 30 + .../bpel/MyRolePartnerRoleNull/helloworld.bpel | 66 + .../MyRolePartnerRoleNull/helloworld.componentType | 30 + .../MyRolePartnerRoleNull/helloworld.composite | 29 + .../bpel/MyRolePartnerRoleNull/helloworld.wsdl | 82 ++ .../impl/bpel/PartnerLinkHasBothAttr/deploy.xml | 30 + .../bpel/PartnerLinkHasBothAttr/helloworld.bpel | 68 + .../helloworld.componentType | 30 + .../PartnerLinkHasBothAttr/helloworld.composite | 29 + .../bpel/PartnerLinkHasBothAttr/helloworld.wsdl | 82 ++ .../impl/bpel/PartnerLinkNoMatchingType/deploy.xml | 30 + .../bpel/PartnerLinkNoMatchingType/helloworld.bpel | 66 + .../helloworld.componentType | 30 + .../PartnerLinkNoMatchingType/helloworld.composite | 29 + .../bpel/PartnerLinkNoMatchingType/helloworld.wsdl | 82 ++ .../impl/bpel/PartnerLinkTypeNoRoles/deploy.xml | 30 + .../bpel/PartnerLinkTypeNoRoles/helloworld.bpel | 66 + .../helloworld.componentType | 30 + .../PartnerLinkTypeNoRoles/helloworld.composite | 29 + .../bpel/PartnerLinkTypeNoRoles/helloworld.wsdl | 80 ++ .../impl/ejb/EJBLinkAttributeMissing/ejb.composite | 29 + .../ClassNotFoundException/Calculator.composite | 49 + .../Calculator.composite | 49 + .../OSGiTestService.componentType | 28 + .../CouldNotLocateOSGiBundle/osgitest.composite | 34 + .../MissingComponentTypeFile/osgitest.composite | 34 + .../OSGiTestService.componentType | 28 + .../PropertyShouldSpecifySR/osgitest.composite | 36 + .../CouldNotResolveLocation/resource.composite | 30 + .../LocationAttributeMissing/resource.composite | 30 + .../SpringHelloWorld.composite | 27 + .../SpringHelloWorld.composite | 27 + .../SpringHelloWorld-context.xml | 0 .../SpringHelloWorld.composite | 34 + .../TestHelloWorldBean.componentType | 27 + .../CouldNotResolveLocation/widget.composite | 29 + .../LocationAttributeMissing/widget.composite | 30 + .../xquery/CouldNotLocateFile/HelloWorld.composite | 28 + .../LocationAttributeMissing/HelloWorld.composite | 28 + .../ClassNotFoundException/Calculator.composite | 53 + .../CalculatorServiceImpl.componentType | 27 + .../Calculator.composite | 53 + .../CalculatorServiceImpl.componentType | 27 + .../InvalidWSDLInterfaceAttr/Calculator.composite | 54 + .../helloworld-interface.wsdl | 67 + .../helloworld-service.wsdl | 49 + .../xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl | 92 ++ .../helloworldwsjms.composite | 34 + .../ClassNotFoundException/Calculator.composite | 56 + .../ClassNotFoundException/definitions.xml | 78 ++ .../Calculator.composite | 56 + .../RequiredAttributeRolesMissing/definitions.xml | 78 ++ .../Calculator.composite | 56 + .../AlwaysProvidedIntentNotFound/definitions.xml | 63 + .../Calculator.composite | 56 + .../ErrorInPolicyIntentDefinition/definitions.xml | 76 + .../xml/IntentNotSpecified/Calculator.composite | 56 + .../policy/xml/IntentNotSpecified/definitions.xml | 175 +++ .../MayProvideIntentNotFound/Calculator.composite | 56 + .../xml/MayProvideIntentNotFound/definitions.xml | 63 + .../RequiredAttributeMissing/Calculator.composite | 56 + .../xml/RequiredAttributeMissing/definitions.xml | 70 + .../xml/UnableToMapPolicies/Calculator.composite | 56 + .../policy/xml/UnableToMapPolicies/definitions.xml | 242 ++++ .../Calculator.composite | 56 + .../definitions.xml | 68 + .../assembly/xml/ContributionReadException.java | 60 + .../xml/PolicyImplValidationException.java | 60 + .../xml/PolicyServiceValidationException.java | 60 + .../assembly/xml/UnexpectedBindingElement.java | 60 + .../xml/UnexpectedImplementationElement.java | 60 + .../assembly/xml/UnexpectedInterfaceElement.java | 59 + .../binding/ejb/UnknownEJBSessionTypeTestCase.java | 66 + .../binding/ejb/UnknownEJBVersionTestCase.java | 65 + .../jms/DoesntProcessActivationSpecTestCase.java | 59 + .../jms/DoesntProcessDestinationTypeTestCase.java | 59 + .../binding/jms/DoesntProcessHeadersTestCase.java | 61 + .../jms/DoesntProcessResourceAdapterTestCase.java | 59 + ...oesntProcessResponseActivationSpecTestCase.java | 59 + ...ntProcessResponseConnectionFactoryTestCase.java | 59 + ...esntProcessResponseDestinationTypeTestCase.java | 59 + .../jms/InvalidCorrelationSchemeTestCase.java | 59 + .../jms/InvalidJMSDeliveryModeTestCase.java | 59 + .../binding/jms/InvalidJMSPriorityTestCase.java | 59 + .../InvalidResponseDestinationTypeTestCase.java | 59 + .../jms/MissingActivationSpecNameTestCase.java | 59 + .../jms/MissingConnectionFactoryNameTestCase.java | 59 + .../jms/MissingResponseActivationSpecTestCase.java | 59 + .../MissingResponseConnectionFactoryTestCase.java | 59 + .../binding/jms/MustStartWithSchemaTestCase.java | 59 + .../binding/jms/UnexpectedElementTestCase.java | 59 + .../jms/UnexpectedResponseElementTestCase.java | 59 + .../binding/jms/UnknownTokenInURITestCase.java | 59 + .../wsxml/InvalidWsdlElementAttrTestCase.java | 60 + .../binding/wsxml/MustUseWsdlBindingTestCase.java | 60 + .../wsxml/WsdlBindingDoesNotMatchTestCase.java | 60 + .../wsxml/WsdlPortTypeDoesNotMatchTestCase.java | 59 + .../wsxml/WsdlServiceDoesNotMatchTestCase.java | 60 + .../ComponentReferenceTargetNotFoundTestCase.java | 76 + .../warning/DuplicateComponentNameTestCase.java | 60 + ...uplicateImplementationPropertyNameTestCase.java | 64 + ...plicateImplementationReferenceNameTestCase.java | 65 + .../warning/DuplicatePropertyNameTestCase.java | 70 + .../warning/DuplicateReferenceNameTestCase.java | 70 + .../MultipleBindingsForServiceTestCase.java | 70 + .../warning/NoComponentImplementationTestCase.java | 66 + .../warning/NoCompositeNamespaceTestCase.java | 70 + .../warning/NoMatchingBindingTestCase.java | 72 + .../warning/PromotedReferenceNotFoundTestCase.java | 70 + .../warning/PromotedServiceNotFoundTestCase.java | 70 + .../PropertyAttributeMustSupplyNullTestCase.java | 70 + .../warning/PropertyAttributeTestCase.java | 70 + .../warning/PropertyNotFoundTestCase.java | 70 + .../PropertyOverrideManyAttributeTestCase.java | 70 + ...enceIncompatibleComponentInterfaceTestCase.java | 70 + .../ReferenceIncompatibleInterfaceTestCase.java | 70 + .../ReferenceIncompatibleMultiplicityTestCase.java | 70 + .../warning/ReferenceNotFoundTestCase.java | 71 + .../warning/ReferenceWithoutTargetsTestCase.java | 70 + ...ServiceNotFoundForComponentServiceTestCase.java | 70 + .../UnresolvedComponentImplementationTestCase.java | 66 + .../calculator/warning/XSDValidationTestCase.java | 67 + .../java/AttributePackageMissingTestCase.java | 60 + .../AttributeNameSpaceMissingTestCase.java | 60 + .../resource/AttributeURIMissingTestCase.java | 60 + .../xml/AttributeCompositeMissingTestCase.java | 60 + .../xml/MultipleCompositeErrorsTestCase.java | 64 + .../test/java/domain/CustomCompositeBuilder.java | 230 ++++ .../AttributeUnrecognizedNamespaceTestCase.java | 59 + .../bpel/AttributeWithoutNamespaceTestCase.java | 59 + .../impl/bpel/BPELProcessNotFoundTestCase.java | 59 + .../bpel/CannotResolveWSDLReferenceTestCase.java | 59 + .../impl/bpel/MyRolePartnerRoleNullTestCase.java | 59 + .../impl/bpel/PartnerLinkHasBothAttrTestCase.java | 68 + .../bpel/PartnerLinkNoMatchingTypeTestCase.java | 59 + .../impl/bpel/PartnerLinkTypeNoRolesTestCase.java | 69 + .../impl/ejb/EJBLinkAttributeMissingTestCase.java | 59 + .../impl/java/ClassNotFoundExceptionTestCase.java | 59 + .../java/ContributionResolveExceptionTestCase.java | 60 + .../resource/CouldNotResolveLocationTestCase.java | 58 + .../resource/LocationAttributeMissingTestCase.java | 59 + .../ContributionResolveExceptionTestCase.java | 66 + .../spring/LocationAttributeMissingTestCase.java | 59 + .../UnableToResolveComponentTypeTestCase.java | 59 + .../widget/CouldNotResolveLocationTestCase.java | 58 + .../widget/LocationAttributeMissingTestCase.java | 59 + .../impl/xquery/CouldNotLocateFileTestCase.java | 59 + .../xquery/LocationAttributeMissingTestCase.java | 59 + .../interfacejava/xml/ClassNotFoundTestCase.java | 59 + .../xml/ContributionResolveExceptionTestCase.java | 59 + .../xml/InvalidWSDLInterfaceAttrTestCase.java | 59 + .../xml/WsdlInterfaceDoesNotMatchTestCase.java | 59 + .../xml/AlwaysProvidedIntentNotFoundTestCase.java | 59 + .../xml/ErrorInPolicyIntentDefinitionTestCase.java | 59 + .../policy/xml/IntentNotSpecifiedTestCase.java | 68 + .../xml/MayProvideIntentNotFoundTestCase.java | 59 + .../xml/RequiredAttributeMissingTestCase.java | 59 + .../policy/xml/UnableToMapPoliciesTestCase.java | 64 + .../UnrecognizedIntentAttachPointTypeTestCase.java | 59 + java/sca/contrib/itest/ws-void-args-return/pom.xml | 61 + .../src/main/java/voidtest/Bean.java | 39 + .../src/main/java/voidtest/HelloWorldImpl.java | 64 + .../src/main/java/voidtest/HelloWorldService.java | 47 + .../src/main/java/voidtest/TestClient.java | 23 + .../src/main/java/voidtest/TestClientImpl.java | 53 + .../src/main/resources/voidtest.composite | 41 + .../test/java/voidtest/VoidArgsReturnTestCase.java | 53 + java/sca/contrib/itest/wsdl-multiple/pom.xml | 135 ++ .../main/java/helloworld/HelloWorldCallback.java | 30 + .../main/java/helloworld/HelloWorldClientImpl.java | 42 + .../main/java/helloworld/HelloWorldService.java | 32 + .../java/helloworld/HelloWorldServiceImpl.java | 37 + .../src/main/resources/auto-wsdl.composite | 44 + .../src/main/resources/manual-wsdl.composite | 46 + .../wsdl/helloworld.HelloWorldCallback.wsdl | 98 ++ .../wsdl/helloworld.HelloWorldService.wsdl | 95 ++ .../apache/tuscany/sca/itest/AutoWSDLTestCase.java | 65 + .../tuscany/sca/itest/ManualWSDLTestCase.java | 65 + java/sca/contrib/itest/wsdl/pom.xml | 135 ++ .../services/accountdata/AccountDataService.java | 92 ++ .../accountdata/AccountDataServiceImpl.java | 93 ++ .../accountdata/AccountServiceClientImpl.java | 79 ++ .../services/accountdata/Component2aImpl.java | 79 ++ .../services/accountdata/Component2bImpl.java | 79 ++ .../services/accountdata/Component3aImpl.java | 79 ++ .../services/accountdata/Component3bImpl.java | 79 ++ .../services/accountdata/CustomerIdService.java | 98 ++ .../src/main/java/helloworld/HelloWorldImpl.java | 33 + .../main/java/helloworld/HelloWorldService.java | 30 + .../helloworld/HelloWorldServiceComponent.java | 43 + .../apache/tuscany/sca/itest/Component2aImpl.java | 38 + .../apache/tuscany/sca/itest/Component2bImpl.java | 39 + .../apache/tuscany/sca/itest/Component3aImpl.java | 39 + .../apache/tuscany/sca/itest/Component3bImpl.java | 39 + .../wsdl/src/main/resources/SDOWSDLTest.composite | 344 +++++ .../wsdl/src/main/resources/WSDLTest.composite | 371 +++++ .../src/main/resources/wsdl/AccountService.wsdl | 453 ++++++ .../itest/wsdl/src/main/resources/wsdl/Hello.xsd | 37 + .../wsdl/src/main/resources/wsdl/helloworld.wsdl | 64 + .../apache/tuscany/sca/itest/SDOWSDLTestCase.java | 169 +++ .../org/apache/tuscany/sca/itest/WSDLTestCase.java | 146 ++ java/sca/contrib/itest/wsdl2java/pom.xml | 188 +++ .../src/test/resources/AccountService.wsdl | 479 +++++++ .../wsdl2java/src/test/resources/EchoService.wsdl | 64 + .../wsdl2java/src/test/resources/EchoService.xsd | 40 + .../src/test/resources/StockExceptionTest.wsdl | 167 +++ java/sca/contrib/itest/wsdlless/pom.xml | 202 +++ .../services/accountdata/AccountDataService.java | 95 ++ .../accountdata/AccountDataServiceImpl.java | 91 ++ .../accountdata/AccountServiceClientImpl.java | 77 ++ .../services/accountdata/Component2aImpl.java | 77 ++ .../services/accountdata/Component2bImpl.java | 77 ++ .../services/accountdata/Component3aImpl.java | 77 ++ .../services/accountdata/Component3bImpl.java | 77 ++ .../services/accountdata/CustomerIdService.java | 98 ++ .../src/main/java/helloworld/HelloWorldImpl.java | 44 + .../main/java/helloworld/HelloWorldService.java | 31 + .../helloworld/HelloWorldServiceComponent.java | 47 + .../apache/tuscany/sca/itest/Component2aImpl.java | 43 + .../apache/tuscany/sca/itest/Component2bImpl.java | 42 + .../apache/tuscany/sca/itest/Component3aImpl.java | 42 + .../apache/tuscany/sca/itest/Component3bImpl.java | 43 + .../wsdlless/src/main/java/service/AnObject.java | 62 + .../src/main/java/service/MoreComplexObject.java | 53 + .../src/main/java/service/SomeService.java | 31 + .../src/main/java/service/SomeServiceImpl.java | 42 + .../src/main/resources/SDOWSDLTest.composite | 321 +++++ .../wsdlless/src/main/resources/WSDLTest.composite | 350 +++++ .../wsdlless/src/main/resources/some.composite | 33 + .../src/main/resources/wsdl/AccountService.wsdl | 453 ++++++ .../src/main/resources/wsdl/helloworld.wsdl | 131 ++ .../apache/tuscany/sca/itest/SDOWSDLTestCase.java | 173 +++ .../org/apache/tuscany/sca/itest/WSDLTestCase.java | 150 ++ .../test/java/service/SomeComponentTestCase.java | 83 ++ .../src/test/java/service/generated/AnObject.java | 100 ++ .../generated/GetUsingMoreComplexObject.java | 79 ++ .../GetUsingMoreComplexObjectResponse.java | 79 ++ .../java/service/generated/GetUsingString.java | 79 ++ .../service/generated/GetUsingStringResponse.java | 79 ++ .../java/service/generated/MoreComplexObject.java | 126 ++ .../test/java/service/generated/ObjectFactory.java | 141 ++ .../test/java/service/generated/SomeService.java | 65 + .../java/service/generated/SomeServiceService.java | 81 ++ .../test/java/service/generated/package-info.java | 21 + java/sca/itest/admin/README | 28 - java/sca/itest/admin/pom.xml | 60 - .../tuscany/sca/itest/admin/MyListService.java | 9 - .../sca/itest/admin/MyListServiceByYear.java | 8 - .../tuscany/sca/itest/admin/MyListServiceImpl.java | 69 - .../apache/tuscany/sca/itest/admin/MyLogger.java | 17 - .../apache/tuscany/sca/itest/admin/MyService.java | 9 - .../tuscany/sca/itest/admin/MyServiceByDate.java | 10 - .../tuscany/sca/itest/admin/MyServiceImpl.java | 113 -- .../tuscany/sca/itest/admin/MyTotalService.java | 6 - .../sca/itest/admin/MyTotalServiceImpl.java | 74 - .../sca/itest/admin/SCAComponentService.java | 9 - .../admin/MySimpleServiceInRecursiveTestCase.java | 61 - .../sca/itest/admin/MySimpleServiceTestCase.java | 57 - .../sca/itest/admin/MyTotalServiceTestCase.java | 48 - .../test/resources/Iteration1Composite.composite | 43 - .../test/resources/Iteration3Composite.composite | 68 - .../src/test/resources/MySimpleService.composite | 59 - java/sca/itest/binding-sca-jms/client/pom.xml | 63 - .../client/src/main/java/itest/MyClientImpl.java | 32 - .../client/src/main/java/itest/MyService.java | 28 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../client/src/main/resources/MyClient.composite | 29 - .../src/test/java/itest/MyClientTestCase.java | 39 - java/sca/itest/binding-sca-jms/pom.xml | 36 - java/sca/itest/binding-sca-jms/service/pom.xml | 63 - .../service/src/main/java/itest/MyService.java | 28 - .../service/src/main/java/itest/MyServiceImpl.java | 28 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../service/src/main/resources/MyService.composite | 28 - .../src/test/java/itest/MyServiceTestCase.java | 34 - java/sca/itest/bpel/helloworld-reference/pom.xml | 210 --- .../src/test/java/greetings/GreetingsService.java | 31 - .../test/java/greetings/GreetingsServiceImpl.java | 33 - .../src/test/java/greetings/GreetingsTestCase.java | 60 - .../test/java/helloworld/HelloWorldService.java | 29 - .../java/helloworld/HelloWorldServiceImpl.java | 47 - .../test/java/helloworld/HelloWorldTestCase.java | 55 - .../test/resources/greetings/greetings.composite | 32 - .../src/test/resources/greetings/greetings.wsdl | 87 -- .../src/test/resources/helloworld/deploy.xml | 35 - .../src/test/resources/helloworld/helloworld.bpel | 84 -- .../resources/helloworld/helloworld.componentType | 36 - .../test/resources/helloworld/helloworld.composite | 36 - .../src/test/resources/helloworld/helloworld.wsdl | 82 -- .../src/test/resources/log4j.properties | 36 - java/sca/itest/bpel/helloworld-ws/pom.xml | 176 --- .../src/test/java/helloworld/HelloWorld.java | 45 - .../test/java/helloworld/HelloWorldTestCase.java | 64 - .../src/test/resources/helloworld/deploy.xml | 31 - .../src/test/resources/helloworld/helloworld.bpel | 66 - .../resources/helloworld/helloworld.componentType | 30 - .../test/resources/helloworld/helloworld.composite | 32 - .../src/test/resources/helloworld/helloworld.wsdl | 82 -- .../src/test/resources/log4j.properties | 36 - java/sca/itest/bpel/helloworld/pom.xml | 162 --- .../src/test/java/helloworld/HelloWorld.java | 45 - .../test/java/helloworld/HelloWorldTestCase.java | 63 - .../src/test/resources/helloworld/deploy.xml | 31 - .../src/test/resources/helloworld/helloworld.bpel | 66 - .../resources/helloworld/helloworld.componentType | 30 - .../test/resources/helloworld/helloworld.composite | 36 - .../src/test/resources/helloworld/helloworld.wsdl | 82 -- .../helloworld/src/test/resources/log4j.properties | 36 - java/sca/itest/bpel/pom.xml | 37 - java/sca/itest/builder/pom.xml | 99 -- .../tuscany/sca/itest/builder/ComponentDImpl.java | 45 - .../ComponentDReferenceMultiplicityImpl.java | 48 - .../tuscany/sca/itest/builder/ComponentEImpl.java | 36 - .../tuscany/sca/itest/builder/ComponentFImpl.java | 36 - .../apache/tuscany/sca/itest/builder/Service3.java | 33 - .../tuscany/sca/itest/builder/Service3a.java | 33 - .../scenario1/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario1/scenario1.composite | 45 - .../main/resources/scenario1/scenario1a.composite | 47 - .../scenario10/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario10/scenario10.composite | 62 - .../resources/scenario10/scenario10a.composite | 61 - .../src/main/resources/scenario10/service3.wsdl | 63 - .../scenario11/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario11/scenario11.composite | 59 - .../resources/scenario11/scenario11a.composite | 64 - .../src/main/resources/scenario11/service3.wsdl | 63 - .../scenario12/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario12/scenario12.composite | 58 - .../resources/scenario12/scenario12a.composite | 64 - .../scenario13/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario13/scenario13.composite | 58 - .../resources/scenario13/scenario13a.composite | 64 - .../scenario2/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario2/scenario2.composite | 45 - .../main/resources/scenario2/scenario2a.composite | 47 - .../scenario3/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario3/scenario3.composite | 44 - .../main/resources/scenario3/scenario3a.composite | 48 - .../scenario4/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario4/scenario4.composite | 44 - .../main/resources/scenario4/scenario4a.composite | 48 - .../scenario5/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario5/scenario5.composite | 46 - .../main/resources/scenario5/scenario5a.composite | 47 - .../src/main/resources/scenario5/scenarios.wsdl | 63 - .../scenario6/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario6/scenario6.composite | 47 - .../main/resources/scenario6/scenario6a.composite | 47 - .../src/main/resources/scenario6/scenarios.wsdl | 63 - .../scenario7/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario7/scenario7.composite | 45 - .../main/resources/scenario7/scenario7a.composite | 49 - .../src/main/resources/scenario7/scenarios.wsdl | 63 - .../scenario8/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario8/scenario8.composite | 44 - .../main/resources/scenario8/scenario8a.composite | 50 - .../src/main/resources/scenario8/scenarios.wsdl | 63 - .../scenario9/META-INF/sca-contribution.xml | 24 - .../main/resources/scenario9/scenario9.composite | 60 - .../main/resources/scenario9/scenario9a.composite | 61 - .../tuscany/sca/itest/builder/BuilderTestCase.java | 805 ----------- .../builder/CompositeBuilderNonWiringImpl.java | 153 --- .../sca/itest/builder/CustomCompositeBuilder.java | 207 --- .../tuscany/sca/itest/builder/TestUtils.java | 203 --- java/sca/itest/callablereferences-ws/pom.xml | 59 - .../src/main/java/com/example/ExampleClient.java | 26 - .../main/java/com/example/ExampleClientImpl.java | 59 - .../src/main/java/com/example/ExampleService.java | 30 - .../main/java/com/example/ExampleServiceImpl.java | 33 - .../sca/itest/callablerefwsreturn/Alpha.java | 26 - .../sca/itest/callablerefwsreturn/AlphaImpl.java | 96 -- .../sca/itest/callablerefwsreturn/Beta.java | 27 - .../sca/itest/callablerefwsreturn/BetaImpl.java | 46 - .../sca/itest/callablerefwsreturn/Gamma.java | 34 - .../sca/itest/callablerefwsreturn/GammaImpl.java | 49 - .../CallableReferenceWsReturnTest.composite | 54 - .../src/main/resources/example.composite | 40 - .../src/test/java/com/example/ExampleTestCase.java | 44 - .../CallableReferenceReturnTestCase.java | 49 - java/sca/itest/callablereferences/pom.xml | 81 -- .../tuscany/sca/itest/callableref/AComponent.java | 39 - .../sca/itest/callableref/AComponentImpl.java | 114 -- .../tuscany/sca/itest/callableref/BComponent.java | 30 - .../sca/itest/callableref/BComponentImpl.java | 38 - .../tuscany/sca/itest/callableref/CComponent.java | 27 - .../sca/itest/callableref/CComponentImpl.java | 30 - .../tuscany/sca/itest/callableref/DComponent.java | 30 - .../sca/itest/callableref/DComponentImpl.java | 65 - .../ConversationalService.java | 68 - .../ConversationalServiceImpl.java | 111 -- .../tuscany/sca/itest/callablerefreturn/Alpha.java | 27 - .../sca/itest/callablerefreturn/AlphaImpl.java | 86 -- .../tuscany/sca/itest/callablerefreturn/Beta.java | 28 - .../sca/itest/callablerefreturn/BetaImpl.java | 44 - .../tuscany/sca/itest/callablerefreturn/Gamma.java | 35 - .../sca/itest/callablerefreturn/GammaImpl.java | 47 - .../CallableReferenceConversationalTest.composite | 29 - .../CallableReferenceReturnTest.composite | 39 - .../main/resources/CallableReferenceTest.composite | 45 - .../src/main/resources/nodeA/CompositeA.composite | 46 - .../resources/nodeA/META-INF/sca-contribution.xml | 22 - .../src/main/resources/nodeB/CompositeB.composite | 43 - .../resources/nodeB/META-INF/sca-contribution.xml | 22 - .../CallableReferenceConversationalTestCase.java | 109 -- .../CallableReferenceRemoteTestCase.java | 145 -- .../CallableReferenceReturnTestCase.java | 48 - .../callableref/CallableReferenceTestCase.java | 83 -- .../contribution-classes/build-jar.xml | 39 - .../contribution-classes/pom.xml | 203 --- .../main/java/supplychain/customer/Customer.java | 35 - .../customer/JavaCustomerComponentImpl.java | 63 - .../illegal/JavaCustomerComponentImpl.java | 74 - .../retailer/JavaRetailerComponentImpl.java | 61 - .../main/java/supplychain/retailer/Retailer.java | 28 - .../shipper/JavaShipperComponentImpl.java | 52 - .../src/main/java/supplychain/shipper/Shipper.java | 28 - .../warehouse/JavaWarehouseComponentImpl.java | 47 - .../main/java/supplychain/warehouse/Warehouse.java | 28 - .../complete-supplychain-sca-contribution.xml | 26 - .../META-INF/customer-impl-sca-contribution.xml | 26 - .../customer-interface-sca-contribution.xml | 26 - .../META-INF/customer-sca-contribution.xml | 25 - .../META-INF/illegal-customer-sca-contribution.xml | 26 - .../illegal1-supplychain-sca-contribution.xml | 24 - .../illegal2-supplychain-sca-contribution.xml | 31 - .../META-INF/retailer-sca-contribution.xml | 25 - .../META-INF/shipper-sca-contribution.xml | 25 - .../META-INF/supplychain-sca-contribution.xml | 30 - .../META-INF/warehouse-sca-contribution.xml | 25 - .../supplychain/illegalsupplychain.composite | 48 - .../resources/supplychain/supplychain.composite | 48 - .../JavaWarehouseComponentImpl.componentType | 28 - .../contribution-test/pom.xml | 53 - .../test/contribution/ContributionTestCase.java | 373 ----- .../tuscany/sca/test/contribution/SupplyChain.java | 231 ---- .../TuscanyClassloadingTestCaseFIXME.java | 381 ----- java/sca/itest/contribution-classloader/pom.xml | 51 - .../export-composite/pom.xml | 67 - .../src/main/java/hello/Hello.java | 30 - .../src/main/java/hello/HelloImpl.java | 33 - .../main/resources/META-INF/sca-contribution.xml | 25 - .../src/main/resources/hello.composite | 31 - .../sca/test/contribution/HelloTestCase.java | 91 -- .../contribution-import-export/export-java/pom.xml | 67 - .../main/java/helloworld/HelloWorldService.java | 30 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../helloworld/HelloWorldImpl.componentType | 30 - .../export-resource/pom.xml | 31 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../src/main/resources/ufservices/store.html | 27 - .../contribution-import-export/export-wsdl/pom.xml | 31 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../export-wsdl/src/main/resources/helloworld.wsdl | 76 - .../export-wsdl/src/main/resources/helloworld.xsd | 35 - .../import-composite/pom.xml | 73 - .../src/main/java/helloworld/HelloWorldImpl.java | 38 - .../src/main/java/helloworld/HelloWorldServer.java | 46 - .../main/java/helloworld/HelloWorldService.java | 30 - .../main/resources/META-INF/sca-contribution.xml | 27 - .../src/main/resources/helloworld.wsdl | 76 - .../src/main/resources/helloworld.xsd | 35 - .../src/main/resources/helloworldws.composite | 39 - .../contribution/HelloWorldServerTestCase.java | 126 -- .../contribution-import-export/import-java/pom.xml | 73 - .../src/main/java/helloworld/HelloWorldImpl.java | 33 - .../main/resources/META-INF/sca-contribution.xml | 25 - .../src/main/resources/helloworldws.composite | 29 - .../contribution/HelloWorldServerTestCase.java | 127 -- .../import-resource/pom.xml | 102 -- .../main/resources/META-INF/sca-contribution.xml | 25 - .../src/main/resources/store.composite | 33 - .../sca/test/contribution/StoreTestCase.java | 129 -- .../contribution-import-export/import-wsdl/pom.xml | 73 - .../src/main/java/helloworld/HelloWorldImpl.java | 33 - .../src/main/java/helloworld/HelloWorldServer.java | 46 - .../main/java/helloworld/HelloWorldService.java | 30 - .../main/resources/META-INF/sca-contribution.xml | 25 - .../src/main/resources/helloworldws.composite | 33 - .../contribution/HelloWorldServerTestCase.java | 137 -- java/sca/itest/contribution-import-export/pom.xml | 56 - java/sca/itest/contribution-multiple/pom.xml | 51 - .../src/test/java/hello/Hello.java | 27 - .../src/test/java/hello/HelloImpl.java | 33 - .../src/test/java/helloworld/HelloWorldImpl.java | 38 - .../test/java/helloworld/HelloWorldService.java | 28 - .../java/test/ContributionCycleTestCaseFIXME.java | 121 -- .../test/ContributionMultipleTestCaseFIXME.java | 131 -- .../src/test/java/test/ContributionTestCase.java | 145 -- .../META-INF/sca-contribution.xml | 26 - .../contribution-cycle-export/hello.composite | 31 - .../META-INF/sca-contribution.xml | 26 - .../helloworld_one.composite | 35 - .../META-INF/sca-contribution.xml | 25 - .../resources/contribution-export/hello.composite | 31 - .../META-INF/sca-contribution.xml | 26 - .../helloworld_one.composite | 35 - .../META-INF/sca-contribution.xml | 26 - .../helloworld_two.composite | 35 - java/sca/itest/contribution/pom.xml | 52 - .../src/main/java/calculator/AddService.java | 32 - .../src/main/java/calculator/AddServiceImpl.java | 30 - .../src/main/java/calculator/CalculatorClient.java | 46 - .../main/java/calculator/CalculatorService.java | 35 - .../java/calculator/CalculatorServiceImpl.java | 70 - .../src/main/java/calculator/DivideService.java | 32 - .../main/java/calculator/DivideServiceImpl.java | 30 - .../src/main/java/calculator/MultiplyService.java | 33 - .../main/java/calculator/MultiplyServiceImpl.java | 30 - .../src/main/java/calculator/SubtractService.java | 33 - .../main/java/calculator/SubtractServiceImpl.java | 30 - .../src/main/resources/ContributionTest.composite | 24 - .../main/resources/calculator/Calculator.composite | 51 - .../main/resources/calculator/sca-contribution.xml | 24 - .../contribution/ContributionServiceTestCase.java | 218 --- .../resources/deployables/sample-calculator.jar | Bin 26901 -> 0 bytes .../resources/repository/sample-calculator.jar | Bin 26901 -> 0 bytes java/sca/itest/conversations-ws/pom.xml | 60 - .../itest/conversational/BusinessException.java | 41 - .../conversational/ConversationIdService.java | 29 - .../conversational/ConversationalCallback.java | 50 - .../itest/conversational/ConversationalClient.java | 50 - .../ConversationalReferenceClient.java | 36 - .../conversational/ConversationalService.java | 58 - ...ersationalServiceNonConversationalCallback.java | 59 - .../conversational/NonConversationalCallback.java | 42 - .../impl/ConversationAgeComponentImpl.java | 76 - .../impl/ConversationIdComponentImpl.java | 48 - .../impl/ConversationMaxIdleComponentImpl.java | 76 - .../impl/ConversationalClientStatefulImpl.java | 322 ----- ...lientStatefulNonConversationalCallbackImpl.java | 311 ----- .../impl/ConversationalClientStatelessImpl.java | 318 ----- .../impl/ConversationalReferenceClientImpl.java | 43 - .../impl/ConversationalServiceRequestImpl.java | 124 -- .../impl/ConversationalServiceStatefulImpl.java | 119 -- ...rviceStatefulNonConversationalCallbackImpl.java | 118 -- .../impl/ConversationalServiceStatelessImpl.java | 122 -- .../ConversationalServiceStatelessScopeImpl.java | 94 -- .../Conversational/META-INF/sca-contribution.xml | 22 - .../Conversational/conversational.composite | 169 --- .../ConversationalServiceStateful.wsdl | 383 ------ .../META-INF/sca-contribution.xml | 22 - .../conversationalWSDL.composite | 46 - .../conversational/ConversationWSDLTestCase.java | 75 - .../NonConversationalCallbackTestCase.java | 198 --- .../itest/conversational/RequestScopeTestCase.java | 209 --- .../conversational/StatefulStatefulTestCase.java | 193 --- .../conversational/StatefulStatelessTestCase.java | 193 --- .../conversational/StatelessStatefulTestCase.java | 205 --- .../conversational/StatelessStatelessTestCase.java | 192 --- java/sca/itest/corba/pom.xml | 169 --- .../sca/test/corba/ScenarioFiveTestCase.java | 51 - .../sca/test/corba/ScenarioFourTestCase.java | 149 -- .../sca/test/corba/ScenarioOneTestCase.java | 371 ----- .../sca/test/corba/ScenarioSixTestCase.java | 228 --- .../sca/test/corba/ScenarioThreeTestCase.java | 130 -- .../sca/test/corba/ScenarioTwoTestCase.java | 139 -- .../tuscany/sca/test/corba/TestCorbaHost.java | 56 - .../test/corba/TestCorbaHostModuleActivator.java | 41 - .../sca/test/corba/generated/AnnotatedStruct.java | 43 - .../corba/generated/AnnotatedStructHelper.java | 97 -- .../corba/generated/AnnotatedStructHolder.java | 57 - .../tuscany/sca/test/corba/generated/Color.java | 61 - .../sca/test/corba/generated/ColorHelper.java | 72 - .../sca/test/corba/generated/ColorHolder.java | 57 - .../sca/test/corba/generated/InnerStruct.java | 47 - .../test/corba/generated/InnerStructHelper.java | 112 -- .../test/corba/generated/InnerStructHolder.java | 57 - .../sca/test/corba/generated/InnerUnion.java | 112 -- .../sca/test/corba/generated/InnerUnionHelper.java | 106 -- .../sca/test/corba/generated/InnerUnionHolder.java | 38 - .../test/corba/generated/LongSequenceHelper.java | 79 -- .../test/corba/generated/LongSequenceHolder.java | 58 - .../sca/test/corba/generated/RichStruct.java | 47 - .../sca/test/corba/generated/RichStructHelper.java | 110 -- .../sca/test/corba/generated/RichStructHolder.java | 57 - .../sca/test/corba/generated/RichUnion.java | 177 --- .../sca/test/corba/generated/RichUnionHelper.java | 157 --- .../sca/test/corba/generated/RichUnionHolder.java | 38 - .../sca/test/corba/generated/ScenarioOne.java | 32 - .../test/corba/generated/ScenarioOneHelper.java | 104 -- .../test/corba/generated/ScenarioOneHolder.java | 57 - .../corba/generated/ScenarioOneOperations.java | 33 - .../sca/test/corba/generated/ScenarioSix.java | 32 - .../test/corba/generated/ScenarioSixHelper.java | 104 -- .../test/corba/generated/ScenarioSixHolder.java | 57 - .../corba/generated/ScenarioSixOperations.java | 35 - .../sca/test/corba/generated/ScenarioTwo.java | 34 - .../test/corba/generated/ScenarioTwoHelper.java | 106 -- .../test/corba/generated/ScenarioTwoHolder.java | 59 - .../corba/generated/ScenarioTwoOperations.java | 36 - .../test/corba/generated/StringArrayHelper.java | 95 -- .../test/corba/generated/StringArrayHolder.java | 58 - .../test/corba/generated/StringSequenceHelper.java | 81 -- .../test/corba/generated/StringSequenceHolder.java | 58 - .../corba/generated/TwoDimLongSequenceHelper.java | 83 -- .../corba/generated/TwoDimLongSequenceHolder.java | 58 - .../test/corba/generated/UnexpectedException.java | 52 - .../corba/generated/UnexpectedExceptionHelper.java | 98 -- .../corba/generated/UnexpectedExceptionHolder.java | 57 - .../sca/test/corba/generated/WrongColor.java | 55 - .../sca/test/corba/generated/WrongColorHelper.java | 105 -- .../sca/test/corba/generated/WrongColorHolder.java | 57 - .../test/corba/generated/_ScenarioOneImplBase.java | 91 -- .../sca/test/corba/generated/_ScenarioOneStub.java | 84 -- .../test/corba/generated/_ScenarioSixImplBase.java | 105 -- .../sca/test/corba/generated/_ScenarioSixStub.java | 119 -- .../test/corba/generated/_ScenarioTwoImplBase.java | 93 -- .../sca/test/corba/generated/_ScenarioTwoStub.java | 99 -- .../tuscany/sca/test/corba/types/ScenarioFive.java | 33 - .../test/corba/types/ScenarioFiveComponent.java | 41 - .../sca/test/corba/types/ScenarioFiveImpl.java | 32 - .../tuscany/sca/test/corba/types/ScenarioFour.java | 38 - .../test/corba/types/ScenarioFourComponent.java | 41 - .../test/corba/types/ScenarioFourException.java | 41 - .../sca/test/corba/types/ScenarioFourImpl.java | 44 - .../sca/test/corba/types/ScenarioFourStruct.java | 40 - .../sca/test/corba/types/ScenarioOneComponent.java | 46 - .../sca/test/corba/types/ScenarioOneServant.java | 45 - .../sca/test/corba/types/ScenarioSixServant.java | 46 - .../sca/test/corba/types/ScenarioTwoServant.java | 42 - .../sca/test/corba/types/TAnnotatedStruct.java | 40 - .../tuscany/sca/test/corba/types/TColor.java | 62 - .../tuscany/sca/test/corba/types/TInnerStruct.java | 42 - .../tuscany/sca/test/corba/types/TInnerUnion.java | 59 - .../tuscany/sca/test/corba/types/TRichStruct.java | 42 - .../tuscany/sca/test/corba/types/TRichUnion.java | 95 -- .../tuscany/sca/test/corba/types/TScenarioOne.java | 33 - .../test/corba/types/TScenarioOneComponent.java | 43 - .../sca/test/corba/types/TScenarioOneServant.java | 44 - .../tuscany/sca/test/corba/types/TScenarioSix.java | 37 - .../test/corba/types/TScenarioSixComponent.java | 41 - .../sca/test/corba/types/TScenarioSixServant.java | 42 - .../sca/test/corba/types/TScenarioThree.java | 42 - .../test/corba/types/TScenarioThreeComponent.java | 41 - .../test/corba/types/TScenarioThreeServant.java | 52 - .../tuscany/sca/test/corba/types/TScenarioTwo.java | 32 - .../test/corba/types/TScenarioTwoComponent.java | 41 - .../sca/test/corba/types/TScenarioTwoServant.java | 38 - .../org.apache.tuscany.sca.core.ModuleActivator | 18 - .../src/test/resources/ScenarioFive.composite | 41 - .../src/test/resources/ScenarioFour.composite | 56 - .../corba/src/test/resources/ScenarioOne.composite | 111 -- .../corba/src/test/resources/ScenarioSix.composite | 41 - .../src/test/resources/ScenarioThree.composite | 43 - .../corba/src/test/resources/ScenarioTwo.composite | 43 - .../corba/src/test/resources/itest_scenario.idl | 110 -- .../corba/src/test/resources/scenariofour.xsd | 31 - java/sca/itest/databindings/common/pom.xml | 126 -- .../tuscany/sca/itest/generate/Generate.java | 181 --- .../resources/generate/DatabindingTestCase.java.vm | 112 -- .../src/main/resources/generate/Greeter.wsdl.vm | 103 -- .../main/resources/generate/GreeterService.java.vm | 53 - .../generate/GreeterServiceClient.java.vm | 42 - .../generate/GreeterServiceClientImpl.java.vm | 65 - .../resources/generate/GreeterServiceImpl.java.vm | 55 - .../src/main/resources/generate/generate.xsd | 61 - .../common/src/main/resources/wsdl/Dummy.txt | 4 - .../common/src/main/resources/xsd/Annotation.xml | 24 - .../common/src/main/resources/xsd/Annotation.xsd | 38 - .../common/src/main/resources/xsd/Attribute.xml | 24 - .../common/src/main/resources/xsd/Attribute.xsd | 39 - .../src/main/resources/xsd/AttributeReference.xml | 24 - .../src/main/resources/xsd/AttributeReference.xsd | 40 - .../resources/xsd/AttributeWithDefaultValue.xml | 24 - .../resources/xsd/AttributeWithDefaultValue.xsd | 38 - .../main/resources/xsd/AttributeWithFixedValue.xml | 24 - .../main/resources/xsd/AttributeWithFixedValue.xsd | 38 - .../resources/xsd/AttributeWithSDOAliasName.xml | 24 - .../resources/xsd/AttributeWithSDOAliasName.xsd | 38 - .../resources/xsd/AttributeWithSDODataType.xml | 24 - .../resources/xsd/AttributeWithSDODataType.xsd | 38 - .../main/resources/xsd/AttributeWithSDOName.xml | 24 - .../main/resources/xsd/AttributeWithSDOName.xsd | 38 - ...ibuteWithSDOPropertySDOOppositePropertyType.xml | 24 - ...ibuteWithSDOPropertySDOOppositePropertyType.xsd | 38 - .../resources/xsd/AttributeWithSDOPropertyType.xml | 24 - .../resources/xsd/AttributeWithSDOPropertyType.xsd | 38 - .../main/resources/xsd/AttributeWithSDOString.xml | 24 - .../main/resources/xsd/AttributeWithSDOString.xsd | 38 - .../main/resources/xsd/BuiltInAnySimpleType.xml | 24 - .../main/resources/xsd/BuiltInAnySimpleType.xsd | 31 - .../src/main/resources/xsd/BuiltInAnyType.xml | 24 - .../src/main/resources/xsd/BuiltInAnyType.xsd | 31 - .../src/main/resources/xsd/BuiltInAnyURI.xml | 24 - .../src/main/resources/xsd/BuiltInAnyURI.xsd | 31 - .../src/main/resources/xsd/BuiltInBase64Binary.xml | 24 - .../src/main/resources/xsd/BuiltInBase64Binary.xsd | 31 - .../src/main/resources/xsd/BuiltInBoolean.xml | 27 - .../src/main/resources/xsd/BuiltInBoolean.xsd | 31 - .../common/src/main/resources/xsd/BuiltInByte.xml | 25 - .../common/src/main/resources/xsd/BuiltInByte.xsd | 31 - .../common/src/main/resources/xsd/BuiltInDate.xml | 24 - .../common/src/main/resources/xsd/BuiltInDate.xsd | 31 - .../src/main/resources/xsd/BuiltInDateTime.xml | 24 - .../src/main/resources/xsd/BuiltInDateTime.xsd | 31 - .../src/main/resources/xsd/BuiltInDecimal.xml | 23 - .../src/main/resources/xsd/BuiltInDecimal.xsd | 31 - .../src/main/resources/xsd/BuiltInDouble.xml | 25 - .../src/main/resources/xsd/BuiltInDouble.xsd | 31 - .../src/main/resources/xsd/BuiltInDuration.xml | 24 - .../src/main/resources/xsd/BuiltInDuration.xsd | 31 - .../common/src/main/resources/xsd/BuiltInFloat.xml | 24 - .../common/src/main/resources/xsd/BuiltInFloat.xsd | 31 - .../common/src/main/resources/xsd/BuiltInGDay.xml | 24 - .../common/src/main/resources/xsd/BuiltInGDay.xsd | 31 - .../src/main/resources/xsd/BuiltInGMonth.xml | 24 - .../src/main/resources/xsd/BuiltInGMonth.xsd | 31 - .../src/main/resources/xsd/BuiltInGMonthDay.xml | 24 - .../src/main/resources/xsd/BuiltInGMonthDay.xsd | 31 - .../common/src/main/resources/xsd/BuiltInGYear.xml | 24 - .../common/src/main/resources/xsd/BuiltInGYear.xsd | 31 - .../src/main/resources/xsd/BuiltInGYearMonth.xml | 24 - .../src/main/resources/xsd/BuiltInGYearMonth.xsd | 31 - .../src/main/resources/xsd/BuiltInHexBinary.xml | 24 - .../src/main/resources/xsd/BuiltInHexBinary.xsd | 31 - .../common/src/main/resources/xsd/BuiltInID.xml | 24 - .../common/src/main/resources/xsd/BuiltInID.xsd | 31 - .../common/src/main/resources/xsd/BuiltInIDREF.xml | 24 - .../common/src/main/resources/xsd/BuiltInIDREF.xsd | 31 - .../src/main/resources/xsd/BuiltInIDREFS.xml | 24 - .../src/main/resources/xsd/BuiltInIDREFS.xsd | 31 - .../common/src/main/resources/xsd/BuiltInInt.xml | 25 - .../common/src/main/resources/xsd/BuiltInInt.xsd | 31 - .../src/main/resources/xsd/BuiltInInteger.xml | 25 - .../src/main/resources/xsd/BuiltInInteger.xsd | 31 - .../src/main/resources/xsd/BuiltInLanguage.xml | 24 - .../src/main/resources/xsd/BuiltInLanguage.xsd | 31 - .../common/src/main/resources/xsd/BuiltInLong.xml | 25 - .../common/src/main/resources/xsd/BuiltInLong.xsd | 33 - .../src/main/resources/xsd/BuiltInNCName.xml | 24 - .../src/main/resources/xsd/BuiltInNCName.xsd | 31 - .../src/main/resources/xsd/BuiltInNMTOKEN.xml | 24 - .../src/main/resources/xsd/BuiltInNMTOKEN.xsd | 31 - .../src/main/resources/xsd/BuiltInNMTOKENS.xml | 24 - .../src/main/resources/xsd/BuiltInNMTOKENS.xsd | 31 - .../src/main/resources/xsd/BuiltInNOTATION.xml | 24 - .../src/main/resources/xsd/BuiltInNOTATION.xsd | 39 - .../common/src/main/resources/xsd/BuiltInName.xml | 24 - .../common/src/main/resources/xsd/BuiltInName.xsd | 31 - .../main/resources/xsd/BuiltInNegativeInteger.xml | 24 - .../main/resources/xsd/BuiltInNegativeInteger.xsd | 31 - .../resources/xsd/BuiltInNonNegativeInteger.xml | 24 - .../resources/xsd/BuiltInNonNegativeInteger.xsd | 31 - .../resources/xsd/BuiltInNonPositiveInteger.xml | 24 - .../resources/xsd/BuiltInNonPositiveInteger.xsd | 31 - .../main/resources/xsd/BuiltInNormalizedString.xml | 24 - .../main/resources/xsd/BuiltInNormalizedString.xsd | 31 - .../main/resources/xsd/BuiltInPositiveInteger.xml | 24 - .../main/resources/xsd/BuiltInPositiveInteger.xsd | 31 - .../common/src/main/resources/xsd/BuiltInQName.xml | 24 - .../common/src/main/resources/xsd/BuiltInQName.xsd | 31 - .../common/src/main/resources/xsd/BuiltInShort.xml | 25 - .../common/src/main/resources/xsd/BuiltInShort.xsd | 31 - .../src/main/resources/xsd/BuiltInString.xml | 24 - .../src/main/resources/xsd/BuiltInString.xsd | 31 - .../common/src/main/resources/xsd/BuiltInTime.xml | 24 - .../common/src/main/resources/xsd/BuiltInTime.xsd | 31 - .../common/src/main/resources/xsd/BuiltInToken.xml | 24 - .../common/src/main/resources/xsd/BuiltInToken.xsd | 31 - .../src/main/resources/xsd/BuiltInUnsignedByte.xml | 25 - .../src/main/resources/xsd/BuiltInUnsignedByte.xsd | 31 - .../src/main/resources/xsd/BuiltInUnsignedInt.xml | 25 - .../src/main/resources/xsd/BuiltInUnsignedInt.xsd | 31 - .../src/main/resources/xsd/BuiltInUnsignedLong.xml | 25 - .../src/main/resources/xsd/BuiltInUnsignedLong.xsd | 31 - .../main/resources/xsd/BuiltInUnsignedShort.xml | 25 - .../main/resources/xsd/BuiltInUnsignedShort.xsd | 31 - ...lexTypeComplexContentRestrictingComplexType.xml | 26 - ...lexTypeComplexContentRestrictingComplexType.xsd | 44 - .../xsd/ComplexTypeExtendingComplexType.xml | 27 - .../xsd/ComplexTypeExtendingComplexType.xsd | 43 - .../xsd/ComplexTypeExtendingSimpleType.xml | 24 - .../xsd/ComplexTypeExtendingSimpleType.xsd | 41 - ...plexTypeSimpleContentRestrictingComplexType.xml | 24 - ...plexTypeSimpleContentRestrictingComplexType.xsd | 41 - .../main/resources/xsd/ComplexTypeWithAbstract.xml | 27 - .../main/resources/xsd/ComplexTypeWithAbstract.xsd | 47 - .../main/resources/xsd/ComplexTypeWithCDATA.xml | 30 - .../main/resources/xsd/ComplexTypeWithCDATA.xsd | 39 - .../main/resources/xsd/ComplexTypeWithContent.xml | 26 - .../main/resources/xsd/ComplexTypeWithContent.xsd | 37 - .../main/resources/xsd/ComplexTypeWithMixed.xml | 29 - .../main/resources/xsd/ComplexTypeWithMixed.xsd | 39 - .../xsd/ComplexTypeWithOpenAttributes.xml | 24 - .../xsd/ComplexTypeWithOpenAttributes.xsd | 42 - .../resources/xsd/ComplexTypeWithOpenContent.xml | 31 - .../resources/xsd/ComplexTypeWithOpenContent.xsd | 39 - .../xsd/ComplexTypeWithOppositeProperty.xml | 30 - .../xsd/ComplexTypeWithOppositeProperty.xsd | 59 - .../resources/xsd/ComplexTypeWithSDOAliasName.xml | 26 - .../resources/xsd/ComplexTypeWithSDOAliasName.xsd | 38 - .../main/resources/xsd/ComplexTypeWithSDOName.xml | 26 - .../main/resources/xsd/ComplexTypeWithSDOName.xsd | 38 - .../resources/xsd/ComplexTypeWithSDOSequence.xml | 26 - .../resources/xsd/ComplexTypeWithSDOSequence.xsd | 40 - .../resources/xsd/ComplexTypeWithoutContent.xml | 24 - .../resources/xsd/ComplexTypeWithoutContent.xsd | 33 - .../main/resources/xsd/ComplexTypeWithoutName.xml | 26 - .../main/resources/xsd/ComplexTypeWithoutName.xsd | 39 - .../src/main/resources/xsd/DefaultNamespace.xml | 23 - .../src/main/resources/xsd/DefaultNamespace.xsd | 32 - .../common/src/main/resources/xsd/ElementInAll.xml | 27 - .../common/src/main/resources/xsd/ElementInAll.xsd | 40 - .../src/main/resources/xsd/ElementInChoice.xml | 25 - .../src/main/resources/xsd/ElementInChoice.xsd | 48 - .../xsd/ElementOfSDOChangeSummaryType.xml | 29 - .../xsd/ElementOfSDOChangeSummaryType.xsd | 34 - .../xsd/ElementOfSimpleTypeWithDefault.xml | 24 - .../xsd/ElementOfSimpleTypeWithDefault.xsd | 31 - .../resources/xsd/ElementOfSimpleTypeWithFixed.xml | 24 - .../resources/xsd/ElementOfSimpleTypeWithFixed.xsd | 31 - .../xsd/ElementOfSimpleTypeWithSDODataType.xml | 24 - .../xsd/ElementOfSimpleTypeWithSDODataType.xsd | 33 - ...mentOfSimpleTypeWithSDOOppositePropertyType.xml | 24 - ...mentOfSimpleTypeWithSDOOppositePropertyType.xsd | 33 - .../xsd/ElementOfSimpleTypeWithSDOPropertyType.xml | 24 - .../xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd | 32 - .../xsd/ElementOfSimpleTypeWithSDOString.xml | 24 - .../xsd/ElementOfSimpleTypeWithSDOString.xsd | 32 - .../resources/xsd/ElementSubstitutionGroupBase.xml | 40 - .../resources/xsd/ElementSubstitutionGroupBase.xsd | 52 - .../main/resources/xsd/ElementWithMaxOccurs.xml | 25 - .../main/resources/xsd/ElementWithMaxOccurs.xsd | 31 - .../src/main/resources/xsd/ElementWithNillable.xml | 24 - .../src/main/resources/xsd/ElementWithNillable.xsd | 31 - .../main/resources/xsd/ElementWithSDOAliasName.xml | 24 - .../main/resources/xsd/ElementWithSDOAliasName.xsd | 32 - .../src/main/resources/xsd/ElementWithSDOName.xml | 24 - .../src/main/resources/xsd/ElementWithSDOName.xsd | 32 - .../resources/xsd/GlobalElementComplexType.xml | 24 - .../resources/xsd/GlobalElementComplexType.xsd | 31 - .../main/resources/xsd/GlobalElementSimpleType.xml | 24 - .../main/resources/xsd/GlobalElementSimpleType.xsd | 26 - .../common/src/main/resources/xsd/Import.xml | 30 - .../common/src/main/resources/xsd/Import.xsd | 40 - .../src/main/resources/xsd/ImportedSchema.xsd | 33 - .../common/src/main/resources/xsd/Include.xml | 24 - .../common/src/main/resources/xsd/Include.xsd | 36 - .../common/src/main/resources/xsd/Interop.xsd | 138 -- .../common/src/main/resources/xsd/Notation.xml | 24 - .../common/src/main/resources/xsd/Notation.xsd | 35 - .../common/src/main/resources/xsd/Person.xsd | 30 - .../src/main/resources/xsd/SDOJavaPackage.xml | 25 - .../src/main/resources/xsd/SDOJavaPackage.xsd | 39 - .../main/resources/xsd/SimpleTypeWithAbstract.xml | 24 - .../main/resources/xsd/SimpleTypeWithAbstract.xsd | 40 - .../xsd/SimpleTypeWithExtendedInstanceClass.xml | 24 - .../xsd/SimpleTypeWithExtendedInstanceClass.xsd | 36 - .../resources/xsd/SimpleTypeWithInstanceClass.xml | 24 - .../resources/xsd/SimpleTypeWithInstanceClass.xsd | 37 - .../src/main/resources/xsd/SimpleTypeWithList.xml | 24 - .../src/main/resources/xsd/SimpleTypeWithList.xsd | 37 - .../src/main/resources/xsd/SimpleTypeWithName.xml | 24 - .../src/main/resources/xsd/SimpleTypeWithName.xsd | 36 - .../main/resources/xsd/SimpleTypeWithSDOName.xml | 24 - .../main/resources/xsd/SimpleTypeWithSDOName.xsd | 37 - .../src/main/resources/xsd/SimpleTypeWithUnion.xml | 25 - .../src/main/resources/xsd/SimpleTypeWithUnion.xsd | 46 - .../main/resources/xsd/SimpleTypeWithoutName.xml | 26 - .../main/resources/xsd/SimpleTypeWithoutName.xsd | 38 - .../src/main/resources/xsd/TargetNamespace.xml | 24 - .../src/main/resources/xsd/TargetNamespace.xsd | 34 - .../common/src/main/resources/xsd/datagraph.xsd | 88 -- .../common/src/main/resources/xsd/sdoJava.xsd | 88 -- .../common/src/main/resources/xsd/sdoModel.xsd | 221 --- .../sca/itest/generate/GenerateTestCase.java | 49 - java/sca/itest/databindings/config.png | Bin 31222 -> 0 bytes java/sca/itest/databindings/config.svg | 117 -- java/sca/itest/databindings/databinding.png | Bin 14106 -> 0 bytes java/sca/itest/databindings/databinding.svg | 242 ---- java/sca/itest/databindings/interop.png | Bin 23179 -> 0 bytes java/sca/itest/databindings/interop.svg | 352 ----- java/sca/itest/databindings/interop/pom.xml | 223 --- .../generate/InteropDatabindingTestCase.java.vm | 113 -- .../main/resources/generate/JAXBGreeter.wsdl.vm | 103 -- .../src/main/resources/generate/SDOGreeter.wsdl.vm | 103 -- .../src/main/resources/generate/generate.xml | 159 --- .../resources/generate/interopgreeter.composite.vm | 78 -- java/sca/itest/databindings/jaxb-bottom-up/pom.xml | 239 ---- .../itest/databindings/jaxb/AClientService.java | 29 - .../sca/itest/databindings/jaxb/AService.java | 32 - .../tuscany/sca/itest/databindings/jaxb/Bean1.java | 63 - .../sca/itest/databindings/jaxb/Bean10.java | 25 - .../sca/itest/databindings/jaxb/Bean11.java | 25 - .../tuscany/sca/itest/databindings/jaxb/Bean2.java | 56 - .../tuscany/sca/itest/databindings/jaxb/Bean3.java | 56 - .../sca/itest/databindings/jaxb/Bean31.java | 56 - .../databindings/jaxb/GenericsLocalService.java | 42 - .../itest/databindings/jaxb/GenericsService.java | 30 - .../databindings/jaxb/GenericsServiceClient.java | 43 - .../databindings/jaxb/HelloLocalServiceSimple.java | 37 - .../databindings/jaxb/HelloServiceSimple.java | 29 - .../jaxb/HelloServiceSimpleClient.java | 38 - .../databindings/jaxb/PrimitivesLocalService.java | 47 - .../itest/databindings/jaxb/PrimitivesService.java | 29 - .../databindings/jaxb/PrimitivesServiceClient.java | 48 - .../jaxb/StandardTypesLocalService.java | 78 -- .../databindings/jaxb/StandardTypesService.java | 30 - .../jaxb/StandardTypesServiceClient.java | 79 -- .../databindings/jaxb/impl/AClientServiceImpl.java | 38 - .../itest/databindings/jaxb/impl/AServiceImpl.java | 33 - .../jaxb/impl/GenericsLocalServiceClientImpl.java | 77 -- .../jaxb/impl/GenericsServiceClientImpl.java | 40 - .../jaxb/impl/GenericsServiceImpl.java | 69 - .../jaxb/impl/GenericsTransformer.java | 125 -- .../impl/HelloLocalServiceSimpleClientImpl.java | 73 - .../jaxb/impl/HelloServiceSimpleClientImpl.java | 38 - .../jaxb/impl/HelloServiceSimpleImpl.java | 86 -- .../impl/PrimitivesLocalServiceClientImpl.java | 138 -- .../jaxb/impl/PrimitivesServiceClientImpl.java | 38 - .../jaxb/impl/PrimitivesServiceImpl.java | 151 -- .../impl/StandardTypesLocalServiceClientImpl.java | 157 --- .../jaxb/impl/StandardTypesServiceClientImpl.java | 38 - .../jaxb/impl/StandardTypesServiceImpl.java | 208 --- .../jaxb/impl/StandardTypesTransformer.java | 144 -- .../src/main/resources/aservice.wsdl | 127 -- .../src/main/resources/doclitbarewsdl.composite | 37 - .../src/main/resources/generics-service.composite | 69 - .../src/main/resources/helloservice.composite | 65 - .../src/main/resources/primitivesservice.composite | 66 - .../resources/standard-types-service.composite | 66 - .../databindings/jaxb/DatabindingTestCase.java | 339 ----- .../databindings/jaxb/DocLitBareWsdlTestCase.java | 67 - .../jaxb/GenericsDatabindingTestCase.java | 484 ------- .../jaxb/PrimitivesDatabindingTestCase.java | 776 ----------- .../jaxb/StandardTypesDatabindingTestCase.java | 1438 ------------------- java/sca/itest/databindings/jaxb-top-down/pom.xml | 194 --- .../sca/itest/databindings/jaxb/HelloService.java | 42 - .../databindings/jaxb/HelloServiceClient.java | 41 - .../itest/databindings/jaxb/PrimitivesService.java | 51 - .../databindings/jaxb/PrimitivesServiceClient.java | 50 - .../databindings/jaxb/StandardTypesService.java | 84 -- .../jaxb/StandardTypesServiceClient.java | 81 -- .../jaxb/impl/HelloServiceClientImpl.java | 73 - .../databindings/jaxb/impl/HelloServiceImpl.java | 86 -- .../jaxb/impl/PrimitivesServiceClientImpl.java | 139 -- .../jaxb/impl/PrimitivesServiceImpl.java | 151 -- .../jaxb/impl/StandardTypesServiceClientImpl.java | 159 --- .../jaxb/impl/StandardTypesServiceImpl.java | 207 --- .../jaxb/impl/StandardTypesTransformer.java | 142 -- .../main/resources/wsdl/wrapped/hello-service.wsdl | 371 ----- .../resources/wsdl/wrapped/helloservice.composite | 80 -- .../resources/wsdl/wrapped/primitives-service.wsdl | 927 ------------- .../wsdl/wrapped/primitivesservice.composite | 80 -- .../wsdl/wrapped/standard-types-service.composite | 80 -- .../wsdl/wrapped/standard-types-service.wsdl | 1155 ---------------- .../jaxb/topdown/DatabindingTestCase.java | 349 ----- .../topdown/PrimitivesDatabindingTestCase.java | 848 ------------ .../topdown/StandardTypesDatabindingTestCase.java | 1450 -------------------- java/sca/itest/databindings/jaxbgen/pom.xml | 262 ---- .../src/main/resources/generate/generate.xml | 172 --- .../jaxbgen/src/main/resources/greeter.composite | 49 - java/sca/itest/databindings/pom.xml | 47 - java/sca/itest/databindings/readme.html | 157 --- java/sca/itest/databindings/sdogen/pom.xml | 251 ---- .../src/main/resources/generate/generate.xml | 170 --- .../main/resources/generate/greeter.composite.vm | 56 - java/sca/itest/definitions-multiple/pom.xml | 51 - .../src/main/java/calculator/AddService.java | 34 - .../src/main/java/calculator/AddServiceImpl.java | 35 - .../main/java/calculator/CalculatorService.java | 35 - .../java/calculator/CalculatorServiceImpl.java | 75 - .../src/main/java/calculator/DivideService.java | 33 - .../main/java/calculator/DivideServiceImpl.java | 35 - .../src/main/java/calculator/MultiplyService.java | 28 - .../main/java/calculator/MultiplyServiceImpl.java | 35 - .../src/main/java/calculator/PolicyQNames.java | 43 - .../src/main/java/calculator/SubtractService.java | 28 - .../main/java/calculator/SubtractServiceImpl.java | 35 - .../contrib3/META-INF/sca-contribution.xml | 22 - .../src/main/resources/contrib3/definitions.xml | 37 - .../sca/itest/MultipleDefinitionsTestCase.java | 72 - .../java/org/apache/tuscany/sca/itest/Policy.java | 33 - .../tuscany/sca/itest/TestPolicyProcessor.java | 83 -- ...ca.contribution.processor.StAXArtifactProcessor | 19 - .../test/resources/contrib1/Calculator.composite | 61 - .../contrib1/META-INF/sca-contribution.xml | 22 - .../src/test/resources/contrib1/definitions.xml | 33 - .../resources/contrib1/definitions/definitions.xml | 49 - .../src/test/resources/contrib2/definitions.xml | 32 - java/sca/itest/domain/pom.xml | 100 -- .../src/main/java/calculator/AddService.java | 31 - .../src/main/java/calculator/AddServiceImpl.java | 31 - .../main/java/calculator/AddServiceUpdateImpl.java | 31 - .../main/java/calculator/CalculatorService.java | 38 - .../java/calculator/CalculatorServiceImpl.java | 74 - .../src/main/java/calculator/DivideService.java | 28 - .../main/java/calculator/DivideServiceImpl.java | 30 - .../src/main/java/calculator/MultiplyService.java | 28 - .../main/java/calculator/MultiplyServiceImpl.java | 30 - .../src/main/java/calculator/SubtractService.java | 31 - .../main/java/calculator/SubtractServiceImpl.java | 31 - .../resources/contributionA/Calculator.composite | 44 - .../contributionA/META-INF/sca-contribution.xml | 24 - .../META-INF/sca-deployables/Calculator.composite | 45 - .../META-INF/sca-deployables/Calculator.composite | 32 - .../contributionDependent/Calculator.composite | 36 - .../META-INF/sca-contribution.xml | 24 - .../contributionPrimary/Calculator.composite | 57 - .../META-INF/sca-contribution.xml | 25 - .../sca/itest/domain/ContributionSPIsTestCase.java | 279 ---- java/sca/itest/exceptions-cross-binding-ws/pom.xml | 243 ---- .../test/exceptions/impl/StockExchangeJaxB.java | 71 - .../sca/test/exceptions/impl/StockTraderSDO.java | 39 - .../test/exceptions/impl/StockTraderSDOImpl.java | 136 -- .../sdohandgen/InvalidSymbolSDOException.java | 84 -- .../sdohandgen/MarketClosedSDOException.java | 76 - .../exceptions/sdohandgen/StockExceptionTest.java | 45 - .../src/main/resources/ExceptionTest.composite | 23 - .../src/main/resources/intracomposite.composite | 42 - .../main/resources/wsdl/StockExceptionTest.wsdl | 148 -- .../src/main/resources/xsd/StockExceptionTest.xsd | 65 - .../test/exceptions/IntraCompositeTestCase.java | 102 -- java/sca/itest/exceptions-cross-binding/pom.xml | 234 ---- .../exceptions/impl/StockExceptionTestJAXB.java | 31 - .../test/exceptions/impl/StockExchangeJaxB.java | 76 - .../sca/test/exceptions/impl/StockTraderSDO.java | 37 - .../test/exceptions/impl/StockTraderSDOImpl.java | 119 -- .../sdohandgen/InvalidSymbolSDOException.java | 84 -- .../sdohandgen/MarketClosedSDOException.java | 75 - .../exceptions/sdohandgen/StockExceptionTest.java | 45 - .../src/main/resources/ExceptionTest.composite | 25 - .../src/main/resources/intracomposite.composite | 35 - .../resources/wsdl.sdo/StockExceptionTest.wsdl | 141 -- .../main/resources/wsdl/StockExceptionTest.wsdl | 148 -- .../src/main/resources/xsd/StockExceptionTest.xsd | 65 - .../test/exceptions/IntraCompositeTestCase.java | 93 -- java/sca/itest/exceptions-simple-ws/pom.xml | 59 - .../main/java/com/example/BusinessException.java | 43 - .../java/com/example/BusinessExceptionMinimal.java | 28 - .../src/main/java/com/example/ExampleClient.java | 23 - .../main/java/com/example/ExampleClientImpl.java | 44 - .../java/com/example/ExampleClientMinimalImpl.java | 54 - .../src/main/java/com/example/ExampleService.java | 27 - .../main/java/com/example/ExampleServiceImpl.java | 26 - .../java/com/example/ExampleServiceMinimal.java | 28 - .../com/example/ExampleServiceMinimalImpl.java | 30 - .../src/main/resources/example.composite | 56 - .../src/main/resources/wsdl/ExampleService.wsdl | 126 -- .../java/com/example/ExampleMinimalTestCase.java | 44 - .../src/test/java/com/example/ExampleTestCase.java | 44 - java/sca/itest/extended-api/pom.xml | 51 - .../tuscany/sca/test/extended/BasicService.java | 26 - .../tuscany/sca/test/extended/MathService.java | 25 - .../sca/test/extended/impl/BasicServiceImpl.java | 45 - .../sca/test/extended/impl/MathServiceImpl.java | 31 - .../src/main/resources/BasicService.composite | 29 - .../src/main/resources/MathService.composite | 29 - .../sca/test/extended/ServiceLocateTestCase.java | 73 - java/sca/itest/interop-soap-client/pom.xml | 126 -- .../LoopbackInteropDocServiceComponentImpl.java | 46 - .../src/main/resources/default.composite | 35 - .../src/main/resources/wsdl/interopdoc.wsdl | 195 --- .../interop/client/InteropDocClientTestCase.java | 144 -- java/sca/itest/interop-soap-round2-client/pom.xml | 124 -- .../test/interop/client/InteropTestDocLit.java | 44 - .../src/main/resources/default.composite | 38 - .../src/main/resources/wsdl/interoptestdoclit.wsdl | 155 --- .../interop/client/InteropTestDocLitTestCase.java | 133 -- java/sca/itest/interop-soap-service/pom.xml | 134 -- .../server/InteropDocServiceComponentImpl.java | 47 - .../src/main/resources/wsdl/interopdoc.wsdl | 180 --- .../src/main/webapp/META-INF/sca/default.scdl | 42 - .../src/main/webapp/WEB-INF/web.xml | 51 - java/sca/itest/interop-soap-service/t.bat | 34 - java/sca/itest/jms-args/pom.xml | 92 -- .../apache/tuscany/sca/binding/jms/ClientImpl.java | 41 - .../apache/tuscany/sca/binding/jms/MyService.java | 29 - .../tuscany/sca/binding/jms/ServiceImpl.java | 38 - .../jms-args/src/main/resources/jndi.properties | 38 - .../main/resources/selectors/selectors.composite | 39 - .../tuscany/sca/binding/jms/ArgsTestCase.java | 61 - java/sca/itest/jms-callbacks/pom.xml | 94 -- .../apache/tuscany/sca/binding/jms/JMSClient.java | 28 - .../tuscany/sca/binding/jms/JMSClientImpl.java | 50 - .../apache/tuscany/sca/binding/jms/JMSService.java | 34 - .../sca/binding/jms/JMSServiceCallback.java | 32 - .../tuscany/sca/binding/jms/JMSServiceImpl.java | 47 - .../src/main/resources/jndi.properties | 39 - .../src/main/resources/simple/client.composite | 44 - .../src/main/resources/simple/tempq.composite | 50 - .../tuscany/sca/binding/jms/CallbackTestCase.java | 60 - .../sca/binding/jms/TempCallbackQTestCase.java | 63 - java/sca/itest/jms-definitions/pom.xml | 93 -- .../tuscany/sca/binding/jms/OneWayClientImpl.java | 41 - .../tuscany/sca/binding/jms/OneWayService.java | 29 - .../tuscany/sca/binding/jms/OneWayServiceImpl.java | 34 - .../src/main/resources/definitions.xml | 29 - .../resources/definitions/definitions.composite | 39 - .../src/main/resources/jndi.properties | 38 - .../sca/binding/jms/DefinitionsTestCase.java | 61 - java/sca/itest/jms-format/pom.xml | 97 -- .../jmsbytes/helloworld/HelloWorldReference.java | 32 - .../helloworld/HelloWorldReferenceImpl.java | 35 - .../jmsbytes/helloworld/HelloWorldService.java | 33 - .../jmsbytes/helloworld/HelloWorldServiceImpl.java | 33 - .../helloworld/HelloWorldReference.java | 33 - .../helloworld/HelloWorldReferenceImpl.java | 42 - .../jmsdelimited/helloworld/HelloWorldService.java | 35 - .../helloworld/HelloWorldServiceImpl.java | 36 - .../jmsmessage/helloworld/HelloWorldReference.java | 32 - .../helloworld/HelloWorldReferenceImpl.java | 41 - .../jmsmessage/helloworld/HelloWorldService.java | 34 - .../helloworld/HelloWorldServiceImpl.java | 51 - .../helloworld/HelloWorldServiceReferenceSide.java | 37 - .../jms/format/jmsmessage/helloworld/README | 3 - .../helloworld/HelloWorldReferenceImpl.java | 47 - .../jmstextxml/helloworld/HelloWorldService.java | 33 - .../helloworld/HelloWorldServiceImpl.java | 35 - .../jms/format/jmstextxml/helloworld/Person.java | 44 - .../main/resources/jmsbytes/helloworld.composite | 45 - .../resources/jmsdelimited/helloworld.composite | 44 - .../main/resources/jmsdelimited/helloworld.wsdl | 129 -- .../main/resources/jmsmessage/helloworld.composite | 44 - .../src/main/resources/jmsmessage/helloworld.wsdl | 129 -- .../main/resources/jmstextxml/helloworld.composite | 76 - .../src/main/resources/jmstextxml/helloworld.wsdl | 139 -- .../src/main/resources/jmstextxml/messages.xml | 19 - .../jms-format/src/main/resources/jndi.properties | 39 - .../binding/jms/format/FormatJMSBytesTestCase.java | 64 - .../jms/format/FormatJMSDelimitedTestCase.java | 66 - .../jms/format/FormatJMSMessageTestCase.java | 64 - .../jms/format/FormatJMSTextXMLTestCase.java | 68 - java/sca/itest/jms-selectors/pom.xml | 93 -- .../apache/tuscany/sca/binding/jms/ClientImpl.java | 41 - .../tuscany/sca/binding/jms/SelectorService.java | 29 - .../sca/binding/jms/SelectorServiceImpl1.java | 40 - .../sca/binding/jms/SelectorServiceImpl2.java | 38 - .../sca/binding/jms/SelectorServiceImpl3.java | 38 - .../src/main/resources/jndi.properties | 38 - .../main/resources/selectors/selectors.composite | 68 - .../tuscany/sca/binding/jms/SelectorsTestCase.java | 75 - java/sca/itest/jms/pom.xml | 97 -- .../tuscany/sca/binding/jms/CheckedExcpetion.java | 28 - .../tuscany/sca/binding/jms/ExceptionService.java | 30 - .../sca/binding/jms/ExceptionServiceClient.java | 45 - .../sca/binding/jms/ExceptionServiceImpl.java | 32 - .../sca/binding/jms/HelloWorldClientImpl.java | 41 - .../tuscany/sca/binding/jms/HelloWorldService.java | 26 - .../sca/binding/jms/HelloWorldServiceImpl.java | 30 - .../apache/tuscany/sca/binding/jms/JMSClient.java | 28 - .../apache/tuscany/sca/binding/jms/MsgClient.java | 29 - .../tuscany/sca/binding/jms/MsgClientImpl.java | 38 - .../tuscany/sca/binding/jms/MsgClientService.java | 33 - .../apache/tuscany/sca/binding/jms/MsgService.java | 32 - .../tuscany/sca/binding/jms/MsgServiceImpl.java | 39 - .../tuscany/sca/binding/jms/OneWayClientImpl.java | 41 - .../sca/binding/jms/OneWayObjectService.java | 29 - .../sca/binding/jms/OneWayObjectServiceImpl.java | 34 - .../tuscany/sca/binding/jms/OneWayService.java | 29 - .../tuscany/sca/binding/jms/OneWayServiceImpl.java | 34 - .../sca/binding/jms/TestMessageProcessor.java | 57 - .../src/main/resources/defaults/client.composite | 33 - .../src/main/resources/defaults/service.composite | 30 - .../src/main/resources/dynamic/client.composite | 36 - .../src/main/resources/exceptions/client.composite | 33 - .../main/resources/exceptions/service.composite | 30 - .../src/main/resources/external/client.composite | 38 - .../src/main/resources/external/service.composite | 35 - .../itest/jms/src/main/resources/jndi.properties | 39 - .../main/resources/nonSCAclient/service.composite | 50 - .../main/resources/oneway/OneWayClient.composite | 35 - .../main/resources/oneway/OneWayService.composite | 32 - .../main/resources/policyHeaders/definitions.xml | 54 - .../policyHeaders/policyHeaders.composite | 46 - .../main/resources/properties/properties.composite | 55 - .../jms/src/main/resources/simple/client.composite | 38 - .../src/main/resources/simple/mpclient.composite | 38 - .../src/main/resources/simple/service.composite | 35 - .../src/main/resources/simple/uriclient.composite | 33 - .../tuscany/sca/binding/jms/DefaultsTestCase.java | 54 - .../sca/binding/jms/DynamicReplyQTestCase.java | 53 - .../sca/binding/jms/ExceptionsTestCase.java | 72 - .../sca/binding/jms/ExternalBrokerTestCase.java | 70 - .../sca/binding/jms/MessageProcessorTestCase.java | 58 - .../sca/binding/jms/NonSCAClientTestCase.java | 142 -- .../tuscany/sca/binding/jms/OneWayTestCase.java | 58 - .../sca/binding/jms/PolicyHeadersTestCase.java | 97 -- .../sca/binding/jms/PropertiesTestCase.java | 92 -- .../tuscany/sca/binding/jms/RPCTestCase.java | 54 - .../tuscany/sca/binding/jms/URIRPCTestCase.java | 54 - java/sca/itest/large-sdo-ws/pom.xml | 141 -- .../tuscany/sca/itest/trninq/TrnInqClient.java | 43 - .../tuscany/sca/itest/trninq/TrnInqService.java | 112 -- .../tuscany/sca/itest/trninq/TrninqInterface.java | 38 - .../main/resources/META-INF/sca-contribution.xml | 23 - .../src/main/resources/trnInq.composite | 39 - .../src/main/resources/wsdl/IFX170_XSD.xsd | 146 -- .../src/main/resources/wsdl/trninq.wsdl | 57 - .../test/java/trninq/TrnInqServiceTestCase.java | 87 -- java/sca/itest/late-reference-resolution/pom.xml | 126 -- .../src/main/java/calculator/AddService.java | 31 - .../src/main/java/calculator/AddServiceImpl.java | 31 - .../main/java/calculator/CalculatorService.java | 35 - .../java/calculator/CalculatorServiceImpl.java | 74 - .../src/main/java/calculator/DivideService.java | 28 - .../main/java/calculator/DivideServiceImpl.java | 30 - .../src/main/java/calculator/MultiplyService.java | 28 - .../main/java/calculator/MultiplyServiceImpl.java | 30 - .../src/main/java/calculator/SubtractService.java | 31 - .../main/java/calculator/SubtractServiceImpl.java | 31 - ...ny.sca.endpointresolver.EndpointResolverFactory | 19 - .../src/main/resources/nodeA/Calculator.composite | 41 - .../resources/nodeA/META-INF/sca-contribution.xml | 24 - .../src/main/resources/nodeB/Calculator.composite | 32 - .../resources/nodeB/META-INF/sca-contribution.xml | 24 - .../src/main/resources/nodeC/Calculator.composite | 32 - .../resources/nodeC/META-INF/sca-contribution.xml | 24 - .../sca/BindingScaEndpointResolverFactoryImpl.java | 50 - .../sca/BindingScaEndpointResolverImpl.java | 72 - .../LateReferenceResolutionTestCase.java | 97 -- .../src/test/java/calculator/TestRegistryImpl.java | 40 - java/sca/itest/oneway/build.xml | 127 -- java/sca/itest/oneway/pom.xml | 59 - .../tuscany/sca/itest/oneway/OneWayClient.java | 40 - .../tuscany/sca/itest/oneway/OneWayService.java | 45 - .../sca/itest/oneway/impl/OneWayClientImpl.java | 63 - .../sca/itest/oneway/impl/OneWayServiceImpl.java | 67 - .../META-INF/sca-deployables/oneWay.composite | 58 - .../tuscany/sca/itest/oneway/OneWayTestCase.java | 235 ---- .../contribution-classes-v2/build-bundles.xml | 39 - .../contribution-classes-v2/pom.xml | 211 --- .../src/main/java/supplychain/OSGiBundleImpl.java | 121 -- .../main/java/supplychain/customer/Customer.java | 33 - .../customer/JavaCustomerComponentImpl.java | 55 - .../customer/OSGiCustomerComponentImpl.java | 51 - .../supplychain/customer/OSGiCustomerImpl.java | 47 - .../retailer/JavaRetailerComponentImpl.java | 57 - .../retailer/OSGiRetailerComponentImpl.java | 46 - .../supplychain/retailer/OSGiRetailerImpl.java | 44 - .../main/java/supplychain/retailer/Retailer.java | 28 - .../shipper/JavaShipperComponentImpl.java | 52 - .../shipper/OSGiShipperComponentImpl.java | 45 - .../java/supplychain/shipper/OSGiShipperImpl.java | 42 - .../src/main/java/supplychain/shipper/Shipper.java | 28 - .../warehouse/JavaWarehouseComponentImpl.java | 51 - .../warehouse/OSGiWarehouseComponentImpl.java | 47 - .../supplychain/warehouse/OSGiWarehouseImpl.java | 44 - .../main/java/supplychain/warehouse/Warehouse.java | 28 - .../src/main/resources/Customer2V2.componentType | 28 - .../src/main/resources/CustomerV2.componentType | 28 - .../META-INF/customer-sca-contribution.xml | 32 - .../META-INF/retailer-sca-contribution.xml | 29 - .../META-INF/shipper-sca-contribution.xml | 27 - .../META-INF/supplychain-sca-contribution.xml | 24 - .../META-INF/warehouse-sca-contribution.xml | 28 - .../src/main/resources/RetailerV2.componentType | 28 - .../src/main/resources/ShipperV2.componentType | 28 - .../src/main/resources/WarehouseV2.componentType | 28 - .../src/main/resources/osgi/Customer.mf | 13 - .../src/main/resources/osgi/Customer2.mf | 13 - .../src/main/resources/osgi/Retailer.mf | 10 - .../src/main/resources/osgi/RetailerJar.mf | 1 - .../src/main/resources/osgi/Shipper.mf | 10 - .../src/main/resources/osgi/SupplyChain.mf | 13 - .../src/main/resources/osgi/Warehouse.mf | 10 - .../src/main/resources/supplychain.composite | 67 - .../contribution-classes/build-bundles.xml | 39 - .../osgi-contribution/contribution-classes/pom.xml | 212 --- .../src/main/java/supplychain/OSGiBundleImpl.java | 121 -- .../main/java/supplychain/customer/Customer.java | 33 - .../customer/JavaCustomerComponentImpl.java | 55 - .../customer/OSGiCustomerComponentImpl.java | 51 - .../supplychain/customer/OSGiCustomerImpl.java | 47 - .../retailer/JavaRetailerComponentImpl.java | 57 - .../retailer/OSGiRetailerComponentImpl.java | 46 - .../supplychain/retailer/OSGiRetailerImpl.java | 44 - .../main/java/supplychain/retailer/Retailer.java | 28 - .../shipper/JavaShipperComponentImpl.java | 52 - .../shipper/OSGiShipperComponentImpl.java | 45 - .../java/supplychain/shipper/OSGiShipperImpl.java | 42 - .../src/main/java/supplychain/shipper/Shipper.java | 28 - .../warehouse/JavaWarehouseComponentImpl.java | 51 - .../warehouse/OSGiWarehouseComponentImpl.java | 47 - .../supplychain/warehouse/OSGiWarehouseImpl.java | 44 - .../main/java/supplychain/warehouse/Warehouse.java | 28 - .../src/main/resources/Customer2V1.componentType | 28 - .../src/main/resources/CustomerV1.componentType | 28 - .../META-INF/customer-sca-contribution.xml | 30 - .../META-INF/retailer-sca-contribution.xml | 26 - .../META-INF/shipper-sca-contribution.xml | 26 - .../META-INF/supplychain-sca-contribution.xml | 24 - .../META-INF/warehouse-sca-contribution.xml | 26 - .../src/main/resources/RetailerV1.componentType | 28 - .../src/main/resources/ShipperV1.componentType | 28 - .../src/main/resources/WarehouseV1.componentType | 28 - .../src/main/resources/osgi/Customer.mf | 13 - .../src/main/resources/osgi/Customer2.mf | 13 - .../src/main/resources/osgi/Retailer.mf | 10 - .../src/main/resources/osgi/RetailerJar.mf | 1 - .../src/main/resources/osgi/Shipper.mf | 10 - .../src/main/resources/osgi/SupplyChain.mf | 13 - .../src/main/resources/osgi/Warehouse.mf | 10 - .../src/main/resources/supplychain.composite | 66 - .../osgi-contribution/contribution-test/pom.xml | 92 -- .../sca/contribution/osgi/OSGiTestUtil.java | 73 - .../osgi/test/MixedContributionTestCase.java | 43 - .../osgi/test/NestedBundleTestCase.java | 182 --- .../osgi/test/OSGiResolverTestCase.java | 257 ---- .../osgi/test/SCAResolverTestCase.java | 240 ---- .../resources/osgi/felix/felix.config.properties | 44 - java/sca/itest/osgi-contribution/pom.xml | 52 - .../itest/osgi-implementation/build-bundles.xml | 48 - java/sca/itest/osgi-implementation/pom.xml | 1220 ---------------- .../java/callback/client/CallbackCallback.java | 33 - .../main/java/callback/client/CallbackClient.java | 31 - .../callback/client/JavaCallbackClientImpl.java | 141 -- .../callback/client/OSGiCallbackClientImpl.java | 181 --- .../java/callback/service/CallbackService.java | 39 - .../callback/service/JavaCallbackServiceImpl.java | 68 - .../callback/service/OSGiCallbackServiceImpl.java | 95 -- .../client/ConversationalCallback.java | 50 - .../conversation/client/ConversationalClient.java | 51 - .../client/ConversationalClientActivator.java | 105 -- .../client/ConversationalClientServiceFactory.java | 135 -- .../client/ConversationalClientStatefulImpl.java | 254 ---- .../client/ConversationalClientStatelessImpl.java | 253 ---- .../ConversationalReferenceClient.java | 38 - .../ConversationalReferenceClientActivator.java | 66 - .../ConversationalReferenceClientImpl.java | 45 - .../service/ConversationalService.java | 65 - .../service/ConversationalServiceActivator.java | 76 - .../service/ConversationalServiceFactory.java | 52 - .../service/ConversationalServiceStatefulImpl.java | 121 -- .../ConversationalServiceStatelessImpl.java | 127 -- .../src/main/java/helloworld/Greetings.java | 36 - .../src/main/java/helloworld/HelloWorld.java | 29 - .../java/helloworld/JavaGreetingsComponent.java | 73 - .../java/helloworld/JavaHelloWorldComponent.java | 41 - .../main/java/helloworld/OSGiGreetingsImpl.java | 112 -- .../main/java/helloworld/OSGiHelloWorldImpl.java | 81 -- .../java/helloworld/sdo/HelloWorldService.java | 30 - .../helloworld/sdo/HelloWorldServiceComponent.java | 33 - .../helloworld/sdo/client/HelloWorldClient.java | 30 - .../sdo/client/HelloWorldClientComponent.java | 50 - .../src/main/java/helloworld/ws/HelloWorld.java | 29 - .../main/java/helloworld/ws/HelloWorldService.java | 28 - .../stockquote/OSGiStockQuoteComponentImpl.java | 86 -- .../java/stockquote/OSGiStockQuoteFactoryImpl.java | 65 - .../main/java/stockquote/OSGiStockQuoteImpl.java | 119 -- .../src/main/java/stockquote/StockQuote.java | 31 - .../src/main/java/supplychain/OSGiBundleImpl.java | 163 --- .../main/java/supplychain/customer/Customer.java | 39 - .../customer/JavaCustomerComponentImpl.java | 88 -- .../customer/OSGiCustomerComponentImpl.java | 106 -- .../customer/OSGiCustomerFactoryImpl.java | 65 - .../supplychain/customer/OSGiCustomerImpl.java | 92 -- .../OSGiCustomerWithQueryComponentImpl.java | 100 -- .../customer/OSGiCustomerWithQueryImpl.java | 82 -- .../OSGiStatelessCustomerComponentImpl.java | 30 - .../customer/OSGiStatelessCustomerImpl.java | 35 - .../customer/OSGiVersionedCustomerImpl.java | 98 -- .../retailer/JavaRetailerComponentImpl.java | 67 - .../retailer/OSGiRetailerComponentImpl.java | 64 - .../supplychain/retailer/OSGiRetailerImpl.java | 58 - .../retailer/OSGiRetailerServiceImpl.java | 45 - .../OSGiRetailerWithQueryComponentImpl.java | 78 -- .../retailer/OSGiRetailerWithQueryImpl.java | 64 - .../retailer/OSGiVersionedRetailerImpl.java | 75 - .../retailer/OSGiVersionedRetailerServiceImpl.java | 47 - .../main/java/supplychain/retailer/Retailer.java | 28 - .../java/supplychain/retailer/RetailerQuery.java | 28 - .../shipper/JavaShipperComponentImpl.java | 58 - .../shipper/OSGiShipperComponentImpl.java | 62 - .../shipper/OSGiShipperFactoryImpl.java | 78 -- .../java/supplychain/shipper/OSGiShipperImpl.java | 57 - .../shipper/OSGiShipperServiceImpl.java | 43 - .../shipper/OSGiStatelessShipperComponentImpl.java | 30 - .../shipper/OSGiStatelessShipperServiceImpl.java | 35 - .../shipper/OSGiVersionedShipperImpl.java | 78 -- .../shipper/OSGiVersionedShipperServiceImpl.java | 46 - .../src/main/java/supplychain/shipper/Shipper.java | 28 - .../warehouse/JavaWarehouseComponentImpl.java | 48 - .../JavaWarehouseWithQueryComponentImpl.java | 52 - .../warehouse/OSGiWarehouseComponentImpl.java | 57 - .../supplychain/warehouse/OSGiWarehouseImpl.java | 68 - .../warehouse/OSGiWarehouseServiceImpl.java | 62 - .../main/java/supplychain/warehouse/Warehouse.java | 28 - .../java/supplychain/warehouse/WarehouseQuery.java | 28 - .../callback/CallbackClient.componentType | 31 - .../callback/CallbackService.componentType | 27 - .../resources/callback/callback-test1.composite | 39 - .../resources/callback/callback-test2.composite | 41 - .../resources/callback/callback-test3.composite | 38 - .../ConversationalClient.componentType | 37 - .../ConversationalReferenceClient.componentType | 28 - .../ConversationalService.componentType | 29 - .../conversation/conversation-test.composite | 162 --- .../main/resources/factory/Customer.componentType | 34 - .../main/resources/factory/Retailer.componentType | 29 - .../main/resources/factory/Shipper.componentType | 29 - .../main/resources/factory/Warehouse.componentType | 28 - .../resources/factory/ds/Customer.componentType | 34 - .../resources/factory/ds/Retailer.componentType | 29 - .../resources/factory/ds/Shipper.componentType | 29 - .../resources/factory/ds/Warehouse.componentType | 28 - .../resources/factory/ds/factory-ds-test.composite | 130 -- .../main/resources/factory/factory-test.composite | 116 -- .../resources/helloworld/Greetings.componentType | 30 - .../resources/helloworld/HelloWorld.componentType | 31 - .../resources/interfaces/Customer.componentType | 31 - .../resources/interfaces/Retailer.componentType | 35 - .../resources/interfaces/Shipper.componentType | 29 - .../resources/interfaces/Warehouse.componentType | 31 - .../resources/interfaces/ds/Customer.componentType | 31 - .../resources/interfaces/ds/Retailer.componentType | 35 - .../resources/interfaces/ds/Shipper.componentType | 29 - .../interfaces/ds/Warehouse.componentType | 31 - .../interfaces/ds/interfaces-ds-test.composite | 57 - .../resources/interfaces/interfaces-test.composite | 57 - .../main/resources/osgi/callback/CallbackClient.mf | 10 - .../resources/osgi/callback/CallbackService.mf | 10 - .../osgi/conversation/ConversationalClient.mf | 11 - .../conversation/ConversationalReferenceClient.mf | 11 - .../osgi/conversation/ConversationalService.mf | 11 - .../src/main/resources/osgi/factory/Customer.mf | 11 - .../src/main/resources/osgi/factory/Retailer.mf | 10 - .../src/main/resources/osgi/factory/Shipper.mf | 10 - .../src/main/resources/osgi/factory/ds/Customer.mf | 10 - .../main/resources/osgi/factory/ds/Customer.xml | 41 - .../src/main/resources/osgi/factory/ds/Retailer.mf | 11 - .../main/resources/osgi/factory/ds/Retailer1.xml | 32 - .../main/resources/osgi/factory/ds/Retailer2.xml | 32 - .../src/main/resources/osgi/factory/ds/Shipper.mf | 10 - .../main/resources/osgi/factory/ds/Shipper1.xml | 34 - .../main/resources/osgi/factory/ds/Shipper2.xml | 34 - .../main/resources/osgi/factory/ds/Warehouse.mf | 11 - .../main/resources/osgi/factory/ds/Warehouse.xml | 32 - .../src/main/resources/osgi/interfaces/Customer.mf | 11 - .../src/main/resources/osgi/interfaces/Retailer.mf | 10 - .../src/main/resources/osgi/interfaces/Shipper.mf | 10 - .../main/resources/osgi/interfaces/ds/Customer.mf | 10 - .../main/resources/osgi/interfaces/ds/Customer.xml | 43 - .../main/resources/osgi/interfaces/ds/Retailer.mf | 11 - .../main/resources/osgi/interfaces/ds/Retailer.xml | 39 - .../main/resources/osgi/interfaces/ds/Shipper.mf | 10 - .../main/resources/osgi/interfaces/ds/Shipper.xml | 34 - .../src/main/resources/osgi/passbyref/Greetings.mf | 11 - .../osgi/properties/ManagedStockQuoteFactory.mf | 11 - .../main/resources/osgi/properties/StockQuote.mf | 10 - .../resources/osgi/properties/StockQuoteFactory.mf | 11 - .../resources/osgi/properties/ds/StockQuote.mf | 12 - .../resources/osgi/properties/ds/StockQuote.xml | 27 - .../osgi/properties/ds/StockQuoteFactory.mf | 12 - .../osgi/properties/ds/StockQuoteFactory.xml | 27 - .../main/resources/osgi/sdo/ds/HelloWorldClient.mf | 14 - .../resources/osgi/sdo/ds/HelloWorldClient.xml | 33 - .../resources/osgi/sdo/ds/HelloWorldService.mf | 13 - .../resources/osgi/sdo/ds/HelloWorldService.xml | 25 - .../src/main/resources/osgi/services/Customer.mf | 11 - .../src/main/resources/osgi/services/Retailer.mf | 10 - .../src/main/resources/osgi/services/Shipper.mf | 10 - .../src/main/resources/osgi/services/Warehouse.mf | 10 - .../main/resources/osgi/services/ds/Customer.mf | 10 - .../main/resources/osgi/services/ds/Customer.xml | 41 - .../main/resources/osgi/services/ds/Retailer.mf | 11 - .../main/resources/osgi/services/ds/Retailer1.xml | 32 - .../main/resources/osgi/services/ds/Retailer2.xml | 32 - .../src/main/resources/osgi/services/ds/Shipper.mf | 10 - .../main/resources/osgi/services/ds/Shipper1.xml | 34 - .../main/resources/osgi/services/ds/Shipper2.xml | 34 - .../main/resources/osgi/services/ds/Warehouse.mf | 11 - .../main/resources/osgi/services/ds/Warehouse1.xml | 32 - .../main/resources/osgi/services/ds/Warehouse2.xml | 32 - .../src/main/resources/osgi/version/Customer1.mf | 11 - .../src/main/resources/osgi/version/Customer2.mf | 11 - .../src/main/resources/osgi/version/Retailer1.mf | 10 - .../src/main/resources/osgi/version/Retailer2.mf | 10 - .../src/main/resources/osgi/version/Shipper1.mf | 10 - .../src/main/resources/osgi/version/Shipper2.mf | 10 - .../src/main/resources/osgi/version/Warehouse1.mf | 10 - .../src/main/resources/osgi/version/Warehouse2.mf | 10 - .../main/resources/osgi/version/ds/Customer1.mf | 10 - .../main/resources/osgi/version/ds/Customer2.mf | 10 - .../main/resources/osgi/version/ds/CustomerV1.xml | 41 - .../main/resources/osgi/version/ds/CustomerV2.xml | 41 - .../main/resources/osgi/version/ds/Retailer1.mf | 11 - .../main/resources/osgi/version/ds/Retailer1V1.xml | 34 - .../main/resources/osgi/version/ds/Retailer1V2.xml | 34 - .../main/resources/osgi/version/ds/Retailer2.mf | 11 - .../main/resources/osgi/version/ds/Retailer2V1.xml | 33 - .../main/resources/osgi/version/ds/Retailer2V2.xml | 33 - .../src/main/resources/osgi/version/ds/Shipper1.mf | 10 - .../main/resources/osgi/version/ds/Shipper1V1.xml | 35 - .../main/resources/osgi/version/ds/Shipper1V2.xml | 35 - .../src/main/resources/osgi/version/ds/Shipper2.mf | 10 - .../main/resources/osgi/version/ds/Shipper2V1.xml | 35 - .../main/resources/osgi/version/ds/Shipper2V2.xml | 35 - .../main/resources/osgi/version/ds/Warehouse1.mf | 11 - .../resources/osgi/version/ds/Warehouse1V1.xml | 32 - .../resources/osgi/version/ds/Warehouse1V2.xml | 32 - .../main/resources/osgi/version/ds/Warehouse2.mf | 11 - .../resources/osgi/version/ds/Warehouse2V1.xml | 32 - .../resources/osgi/version/ds/Warehouse2V2.xml | 32 - .../src/main/resources/osgi/wiring/Customer.mf | 11 - .../src/main/resources/osgi/wiring/Retailer.mf | 10 - .../src/main/resources/osgi/wiring/Shipper.mf | 10 - .../src/main/resources/osgi/wiring/Warehouse.mf | 10 - .../src/main/resources/osgi/wiring/ds/Customer.mf | 10 - .../src/main/resources/osgi/wiring/ds/Customer.xml | 41 - .../src/main/resources/osgi/wiring/ds/Retailer.mf | 11 - .../main/resources/osgi/wiring/ds/Retailer1.xml | 33 - .../main/resources/osgi/wiring/ds/Retailer2.xml | 33 - .../src/main/resources/osgi/wiring/ds/Shipper.mf | 10 - .../src/main/resources/osgi/wiring/ds/Shipper1.xml | 35 - .../src/main/resources/osgi/wiring/ds/Shipper2.xml | 34 - .../src/main/resources/osgi/wiring/ds/Warehouse.mf | 11 - .../main/resources/osgi/wiring/ds/Warehouse1.xml | 33 - .../main/resources/osgi/wiring/ds/Warehouse2.xml | 33 - .../src/main/resources/osgi/ws/HelloWorld.mf | 12 - .../resources/passbyref/Greetings.componentType | 30 - .../resources/passbyref/passbyref-test.composite | 39 - .../resources/properties/StockQuote.componentType | 28 - .../properties/StockQuoteFactory.componentType | 28 - .../properties/ds/StockQuote.componentType | 28 - .../properties/ds/StockQuoteFactory.componentType | 28 - .../properties/ds/properties-ds-test.composite | 39 - .../properties/ds/properties2-ds-test.composite | 54 - .../resources/properties/properties-test.composite | 39 - .../properties/properties2-test.composite | 50 - .../sdo/ds/HelloWorldClient.componentType | 30 - .../sdo/ds/HelloWorldService.componentType | 25 - .../resources/sdo/ds/META-INF/sca-contribution.xml | 26 - .../src/main/resources/sdo/ds/helloworld.wsdl | 88 -- .../main/resources/sdo/ds/helloworldsdo.composite | 47 - .../main/resources/services/Customer.componentType | 34 - .../main/resources/services/Retailer.componentType | 33 - .../main/resources/services/Shipper.componentType | 30 - .../resources/services/Warehouse.componentType | 28 - .../resources/services/ds/Customer.componentType | 34 - .../resources/services/ds/Retailer.componentType | 33 - .../resources/services/ds/Shipper.componentType | 30 - .../resources/services/ds/Warehouse.componentType | 28 - .../services/ds/services-ds-test.composite | 90 -- .../resources/services/services-test.composite | 89 -- .../resources/stockquote/StockQuote.componentType | 28 - .../main/resources/version/Customer1.componentType | 34 - .../main/resources/version/Customer2.componentType | 34 - .../main/resources/version/Retailer1.componentType | 33 - .../main/resources/version/Retailer2.componentType | 33 - .../main/resources/version/Shipper1.componentType | 30 - .../main/resources/version/Shipper2.componentType | 30 - .../resources/version/Warehouse1.componentType | 28 - .../resources/version/Warehouse2.componentType | 28 - .../resources/version/ds/Customer1.componentType | 34 - .../resources/version/ds/Customer2.componentType | 34 - .../resources/version/ds/Retailer1.componentType | 33 - .../resources/version/ds/Retailer2.componentType | 33 - .../resources/version/ds/Shipper1.componentType | 30 - .../resources/version/ds/Shipper2.componentType | 30 - .../resources/version/ds/Warehouse1.componentType | 28 - .../resources/version/ds/Warehouse2.componentType | 28 - .../resources/version/ds/version-ds-test.composite | 184 --- .../main/resources/version/version-test.composite | 170 --- .../main/resources/wiring/Customer.componentType | 34 - .../main/resources/wiring/Retailer.componentType | 29 - .../main/resources/wiring/Shipper.componentType | 29 - .../main/resources/wiring/Warehouse.componentType | 28 - .../resources/wiring/ds/Customer.componentType | 34 - .../resources/wiring/ds/Retailer.componentType | 29 - .../main/resources/wiring/ds/Shipper.componentType | 29 - .../resources/wiring/ds/Warehouse.componentType | 28 - .../resources/wiring/ds/wiring-ds-test1.composite | 136 -- .../resources/wiring/ds/wiring-ds-test2.composite | 151 -- .../main/resources/wiring/wiring-test1.composite | 127 -- .../main/resources/wiring/wiring-test2.composite | 151 -- .../src/main/resources/ws/HelloWorld.componentType | 31 - .../src/main/resources/ws/helloworld.wsdl | 80 -- .../src/main/resources/ws/ws-helloworld.composite | 51 - .../src/test/java/callback/Callback1TestCase.java | 30 - .../src/test/java/callback/Callback2TestCase.java | 29 - .../src/test/java/callback/Callback3TestCase.java | 29 - .../src/test/java/callback/CallbackTestCase.java | 50 - .../java/conversation/ConversationTestCase.java | 325 ----- .../helloworld/passbyref/PassByRefTestCase.java | 130 -- .../src/test/java/helloworld/sdo/SdoTestCase.java | 95 -- .../java/helloworld/ws/HelloWorldTestCase.java | 55 - .../test/java/supplychain/SupplyChainTestCase.java | 63 - .../supplychain/VersionedSupplyChainTestCase.java | 71 - .../supplychain/factory/DSFactoryTestCase.java | 32 - .../java/supplychain/factory/FactoryTestCase.java | 72 - .../interfaces/DSInterfacesTestCase.java | 32 - .../supplychain/interfaces/InterfacesTestCase.java | 32 - .../properties/DSProperties2TestCase.java | 31 - .../properties/DSPropertiesTestCase.java | 31 - .../properties/Properties2TestCase.java | 69 - .../supplychain/properties/PropertiesTestCase.java | 58 - .../supplychain/services/DSServicesTestCase.java | 32 - .../supplychain/services/ServicesTestCase.java | 32 - .../supplychain/version/DSVersionTestCase.java | 33 - .../java/supplychain/version/VersionTestCase.java | 33 - .../java/supplychain/wiring/DSWiring1TestCase.java | 33 - .../java/supplychain/wiring/DSWiring2TestCase.java | 33 - .../java/supplychain/wiring/Wiring1TestCase.java | 32 - .../java/supplychain/wiring/Wiring2TestCase.java | 32 - .../src/test/java/test/OSGiTestCase.java | 67 - .../src/test/java/util/OSGiTestUtil.java | 71 - .../resources/osgi/felix/felix.config.properties | 45 - .../itest/osgi-tuscany/osgi-tuscany-test/pom.xml | 99 -- .../test/osgi/runtime/impl/EquinoxTestRuntime.java | 92 -- .../test/osgi/runtime/impl/FelixTestRuntime.java | 163 --- .../test/osgi/runtime/impl/OSGiTestRuntime.java | 163 --- .../tuscany/sca/test/util/OSGiRuntimeLoader.java | 86 -- .../tuscany/sca/test/util/TuscanyLoader.java | 136 -- .../harness/OSGiTuscanyNonOSGiTestHarness.java | 109 -- .../test/osgi/harness/OSGiTuscanyTestHarness.java | 243 ---- .../CalculatorImplementationPoliciesTestCase.java | 61 - .../test/osgi/tuscany/CalculatorRmiTestCase.java | 62 - .../osgi/tuscany/CalculatorScriptTestCase.java | 63 - .../osgi/tuscany/CallbackWsClientTestCase.java | 61 - .../osgi/tuscany/CallbackWsServiceTestCase.java | 61 - .../tuscany/HelloworldWsServiceJmsTestCase.java | 61 - .../tuscany/HelloworldWsServiceSecureTestCase.java | 61 - .../osgi/tuscany/HelloworldWsServiceTestCase.java | 61 - .../test/osgi/tuscany/NonOSGiSamplesTestCase.java | 85 -- .../test/osgi/tuscany/OSGiSupplyChainTestCase.java | 71 - .../osgi/tuscany/OSGiTuscanyRuntimeTestCase.java | 137 -- .../tuscany/TuscanySampleExtensionsTestCase.java | 93 -- .../TuscanySamplesUsingOldDomainTestCase.java | 80 -- .../src/test/resources/META-INF/MANIFEST.MF | 14 - .../test/resources/felix/felix.config.properties | 45 - java/sca/itest/osgi-tuscany/pom.xml | 39 - .../osgi-tuscany/test-bundles/build-bundles.xml | 31 - java/sca/itest/osgi-tuscany/test-bundles/pom.xml | 124 -- .../java/supplychain/client/SupplyChainClient.java | 115 -- .../main/java/supplychain/customer/Customer.java | 37 - .../customer/JavaCustomerComponentImpl.java | 61 - .../retailer/JavaRetailerComponentImpl.java | 59 - .../main/java/supplychain/retailer/Retailer.java | 28 - .../shipper/JavaShipperComponentImpl.java | 50 - .../src/main/java/supplychain/shipper/Shipper.java | 28 - .../warehouse/JavaWarehouseComponentImpl.java | 49 - .../main/java/supplychain/warehouse/Warehouse.java | 28 - .../src/main/resources/META-INF/SupplyChain.mf | 12 - .../main/resources/META-INF/SupplyChainClient.mf | 21 - .../main/resources/META-INF/sca-contribution.xml | 26 - .../resources/supplychain/supplychain.composite | 48 - .../main/resources/supplychain/ws/Customer.wsdl | 135 -- .../resources/supplychain/ws/supplychain.composite | 55 - .../osgi-tuscany/tuscany-osgi-installer/pom.xml | 666 --------- .../sca/installer/InstallerBundleActivator.java | 405 ------ .../itest/osgi-tuscany/tuscany-versioned/pom.xml | 639 --------- java/sca/itest/policy-security-basicauth/pom.xml | 113 -- .../main/java/helloworld/HelloWorldClientImpl.java | 40 - .../main/java/helloworld/HelloWorldService.java | 30 - .../java/helloworld/HelloWorldServiceImpl.java | 46 - .../src/main/resources/definitions.xml | 44 - .../src/main/resources/helloworld.composite | 46 - .../tuscany/sca/itest/BasicAuthTestCase.java | 114 -- java/sca/itest/policy-security-jsr250/pom.xml | 75 - .../src/main/java/helloworld/HelloWorldImpl.java | 51 - .../main/java/helloworld/HelloWorldService.java | 38 - .../src/main/resources/definitions.xml | 29 - .../src/main/resources/helloworld.composite | 33 - .../sca/itest/PolicySecurityJSR250TestCase.java | 54 - java/sca/itest/policy-security-token/pom.xml | 106 -- .../main/java/helloworld/HelloWorldClientImpl.java | 42 - .../main/java/helloworld/HelloWorldService.java | 30 - .../java/helloworld/HelloWorldServiceImpl.java | 46 - .../src/main/resources/definitions.xml | 49 - .../src/main/resources/helloworld.composite | 56 - .../src/main/resources/jndi.properties | 39 - .../tuscany/sca/itest/TokenAuthTestCase.java | 115 -- java/sca/itest/policy-security/pom.xml | 68 - .../src/main/java/helloworld/HelloWorldImpl.java | 33 - .../main/java/helloworld/HelloWorldService.java | 30 - .../src/main/resources/definitions.xml | 33 - .../src/main/resources/helloworld.composite | 34 - .../tuscany/sca/itest/PolicyIdentityTestCase.java | 54 - java/sca/itest/policy/pom.xml | 68 - .../src/main/java/calculator/AddService.java | 34 - .../src/main/java/calculator/AddServiceImpl.java | 35 - .../src/main/java/calculator/CalculatorClient.java | 69 - .../main/java/calculator/CalculatorService.java | 35 - .../java/calculator/CalculatorServiceImpl.java | 76 - .../src/main/java/calculator/DivideService.java | 33 - .../main/java/calculator/DivideServiceImpl.java | 35 - .../src/main/java/calculator/MultiplyService.java | 28 - .../main/java/calculator/MultiplyServiceImpl.java | 35 - .../src/main/java/calculator/PolicyQNames.java | 43 - .../src/main/java/calculator/SubtractService.java | 28 - .../main/java/calculator/SubtractServiceImpl.java | 35 - .../calculator/policy/TestImplPolicyHandler.java | 84 -- .../calculator/policy/TestRefPolicyHandler.java | 61 - .../calculator/policy/TestSvcPolicyHandler.java | 61 - .../policy/src/main/resources/Calculator.composite | 66 - ...ca.contribution.processor.StAXArtifactProcessor | 19 - ...rg.apache.tuscany.sca.policy.util.PolicyHandler | 28 - .../policy/src/main/resources/definitions.xml | 147 -- .../sca/itest/PoliciedCalculatorTestCase.java | 55 - .../java/org/apache/tuscany/sca/itest/Policy.java | 33 - .../tuscany/sca/itest/TestPolicyProcessor.java | 82 -- .../itest/promotion-interface-missmatch/pom.xml | 59 - .../main/java/com/example/BusinessException.java | 43 - .../src/main/java/com/example/ExampleClient.java | 23 - .../main/java/com/example/ExampleClientImpl.java | 44 - .../src/main/java/com/example/ExampleService.java | 27 - .../main/java/com/example/ExampleServiceImpl.java | 26 - .../src/main/resources/example.composite | 50 - .../src/main/resources/wsdl/ExampleService.wsdl | 133 -- .../main/resources/wsdl/ExampleServiceTypes.xsd | 45 - .../src/test/java/com/example/ExampleTestCase.java | 44 - java/sca/itest/recursive-ws/pom.xml | 87 -- .../recursive-ws/src/main/java/policy/Target.java | 26 - .../src/main/java/policy/TargetClientImpl.java | 33 - .../src/main/java/policy/TargetServiceImpl.java | 29 - .../src/main/java/recursive/Composer.java | 26 - .../src/main/java/recursive/ComposerClient.java | 35 - .../main/java/recursive/ComposerClientImpl.java | 38 - .../src/main/java/recursive/ComposerImpl.java | 34 - .../src/main/java/recursive/ComposerServer.java | 35 - .../src/main/resources/Client.composite | 28 - .../src/main/resources/Inner.composite | 26 - .../src/main/resources/Outer.composite | 31 - .../bindingoverride/InnerComposite.composite | 36 - .../bindingoverride/OuterComposite.composite | 40 - .../policy/PolicyInnerComposite.composite | 37 - .../policy/PolicyOuterComposite.composite | 41 - .../src/main/resources/policy/definitions.xml | 39 - .../bindingoverride/BindingOverrideTestCase.java | 57 - .../src/test/java/policy/PolicyTestCase.java | 74 - .../java/recursive/ComposerClientTestCase.java | 68 - .../test/java/recursive/ComposerTestServer.java | 55 - java/sca/itest/recursive/pom.xml | 45 - .../src/main/java/circular/include/DemoClass.java | 27 - .../src/main/java/composite/CompositeClient.java | 42 - .../recursive/src/main/java/composite/Source.java | 24 - .../src/main/java/composite/SourceCallback.java | 24 - .../src/main/java/composite/SourceImpl.java | 55 - .../recursive/src/main/java/composite/Target.java | 30 - .../src/main/java/composite/TargetImpl.java | 41 - java/sca/itest/recursive/src/main/java/foo/A.java | 28 - java/sca/itest/recursive/src/main/java/foo/B.java | 36 - java/sca/itest/recursive/src/main/java/foo/I.java | 23 - .../recursive/src/main/java/policy/Target.java | 26 - .../src/main/java/policy/TargetClientImpl.java | 33 - .../src/main/java/policy/TargetServiceImpl.java | 29 - .../src/main/java/sample/ComponentAImpl.java | 41 - .../src/main/java/sample/ComponentCImpl.java | 41 - .../src/main/java/sample/ComponentEImpl.java | 38 - .../src/main/java/sample/ComponentFImpl.java | 45 - .../recursive/src/main/java/sample/Service1.java | 27 - .../recursive/src/main/java/test/Aggregator.java | 27 - .../src/main/java/test/AggregatorImpl.java | 55 - .../src/main/java/test/InnerSourceImpl.java | 34 - .../src/main/java/test/OuterSourceImpl.java | 34 - .../itest/recursive/src/main/java/test/Source.java | 30 - .../src/main/java/test1/composite/Target.java | 23 - .../src/main/java/test1/composite/TargetOne.java | 29 - .../src/main/java/test1/composite/TargetTwo.java | 29 - .../src/main/resources/AComposite.composite | 30 - .../src/main/resources/BComposite.composite | 45 - .../src/main/resources/CComposite.composite | 44 - .../src/main/resources/Composite1.composite | 42 - .../src/main/resources/Composite2.composite | 43 - .../src/main/resources/Composite3.composite | 48 - .../src/main/resources/Demo1Composite.composite | 27 - .../src/main/resources/Demo2Composite.composite | 28 - .../recursive/src/main/resources/Inner.composite | 45 - .../src/main/resources/InnerComposite.composite | 41 - .../src/main/resources/InnerComposite2.composite | 33 - .../main/resources/META-INF/sca-contribution.xml | 24 - .../recursive/src/main/resources/Outer.composite | 39 - .../src/main/resources/OuterComposite.composite | 39 - .../itest/recursive/src/main/resources/foo/foo.png | Bin 571816 -> 0 bytes .../recursive/src/main/resources/foo/o1.composite | 31 - .../recursive/src/main/resources/foo/o2.composite | 31 - .../recursive/src/main/resources/foo/o3.composite | 35 - .../recursive/src/main/resources/foo/o4.composite | 37 - .../policy/PolicyInnerComposite.composite | 32 - .../policy/PolicyOuterComposite.composite | 35 - .../src/main/resources/policy/definitions.xml | 46 - .../main/resources/test1/InnerComposite.composite | 39 - .../main/resources/test1/OuterComposite.composite | 27 - .../circular/include/CircularIncludeTestCase.java | 39 - .../src/test/java/composite/CompositeTestCase.java | 51 - .../LocateServiceEmbeddedSCADomainTestCase.java | 113 -- .../composite/LocateServiceSCADomainTestCase.java | 73 - .../recursive/src/test/java/foo/O2TestCase.java | 32 - .../recursive/src/test/java/foo/O4TestCase.java | 39 - .../src/test/java/policy/PolicyTestCase.java | 68 - .../itest/recursive/src/test/java/sample/C.java | 32 - .../recursive/src/test/java/sample/CImpl.java | 80 -- .../src/test/java/sample/NestedTestCase.java | 96 -- .../sample/RecursiveCompositeTestCaseFIXME.java | 53 - .../itest/recursive/src/test/java/sample/X.java | 32 - .../recursive/src/test/java/sample/XImpl.java | 37 - .../itest/recursive/src/test/java/sample/Y.java | 32 - .../recursive/src/test/java/sample/YImpl.java | 38 - .../src/test/java/test/InnerTestCase.java | 51 - .../src/test/java/test/OuterTestCase.java | 53 - .../test1/composite/CompositeClientTestCase.java | 62 - java/sca/itest/serialization/pom.xml | 66 - .../servicereference/ConversationalService.java | 81 -- .../ConversationalServiceCallback.java | 37 - .../ConversationalServiceImpl.java | 141 -- .../itest/servicereference/SCAManagedClient.java | 51 - .../servicereference/SCAManagedClientImpl.java | 115 -- .../SCAManagedConversationalClient.java | 55 - .../SCAManagedConversationalClientImpl.java | 132 -- .../itest/servicereference/StatelessService.java | 46 - .../servicereference/StatelessServiceCallback.java | 34 - .../servicereference/StatelessServiceImpl.java | 82 -- .../utils/ServiceReferenceUtils.java | 127 -- .../ServiceReferenceSerializationTest.composite | 45 - .../src/main/resources/nestedcomposite.composite | 33 - .../SerializeServiceReferenceTestCase.java | 145 -- java/sca/itest/spring/pom.xml | 105 -- .../java/bigbank/stockquote/StockQuoteImpl.java | 38 - .../java/bigbank/stockquote/StockQuoteService.java | 30 - .../src/main/java/calculator/AddService.java | 28 - .../src/main/java/calculator/AddServiceImpl.java | 35 - .../main/java/calculator/CalculatorService.java | 35 - .../java/calculator/CalculatorServiceImpl.java | 79 -- .../src/main/java/calculator/DivideService.java | 28 - .../main/java/calculator/DivideServiceImpl.java | 35 - .../src/main/java/calculator/MultiplyService.java | 28 - .../main/java/calculator/MultiplyServiceImpl.java | 35 - .../src/main/java/calculator/SubtractService.java | 28 - .../main/java/calculator/SubtractServiceImpl.java | 35 - .../security/CalculatorCallbackHandler.java | 50 - .../java/calculator/security/JaasLoginModule.java | 178 --- .../java/calculator/security/UserPrincipal.java | 66 - .../access/SCAApplicationContextProvider.java | 19 - .../spring/annotations/CalculatorServiceImpl.java | 131 -- .../main/resources/CalculatorService-context.xml | 39 - .../sca/SpringDelegationHelloWorld-context.xml | 37 - .../META-INF/sca/SpringHelloWorld-context.xml | 31 - .../context-access/CalculatorService-context.xml | 45 - .../context-imports/CalculatorService-context.xml | 39 - .../sca/context-imports/SpringImport-context.xml | 29 - .../context-multiple/StockQuoteService-context.xml | 36 - .../sca/context-multiple/beanRefContext.xml | 34 - .../CalculatorService-context.xml | 39 - .../CalculatorService-context.xml | 41 - .../resources/context/access/Calculator.composite | 49 - .../resources/context/imports/Calculator.composite | 49 - .../context/multiple/StockQuote.composite | 35 - .../implementation/policies/Calculator.composite | 61 - .../implementation/policies/CalculatorJass.config | 3 - .../policies/CalculatorLogMessages.properties | 18 - .../implementation/policies/definitions.xml | 40 - .../spring/SpringDelegationHelloWorld.composite | 32 - .../sca/itest/spring/SpringHelloWorld.composite | 32 - .../spring/annotations/Calculator.composite | 60 - .../test/java/context/access/CalculatorClient.java | 60 - .../java/context/access/ContextAccessTestCase.java | 32 - .../java/context/imports/CalculatorClient.java | 54 - .../context/imports/ContextImportsTestCase.java | 32 - .../context/multiple/MultipleContextTestCase.java | 32 - .../java/context/multiple/StockQuoteServer.java | 51 - .../implementation/policies/CalculatorClient.java | 78 -- .../policies/ImplementationPoliciesTestCase.java | 32 - .../itest/spring/AbstractHelloWorldTestCase.java | 40 - .../sca/itest/spring/AbstractSCATestCase.java | 51 - .../tuscany/sca/itest/spring/HelloWorld.java | 34 - .../tuscany/sca/itest/spring/HelloWorldProxy.java | 41 - .../spring/SpringDelegationHelloWorldTestCase.java | 31 - .../sca/itest/spring/SpringHelloWorldTestCase.java | 32 - .../sca/itest/spring/TestHelloWorldBean.java | 36 - .../itest/spring/TestHelloWorldDelegatorBean.java | 40 - .../java/spring/annotations/CalculatorClient.java | 65 - .../annotations/SpringAnnotationsTestCase.java | 32 - java/sca/itest/transaction/pom.xml | 91 -- .../transaction/AccountNotFoundException.java | 36 - .../sca/itest/transaction/AccountService.java | 31 - .../sca/itest/transaction/AccountServiceImpl.java | 70 - .../transaction/CheckingAccountServiceImpl.java | 143 -- .../sca/itest/transaction/OverDraftException.java | 36 - .../transaction/SavingsAccountServiceImpl.java | 133 -- .../sca/itest/transaction/TransferService.java | 31 - .../sca/itest/transaction/TransferServiceImpl.java | 64 - .../src/main/resources/accounts.composite | 43 - .../transaction/src/main/resources/definitions.xml | 99 -- .../src/main/resources/log4j.properties | 29 - .../transaction/ConcurrentXAResourceTestCase.java | 119 -- .../sca/itest/transaction/TransactionTestCase.java | 53 - java/sca/itest/validation/pom.xml | 141 -- .../main/java/binding/ejb/account/Customer.java | 35 - .../java/binding/ejb/account/CustomerImpl.java | 57 - .../java/binding/ejb/calculator/AddService.java | 27 - .../binding/ejb/calculator/AddServiceHome.java | 31 - .../main/java/binding/jms/HelloWorldService.java | 26 - .../java/binding/jms/HelloWorldServiceImpl.java | 27 - .../main/java/calculator/warning/AddService.java | 32 - .../java/calculator/warning/AddServiceImpl.java | 44 - .../warning/AddServiceImplWithServiceName.java | 46 - .../java/calculator/warning/CalculatorClient.java | 45 - .../java/calculator/warning/CalculatorService.java | 35 - .../calculator/warning/CalculatorServiceImpl.java | 70 - .../java/calculator/warning/DivideService.java | 28 - .../java/calculator/warning/DivideServiceImpl.java | 35 - .../java/calculator/warning/MultiplyService.java | 28 - .../calculator/warning/MultiplyServiceImpl.java | 35 - .../java/calculator/warning/PropertyService.java | 29 - .../calculator/warning/PropertyServiceImpl.java | 41 - .../java/calculator/warning/SubtractService.java | 28 - .../calculator/warning/SubtractServiceImpl.java | 35 - .../SubtractServiceImplWithServiceName.java | 38 - .../src/main/java/impl/java/AddService.java | 29 - .../src/main/java/impl/java/AddServiceImpl.java | 44 - .../src/main/java/impl/java/CalculatorClient.java | 45 - .../src/main/java/impl/java/CalculatorService.java | 35 - .../main/java/impl/java/CalculatorServiceImpl.java | 75 - .../src/main/java/impl/java/DivideService.java | 28 - .../src/main/java/impl/java/DivideServiceImpl.java | 35 - .../src/main/java/impl/java/MultiplyService.java | 28 - .../main/java/impl/java/MultiplyServiceImpl.java | 35 - .../src/main/java/impl/java/SubtractService.java | 28 - .../main/java/impl/java/SubtractServiceImpl.java | 35 - .../src/main/java/impl/spring/HelloWorld.java | 36 - .../src/main/java/impl/spring/HelloWorldProxy.java | 41 - .../main/java/impl/spring/TestHelloWorldBean.java | 36 - .../java/interfacejava/xml/CalculatorService.java | 35 - .../interfacejava/xml/CalculatorServiceImpl.java | 75 - .../Calculator.composite | 49 - .../DuplicateComponentName/Calculator.composite | 53 - .../Calculator.composite | 55 - .../dummyImplementation.composite | 31 - .../Calculator.composite | 56 - .../dummyImplementation.composite | 32 - .../DuplicatePropertyName/Calculator.composite | 51 - .../DuplicateReferenceName/Calculator.composite | 50 - .../META-INF/sca/SpringHelloWorld-context.xml | 31 - .../Calculator.composite | 53 - .../NoComponentImplementation/Calculator.composite | 52 - .../NoCompositeNamespace/Calculator.composite | 48 - .../NoMatchingBinding/Calculator.composite | 54 - .../PromotedReferenceNotFound/Calculator.composite | 51 - .../PromotedServiceNotFound/Calculator.composite | 51 - .../PropertyAttribute/Calculator.composite | 55 - .../CalculatorNullMustSupply.composite | 53 - .../CalculatorOverrideManyAttribute.composite | 54 - .../PropertyNotFound/Calculator.composite | 50 - .../Calculator.composite | 51 - .../Calculator.composite | 49 - .../Calculator.composite | 49 - .../ReferenceNotFound/Calculator.composite | 50 - .../ReferenceWithoutTargets/Calculator.composite | 49 - .../Calculator.composite | 54 - .../Calculator.composite | 54 - .../resources/XsdValidation/Calculator.composite | 51 - .../ContributionReadException/Calculator.composite | 53 - .../Calculator.composite | 53 - .../Calculator.composite | 54 - .../UnexpectedBindingElement/Calculator.composite | 55 - .../Calculator.composite | 54 - .../Calculator.composite | 54 - .../InvalidWsdlElementAttr/Calculator.composite | 58 - .../wsxml/MustUseWsdlBinding/Calculator.composite | 59 - .../wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl | 92 -- .../helloworldwsjms.composite | 34 - .../wsxml/WsdlPortTypeDoesNotMatch/helloworld.wsdl | 92 -- .../helloworldwsclient.composite | 45 - .../wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl | 92 -- .../helloworldwsjms.composite | 34 - .../UnknownEJBSessionType/account.composite | 35 - .../bindingejb/UnknownEJBVersion/account.composite | 35 - .../DoesntProcessActivationSpec/service.composite | 36 - .../DoesntProcessDestinationType/service.composite | 35 - .../DoesntProcessHeaders/service.composite | 36 - .../DoesntProcessResourceAdapter/service.composite | 32 - .../service.composite | 35 - .../service.composite | 35 - .../service.composite | 35 - .../InvalidCorrelationScheme/service.composite | 35 - .../InvalidJMSDeliveryMode/service.composite | 36 - .../InvalidJMSPriority/service.composite | 36 - .../service.composite | 35 - .../MissingActivationSpecName/service.composite | 36 - .../MissingConnectionFactoryName/service.composite | 36 - .../service.composite | 36 - .../service.composite | 36 - .../MustStartWithSchema/service.composite | 36 - .../bindingjms/UnexpectedElement/service.composite | 38 - .../UnexpectedResponseElement/service.composite | 38 - .../bindingjms/UnknownTokenInURI/service.composite | 36 - .../AttributePackageMissing/Calculator.composite | 55 - .../AttributeNameSpaceMissing/Calculator.composite | 55 - .../AttributeURIMissing/Calculator.composite | 55 - .../META-INF/sca-contribution.xml | 24 - .../AttributeCompositeMissing/Calculator.composite | 53 - .../AttributeCompositeMissing/sca-contribution.xml | 24 - .../MultipleCompositeErrors/Calculator.composite | 53 - .../MultipleCompositeErrors/sca-contribution.xml | 31 - .../helloworld.composite | 29 - .../AttributeWithoutNamespace/helloworld.composite | 29 - .../impl/bpel/BPELProcessNotFound/deploy.xml | 30 - .../impl/bpel/BPELProcessNotFound/helloworld.bpel | 66 - .../BPELProcessNotFound/helloworld.componentType | 30 - .../bpel/BPELProcessNotFound/helloworld.composite | 29 - .../impl/bpel/BPELProcessNotFound/helloworld.wsdl | 82 -- .../bpel/CannotResolveWSDLReference/deploy.xml | 30 - .../CannotResolveWSDLReference/helloworld.bpel | 66 - .../helloworld.componentType | 30 - .../helloworld.composite | 29 - .../impl/bpel/MyRolePartnerRoleNull/deploy.xml | 30 - .../bpel/MyRolePartnerRoleNull/helloworld.bpel | 66 - .../MyRolePartnerRoleNull/helloworld.componentType | 30 - .../MyRolePartnerRoleNull/helloworld.composite | 29 - .../bpel/MyRolePartnerRoleNull/helloworld.wsdl | 82 -- .../impl/bpel/PartnerLinkHasBothAttr/deploy.xml | 30 - .../bpel/PartnerLinkHasBothAttr/helloworld.bpel | 68 - .../helloworld.componentType | 30 - .../PartnerLinkHasBothAttr/helloworld.composite | 29 - .../bpel/PartnerLinkHasBothAttr/helloworld.wsdl | 82 -- .../impl/bpel/PartnerLinkNoMatchingType/deploy.xml | 30 - .../bpel/PartnerLinkNoMatchingType/helloworld.bpel | 66 - .../helloworld.componentType | 30 - .../PartnerLinkNoMatchingType/helloworld.composite | 29 - .../bpel/PartnerLinkNoMatchingType/helloworld.wsdl | 82 -- .../impl/bpel/PartnerLinkTypeNoRoles/deploy.xml | 30 - .../bpel/PartnerLinkTypeNoRoles/helloworld.bpel | 66 - .../helloworld.componentType | 30 - .../PartnerLinkTypeNoRoles/helloworld.composite | 29 - .../bpel/PartnerLinkTypeNoRoles/helloworld.wsdl | 80 -- .../impl/ejb/EJBLinkAttributeMissing/ejb.composite | 29 - .../ClassNotFoundException/Calculator.composite | 49 - .../Calculator.composite | 49 - .../OSGiTestService.componentType | 28 - .../CouldNotLocateOSGiBundle/osgitest.composite | 34 - .../MissingComponentTypeFile/osgitest.composite | 34 - .../OSGiTestService.componentType | 28 - .../PropertyShouldSpecifySR/osgitest.composite | 36 - .../CouldNotResolveLocation/resource.composite | 30 - .../LocationAttributeMissing/resource.composite | 30 - .../SpringHelloWorld.composite | 27 - .../SpringHelloWorld.composite | 27 - .../SpringHelloWorld-context.xml | 0 .../SpringHelloWorld.composite | 34 - .../TestHelloWorldBean.componentType | 27 - .../CouldNotResolveLocation/widget.composite | 29 - .../LocationAttributeMissing/widget.composite | 30 - .../xquery/CouldNotLocateFile/HelloWorld.composite | 28 - .../LocationAttributeMissing/HelloWorld.composite | 28 - .../ClassNotFoundException/Calculator.composite | 53 - .../CalculatorServiceImpl.componentType | 27 - .../Calculator.composite | 53 - .../CalculatorServiceImpl.componentType | 27 - .../InvalidWSDLInterfaceAttr/Calculator.composite | 54 - .../helloworld-interface.wsdl | 67 - .../helloworld-service.wsdl | 49 - .../xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl | 92 -- .../helloworldwsjms.composite | 34 - .../ClassNotFoundException/Calculator.composite | 56 - .../ClassNotFoundException/definitions.xml | 78 -- .../Calculator.composite | 56 - .../RequiredAttributeRolesMissing/definitions.xml | 78 -- .../Calculator.composite | 56 - .../AlwaysProvidedIntentNotFound/definitions.xml | 63 - .../Calculator.composite | 56 - .../ErrorInPolicyIntentDefinition/definitions.xml | 76 - .../xml/IntentNotSpecified/Calculator.composite | 56 - .../policy/xml/IntentNotSpecified/definitions.xml | 175 --- .../MayProvideIntentNotFound/Calculator.composite | 56 - .../xml/MayProvideIntentNotFound/definitions.xml | 63 - .../RequiredAttributeMissing/Calculator.composite | 56 - .../xml/RequiredAttributeMissing/definitions.xml | 70 - .../xml/UnableToMapPolicies/Calculator.composite | 56 - .../policy/xml/UnableToMapPolicies/definitions.xml | 242 ---- .../Calculator.composite | 56 - .../definitions.xml | 68 - .../assembly/xml/ContributionReadException.java | 60 - .../xml/PolicyImplValidationException.java | 60 - .../xml/PolicyServiceValidationException.java | 60 - .../assembly/xml/UnexpectedBindingElement.java | 60 - .../xml/UnexpectedImplementationElement.java | 60 - .../assembly/xml/UnexpectedInterfaceElement.java | 59 - .../binding/ejb/UnknownEJBSessionTypeTestCase.java | 66 - .../binding/ejb/UnknownEJBVersionTestCase.java | 65 - .../jms/DoesntProcessActivationSpecTestCase.java | 59 - .../jms/DoesntProcessDestinationTypeTestCase.java | 59 - .../binding/jms/DoesntProcessHeadersTestCase.java | 61 - .../jms/DoesntProcessResourceAdapterTestCase.java | 59 - ...oesntProcessResponseActivationSpecTestCase.java | 59 - ...ntProcessResponseConnectionFactoryTestCase.java | 59 - ...esntProcessResponseDestinationTypeTestCase.java | 59 - .../jms/InvalidCorrelationSchemeTestCase.java | 59 - .../jms/InvalidJMSDeliveryModeTestCase.java | 59 - .../binding/jms/InvalidJMSPriorityTestCase.java | 59 - .../InvalidResponseDestinationTypeTestCase.java | 59 - .../jms/MissingActivationSpecNameTestCase.java | 59 - .../jms/MissingConnectionFactoryNameTestCase.java | 59 - .../jms/MissingResponseActivationSpecTestCase.java | 59 - .../MissingResponseConnectionFactoryTestCase.java | 59 - .../binding/jms/MustStartWithSchemaTestCase.java | 59 - .../binding/jms/UnexpectedElementTestCase.java | 59 - .../jms/UnexpectedResponseElementTestCase.java | 59 - .../binding/jms/UnknownTokenInURITestCase.java | 59 - .../wsxml/InvalidWsdlElementAttrTestCase.java | 60 - .../binding/wsxml/MustUseWsdlBindingTestCase.java | 60 - .../wsxml/WsdlBindingDoesNotMatchTestCase.java | 60 - .../wsxml/WsdlPortTypeDoesNotMatchTestCase.java | 59 - .../wsxml/WsdlServiceDoesNotMatchTestCase.java | 60 - .../ComponentReferenceTargetNotFoundTestCase.java | 76 - .../warning/DuplicateComponentNameTestCase.java | 60 - ...uplicateImplementationPropertyNameTestCase.java | 64 - ...plicateImplementationReferenceNameTestCase.java | 65 - .../warning/DuplicatePropertyNameTestCase.java | 70 - .../warning/DuplicateReferenceNameTestCase.java | 70 - .../MultipleBindingsForServiceTestCase.java | 70 - .../warning/NoComponentImplementationTestCase.java | 66 - .../warning/NoCompositeNamespaceTestCase.java | 70 - .../warning/NoMatchingBindingTestCase.java | 72 - .../warning/PromotedReferenceNotFoundTestCase.java | 70 - .../warning/PromotedServiceNotFoundTestCase.java | 70 - .../PropertyAttributeMustSupplyNullTestCase.java | 70 - .../warning/PropertyAttributeTestCase.java | 70 - .../warning/PropertyNotFoundTestCase.java | 70 - .../PropertyOverrideManyAttributeTestCase.java | 70 - ...enceIncompatibleComponentInterfaceTestCase.java | 70 - .../ReferenceIncompatibleInterfaceTestCase.java | 70 - .../ReferenceIncompatibleMultiplicityTestCase.java | 70 - .../warning/ReferenceNotFoundTestCase.java | 71 - .../warning/ReferenceWithoutTargetsTestCase.java | 70 - ...ServiceNotFoundForComponentServiceTestCase.java | 70 - .../UnresolvedComponentImplementationTestCase.java | 66 - .../calculator/warning/XSDValidationTestCase.java | 67 - .../java/AttributePackageMissingTestCase.java | 60 - .../AttributeNameSpaceMissingTestCase.java | 60 - .../resource/AttributeURIMissingTestCase.java | 60 - .../xml/AttributeCompositeMissingTestCase.java | 60 - .../xml/MultipleCompositeErrorsTestCase.java | 64 - .../test/java/domain/CustomCompositeBuilder.java | 230 ---- .../AttributeUnrecognizedNamespaceTestCase.java | 59 - .../bpel/AttributeWithoutNamespaceTestCase.java | 59 - .../impl/bpel/BPELProcessNotFoundTestCase.java | 59 - .../bpel/CannotResolveWSDLReferenceTestCase.java | 59 - .../impl/bpel/MyRolePartnerRoleNullTestCase.java | 59 - .../impl/bpel/PartnerLinkHasBothAttrTestCase.java | 68 - .../bpel/PartnerLinkNoMatchingTypeTestCase.java | 59 - .../impl/bpel/PartnerLinkTypeNoRolesTestCase.java | 69 - .../impl/ejb/EJBLinkAttributeMissingTestCase.java | 59 - .../impl/java/ClassNotFoundExceptionTestCase.java | 59 - .../java/ContributionResolveExceptionTestCase.java | 60 - .../resource/CouldNotResolveLocationTestCase.java | 58 - .../resource/LocationAttributeMissingTestCase.java | 59 - .../ContributionResolveExceptionTestCase.java | 66 - .../spring/LocationAttributeMissingTestCase.java | 59 - .../UnableToResolveComponentTypeTestCase.java | 59 - .../widget/CouldNotResolveLocationTestCase.java | 58 - .../widget/LocationAttributeMissingTestCase.java | 59 - .../impl/xquery/CouldNotLocateFileTestCase.java | 59 - .../xquery/LocationAttributeMissingTestCase.java | 59 - .../interfacejava/xml/ClassNotFoundTestCase.java | 59 - .../xml/ContributionResolveExceptionTestCase.java | 59 - .../xml/InvalidWSDLInterfaceAttrTestCase.java | 59 - .../xml/WsdlInterfaceDoesNotMatchTestCase.java | 59 - .../xml/AlwaysProvidedIntentNotFoundTestCase.java | 59 - .../xml/ErrorInPolicyIntentDefinitionTestCase.java | 59 - .../policy/xml/IntentNotSpecifiedTestCase.java | 68 - .../xml/MayProvideIntentNotFoundTestCase.java | 59 - .../xml/RequiredAttributeMissingTestCase.java | 59 - .../policy/xml/UnableToMapPoliciesTestCase.java | 64 - .../UnrecognizedIntentAttachPointTypeTestCase.java | 59 - java/sca/itest/ws-void-args-return/pom.xml | 61 - .../src/main/java/voidtest/Bean.java | 39 - .../src/main/java/voidtest/HelloWorldImpl.java | 64 - .../src/main/java/voidtest/HelloWorldService.java | 47 - .../src/main/java/voidtest/TestClient.java | 23 - .../src/main/java/voidtest/TestClientImpl.java | 53 - .../src/main/resources/voidtest.composite | 41 - .../test/java/voidtest/VoidArgsReturnTestCase.java | 53 - java/sca/itest/wsdl-multiple/pom.xml | 135 -- .../main/java/helloworld/HelloWorldCallback.java | 30 - .../main/java/helloworld/HelloWorldClientImpl.java | 42 - .../main/java/helloworld/HelloWorldService.java | 32 - .../java/helloworld/HelloWorldServiceImpl.java | 37 - .../src/main/resources/auto-wsdl.composite | 44 - .../src/main/resources/manual-wsdl.composite | 46 - .../wsdl/helloworld.HelloWorldCallback.wsdl | 98 -- .../wsdl/helloworld.HelloWorldService.wsdl | 95 -- .../apache/tuscany/sca/itest/AutoWSDLTestCase.java | 65 - .../tuscany/sca/itest/ManualWSDLTestCase.java | 65 - java/sca/itest/wsdl/pom.xml | 135 -- .../services/accountdata/AccountDataService.java | 92 -- .../accountdata/AccountDataServiceImpl.java | 93 -- .../accountdata/AccountServiceClientImpl.java | 79 -- .../services/accountdata/Component2aImpl.java | 79 -- .../services/accountdata/Component2bImpl.java | 79 -- .../services/accountdata/Component3aImpl.java | 79 -- .../services/accountdata/Component3bImpl.java | 79 -- .../services/accountdata/CustomerIdService.java | 98 -- .../src/main/java/helloworld/HelloWorldImpl.java | 33 - .../main/java/helloworld/HelloWorldService.java | 30 - .../helloworld/HelloWorldServiceComponent.java | 43 - .../apache/tuscany/sca/itest/Component2aImpl.java | 38 - .../apache/tuscany/sca/itest/Component2bImpl.java | 39 - .../apache/tuscany/sca/itest/Component3aImpl.java | 39 - .../apache/tuscany/sca/itest/Component3bImpl.java | 39 - .../wsdl/src/main/resources/SDOWSDLTest.composite | 344 ----- .../wsdl/src/main/resources/WSDLTest.composite | 371 ----- .../src/main/resources/wsdl/AccountService.wsdl | 453 ------ .../itest/wsdl/src/main/resources/wsdl/Hello.xsd | 37 - .../wsdl/src/main/resources/wsdl/helloworld.wsdl | 64 - .../apache/tuscany/sca/itest/SDOWSDLTestCase.java | 169 --- .../org/apache/tuscany/sca/itest/WSDLTestCase.java | 146 -- java/sca/itest/wsdl2java/pom.xml | 188 --- .../src/test/resources/AccountService.wsdl | 479 ------- .../wsdl2java/src/test/resources/EchoService.wsdl | 64 - .../wsdl2java/src/test/resources/EchoService.xsd | 40 - .../src/test/resources/StockExceptionTest.wsdl | 167 --- java/sca/itest/wsdlless/pom.xml | 202 --- .../services/accountdata/AccountDataService.java | 95 -- .../accountdata/AccountDataServiceImpl.java | 91 -- .../accountdata/AccountServiceClientImpl.java | 77 -- .../services/accountdata/Component2aImpl.java | 77 -- .../services/accountdata/Component2bImpl.java | 77 -- .../services/accountdata/Component3aImpl.java | 77 -- .../services/accountdata/Component3bImpl.java | 77 -- .../services/accountdata/CustomerIdService.java | 98 -- .../src/main/java/helloworld/HelloWorldImpl.java | 44 - .../main/java/helloworld/HelloWorldService.java | 31 - .../helloworld/HelloWorldServiceComponent.java | 47 - .../apache/tuscany/sca/itest/Component2aImpl.java | 43 - .../apache/tuscany/sca/itest/Component2bImpl.java | 42 - .../apache/tuscany/sca/itest/Component3aImpl.java | 42 - .../apache/tuscany/sca/itest/Component3bImpl.java | 43 - .../wsdlless/src/main/java/service/AnObject.java | 62 - .../src/main/java/service/MoreComplexObject.java | 53 - .../src/main/java/service/SomeService.java | 31 - .../src/main/java/service/SomeServiceImpl.java | 42 - .../src/main/resources/SDOWSDLTest.composite | 321 ----- .../wsdlless/src/main/resources/WSDLTest.composite | 350 ----- .../wsdlless/src/main/resources/some.composite | 33 - .../src/main/resources/wsdl/AccountService.wsdl | 453 ------ .../src/main/resources/wsdl/helloworld.wsdl | 131 -- .../apache/tuscany/sca/itest/SDOWSDLTestCase.java | 173 --- .../org/apache/tuscany/sca/itest/WSDLTestCase.java | 150 -- .../test/java/service/SomeComponentTestCase.java | 83 -- .../src/test/java/service/generated/AnObject.java | 100 -- .../generated/GetUsingMoreComplexObject.java | 79 -- .../GetUsingMoreComplexObjectResponse.java | 79 -- .../java/service/generated/GetUsingString.java | 79 -- .../service/generated/GetUsingStringResponse.java | 79 -- .../java/service/generated/MoreComplexObject.java | 126 -- .../test/java/service/generated/ObjectFactory.java | 141 -- .../test/java/service/generated/SomeService.java | 65 - .../java/service/generated/SomeServiceService.java | 81 -- .../test/java/service/generated/package-info.java | 21 - 3994 files changed, 121562 insertions(+), 121562 deletions(-) create mode 100644 java/sca/contrib/itest/admin/README create mode 100644 java/sca/contrib/itest/admin/pom.xml create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListService.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceByYear.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceImpl.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyLogger.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyService.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyServiceByDate.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyServiceImpl.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyTotalService.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyTotalServiceImpl.java create mode 100644 java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/SCAComponentService.java create mode 100644 java/sca/contrib/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MySimpleServiceInRecursiveTestCase.java create mode 100644 java/sca/contrib/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MySimpleServiceTestCase.java create mode 100644 java/sca/contrib/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MyTotalServiceTestCase.java create mode 100644 java/sca/contrib/itest/admin/src/test/resources/Iteration1Composite.composite create mode 100644 java/sca/contrib/itest/admin/src/test/resources/Iteration3Composite.composite create mode 100644 java/sca/contrib/itest/admin/src/test/resources/MySimpleService.composite create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/pom.xml create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyClientImpl.java create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyService.java create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/MyClient.composite create mode 100644 java/sca/contrib/itest/binding-sca-jms/client/src/test/java/itest/MyClientTestCase.java create mode 100644 java/sca/contrib/itest/binding-sca-jms/pom.xml create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/pom.xml create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyService.java create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyServiceImpl.java create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/MyService.composite create mode 100644 java/sca/contrib/itest/binding-sca-jms/service/src/test/java/itest/MyServiceTestCase.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/pom.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsService.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsServiceImpl.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsTestCase.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.composite create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.wsdl create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/deploy.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.bpel create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.componentType create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.composite create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.wsdl create mode 100644 java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/log4j.properties create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/pom.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorld.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/deploy.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.bpel create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.componentType create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.composite create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.wsdl create mode 100644 java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/log4j.properties create mode 100644 java/sca/contrib/itest/bpel/helloworld/pom.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorld.java create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/deploy.xml create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.bpel create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.componentType create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.composite create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.wsdl create mode 100644 java/sca/contrib/itest/bpel/helloworld/src/test/resources/log4j.properties create mode 100644 java/sca/contrib/itest/bpel/pom.xml create mode 100644 java/sca/contrib/itest/builder/pom.xml create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDImpl.java create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDReferenceMultiplicityImpl.java create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentEImpl.java create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentFImpl.java create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3.java create mode 100644 java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3a.java create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario1/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario10/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario10/service3.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario11/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario11/service3.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario12/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario13/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario2/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario3/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario4/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario5/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario5/scenarios.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario6/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario6/scenarios.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario7/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario7/scenarios.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario8/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8a.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario8/scenarios.wsdl create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario9/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9.composite create mode 100644 java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9a.composite create mode 100644 java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/BuilderTestCase.java create mode 100644 java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CompositeBuilderNonWiringImpl.java create mode 100644 java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CustomCompositeBuilder.java create mode 100644 java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/TestUtils.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/pom.xml create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClient.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClientImpl.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleService.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleServiceImpl.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Alpha.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/AlphaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Beta.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/BetaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Gamma.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/GammaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/resources/CallableReferenceWsReturnTest.composite create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/main/resources/example.composite create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/test/java/com/example/ExampleTestCase.java create mode 100644 java/sca/contrib/itest/callablereferences-ws/src/test/java/org/apache/tuscany/sca/itest/callablerefws/CallableReferenceReturnTestCase.java create mode 100644 java/sca/contrib/itest/callablereferences/pom.xml create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponent.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponentImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponent.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponentImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponent.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponentImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponent.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponentImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalService.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalServiceImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Alpha.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/AlphaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Beta.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/BetaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Gamma.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/GammaImpl.java create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceConversationalTest.composite create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceReturnTest.composite create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceTest.composite create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/CompositeA.composite create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/CompositeB.composite create mode 100644 java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceConversationalTestCase.java create mode 100644 java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java create mode 100644 java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceReturnTestCase.java create mode 100644 java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceTestCase.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/build-jar.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/pom.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/Customer.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/illegal/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/Retailer.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/Shipper.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/complete-supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-impl-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-interface-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal-customer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal1-supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal2-supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/illegalsupplychain.composite create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/supplychain.composite create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/warehouse/JavaWarehouseComponentImpl.componentType create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-test/pom.xml create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionTestCase.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/SupplyChain.java create mode 100644 java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/TuscanyClassloadingTestCaseFIXME.java create mode 100644 java/sca/contrib/itest/contribution-classloader/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/Hello.java create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/HelloImpl.java create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/hello.composite create mode 100644 java/sca/contrib/itest/contribution-import-export/export-composite/src/test/java/org/apache/tuscany/sca/test/contribution/HelloTestCase.java create mode 100644 java/sca/contrib/itest/contribution-import-export/export-java/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-java/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/helloworld/HelloWorldImpl.componentType create mode 100644 java/sca/contrib/itest/contribution-import-export/export-resource/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/ufservices/store.html create mode 100644 java/sca/contrib/itest/contribution-import-export/export-wsdl/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.wsdl create mode 100644 java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.xsd create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldServer.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.wsdl create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.xsd create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworldws.composite create mode 100644 java/sca/contrib/itest/contribution-import-export/import-composite/src/test/java/org/apache/tuscany/test/contribution/HelloWorldServerTestCase.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-java/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-java/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/helloworldws.composite create mode 100644 java/sca/contrib/itest/contribution-import-export/import-java/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-resource/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/store.composite create mode 100644 java/sca/contrib/itest/contribution-import-export/import-resource/src/test/java/org/apache/tuscany/sca/test/contribution/StoreTestCase.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/pom.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldServer.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/helloworldws.composite create mode 100644 java/sca/contrib/itest/contribution-import-export/import-wsdl/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java create mode 100644 java/sca/contrib/itest/contribution-import-export/pom.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/pom.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/hello/Hello.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/hello/HelloImpl.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionCycleTestCaseFIXME.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionMultipleTestCaseFIXME.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionTestCase.java create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/hello.composite create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/helloworld_one.composite create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/hello.composite create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/helloworld_one.composite create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/helloworld_two.composite create mode 100644 java/sca/contrib/itest/contribution/pom.xml create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorClient.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/contribution/src/main/resources/ContributionTest.composite create mode 100644 java/sca/contrib/itest/contribution/src/main/resources/calculator/Calculator.composite create mode 100644 java/sca/contrib/itest/contribution/src/main/resources/calculator/sca-contribution.xml create mode 100644 java/sca/contrib/itest/contribution/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionServiceTestCase.java create mode 100644 java/sca/contrib/itest/contribution/src/test/resources/deployables/sample-calculator.jar create mode 100644 java/sca/contrib/itest/contribution/src/test/resources/repository/sample-calculator.jar create mode 100644 java/sca/contrib/itest/conversations-ws/pom.xml create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/BusinessException.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationIdService.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalCallback.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalClient.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalReferenceClient.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalService.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalServiceNonConversationalCallback.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallback.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationAgeComponentImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationIdComponentImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationMaxIdleComponentImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulNonConversationalCallbackImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatelessImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalReferenceClientImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceRequestImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulNonConversationalCallbackImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessScopeImpl.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/conversational.composite create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/ConversationalServiceStateful.wsdl create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/conversationalWSDL.composite create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java create mode 100644 java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java create mode 100644 java/sca/contrib/itest/corba/pom.xml create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFiveTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFourTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioOneTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioSixTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioThreeTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioTwoTestCase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHost.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHostModuleActivator.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/Color.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnion.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnion.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColor.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFive.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveImpl.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFour.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourException.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourImpl.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioSixServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioTwoServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TAnnotatedStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TColor.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerUnion.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichStruct.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichUnion.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOne.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSix.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThree.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwo.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoComponent.java create mode 100644 java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoServant.java create mode 100644 java/sca/contrib/itest/corba/src/test/resources/META-INF/services/org.apache.tuscany.sca.core.ModuleActivator create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioFive.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioFour.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioOne.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioSix.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioThree.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/ScenarioTwo.composite create mode 100644 java/sca/contrib/itest/corba/src/test/resources/itest_scenario.idl create mode 100644 java/sca/contrib/itest/corba/src/test/resources/scenariofour.xsd create mode 100644 java/sca/contrib/itest/databindings/common/pom.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/java/org/apache/tuscany/sca/itest/generate/Generate.java create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/DatabindingTestCase.java.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/Greeter.wsdl.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterService.java.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClient.java.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClientImpl.java.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceImpl.java.vm create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/generate/generate.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/wsdl/Dummy.txt create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ImportedSchema.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Interop.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Person.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xml create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/datagraph.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoJava.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoModel.xsd create mode 100644 java/sca/contrib/itest/databindings/common/src/test/java/org/apache/tuscany/sca/itest/generate/GenerateTestCase.java create mode 100644 java/sca/contrib/itest/databindings/config.png create mode 100644 java/sca/contrib/itest/databindings/config.svg create mode 100644 java/sca/contrib/itest/databindings/databinding.png create mode 100644 java/sca/contrib/itest/databindings/databinding.svg create mode 100644 java/sca/contrib/itest/databindings/interop.png create mode 100644 java/sca/contrib/itest/databindings/interop.svg create mode 100644 java/sca/contrib/itest/databindings/interop/pom.xml create mode 100644 java/sca/contrib/itest/databindings/interop/src/main/resources/generate/InteropDatabindingTestCase.java.vm create mode 100644 java/sca/contrib/itest/databindings/interop/src/main/resources/generate/JAXBGreeter.wsdl.vm create mode 100644 java/sca/contrib/itest/databindings/interop/src/main/resources/generate/SDOGreeter.wsdl.vm create mode 100644 java/sca/contrib/itest/databindings/interop/src/main/resources/generate/generate.xml create mode 100644 java/sca/contrib/itest/databindings/interop/src/main/resources/generate/interopgreeter.composite.vm create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/pom.xml create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AClientService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean1.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean10.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean11.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean2.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean3.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean31.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsLocalService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloLocalServiceSimple.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimple.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimpleClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesLocalService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesLocalService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AClientServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsLocalServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsTransformer.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloLocalServiceSimpleClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesLocalServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesLocalServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/aservice.wsdl create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/doclitbarewsdl.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/generics-service.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/helloservice.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/primitivesservice.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/standard-types-service.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DocLitBareWsdlTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsDatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesDatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesDatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/pom.xml create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/hello-service.wsdl create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/helloservice.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitives-service.wsdl create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitivesservice.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.composite create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.wsdl create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java create mode 100644 java/sca/contrib/itest/databindings/jaxbgen/pom.xml create mode 100644 java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/generate/generate.xml create mode 100644 java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/greeter.composite create mode 100644 java/sca/contrib/itest/databindings/pom.xml create mode 100644 java/sca/contrib/itest/databindings/readme.html create mode 100644 java/sca/contrib/itest/databindings/sdogen/pom.xml create mode 100644 java/sca/contrib/itest/databindings/sdogen/src/main/resources/generate/generate.xml create mode 100644 java/sca/contrib/itest/databindings/sdogen/src/main/resources/generate/greeter.composite.vm create mode 100644 java/sca/contrib/itest/definitions-multiple/pom.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/PolicyQNames.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/resources/contrib3/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/main/resources/contrib3/definitions.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/MultipleDefinitionsTestCase.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/Policy.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/TestPolicyProcessor.java create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/META-INF/services/org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/contrib1/Calculator.composite create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/contrib1/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/contrib1/definitions.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/contrib1/definitions/definitions.xml create mode 100644 java/sca/contrib/itest/definitions-multiple/src/test/resources/contrib2/definitions.xml create mode 100644 java/sca/contrib/itest/domain/pom.xml create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/AddServiceUpdateImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/domain/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionA/Calculator.composite create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionA/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionB/META-INF/sca-deployables/Calculator.composite create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionC/META-INF/sca-deployables/Calculator.composite create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionDependent/Calculator.composite create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionDependent/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionPrimary/Calculator.composite create mode 100644 java/sca/contrib/itest/domain/src/main/resources/contributionPrimary/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/pom.xml create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExchangeJaxB.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDO.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDOImpl.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/InvalidSymbolSDOException.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/MarketClosedSDOException.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/StockExceptionTest.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/resources/ExceptionTest.composite create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/resources/intracomposite.composite create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/resources/wsdl/StockExceptionTest.wsdl create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/main/resources/xsd/StockExceptionTest.xsd create mode 100644 java/sca/contrib/itest/exceptions-cross-binding-ws/src/test/java/org/apache/tuscany/sca/test/exceptions/IntraCompositeTestCase.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/pom.xml create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExceptionTestJAXB.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExchangeJaxB.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDO.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDOImpl.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/InvalidSymbolSDOException.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/MarketClosedSDOException.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/StockExceptionTest.java create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/resources/ExceptionTest.composite create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/resources/intracomposite.composite create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/resources/wsdl.sdo/StockExceptionTest.wsdl create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/resources/wsdl/StockExceptionTest.wsdl create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/main/resources/xsd/StockExceptionTest.xsd create mode 100644 java/sca/contrib/itest/exceptions-cross-binding/src/test/java/org/apache/tuscany/sca/test/exceptions/IntraCompositeTestCase.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/pom.xml create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/BusinessException.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/BusinessExceptionMinimal.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClient.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClientImpl.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClientMinimalImpl.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleService.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceImpl.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceMinimal.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceMinimalImpl.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/resources/example.composite create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/main/resources/wsdl/ExampleService.wsdl create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/test/java/com/example/ExampleMinimalTestCase.java create mode 100644 java/sca/contrib/itest/exceptions-simple-ws/src/test/java/com/example/ExampleTestCase.java create mode 100644 java/sca/contrib/itest/extended-api/pom.xml create mode 100644 java/sca/contrib/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/BasicService.java create mode 100644 java/sca/contrib/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/MathService.java create mode 100644 java/sca/contrib/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/impl/BasicServiceImpl.java create mode 100644 java/sca/contrib/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/impl/MathServiceImpl.java create mode 100644 java/sca/contrib/itest/extended-api/src/main/resources/BasicService.composite create mode 100644 java/sca/contrib/itest/extended-api/src/main/resources/MathService.composite create mode 100644 java/sca/contrib/itest/extended-api/src/test/java/org/apache/tuscany/sca/test/extended/ServiceLocateTestCase.java create mode 100644 java/sca/contrib/itest/interop-soap-client/pom.xml create mode 100644 java/sca/contrib/itest/interop-soap-client/src/main/java/org/apache/tuscany/test/interop/client/LoopbackInteropDocServiceComponentImpl.java create mode 100644 java/sca/contrib/itest/interop-soap-client/src/main/resources/default.composite create mode 100644 java/sca/contrib/itest/interop-soap-client/src/main/resources/wsdl/interopdoc.wsdl create mode 100644 java/sca/contrib/itest/interop-soap-client/src/test/java/org/apache/tuscany/test/interop/client/InteropDocClientTestCase.java create mode 100644 java/sca/contrib/itest/interop-soap-round2-client/pom.xml create mode 100644 java/sca/contrib/itest/interop-soap-round2-client/src/main/java/org/apache/tuscany/test/interop/client/InteropTestDocLit.java create mode 100644 java/sca/contrib/itest/interop-soap-round2-client/src/main/resources/default.composite create mode 100644 java/sca/contrib/itest/interop-soap-round2-client/src/main/resources/wsdl/interoptestdoclit.wsdl create mode 100644 java/sca/contrib/itest/interop-soap-round2-client/src/test/java/org/apache/tuscany/test/interop/client/InteropTestDocLitTestCase.java create mode 100644 java/sca/contrib/itest/interop-soap-service/pom.xml create mode 100644 java/sca/contrib/itest/interop-soap-service/src/main/java/org/apache/tuscany/test/interop/server/InteropDocServiceComponentImpl.java create mode 100644 java/sca/contrib/itest/interop-soap-service/src/main/resources/wsdl/interopdoc.wsdl create mode 100644 java/sca/contrib/itest/interop-soap-service/src/main/webapp/META-INF/sca/default.scdl create mode 100644 java/sca/contrib/itest/interop-soap-service/src/main/webapp/WEB-INF/web.xml create mode 100755 java/sca/contrib/itest/interop-soap-service/t.bat create mode 100644 java/sca/contrib/itest/jms-args/pom.xml create mode 100644 java/sca/contrib/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/ClientImpl.java create mode 100644 java/sca/contrib/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/MyService.java create mode 100644 java/sca/contrib/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/ServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-args/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms-args/src/main/resources/selectors/selectors.composite create mode 100644 java/sca/contrib/itest/jms-args/src/test/java/org/apache/tuscany/sca/binding/jms/ArgsTestCase.java create mode 100644 java/sca/contrib/itest/jms-callbacks/pom.xml create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClient.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClientImpl.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSService.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSServiceCallback.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/resources/simple/client.composite create mode 100644 java/sca/contrib/itest/jms-callbacks/src/main/resources/simple/tempq.composite create mode 100644 java/sca/contrib/itest/jms-callbacks/src/test/java/org/apache/tuscany/sca/binding/jms/CallbackTestCase.java create mode 100644 java/sca/contrib/itest/jms-callbacks/src/test/java/org/apache/tuscany/sca/binding/jms/TempCallbackQTestCase.java create mode 100644 java/sca/contrib/itest/jms-definitions/pom.xml create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/resources/definitions/definitions.composite create mode 100644 java/sca/contrib/itest/jms-definitions/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms-definitions/src/test/java/org/apache/tuscany/sca/binding/jms/DefinitionsTestCase.java create mode 100644 java/sca/contrib/itest/jms-format/pom.xml create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldReference.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldReferenceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldReference.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldReferenceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldReference.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldReferenceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldServiceReferenceSide.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/README create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldReferenceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/Person.java create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmsbytes/helloworld.composite create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmsdelimited/helloworld.composite create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmsdelimited/helloworld.wsdl create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmsmessage/helloworld.composite create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmsmessage/helloworld.wsdl create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmstextxml/helloworld.composite create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmstextxml/helloworld.wsdl create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jmstextxml/messages.xml create mode 100644 java/sca/contrib/itest/jms-format/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSBytesTestCase.java create mode 100644 java/sca/contrib/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSDelimitedTestCase.java create mode 100644 java/sca/contrib/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSMessageTestCase.java create mode 100644 java/sca/contrib/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSTextXMLTestCase.java create mode 100644 java/sca/contrib/itest/jms-selectors/pom.xml create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/ClientImpl.java create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorService.java create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl1.java create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl2.java create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl3.java create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms-selectors/src/main/resources/selectors/selectors.composite create mode 100644 java/sca/contrib/itest/jms-selectors/src/test/java/org/apache/tuscany/sca/binding/jms/SelectorsTestCase.java create mode 100644 java/sca/contrib/itest/jms/pom.xml create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClient.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClient.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClientImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClientService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgServiceImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java create mode 100644 java/sca/contrib/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.java create mode 100644 java/sca/contrib/itest/jms/src/main/resources/defaults/client.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/defaults/service.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/dynamic/client.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/exceptions/client.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/exceptions/service.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/external/client.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/external/service.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/jms/src/main/resources/nonSCAclient/service.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/oneway/OneWayClient.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/oneway/OneWayService.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/policyHeaders/definitions.xml create mode 100644 java/sca/contrib/itest/jms/src/main/resources/policyHeaders/policyHeaders.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/properties/properties.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/simple/client.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/simple/mpclient.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/simple/service.composite create mode 100644 java/sca/contrib/itest/jms/src/main/resources/simple/uriclient.composite create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/DefaultsTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/DynamicReplyQTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/ExceptionsTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/ExternalBrokerTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/MessageProcessorTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/NonSCAClientTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/OneWayTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/PolicyHeadersTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/PropertiesTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/RPCTestCase.java create mode 100644 java/sca/contrib/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/URIRPCTestCase.java create mode 100644 java/sca/contrib/itest/large-sdo-ws/pom.xml create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrnInqClient.java create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrnInqService.java create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrninqInterface.java create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/resources/trnInq.composite create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/resources/wsdl/IFX170_XSD.xsd create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/main/resources/wsdl/trninq.wsdl create mode 100644 java/sca/contrib/itest/large-sdo-ws/src/test/java/trninq/TrnInqServiceTestCase.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/pom.xml create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java create mode 100644 java/sca/contrib/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java create mode 100644 java/sca/contrib/itest/oneway/build.xml create mode 100644 java/sca/contrib/itest/oneway/pom.xml create mode 100644 java/sca/contrib/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/OneWayClient.java create mode 100644 java/sca/contrib/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/OneWayService.java create mode 100644 java/sca/contrib/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/impl/OneWayClientImpl.java create mode 100644 java/sca/contrib/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/impl/OneWayServiceImpl.java create mode 100644 java/sca/contrib/itest/oneway/src/main/resources/OneWayContribution/META-INF/sca-deployables/oneWay.composite create mode 100644 java/sca/contrib/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/build-bundles.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/pom.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/OSGiBundleImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/Customer.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/OSGiCustomerImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/OSGiRetailerImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/Retailer.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/OSGiShipperImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/Shipper.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/Warehouse.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/Customer2V2.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/CustomerV2.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/customer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/retailer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/shipper-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/warehouse-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/RetailerV2.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/ShipperV2.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/WarehouseV2.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Customer2.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/RetailerJar.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/SupplyChain.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes-v2/src/main/resources/supplychain.composite create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/build-bundles.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/pom.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/OSGiBundleImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/Customer.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/OSGiCustomerImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/OSGiRetailerImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/Retailer.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/OSGiShipperImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/Shipper.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/Customer2V1.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/CustomerV1.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/RetailerV1.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/ShipperV1.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/WarehouseV1.componentType create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Customer2.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/RetailerJar.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/SupplyChain.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-classes/src/main/resources/supplychain.composite create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/pom.xml create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/main/java/org/apache/tuscany/sca/contribution/osgi/OSGiTestUtil.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/MixedContributionTestCase.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/NestedBundleTestCase.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/OSGiResolverTestCase.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/SCAResolverTestCase.java create mode 100644 java/sca/contrib/itest/osgi-contribution/contribution-test/src/test/resources/osgi/felix/felix.config.properties create mode 100644 java/sca/contrib/itest/osgi-contribution/pom.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/build-bundles.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/pom.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/client/CallbackCallback.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/client/CallbackClient.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/client/JavaCallbackClientImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/client/OSGiCallbackClientImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/service/CallbackService.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/service/JavaCallbackServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/callback/service/OSGiCallbackServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalCallback.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClient.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientActivator.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientServiceFactory.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientStatefulImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientStatelessImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClient.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClientActivator.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClientImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/service/ConversationalService.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceActivator.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceFactory.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceStatefulImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceStatelessImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/Greetings.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/HelloWorld.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/JavaGreetingsComponent.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/JavaHelloWorldComponent.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/OSGiGreetingsImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/OSGiHelloWorldImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/sdo/HelloWorldService.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/sdo/HelloWorldServiceComponent.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/sdo/client/HelloWorldClient.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/sdo/client/HelloWorldClientComponent.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/ws/HelloWorld.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/helloworld/ws/HelloWorldService.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteFactoryImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/stockquote/StockQuote.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/OSGiBundleImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/Customer.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerFactoryImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerWithQueryComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerWithQueryImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiStatelessCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiStatelessCustomerImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiVersionedCustomerImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerWithQueryComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerWithQueryImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiVersionedRetailerImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiVersionedRetailerServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/Retailer.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/retailer/RetailerQuery.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperFactoryImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiStatelessShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiStatelessShipperServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiVersionedShipperImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiVersionedShipperServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/shipper/Shipper.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/JavaWarehouseWithQueryComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseServiceImpl.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/Warehouse.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/java/supplychain/warehouse/WarehouseQuery.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/callback/CallbackClient.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/callback/CallbackService.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/callback/callback-test1.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/callback/callback-test2.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/callback/callback-test3.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/conversation/ConversationalClient.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/conversation/ConversationalReferenceClient.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/conversation/ConversationalService.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/conversation/conversation-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/ds/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/ds/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/ds/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/ds/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/ds/factory-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/factory/factory-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/helloworld/Greetings.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/helloworld/HelloWorld.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/ds/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/ds/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/ds/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/ds/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/ds/interfaces-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/interfaces/interfaces-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/callback/CallbackClient.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/callback/CallbackService.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalClient.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalReferenceClient.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalService.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Customer.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Warehouse.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Customer.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Retailer.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Shipper.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/passbyref/Greetings.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/ManagedStockQuoteFactory.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/StockQuote.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/StockQuoteFactory.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuote.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuote.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuoteFactory.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuoteFactory.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldClient.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldClient.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldService.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldService.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Customer.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Customer1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Customer2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Retailer1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Retailer2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Shipper1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Shipper2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Warehouse1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/Warehouse2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Customer1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Customer2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/CustomerV1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/CustomerV2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2V1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2V2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Customer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Customer.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse1.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse2.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/osgi/ws/HelloWorld.mf create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/passbyref/Greetings.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/passbyref/passbyref-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/StockQuote.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/StockQuoteFactory.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/ds/StockQuote.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/ds/StockQuoteFactory.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/ds/properties-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/ds/properties2-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/properties-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/properties/properties2-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/sdo/ds/HelloWorldClient.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/sdo/ds/HelloWorldService.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/sdo/ds/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/sdo/ds/helloworld.wsdl create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/sdo/ds/helloworldsdo.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/ds/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/ds/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/ds/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/ds/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/ds/services-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/services/services-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/stockquote/StockQuote.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Customer1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Customer2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Retailer1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Retailer2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Shipper1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Shipper2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Warehouse1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/Warehouse2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Customer1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Customer2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Retailer1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Retailer2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Shipper1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Shipper2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Warehouse1.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/Warehouse2.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/ds/version-ds-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/version/version-test.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/Customer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/Retailer.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/Shipper.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/Warehouse.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/wiring-ds-test1.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/ds/wiring-ds-test2.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/wiring-test1.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/wiring/wiring-test2.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/ws/HelloWorld.componentType create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/ws/helloworld.wsdl create mode 100644 java/sca/contrib/itest/osgi-implementation/src/main/resources/ws/ws-helloworld.composite create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/callback/Callback1TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/callback/Callback2TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/callback/Callback3TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/callback/CallbackTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/conversation/ConversationTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/helloworld/passbyref/PassByRefTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/helloworld/sdo/SdoTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/helloworld/ws/HelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/SupplyChainTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/VersionedSupplyChainTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/factory/DSFactoryTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/factory/FactoryTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/interfaces/DSInterfacesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/interfaces/InterfacesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/properties/DSProperties2TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/properties/DSPropertiesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/properties/Properties2TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/properties/PropertiesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/services/DSServicesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/services/ServicesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/version/DSVersionTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/version/VersionTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/wiring/DSWiring1TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/wiring/DSWiring2TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/wiring/Wiring1TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/supplychain/wiring/Wiring2TestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/test/OSGiTestCase.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/java/util/OSGiTestUtil.java create mode 100644 java/sca/contrib/itest/osgi-implementation/src/test/resources/osgi/felix/felix.config.properties create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/pom.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/EquinoxTestRuntime.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/FelixTestRuntime.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/OSGiTestRuntime.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/util/OSGiRuntimeLoader.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/util/TuscanyLoader.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/harness/OSGiTuscanyNonOSGiTestHarness.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/harness/OSGiTuscanyTestHarness.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorImplementationPoliciesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorRmiTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorScriptTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CallbackWsClientTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CallbackWsServiceTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceJmsTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceSecureTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/NonOSGiSamplesTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/OSGiSupplyChainTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/OSGiTuscanyRuntimeTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/TuscanySampleExtensionsTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/TuscanySamplesUsingOldDomainTestCase.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/resources/META-INF/MANIFEST.MF create mode 100644 java/sca/contrib/itest/osgi-tuscany/osgi-tuscany-test/src/test/resources/felix/felix.config.properties create mode 100644 java/sca/contrib/itest/osgi-tuscany/pom.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/build-bundles.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/pom.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/client/SupplyChainClient.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/customer/Customer.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/retailer/Retailer.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/shipper/Shipper.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/warehouse/Warehouse.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/SupplyChain.mf create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/SupplyChainClient.mf create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/supplychain.composite create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/ws/Customer.wsdl create mode 100644 java/sca/contrib/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/ws/supplychain.composite create mode 100644 java/sca/contrib/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml create mode 100644 java/sca/contrib/itest/osgi-tuscany/tuscany-osgi-installer/src/main/java/org/apache/tuscany/sca/installer/InstallerBundleActivator.java create mode 100644 java/sca/contrib/itest/osgi-tuscany/tuscany-versioned/pom.xml create mode 100644 java/sca/contrib/itest/policy-security-basicauth/pom.xml create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldClientImpl.java create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/main/resources/helloworld.composite create mode 100644 java/sca/contrib/itest/policy-security-basicauth/src/test/java/org/apache/tuscany/sca/itest/BasicAuthTestCase.java create mode 100644 java/sca/contrib/itest/policy-security-jsr250/pom.xml create mode 100644 java/sca/contrib/itest/policy-security-jsr250/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/policy-security-jsr250/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/policy-security-jsr250/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/policy-security-jsr250/src/main/resources/helloworld.composite create mode 100644 java/sca/contrib/itest/policy-security-jsr250/src/test/java/org/apache/tuscany/sca/itest/PolicySecurityJSR250TestCase.java create mode 100644 java/sca/contrib/itest/policy-security-token/pom.xml create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/java/helloworld/HelloWorldClientImpl.java create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/java/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/resources/helloworld.composite create mode 100644 java/sca/contrib/itest/policy-security-token/src/main/resources/jndi.properties create mode 100644 java/sca/contrib/itest/policy-security-token/src/test/java/org/apache/tuscany/sca/itest/TokenAuthTestCase.java create mode 100644 java/sca/contrib/itest/policy-security/pom.xml create mode 100644 java/sca/contrib/itest/policy-security/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/policy-security/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/policy-security/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/policy-security/src/main/resources/helloworld.composite create mode 100644 java/sca/contrib/itest/policy-security/src/test/java/org/apache/tuscany/sca/itest/PolicyIdentityTestCase.java create mode 100644 java/sca/contrib/itest/policy/pom.xml create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/CalculatorClient.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/PolicyQNames.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/policy/TestImplPolicyHandler.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/policy/TestRefPolicyHandler.java create mode 100644 java/sca/contrib/itest/policy/src/main/java/calculator/policy/TestSvcPolicyHandler.java create mode 100644 java/sca/contrib/itest/policy/src/main/resources/Calculator.composite create mode 100644 java/sca/contrib/itest/policy/src/main/resources/META-INF/services/org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor create mode 100644 java/sca/contrib/itest/policy/src/main/resources/META-INF/services/org.apache.tuscany.sca.policy.util.PolicyHandler create mode 100644 java/sca/contrib/itest/policy/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/policy/src/test/java/org/apache/tuscany/sca/itest/PoliciedCalculatorTestCase.java create mode 100644 java/sca/contrib/itest/policy/src/test/java/org/apache/tuscany/sca/itest/Policy.java create mode 100644 java/sca/contrib/itest/policy/src/test/java/org/apache/tuscany/sca/itest/TestPolicyProcessor.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/pom.xml create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/java/com/example/BusinessException.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleClient.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleClientImpl.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleService.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleServiceImpl.java create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/resources/example.composite create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/resources/wsdl/ExampleService.wsdl create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/main/resources/wsdl/ExampleServiceTypes.xsd create mode 100644 java/sca/contrib/itest/promotion-interface-missmatch/src/test/java/com/example/ExampleTestCase.java create mode 100644 java/sca/contrib/itest/recursive-ws/pom.xml create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/policy/Target.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/policy/TargetClientImpl.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/policy/TargetServiceImpl.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/recursive/Composer.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/recursive/ComposerClient.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/recursive/ComposerClientImpl.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/recursive/ComposerImpl.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/java/recursive/ComposerServer.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/Client.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/Inner.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/Outer.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/bindingoverride/InnerComposite.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/bindingoverride/OuterComposite.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/policy/PolicyInnerComposite.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/policy/PolicyOuterComposite.composite create mode 100644 java/sca/contrib/itest/recursive-ws/src/main/resources/policy/definitions.xml create mode 100644 java/sca/contrib/itest/recursive-ws/src/test/java/bindingoverride/BindingOverrideTestCase.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/test/java/policy/PolicyTestCase.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/test/java/recursive/ComposerClientTestCase.java create mode 100644 java/sca/contrib/itest/recursive-ws/src/test/java/recursive/ComposerTestServer.java create mode 100644 java/sca/contrib/itest/recursive/pom.xml create mode 100644 java/sca/contrib/itest/recursive/src/main/java/circular/include/DemoClass.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/CompositeClient.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/Source.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/SourceCallback.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/SourceImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/Target.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/composite/TargetImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/foo/A.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/foo/B.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/foo/I.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/policy/Target.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/policy/TargetClientImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/policy/TargetServiceImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/sample/ComponentAImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/sample/ComponentCImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/sample/ComponentEImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/sample/ComponentFImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/sample/Service1.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test/Aggregator.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test/AggregatorImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test/InnerSourceImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test/OuterSourceImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test/Source.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test1/composite/Target.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test1/composite/TargetOne.java create mode 100644 java/sca/contrib/itest/recursive/src/main/java/test1/composite/TargetTwo.java create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/AComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/BComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/CComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Composite1.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Composite2.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Composite3.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Demo1Composite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Demo2Composite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Inner.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/InnerComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/InnerComposite2.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/Outer.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/OuterComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/foo/foo.png create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/foo/o1.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/foo/o2.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/foo/o3.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/foo/o4.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/policy/PolicyInnerComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/policy/PolicyOuterComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/policy/definitions.xml create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/test1/InnerComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/main/resources/test1/OuterComposite.composite create mode 100644 java/sca/contrib/itest/recursive/src/test/java/circular/include/CircularIncludeTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/composite/CompositeTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/composite/LocateServiceEmbeddedSCADomainTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/composite/LocateServiceSCADomainTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/foo/O2TestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/foo/O4TestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/policy/PolicyTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/C.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/CImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/NestedTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/RecursiveCompositeTestCaseFIXME.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/X.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/XImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/Y.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/sample/YImpl.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/test/InnerTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/test/OuterTestCase.java create mode 100644 java/sca/contrib/itest/recursive/src/test/java/test1/composite/CompositeClientTestCase.java create mode 100644 java/sca/contrib/itest/serialization/pom.xml create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalService.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalServiceCallback.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalServiceImpl.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedClient.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedClientImpl.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedConversationalClient.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedConversationalClientImpl.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessService.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessServiceCallback.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessServiceImpl.java create mode 100644 java/sca/contrib/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/utils/ServiceReferenceUtils.java create mode 100644 java/sca/contrib/itest/serialization/src/main/resources/ServiceReferenceSerializationTest.composite create mode 100644 java/sca/contrib/itest/serialization/src/main/resources/nestedcomposite.composite create mode 100644 java/sca/contrib/itest/serialization/src/test/java/org/apache/tuscany/sca/itest/servicereference/SerializeServiceReferenceTestCase.java create mode 100644 java/sca/contrib/itest/spring/pom.xml create mode 100644 java/sca/contrib/itest/spring/src/main/java/bigbank/stockquote/StockQuoteImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/bigbank/stockquote/StockQuoteService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/AddService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/CalculatorService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/DivideService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/MultiplyService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/SubtractService.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/security/CalculatorCallbackHandler.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/security/JaasLoginModule.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/calculator/security/UserPrincipal.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/context/access/SCAApplicationContextProvider.java create mode 100644 java/sca/contrib/itest/spring/src/main/java/spring/annotations/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/spring/src/main/resources/CalculatorService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/SpringDelegationHelloWorld-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/SpringHelloWorld-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/context-access/CalculatorService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/context-imports/CalculatorService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/context-imports/SpringImport-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/context-multiple/StockQuoteService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/context-multiple/beanRefContext.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/implementation-policies/CalculatorService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/META-INF/sca/spring-annotation/CalculatorService-context.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/context/access/Calculator.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/context/imports/Calculator.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/context/multiple/StockQuote.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/implementation/policies/Calculator.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/implementation/policies/CalculatorJass.config create mode 100644 java/sca/contrib/itest/spring/src/main/resources/implementation/policies/CalculatorLogMessages.properties create mode 100644 java/sca/contrib/itest/spring/src/main/resources/implementation/policies/definitions.xml create mode 100644 java/sca/contrib/itest/spring/src/main/resources/org/apache/tuscany/sca/itest/spring/SpringDelegationHelloWorld.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/org/apache/tuscany/sca/itest/spring/SpringHelloWorld.composite create mode 100644 java/sca/contrib/itest/spring/src/main/resources/spring/annotations/Calculator.composite create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/access/CalculatorClient.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/access/ContextAccessTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/imports/CalculatorClient.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/imports/ContextImportsTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/multiple/MultipleContextTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/context/multiple/StockQuoteServer.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/implementation/policies/CalculatorClient.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/implementation/policies/ImplementationPoliciesTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/AbstractHelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/AbstractSCATestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/HelloWorld.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/HelloWorldProxy.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/SpringDelegationHelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/SpringHelloWorldTestCase.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/TestHelloWorldBean.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/TestHelloWorldDelegatorBean.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/spring/annotations/CalculatorClient.java create mode 100644 java/sca/contrib/itest/spring/src/test/java/spring/annotations/SpringAnnotationsTestCase.java create mode 100644 java/sca/contrib/itest/transaction/pom.xml create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountNotFoundException.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountService.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountServiceImpl.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/CheckingAccountServiceImpl.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/OverDraftException.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/SavingsAccountServiceImpl.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/TransferService.java create mode 100644 java/sca/contrib/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/TransferServiceImpl.java create mode 100644 java/sca/contrib/itest/transaction/src/main/resources/accounts.composite create mode 100644 java/sca/contrib/itest/transaction/src/main/resources/definitions.xml create mode 100644 java/sca/contrib/itest/transaction/src/main/resources/log4j.properties create mode 100644 java/sca/contrib/itest/transaction/src/test/java/org/apache/tuscany/sca/itest/transaction/ConcurrentXAResourceTestCase.java create mode 100644 java/sca/contrib/itest/transaction/src/test/java/org/apache/tuscany/sca/itest/transaction/TransactionTestCase.java create mode 100644 java/sca/contrib/itest/validation/pom.xml create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/ejb/account/Customer.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/ejb/account/CustomerImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/ejb/calculator/AddService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/ejb/calculator/AddServiceHome.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/jms/HelloWorldService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/binding/jms/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/AddService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/AddServiceImplWithServiceName.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/CalculatorClient.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/CalculatorService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/DivideService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/MultiplyService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/PropertyService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/PropertyServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/SubtractService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/calculator/warning/SubtractServiceImplWithServiceName.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/AddService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/AddServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/CalculatorClient.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/CalculatorService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/DivideService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/DivideServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/MultiplyService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/MultiplyServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/SubtractService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/java/SubtractServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/spring/HelloWorld.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/spring/HelloWorldProxy.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/impl/spring/TestHelloWorldBean.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/interfacejava/xml/CalculatorService.java create mode 100644 java/sca/contrib/itest/validation/src/main/java/interfacejava/xml/CalculatorServiceImpl.java create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ComponentReferenceTargetNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateComponentName/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateImplementationPropertyName/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateImplementationPropertyName/dummyImplementation.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateImplementationReferenceName/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateImplementationReferenceName/dummyImplementation.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicatePropertyName/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/DuplicateReferenceName/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/META-INF/sca/SpringHelloWorld-context.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/MultipleBindingsForService/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/NoComponentImplementation/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/NoCompositeNamespace/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/NoMatchingBinding/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PromotedReferenceNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PromotedServiceNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PropertyAttribute/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PropertyAttribute/CalculatorNullMustSupply.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PropertyAttribute/CalculatorOverrideManyAttribute.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/PropertyNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ReferenceIncompatibleComponentInterface/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ReferenceIncompatibleInterface/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ReferenceIncompatibleMultiplicity/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ReferenceNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ReferenceWithoutTargets/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/ServiceNotFoundForComponentService/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/UnresolvedComponentImplementation/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/XsdValidation/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/ContributionReadException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/PolicyImplValidationException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/PolicyServiceValidationException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/UnexpectedBindingElement/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/UnexpectedImplementationElement/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/assemblyxml/UnexpectedInterfaceElement/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/InvalidWsdlElementAttr/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/MustUseWsdlBinding/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlPortTypeDoesNotMatch/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlPortTypeDoesNotMatch/helloworldwsclient.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingejb/UnknownEJBSessionType/account.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingejb/UnknownEJBVersion/account.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessActivationSpec/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessDestinationType/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessHeaders/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessResourceAdapter/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseActivationSpec/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseConnectionFactory/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseDestinationType/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/InvalidCorrelationScheme/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/InvalidJMSDeliveryMode/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/InvalidJMSPriority/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/InvalidResponseDestinationType/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/MissingActivationSpecName/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/MissingConnectionFactoryName/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/MissingResponseActivationSpec/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/MissingResponseConnectionFactory/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/MustStartWithSchema/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/UnexpectedElement/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/UnexpectedResponseElement/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/bindingjms/UnknownTokenInURI/service.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/java/AttributePackageMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/namespace/AttributeNameSpaceMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/resource/AttributeURIMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/resource/AttributeURIMissing/META-INF/sca-contribution.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/xml/AttributeCompositeMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/xml/AttributeCompositeMissing/sca-contribution.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/xml/MultipleCompositeErrors/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/contribution/xml/MultipleCompositeErrors/sca-contribution.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/AttributeUnrecognizedNamespace/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/AttributeWithoutNamespace/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/deploy.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.bpel create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/ejb/EJBLinkAttributeMissing/ejb.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/java/ClassNotFoundException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/java/ContributionResolveException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/osgi/CouldNotLocateOSGiBundle/OSGiTestService.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/osgi/CouldNotLocateOSGiBundle/osgitest.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/osgi/MissingComponentTypeFile/osgitest.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/osgi/PropertyShouldSpecifySR/OSGiTestService.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/osgi/PropertyShouldSpecifySR/osgitest.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/resource/CouldNotResolveLocation/resource.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/resource/LocationAttributeMissing/resource.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/spring/ContributionResolveException/SpringHelloWorld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/spring/LocationAttributeMissing/SpringHelloWorld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/SpringHelloWorld-context.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/SpringHelloWorld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/TestHelloWorldBean.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/widget/CouldNotResolveLocation/widget.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/widget/LocationAttributeMissing/widget.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/xquery/CouldNotLocateFile/HelloWorld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/impl/xquery/LocationAttributeMissing/HelloWorld.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacejava/xml/ClassNotFoundException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacejava/xml/ClassNotFoundException/CalculatorServiceImpl.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacejava/xml/ContributionResolveException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacejava/xml/ContributionResolveException/CalculatorServiceImpl.componentType create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/helloworld-interface.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/helloworld-service.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl create mode 100644 java/sca/contrib/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/security/ClassNotFoundException/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/security/ClassNotFoundException/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/security/RequiredAttributeRolesMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/security/RequiredAttributeRolesMissing/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/AlwaysProvidedIntentNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/AlwaysProvidedIntentNotFound/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/ErrorInPolicyIntentDefinition/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/ErrorInPolicyIntentDefinition/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/IntentNotSpecified/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/IntentNotSpecified/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/MayProvideIntentNotFound/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/MayProvideIntentNotFound/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/RequiredAttributeMissing/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/RequiredAttributeMissing/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/UnableToMapPolicies/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/UnableToMapPolicies/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/UnrecognizedIntentAttachPointType/Calculator.composite create mode 100644 java/sca/contrib/itest/validation/src/main/resources/policy/xml/UnrecognizedIntentAttachPointType/definitions.xml create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/ContributionReadException.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/contribution/xml/MultipleCompositeErrorsTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/domain/CustomCompositeBuilder.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java create mode 100644 java/sca/contrib/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/pom.xml create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/java/voidtest/Bean.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/java/voidtest/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/java/voidtest/HelloWorldService.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/java/voidtest/TestClient.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/java/voidtest/TestClientImpl.java create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/main/resources/voidtest.composite create mode 100644 java/sca/contrib/itest/ws-void-args-return/src/test/java/voidtest/VoidArgsReturnTestCase.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/pom.xml create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldCallback.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldClientImpl.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldServiceImpl.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/resources/auto-wsdl.composite create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/resources/manual-wsdl.composite create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/resources/wsdl/helloworld.HelloWorldCallback.wsdl create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/main/resources/wsdl/helloworld.HelloWorldService.wsdl create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/test/java/org/apache/tuscany/sca/itest/AutoWSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdl-multiple/src/test/java/org/apache/tuscany/sca/itest/ManualWSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdl/pom.xml create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountDataService.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountDataServiceImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountServiceClientImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component2aImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component2bImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component3aImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component3bImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/bigbank/account/services/accountdata/CustomerIdService.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/helloworld/HelloWorldServiceComponent.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component2aImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component2bImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component3aImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component3bImpl.java create mode 100644 java/sca/contrib/itest/wsdl/src/main/resources/SDOWSDLTest.composite create mode 100644 java/sca/contrib/itest/wsdl/src/main/resources/WSDLTest.composite create mode 100644 java/sca/contrib/itest/wsdl/src/main/resources/wsdl/AccountService.wsdl create mode 100644 java/sca/contrib/itest/wsdl/src/main/resources/wsdl/Hello.xsd create mode 100644 java/sca/contrib/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl create mode 100644 java/sca/contrib/itest/wsdl/src/test/java/org/apache/tuscany/sca/itest/SDOWSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdl/src/test/java/org/apache/tuscany/sca/itest/WSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdl2java/pom.xml create mode 100644 java/sca/contrib/itest/wsdl2java/src/test/resources/AccountService.wsdl create mode 100644 java/sca/contrib/itest/wsdl2java/src/test/resources/EchoService.wsdl create mode 100644 java/sca/contrib/itest/wsdl2java/src/test/resources/EchoService.xsd create mode 100644 java/sca/contrib/itest/wsdl2java/src/test/resources/StockExceptionTest.wsdl create mode 100644 java/sca/contrib/itest/wsdlless/pom.xml create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountDataService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountDataServiceImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountServiceClientImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component2aImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component2bImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component3aImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component3bImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/CustomerIdService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/helloworld/HelloWorldImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/helloworld/HelloWorldService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/helloworld/HelloWorldServiceComponent.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component2aImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component2bImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component3aImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component3bImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/service/AnObject.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/service/MoreComplexObject.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/service/SomeService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/java/service/SomeServiceImpl.java create mode 100644 java/sca/contrib/itest/wsdlless/src/main/resources/SDOWSDLTest.composite create mode 100644 java/sca/contrib/itest/wsdlless/src/main/resources/WSDLTest.composite create mode 100644 java/sca/contrib/itest/wsdlless/src/main/resources/some.composite create mode 100644 java/sca/contrib/itest/wsdlless/src/main/resources/wsdl/AccountService.wsdl create mode 100644 java/sca/contrib/itest/wsdlless/src/main/resources/wsdl/helloworld.wsdl create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/org/apache/tuscany/sca/itest/SDOWSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/org/apache/tuscany/sca/itest/WSDLTestCase.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/SomeComponentTestCase.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/AnObject.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/GetUsingMoreComplexObject.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/GetUsingMoreComplexObjectResponse.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/GetUsingString.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/GetUsingStringResponse.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/MoreComplexObject.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/ObjectFactory.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/SomeService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/SomeServiceService.java create mode 100644 java/sca/contrib/itest/wsdlless/src/test/java/service/generated/package-info.java delete mode 100644 java/sca/itest/admin/README delete mode 100644 java/sca/itest/admin/pom.xml delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListService.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceByYear.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceImpl.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyLogger.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyService.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyServiceByDate.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyServiceImpl.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyTotalService.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyTotalServiceImpl.java delete mode 100644 java/sca/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/SCAComponentService.java delete mode 100644 java/sca/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MySimpleServiceInRecursiveTestCase.java delete mode 100644 java/sca/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MySimpleServiceTestCase.java delete mode 100644 java/sca/itest/admin/src/test/java/org/apache/tuscany/sca/itest/admin/MyTotalServiceTestCase.java delete mode 100644 java/sca/itest/admin/src/test/resources/Iteration1Composite.composite delete mode 100644 java/sca/itest/admin/src/test/resources/Iteration3Composite.composite delete mode 100644 java/sca/itest/admin/src/test/resources/MySimpleService.composite delete mode 100644 java/sca/itest/binding-sca-jms/client/pom.xml delete mode 100644 java/sca/itest/binding-sca-jms/client/src/main/java/itest/MyClientImpl.java delete mode 100644 java/sca/itest/binding-sca-jms/client/src/main/java/itest/MyService.java delete mode 100644 java/sca/itest/binding-sca-jms/client/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/binding-sca-jms/client/src/main/resources/MyClient.composite delete mode 100644 java/sca/itest/binding-sca-jms/client/src/test/java/itest/MyClientTestCase.java delete mode 100644 java/sca/itest/binding-sca-jms/pom.xml delete mode 100644 java/sca/itest/binding-sca-jms/service/pom.xml delete mode 100644 java/sca/itest/binding-sca-jms/service/src/main/java/itest/MyService.java delete mode 100644 java/sca/itest/binding-sca-jms/service/src/main/java/itest/MyServiceImpl.java delete mode 100644 java/sca/itest/binding-sca-jms/service/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/binding-sca-jms/service/src/main/resources/MyService.composite delete mode 100644 java/sca/itest/binding-sca-jms/service/src/test/java/itest/MyServiceTestCase.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/pom.xml delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsService.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsServiceImpl.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsTestCase.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldTestCase.java delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.composite delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.wsdl delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/helloworld/deploy.xml delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.bpel delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.componentType delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.composite delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.wsdl delete mode 100644 java/sca/itest/bpel/helloworld-reference/src/test/resources/log4j.properties delete mode 100644 java/sca/itest/bpel/helloworld-ws/pom.xml delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorld.java delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorldTestCase.java delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/helloworld/deploy.xml delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.bpel delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.componentType delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.composite delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.wsdl delete mode 100644 java/sca/itest/bpel/helloworld-ws/src/test/resources/log4j.properties delete mode 100644 java/sca/itest/bpel/helloworld/pom.xml delete mode 100644 java/sca/itest/bpel/helloworld/src/test/java/helloworld/HelloWorld.java delete mode 100644 java/sca/itest/bpel/helloworld/src/test/java/helloworld/HelloWorldTestCase.java delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/helloworld/deploy.xml delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.bpel delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.componentType delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.composite delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.wsdl delete mode 100644 java/sca/itest/bpel/helloworld/src/test/resources/log4j.properties delete mode 100644 java/sca/itest/bpel/pom.xml delete mode 100644 java/sca/itest/builder/pom.xml delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDImpl.java delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDReferenceMultiplicityImpl.java delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentEImpl.java delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentFImpl.java delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3.java delete mode 100644 java/sca/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3a.java delete mode 100644 java/sca/itest/builder/src/main/resources/scenario1/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario1/scenario1.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario1/scenario1a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario10/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario10/scenario10.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario10/scenario10a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario10/service3.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario11/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario11/scenario11.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario11/scenario11a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario11/service3.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario12/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario12/scenario12.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario12/scenario12a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario13/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario13/scenario13.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario13/scenario13a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario2/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario2/scenario2.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario2/scenario2a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario3/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario3/scenario3.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario3/scenario3a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario4/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario4/scenario4.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario4/scenario4a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario5/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario5/scenario5.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario5/scenario5a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario5/scenarios.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario6/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario6/scenario6.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario6/scenario6a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario6/scenarios.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario7/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario7/scenario7.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario7/scenario7a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario7/scenarios.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario8/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario8/scenario8.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario8/scenario8a.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario8/scenarios.wsdl delete mode 100644 java/sca/itest/builder/src/main/resources/scenario9/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/builder/src/main/resources/scenario9/scenario9.composite delete mode 100644 java/sca/itest/builder/src/main/resources/scenario9/scenario9a.composite delete mode 100644 java/sca/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/BuilderTestCase.java delete mode 100644 java/sca/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CompositeBuilderNonWiringImpl.java delete mode 100644 java/sca/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CustomCompositeBuilder.java delete mode 100644 java/sca/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/TestUtils.java delete mode 100644 java/sca/itest/callablereferences-ws/pom.xml delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/com/example/ExampleClient.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/com/example/ExampleClientImpl.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/com/example/ExampleService.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/com/example/ExampleServiceImpl.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Alpha.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/AlphaImpl.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Beta.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/BetaImpl.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Gamma.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/GammaImpl.java delete mode 100644 java/sca/itest/callablereferences-ws/src/main/resources/CallableReferenceWsReturnTest.composite delete mode 100644 java/sca/itest/callablereferences-ws/src/main/resources/example.composite delete mode 100644 java/sca/itest/callablereferences-ws/src/test/java/com/example/ExampleTestCase.java delete mode 100644 java/sca/itest/callablereferences-ws/src/test/java/org/apache/tuscany/sca/itest/callablerefws/CallableReferenceReturnTestCase.java delete mode 100644 java/sca/itest/callablereferences/pom.xml delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponent.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponentImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponent.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponentImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponent.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponentImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponent.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponentImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalService.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalServiceImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Alpha.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/AlphaImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Beta.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/BetaImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Gamma.java delete mode 100644 java/sca/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/GammaImpl.java delete mode 100644 java/sca/itest/callablereferences/src/main/resources/CallableReferenceConversationalTest.composite delete mode 100644 java/sca/itest/callablereferences/src/main/resources/CallableReferenceReturnTest.composite delete mode 100644 java/sca/itest/callablereferences/src/main/resources/CallableReferenceTest.composite delete mode 100644 java/sca/itest/callablereferences/src/main/resources/nodeA/CompositeA.composite delete mode 100644 java/sca/itest/callablereferences/src/main/resources/nodeA/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/callablereferences/src/main/resources/nodeB/CompositeB.composite delete mode 100644 java/sca/itest/callablereferences/src/main/resources/nodeB/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceConversationalTestCase.java delete mode 100644 java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java delete mode 100644 java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceReturnTestCase.java delete mode 100644 java/sca/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceTestCase.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/build-jar.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/pom.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/Customer.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/illegal/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/Retailer.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/Shipper.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/complete-supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-impl-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-interface-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal-customer-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal1-supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal2-supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/illegalsupplychain.composite delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/supplychain.composite delete mode 100644 java/sca/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/warehouse/JavaWarehouseComponentImpl.componentType delete mode 100644 java/sca/itest/contribution-classloader/contribution-test/pom.xml delete mode 100644 java/sca/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionTestCase.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/SupplyChain.java delete mode 100644 java/sca/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/TuscanyClassloadingTestCaseFIXME.java delete mode 100644 java/sca/itest/contribution-classloader/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/export-composite/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/export-composite/src/main/java/hello/Hello.java delete mode 100644 java/sca/itest/contribution-import-export/export-composite/src/main/java/hello/HelloImpl.java delete mode 100644 java/sca/itest/contribution-import-export/export-composite/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/export-composite/src/main/resources/hello.composite delete mode 100644 java/sca/itest/contribution-import-export/export-composite/src/test/java/org/apache/tuscany/sca/test/contribution/HelloTestCase.java delete mode 100644 java/sca/itest/contribution-import-export/export-java/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/export-java/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/contribution-import-export/export-java/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/export-java/src/main/resources/helloworld/HelloWorldImpl.componentType delete mode 100644 java/sca/itest/contribution-import-export/export-resource/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/export-resource/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/export-resource/src/main/resources/ufservices/store.html delete mode 100644 java/sca/itest/contribution-import-export/export-wsdl/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/export-wsdl/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.wsdl delete mode 100644 java/sca/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.xsd delete mode 100644 java/sca/itest/contribution-import-export/import-composite/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldServer.java delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/resources/helloworld.wsdl delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/resources/helloworld.xsd delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/main/resources/helloworldws.composite delete mode 100644 java/sca/itest/contribution-import-export/import-composite/src/test/java/org/apache/tuscany/test/contribution/HelloWorldServerTestCase.java delete mode 100644 java/sca/itest/contribution-import-export/import-java/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/import-java/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/contribution-import-export/import-java/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/import-java/src/main/resources/helloworldws.composite delete mode 100644 java/sca/itest/contribution-import-export/import-java/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java delete mode 100644 java/sca/itest/contribution-import-export/import-resource/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/import-resource/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/import-resource/src/main/resources/store.composite delete mode 100644 java/sca/itest/contribution-import-export/import-resource/src/test/java/org/apache/tuscany/sca/test/contribution/StoreTestCase.java delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/pom.xml delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldServer.java delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/main/resources/helloworldws.composite delete mode 100644 java/sca/itest/contribution-import-export/import-wsdl/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java delete mode 100644 java/sca/itest/contribution-import-export/pom.xml delete mode 100644 java/sca/itest/contribution-multiple/pom.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/hello/Hello.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/hello/HelloImpl.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/test/ContributionCycleTestCaseFIXME.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/test/ContributionMultipleTestCaseFIXME.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/java/test/ContributionTestCase.java delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-cycle-export/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-cycle-export/hello.composite delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-cycle-import/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-cycle-import/helloworld_one.composite delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-export/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-export/hello.composite delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-import-one/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-import-one/helloworld_one.composite delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-import-two/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/contribution-multiple/src/test/resources/contribution-import-two/helloworld_two.composite delete mode 100644 java/sca/itest/contribution/pom.xml delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/CalculatorClient.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/contribution/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/contribution/src/main/resources/ContributionTest.composite delete mode 100644 java/sca/itest/contribution/src/main/resources/calculator/Calculator.composite delete mode 100644 java/sca/itest/contribution/src/main/resources/calculator/sca-contribution.xml delete mode 100644 java/sca/itest/contribution/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionServiceTestCase.java delete mode 100644 java/sca/itest/contribution/src/test/resources/deployables/sample-calculator.jar delete mode 100644 java/sca/itest/contribution/src/test/resources/repository/sample-calculator.jar delete mode 100644 java/sca/itest/conversations-ws/pom.xml delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/BusinessException.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationIdService.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalCallback.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalClient.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalReferenceClient.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalService.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalServiceNonConversationalCallback.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallback.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationAgeComponentImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationIdComponentImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationMaxIdleComponentImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulNonConversationalCallbackImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatelessImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalReferenceClientImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceRequestImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulNonConversationalCallbackImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessScopeImpl.java delete mode 100644 java/sca/itest/conversations-ws/src/main/resources/Conversational/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/conversations-ws/src/main/resources/Conversational/conversational.composite delete mode 100644 java/sca/itest/conversations-ws/src/main/resources/ConversationalWSDL/ConversationalServiceStateful.wsdl delete mode 100644 java/sca/itest/conversations-ws/src/main/resources/ConversationalWSDL/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/conversations-ws/src/main/resources/ConversationalWSDL/conversationalWSDL.composite delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java delete mode 100644 java/sca/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java delete mode 100644 java/sca/itest/corba/pom.xml delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFiveTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFourTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioOneTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioSixTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioThreeTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioTwoTestCase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHost.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHostModuleActivator.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/Color.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnion.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnion.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColor.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFive.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveImpl.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFour.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourException.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourImpl.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioSixServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioTwoServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TAnnotatedStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TColor.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerUnion.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichStruct.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichUnion.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOne.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSix.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThree.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeServant.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwo.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoComponent.java delete mode 100644 java/sca/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoServant.java delete mode 100644 java/sca/itest/corba/src/test/resources/META-INF/services/org.apache.tuscany.sca.core.ModuleActivator delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioFive.composite delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioFour.composite delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioOne.composite delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioSix.composite delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioThree.composite delete mode 100644 java/sca/itest/corba/src/test/resources/ScenarioTwo.composite delete mode 100644 java/sca/itest/corba/src/test/resources/itest_scenario.idl delete mode 100644 java/sca/itest/corba/src/test/resources/scenariofour.xsd delete mode 100644 java/sca/itest/databindings/common/pom.xml delete mode 100644 java/sca/itest/databindings/common/src/main/java/org/apache/tuscany/sca/itest/generate/Generate.java delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/DatabindingTestCase.java.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/Greeter.wsdl.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/GreeterService.java.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/GreeterServiceClient.java.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/GreeterServiceClientImpl.java.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/GreeterServiceImpl.java.vm delete mode 100644 java/sca/itest/databindings/common/src/main/resources/generate/generate.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/wsdl/Dummy.txt delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Annotation.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Annotation.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Attribute.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Attribute.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeReference.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeReference.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInID.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInID.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInString.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInString.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementInAll.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementInAll.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Import.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Import.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/ImportedSchema.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Include.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Include.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Interop.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Notation.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Notation.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/Person.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xml delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/datagraph.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/sdoJava.xsd delete mode 100644 java/sca/itest/databindings/common/src/main/resources/xsd/sdoModel.xsd delete mode 100644 java/sca/itest/databindings/common/src/test/java/org/apache/tuscany/sca/itest/generate/GenerateTestCase.java delete mode 100644 java/sca/itest/databindings/config.png delete mode 100644 java/sca/itest/databindings/config.svg delete mode 100644 java/sca/itest/databindings/databinding.png delete mode 100644 java/sca/itest/databindings/databinding.svg delete mode 100644 java/sca/itest/databindings/interop.png delete mode 100644 java/sca/itest/databindings/interop.svg delete mode 100644 java/sca/itest/databindings/interop/pom.xml delete mode 100644 java/sca/itest/databindings/interop/src/main/resources/generate/InteropDatabindingTestCase.java.vm delete mode 100644 java/sca/itest/databindings/interop/src/main/resources/generate/JAXBGreeter.wsdl.vm delete mode 100644 java/sca/itest/databindings/interop/src/main/resources/generate/SDOGreeter.wsdl.vm delete mode 100644 java/sca/itest/databindings/interop/src/main/resources/generate/generate.xml delete mode 100644 java/sca/itest/databindings/interop/src/main/resources/generate/interopgreeter.composite.vm delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/pom.xml delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AClientService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean1.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean10.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean11.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean2.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean3.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean31.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsLocalService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloLocalServiceSimple.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimple.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimpleClient.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesLocalService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesLocalService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AClientServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsLocalServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsTransformer.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloLocalServiceSimpleClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesLocalServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesLocalServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/aservice.wsdl delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/doclitbarewsdl.composite delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/generics-service.composite delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/helloservice.composite delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/primitivesservice.composite delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/main/resources/standard-types-service.composite delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DocLitBareWsdlTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsDatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesDatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesDatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/pom.xml delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloService.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/hello-service.wsdl delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/helloservice.composite delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitives-service.wsdl delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitivesservice.composite delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.composite delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.wsdl delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java delete mode 100644 java/sca/itest/databindings/jaxbgen/pom.xml delete mode 100644 java/sca/itest/databindings/jaxbgen/src/main/resources/generate/generate.xml delete mode 100644 java/sca/itest/databindings/jaxbgen/src/main/resources/greeter.composite delete mode 100644 java/sca/itest/databindings/pom.xml delete mode 100644 java/sca/itest/databindings/readme.html delete mode 100644 java/sca/itest/databindings/sdogen/pom.xml delete mode 100644 java/sca/itest/databindings/sdogen/src/main/resources/generate/generate.xml delete mode 100644 java/sca/itest/databindings/sdogen/src/main/resources/generate/greeter.composite.vm delete mode 100644 java/sca/itest/definitions-multiple/pom.xml delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/PolicyQNames.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/definitions-multiple/src/main/resources/contrib3/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/definitions-multiple/src/main/resources/contrib3/definitions.xml delete mode 100644 java/sca/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/MultipleDefinitionsTestCase.java delete mode 100644 java/sca/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/Policy.java delete mode 100644 java/sca/itest/definitions-multiple/src/test/java/org/apache/tuscany/sca/itest/TestPolicyProcessor.java delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/META-INF/services/org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/contrib1/Calculator.composite delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/contrib1/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/contrib1/definitions.xml delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/contrib1/definitions/definitions.xml delete mode 100644 java/sca/itest/definitions-multiple/src/test/resources/contrib2/definitions.xml delete mode 100644 java/sca/itest/domain/pom.xml delete mode 100644 java/sca/itest/domain/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/AddServiceUpdateImpl.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/domain/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/domain/src/main/resources/contributionA/Calculator.composite delete mode 100644 java/sca/itest/domain/src/main/resources/contributionA/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/domain/src/main/resources/contributionB/META-INF/sca-deployables/Calculator.composite delete mode 100644 java/sca/itest/domain/src/main/resources/contributionC/META-INF/sca-deployables/Calculator.composite delete mode 100644 java/sca/itest/domain/src/main/resources/contributionDependent/Calculator.composite delete mode 100644 java/sca/itest/domain/src/main/resources/contributionDependent/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/domain/src/main/resources/contributionPrimary/Calculator.composite delete mode 100644 java/sca/itest/domain/src/main/resources/contributionPrimary/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/domain/src/test/java/org/apache/tuscany/sca/itest/domain/ContributionSPIsTestCase.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/pom.xml delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExchangeJaxB.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDO.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDOImpl.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/InvalidSymbolSDOException.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/MarketClosedSDOException.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/StockExceptionTest.java delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/resources/ExceptionTest.composite delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/resources/intracomposite.composite delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/resources/wsdl/StockExceptionTest.wsdl delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/main/resources/xsd/StockExceptionTest.xsd delete mode 100644 java/sca/itest/exceptions-cross-binding-ws/src/test/java/org/apache/tuscany/sca/test/exceptions/IntraCompositeTestCase.java delete mode 100644 java/sca/itest/exceptions-cross-binding/pom.xml delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExceptionTestJAXB.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockExchangeJaxB.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDO.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/impl/StockTraderSDOImpl.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/InvalidSymbolSDOException.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/MarketClosedSDOException.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/java/org/apache/tuscany/sca/test/exceptions/sdohandgen/StockExceptionTest.java delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/resources/ExceptionTest.composite delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/resources/intracomposite.composite delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/resources/wsdl.sdo/StockExceptionTest.wsdl delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/resources/wsdl/StockExceptionTest.wsdl delete mode 100644 java/sca/itest/exceptions-cross-binding/src/main/resources/xsd/StockExceptionTest.xsd delete mode 100644 java/sca/itest/exceptions-cross-binding/src/test/java/org/apache/tuscany/sca/test/exceptions/IntraCompositeTestCase.java delete mode 100644 java/sca/itest/exceptions-simple-ws/pom.xml delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/BusinessException.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/BusinessExceptionMinimal.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClient.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClientImpl.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleClientMinimalImpl.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleService.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceImpl.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceMinimal.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/java/com/example/ExampleServiceMinimalImpl.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/resources/example.composite delete mode 100644 java/sca/itest/exceptions-simple-ws/src/main/resources/wsdl/ExampleService.wsdl delete mode 100644 java/sca/itest/exceptions-simple-ws/src/test/java/com/example/ExampleMinimalTestCase.java delete mode 100644 java/sca/itest/exceptions-simple-ws/src/test/java/com/example/ExampleTestCase.java delete mode 100644 java/sca/itest/extended-api/pom.xml delete mode 100644 java/sca/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/BasicService.java delete mode 100644 java/sca/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/MathService.java delete mode 100644 java/sca/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/impl/BasicServiceImpl.java delete mode 100644 java/sca/itest/extended-api/src/main/java/org/apache/tuscany/sca/test/extended/impl/MathServiceImpl.java delete mode 100644 java/sca/itest/extended-api/src/main/resources/BasicService.composite delete mode 100644 java/sca/itest/extended-api/src/main/resources/MathService.composite delete mode 100644 java/sca/itest/extended-api/src/test/java/org/apache/tuscany/sca/test/extended/ServiceLocateTestCase.java delete mode 100644 java/sca/itest/interop-soap-client/pom.xml delete mode 100644 java/sca/itest/interop-soap-client/src/main/java/org/apache/tuscany/test/interop/client/LoopbackInteropDocServiceComponentImpl.java delete mode 100644 java/sca/itest/interop-soap-client/src/main/resources/default.composite delete mode 100644 java/sca/itest/interop-soap-client/src/main/resources/wsdl/interopdoc.wsdl delete mode 100644 java/sca/itest/interop-soap-client/src/test/java/org/apache/tuscany/test/interop/client/InteropDocClientTestCase.java delete mode 100644 java/sca/itest/interop-soap-round2-client/pom.xml delete mode 100644 java/sca/itest/interop-soap-round2-client/src/main/java/org/apache/tuscany/test/interop/client/InteropTestDocLit.java delete mode 100644 java/sca/itest/interop-soap-round2-client/src/main/resources/default.composite delete mode 100644 java/sca/itest/interop-soap-round2-client/src/main/resources/wsdl/interoptestdoclit.wsdl delete mode 100644 java/sca/itest/interop-soap-round2-client/src/test/java/org/apache/tuscany/test/interop/client/InteropTestDocLitTestCase.java delete mode 100644 java/sca/itest/interop-soap-service/pom.xml delete mode 100644 java/sca/itest/interop-soap-service/src/main/java/org/apache/tuscany/test/interop/server/InteropDocServiceComponentImpl.java delete mode 100644 java/sca/itest/interop-soap-service/src/main/resources/wsdl/interopdoc.wsdl delete mode 100644 java/sca/itest/interop-soap-service/src/main/webapp/META-INF/sca/default.scdl delete mode 100644 java/sca/itest/interop-soap-service/src/main/webapp/WEB-INF/web.xml delete mode 100755 java/sca/itest/interop-soap-service/t.bat delete mode 100644 java/sca/itest/jms-args/pom.xml delete mode 100644 java/sca/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/ClientImpl.java delete mode 100644 java/sca/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/MyService.java delete mode 100644 java/sca/itest/jms-args/src/main/java/org/apache/tuscany/sca/binding/jms/ServiceImpl.java delete mode 100644 java/sca/itest/jms-args/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms-args/src/main/resources/selectors/selectors.composite delete mode 100644 java/sca/itest/jms-args/src/test/java/org/apache/tuscany/sca/binding/jms/ArgsTestCase.java delete mode 100644 java/sca/itest/jms-callbacks/pom.xml delete mode 100644 java/sca/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClient.java delete mode 100644 java/sca/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClientImpl.java delete mode 100644 java/sca/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSService.java delete mode 100644 java/sca/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSServiceCallback.java delete mode 100644 java/sca/itest/jms-callbacks/src/main/java/org/apache/tuscany/sca/binding/jms/JMSServiceImpl.java delete mode 100644 java/sca/itest/jms-callbacks/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms-callbacks/src/main/resources/simple/client.composite delete mode 100644 java/sca/itest/jms-callbacks/src/main/resources/simple/tempq.composite delete mode 100644 java/sca/itest/jms-callbacks/src/test/java/org/apache/tuscany/sca/binding/jms/CallbackTestCase.java delete mode 100644 java/sca/itest/jms-callbacks/src/test/java/org/apache/tuscany/sca/binding/jms/TempCallbackQTestCase.java delete mode 100644 java/sca/itest/jms-definitions/pom.xml delete mode 100644 java/sca/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java delete mode 100644 java/sca/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java delete mode 100644 java/sca/itest/jms-definitions/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java delete mode 100644 java/sca/itest/jms-definitions/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/jms-definitions/src/main/resources/definitions/definitions.composite delete mode 100644 java/sca/itest/jms-definitions/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms-definitions/src/test/java/org/apache/tuscany/sca/binding/jms/DefinitionsTestCase.java delete mode 100644 java/sca/itest/jms-format/pom.xml delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldReference.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldReferenceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsbytes/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldReference.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldReferenceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsdelimited/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldReference.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldReferenceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/HelloWorldServiceReferenceSide.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmsmessage/helloworld/README delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldReferenceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/jms-format/src/main/java/org/apache/tuscany/sca/binding/jms/format/jmstextxml/helloworld/Person.java delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmsbytes/helloworld.composite delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmsdelimited/helloworld.composite delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmsdelimited/helloworld.wsdl delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmsmessage/helloworld.composite delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmsmessage/helloworld.wsdl delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmstextxml/helloworld.composite delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmstextxml/helloworld.wsdl delete mode 100644 java/sca/itest/jms-format/src/main/resources/jmstextxml/messages.xml delete mode 100644 java/sca/itest/jms-format/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSBytesTestCase.java delete mode 100644 java/sca/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSDelimitedTestCase.java delete mode 100644 java/sca/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSMessageTestCase.java delete mode 100644 java/sca/itest/jms-format/src/test/java/org/apache/tuscany/sca/binding/jms/format/FormatJMSTextXMLTestCase.java delete mode 100644 java/sca/itest/jms-selectors/pom.xml delete mode 100644 java/sca/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/ClientImpl.java delete mode 100644 java/sca/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorService.java delete mode 100644 java/sca/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl1.java delete mode 100644 java/sca/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl2.java delete mode 100644 java/sca/itest/jms-selectors/src/main/java/org/apache/tuscany/sca/binding/jms/SelectorServiceImpl3.java delete mode 100644 java/sca/itest/jms-selectors/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms-selectors/src/main/resources/selectors/selectors.composite delete mode 100644 java/sca/itest/jms-selectors/src/test/java/org/apache/tuscany/sca/binding/jms/SelectorsTestCase.java delete mode 100644 java/sca/itest/jms/pom.xml delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSClient.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClient.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClientImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgClientService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/MsgServiceImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java delete mode 100644 java/sca/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.java delete mode 100644 java/sca/itest/jms/src/main/resources/defaults/client.composite delete mode 100644 java/sca/itest/jms/src/main/resources/defaults/service.composite delete mode 100644 java/sca/itest/jms/src/main/resources/dynamic/client.composite delete mode 100644 java/sca/itest/jms/src/main/resources/exceptions/client.composite delete mode 100644 java/sca/itest/jms/src/main/resources/exceptions/service.composite delete mode 100644 java/sca/itest/jms/src/main/resources/external/client.composite delete mode 100644 java/sca/itest/jms/src/main/resources/external/service.composite delete mode 100644 java/sca/itest/jms/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/jms/src/main/resources/nonSCAclient/service.composite delete mode 100644 java/sca/itest/jms/src/main/resources/oneway/OneWayClient.composite delete mode 100644 java/sca/itest/jms/src/main/resources/oneway/OneWayService.composite delete mode 100644 java/sca/itest/jms/src/main/resources/policyHeaders/definitions.xml delete mode 100644 java/sca/itest/jms/src/main/resources/policyHeaders/policyHeaders.composite delete mode 100644 java/sca/itest/jms/src/main/resources/properties/properties.composite delete mode 100644 java/sca/itest/jms/src/main/resources/simple/client.composite delete mode 100644 java/sca/itest/jms/src/main/resources/simple/mpclient.composite delete mode 100644 java/sca/itest/jms/src/main/resources/simple/service.composite delete mode 100644 java/sca/itest/jms/src/main/resources/simple/uriclient.composite delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/DefaultsTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/DynamicReplyQTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/ExceptionsTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/ExternalBrokerTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/MessageProcessorTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/NonSCAClientTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/OneWayTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/PolicyHeadersTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/PropertiesTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/RPCTestCase.java delete mode 100644 java/sca/itest/jms/src/test/java/org/apache/tuscany/sca/binding/jms/URIRPCTestCase.java delete mode 100644 java/sca/itest/large-sdo-ws/pom.xml delete mode 100644 java/sca/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrnInqClient.java delete mode 100644 java/sca/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrnInqService.java delete mode 100644 java/sca/itest/large-sdo-ws/src/main/java/org/apache/tuscany/sca/itest/trninq/TrninqInterface.java delete mode 100644 java/sca/itest/large-sdo-ws/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/large-sdo-ws/src/main/resources/trnInq.composite delete mode 100644 java/sca/itest/large-sdo-ws/src/main/resources/wsdl/IFX170_XSD.xsd delete mode 100644 java/sca/itest/large-sdo-ws/src/main/resources/wsdl/trninq.wsdl delete mode 100644 java/sca/itest/large-sdo-ws/src/test/java/trninq/TrnInqServiceTestCase.java delete mode 100644 java/sca/itest/late-reference-resolution/pom.xml delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/META-INF/services/org.apache.tuscany.sca.endpointresolver.EndpointResolverFactory delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeA/Calculator.composite delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeA/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeB/Calculator.composite delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeB/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeC/Calculator.composite delete mode 100644 java/sca/itest/late-reference-resolution/src/main/resources/nodeC/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverFactoryImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/test/java/binding/sca/BindingScaEndpointResolverImpl.java delete mode 100644 java/sca/itest/late-reference-resolution/src/test/java/calculator/LateReferenceResolutionTestCase.java delete mode 100644 java/sca/itest/late-reference-resolution/src/test/java/calculator/TestRegistryImpl.java delete mode 100644 java/sca/itest/oneway/build.xml delete mode 100644 java/sca/itest/oneway/pom.xml delete mode 100644 java/sca/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/OneWayClient.java delete mode 100644 java/sca/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/OneWayService.java delete mode 100644 java/sca/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/impl/OneWayClientImpl.java delete mode 100644 java/sca/itest/oneway/src/main/java/org/apache/tuscany/sca/itest/oneway/impl/OneWayServiceImpl.java delete mode 100644 java/sca/itest/oneway/src/main/resources/OneWayContribution/META-INF/sca-deployables/oneWay.composite delete mode 100644 java/sca/itest/oneway/src/test/java/org/apache/tuscany/sca/itest/oneway/OneWayTestCase.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/build-bundles.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/pom.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/OSGiBundleImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/Customer.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/customer/OSGiCustomerImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/OSGiRetailerImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/retailer/Retailer.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/OSGiShipperImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/shipper/Shipper.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/java/supplychain/warehouse/Warehouse.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/Customer2V2.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/CustomerV2.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/customer-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/retailer-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/shipper-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/META-INF/warehouse-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/RetailerV2.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/ShipperV2.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/WarehouseV2.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Customer.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Customer2.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Retailer.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/RetailerJar.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Shipper.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/SupplyChain.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/osgi/Warehouse.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes-v2/src/main/resources/supplychain.composite delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/build-bundles.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/pom.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/OSGiBundleImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/Customer.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/customer/OSGiCustomerImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/OSGiRetailerImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/retailer/Retailer.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/OSGiShipperImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/shipper/Shipper.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/Customer2V1.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/CustomerV1.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/RetailerV1.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/ShipperV1.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/WarehouseV1.componentType delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Customer.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Customer2.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Retailer.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/RetailerJar.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Shipper.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/SupplyChain.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/osgi/Warehouse.mf delete mode 100644 java/sca/itest/osgi-contribution/contribution-classes/src/main/resources/supplychain.composite delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/pom.xml delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/main/java/org/apache/tuscany/sca/contribution/osgi/OSGiTestUtil.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/MixedContributionTestCase.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/NestedBundleTestCase.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/OSGiResolverTestCase.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/test/java/org/apache/tuscany/sca/contribution/osgi/test/SCAResolverTestCase.java delete mode 100644 java/sca/itest/osgi-contribution/contribution-test/src/test/resources/osgi/felix/felix.config.properties delete mode 100644 java/sca/itest/osgi-contribution/pom.xml delete mode 100644 java/sca/itest/osgi-implementation/build-bundles.xml delete mode 100644 java/sca/itest/osgi-implementation/pom.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/client/CallbackCallback.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/client/CallbackClient.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/client/JavaCallbackClientImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/client/OSGiCallbackClientImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/service/CallbackService.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/service/JavaCallbackServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/callback/service/OSGiCallbackServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalCallback.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClient.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientActivator.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientServiceFactory.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientStatefulImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/client/ConversationalClientStatelessImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClient.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClientActivator.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/referenceclient/ConversationalReferenceClientImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/service/ConversationalService.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceActivator.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceFactory.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceStatefulImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/conversation/service/ConversationalServiceStatelessImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/Greetings.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/HelloWorld.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/JavaGreetingsComponent.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/JavaHelloWorldComponent.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/OSGiGreetingsImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/OSGiHelloWorldImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/sdo/HelloWorldService.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/sdo/HelloWorldServiceComponent.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/sdo/client/HelloWorldClient.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/sdo/client/HelloWorldClientComponent.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/ws/HelloWorld.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/helloworld/ws/HelloWorldService.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteFactoryImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/stockquote/OSGiStockQuoteImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/stockquote/StockQuote.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/OSGiBundleImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/Customer.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerFactoryImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerWithQueryComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiCustomerWithQueryImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiStatelessCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiStatelessCustomerImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/customer/OSGiVersionedCustomerImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerWithQueryComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiRetailerWithQueryImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiVersionedRetailerImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/OSGiVersionedRetailerServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/Retailer.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/retailer/RetailerQuery.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperFactoryImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiShipperServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiStatelessShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiStatelessShipperServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiVersionedShipperImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/OSGiVersionedShipperServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/shipper/Shipper.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/JavaWarehouseWithQueryComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/OSGiWarehouseServiceImpl.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/Warehouse.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/java/supplychain/warehouse/WarehouseQuery.java delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/callback/CallbackClient.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/callback/CallbackService.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/callback/callback-test1.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/callback/callback-test2.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/callback/callback-test3.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/conversation/ConversationalClient.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/conversation/ConversationalReferenceClient.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/conversation/ConversationalService.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/conversation/conversation-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/ds/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/ds/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/ds/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/ds/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/ds/factory-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/factory/factory-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/helloworld/Greetings.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/helloworld/HelloWorld.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/ds/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/ds/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/ds/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/ds/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/ds/interfaces-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/interfaces/interfaces-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/callback/CallbackClient.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/callback/CallbackService.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalClient.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalReferenceClient.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/conversation/ConversationalService.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Customer.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Retailer2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Shipper2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Warehouse.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/factory/ds/Warehouse.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Customer.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Retailer.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/interfaces/ds/Shipper.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/passbyref/Greetings.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/ManagedStockQuoteFactory.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/StockQuote.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/StockQuoteFactory.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuote.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuote.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuoteFactory.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/properties/ds/StockQuoteFactory.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldClient.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldClient.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldService.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/sdo/ds/HelloWorldService.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/Warehouse.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Customer.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Retailer2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Shipper2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/services/ds/Warehouse2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Customer1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Customer2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Retailer1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Retailer2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Shipper1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Shipper2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Warehouse1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/Warehouse2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Customer1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Customer2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/CustomerV1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/CustomerV2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer1V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Retailer2V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper1V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Shipper2V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse1V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2V1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/version/ds/Warehouse2V2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/Warehouse.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Customer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Customer.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Retailer2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Shipper2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse1.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/wiring/ds/Warehouse2.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/osgi/ws/HelloWorld.mf delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/passbyref/Greetings.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/passbyref/passbyref-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/StockQuote.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/StockQuoteFactory.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/ds/StockQuote.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/ds/StockQuoteFactory.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/ds/properties-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/ds/properties2-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/properties-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/properties/properties2-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/sdo/ds/HelloWorldClient.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/sdo/ds/HelloWorldService.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/sdo/ds/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/sdo/ds/helloworld.wsdl delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/sdo/ds/helloworldsdo.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/ds/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/ds/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/ds/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/ds/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/ds/services-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/services/services-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/stockquote/StockQuote.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Customer1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Customer2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Retailer1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Retailer2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Shipper1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Shipper2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Warehouse1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/Warehouse2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Customer1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Customer2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Retailer1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Retailer2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Shipper1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Shipper2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Warehouse1.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/Warehouse2.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/ds/version-ds-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/version/version-test.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/Customer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/Retailer.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/Shipper.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/Warehouse.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/wiring-ds-test1.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/ds/wiring-ds-test2.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/wiring-test1.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/wiring/wiring-test2.composite delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/ws/HelloWorld.componentType delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/ws/helloworld.wsdl delete mode 100644 java/sca/itest/osgi-implementation/src/main/resources/ws/ws-helloworld.composite delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/callback/Callback1TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/callback/Callback2TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/callback/Callback3TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/callback/CallbackTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/conversation/ConversationTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/helloworld/passbyref/PassByRefTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/helloworld/sdo/SdoTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/helloworld/ws/HelloWorldTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/SupplyChainTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/VersionedSupplyChainTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/factory/DSFactoryTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/factory/FactoryTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/interfaces/DSInterfacesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/interfaces/InterfacesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/properties/DSProperties2TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/properties/DSPropertiesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/properties/Properties2TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/properties/PropertiesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/services/DSServicesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/services/ServicesTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/version/DSVersionTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/version/VersionTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/wiring/DSWiring1TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/wiring/DSWiring2TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/wiring/Wiring1TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/supplychain/wiring/Wiring2TestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/test/OSGiTestCase.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/java/util/OSGiTestUtil.java delete mode 100644 java/sca/itest/osgi-implementation/src/test/resources/osgi/felix/felix.config.properties delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/pom.xml delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/EquinoxTestRuntime.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/FelixTestRuntime.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/osgi/runtime/impl/OSGiTestRuntime.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/util/OSGiRuntimeLoader.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/main/java/org/apache/tuscany/sca/test/util/TuscanyLoader.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/harness/OSGiTuscanyNonOSGiTestHarness.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/harness/OSGiTuscanyTestHarness.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorImplementationPoliciesTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorRmiTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CalculatorScriptTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CallbackWsClientTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/CallbackWsServiceTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceJmsTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceSecureTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/HelloworldWsServiceTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/NonOSGiSamplesTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/OSGiSupplyChainTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/OSGiTuscanyRuntimeTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/TuscanySampleExtensionsTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/java/org/apache/tuscany/sca/test/osgi/tuscany/TuscanySamplesUsingOldDomainTestCase.java delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/resources/META-INF/MANIFEST.MF delete mode 100644 java/sca/itest/osgi-tuscany/osgi-tuscany-test/src/test/resources/felix/felix.config.properties delete mode 100644 java/sca/itest/osgi-tuscany/pom.xml delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/build-bundles.xml delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/pom.xml delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/client/SupplyChainClient.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/customer/Customer.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/retailer/Retailer.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/shipper/Shipper.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/java/supplychain/warehouse/Warehouse.java delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/SupplyChain.mf delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/SupplyChainClient.mf delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/supplychain.composite delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/ws/Customer.wsdl delete mode 100644 java/sca/itest/osgi-tuscany/test-bundles/src/main/resources/supplychain/ws/supplychain.composite delete mode 100644 java/sca/itest/osgi-tuscany/tuscany-osgi-installer/pom.xml delete mode 100644 java/sca/itest/osgi-tuscany/tuscany-osgi-installer/src/main/java/org/apache/tuscany/sca/installer/InstallerBundleActivator.java delete mode 100644 java/sca/itest/osgi-tuscany/tuscany-versioned/pom.xml delete mode 100644 java/sca/itest/policy-security-basicauth/pom.xml delete mode 100644 java/sca/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldClientImpl.java delete mode 100644 java/sca/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/policy-security-basicauth/src/main/java/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/policy-security-basicauth/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/policy-security-basicauth/src/main/resources/helloworld.composite delete mode 100644 java/sca/itest/policy-security-basicauth/src/test/java/org/apache/tuscany/sca/itest/BasicAuthTestCase.java delete mode 100644 java/sca/itest/policy-security-jsr250/pom.xml delete mode 100644 java/sca/itest/policy-security-jsr250/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/policy-security-jsr250/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/policy-security-jsr250/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/policy-security-jsr250/src/main/resources/helloworld.composite delete mode 100644 java/sca/itest/policy-security-jsr250/src/test/java/org/apache/tuscany/sca/itest/PolicySecurityJSR250TestCase.java delete mode 100644 java/sca/itest/policy-security-token/pom.xml delete mode 100644 java/sca/itest/policy-security-token/src/main/java/helloworld/HelloWorldClientImpl.java delete mode 100644 java/sca/itest/policy-security-token/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/policy-security-token/src/main/java/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/policy-security-token/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/policy-security-token/src/main/resources/helloworld.composite delete mode 100644 java/sca/itest/policy-security-token/src/main/resources/jndi.properties delete mode 100644 java/sca/itest/policy-security-token/src/test/java/org/apache/tuscany/sca/itest/TokenAuthTestCase.java delete mode 100644 java/sca/itest/policy-security/pom.xml delete mode 100644 java/sca/itest/policy-security/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/policy-security/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/policy-security/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/policy-security/src/main/resources/helloworld.composite delete mode 100644 java/sca/itest/policy-security/src/test/java/org/apache/tuscany/sca/itest/PolicyIdentityTestCase.java delete mode 100644 java/sca/itest/policy/pom.xml delete mode 100644 java/sca/itest/policy/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/CalculatorClient.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/PolicyQNames.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/policy/TestImplPolicyHandler.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/policy/TestRefPolicyHandler.java delete mode 100644 java/sca/itest/policy/src/main/java/calculator/policy/TestSvcPolicyHandler.java delete mode 100644 java/sca/itest/policy/src/main/resources/Calculator.composite delete mode 100644 java/sca/itest/policy/src/main/resources/META-INF/services/org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor delete mode 100644 java/sca/itest/policy/src/main/resources/META-INF/services/org.apache.tuscany.sca.policy.util.PolicyHandler delete mode 100644 java/sca/itest/policy/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/policy/src/test/java/org/apache/tuscany/sca/itest/PoliciedCalculatorTestCase.java delete mode 100644 java/sca/itest/policy/src/test/java/org/apache/tuscany/sca/itest/Policy.java delete mode 100644 java/sca/itest/policy/src/test/java/org/apache/tuscany/sca/itest/TestPolicyProcessor.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/pom.xml delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/java/com/example/BusinessException.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleClient.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleClientImpl.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleService.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/java/com/example/ExampleServiceImpl.java delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/resources/example.composite delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/resources/wsdl/ExampleService.wsdl delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/main/resources/wsdl/ExampleServiceTypes.xsd delete mode 100644 java/sca/itest/promotion-interface-missmatch/src/test/java/com/example/ExampleTestCase.java delete mode 100644 java/sca/itest/recursive-ws/pom.xml delete mode 100644 java/sca/itest/recursive-ws/src/main/java/policy/Target.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/policy/TargetClientImpl.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/policy/TargetServiceImpl.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/recursive/Composer.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/recursive/ComposerClient.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/recursive/ComposerClientImpl.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/recursive/ComposerImpl.java delete mode 100644 java/sca/itest/recursive-ws/src/main/java/recursive/ComposerServer.java delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/Client.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/Inner.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/Outer.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/bindingoverride/InnerComposite.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/bindingoverride/OuterComposite.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/policy/PolicyInnerComposite.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/policy/PolicyOuterComposite.composite delete mode 100644 java/sca/itest/recursive-ws/src/main/resources/policy/definitions.xml delete mode 100644 java/sca/itest/recursive-ws/src/test/java/bindingoverride/BindingOverrideTestCase.java delete mode 100644 java/sca/itest/recursive-ws/src/test/java/policy/PolicyTestCase.java delete mode 100644 java/sca/itest/recursive-ws/src/test/java/recursive/ComposerClientTestCase.java delete mode 100644 java/sca/itest/recursive-ws/src/test/java/recursive/ComposerTestServer.java delete mode 100644 java/sca/itest/recursive/pom.xml delete mode 100644 java/sca/itest/recursive/src/main/java/circular/include/DemoClass.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/CompositeClient.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/Source.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/SourceCallback.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/SourceImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/Target.java delete mode 100644 java/sca/itest/recursive/src/main/java/composite/TargetImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/foo/A.java delete mode 100644 java/sca/itest/recursive/src/main/java/foo/B.java delete mode 100644 java/sca/itest/recursive/src/main/java/foo/I.java delete mode 100644 java/sca/itest/recursive/src/main/java/policy/Target.java delete mode 100644 java/sca/itest/recursive/src/main/java/policy/TargetClientImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/policy/TargetServiceImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/sample/ComponentAImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/sample/ComponentCImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/sample/ComponentEImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/sample/ComponentFImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/sample/Service1.java delete mode 100644 java/sca/itest/recursive/src/main/java/test/Aggregator.java delete mode 100644 java/sca/itest/recursive/src/main/java/test/AggregatorImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/test/InnerSourceImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/test/OuterSourceImpl.java delete mode 100644 java/sca/itest/recursive/src/main/java/test/Source.java delete mode 100644 java/sca/itest/recursive/src/main/java/test1/composite/Target.java delete mode 100644 java/sca/itest/recursive/src/main/java/test1/composite/TargetOne.java delete mode 100644 java/sca/itest/recursive/src/main/java/test1/composite/TargetTwo.java delete mode 100644 java/sca/itest/recursive/src/main/resources/AComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/BComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/CComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Composite1.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Composite2.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Composite3.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Demo1Composite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Demo2Composite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/Inner.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/InnerComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/InnerComposite2.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/recursive/src/main/resources/Outer.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/OuterComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/foo/foo.png delete mode 100644 java/sca/itest/recursive/src/main/resources/foo/o1.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/foo/o2.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/foo/o3.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/foo/o4.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/policy/PolicyInnerComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/policy/PolicyOuterComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/policy/definitions.xml delete mode 100644 java/sca/itest/recursive/src/main/resources/test1/InnerComposite.composite delete mode 100644 java/sca/itest/recursive/src/main/resources/test1/OuterComposite.composite delete mode 100644 java/sca/itest/recursive/src/test/java/circular/include/CircularIncludeTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/composite/CompositeTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/composite/LocateServiceEmbeddedSCADomainTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/composite/LocateServiceSCADomainTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/foo/O2TestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/foo/O4TestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/policy/PolicyTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/C.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/CImpl.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/NestedTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/RecursiveCompositeTestCaseFIXME.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/X.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/XImpl.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/Y.java delete mode 100644 java/sca/itest/recursive/src/test/java/sample/YImpl.java delete mode 100644 java/sca/itest/recursive/src/test/java/test/InnerTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/test/OuterTestCase.java delete mode 100644 java/sca/itest/recursive/src/test/java/test1/composite/CompositeClientTestCase.java delete mode 100644 java/sca/itest/serialization/pom.xml delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalService.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalServiceCallback.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/ConversationalServiceImpl.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedClient.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedClientImpl.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedConversationalClient.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/SCAManagedConversationalClientImpl.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessService.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessServiceCallback.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/StatelessServiceImpl.java delete mode 100644 java/sca/itest/serialization/src/main/java/org/apache/tuscany/sca/itest/servicereference/utils/ServiceReferenceUtils.java delete mode 100644 java/sca/itest/serialization/src/main/resources/ServiceReferenceSerializationTest.composite delete mode 100644 java/sca/itest/serialization/src/main/resources/nestedcomposite.composite delete mode 100644 java/sca/itest/serialization/src/test/java/org/apache/tuscany/sca/itest/servicereference/SerializeServiceReferenceTestCase.java delete mode 100644 java/sca/itest/spring/pom.xml delete mode 100644 java/sca/itest/spring/src/main/java/bigbank/stockquote/StockQuoteImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/bigbank/stockquote/StockQuoteService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/AddService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/AddServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/CalculatorService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/DivideService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/DivideServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/MultiplyService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/SubtractService.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/SubtractServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/security/CalculatorCallbackHandler.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/security/JaasLoginModule.java delete mode 100644 java/sca/itest/spring/src/main/java/calculator/security/UserPrincipal.java delete mode 100644 java/sca/itest/spring/src/main/java/context/access/SCAApplicationContextProvider.java delete mode 100644 java/sca/itest/spring/src/main/java/spring/annotations/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/spring/src/main/resources/CalculatorService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/SpringDelegationHelloWorld-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/SpringHelloWorld-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/context-access/CalculatorService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/context-imports/CalculatorService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/context-imports/SpringImport-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/context-multiple/StockQuoteService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/context-multiple/beanRefContext.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/implementation-policies/CalculatorService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/META-INF/sca/spring-annotation/CalculatorService-context.xml delete mode 100644 java/sca/itest/spring/src/main/resources/context/access/Calculator.composite delete mode 100644 java/sca/itest/spring/src/main/resources/context/imports/Calculator.composite delete mode 100644 java/sca/itest/spring/src/main/resources/context/multiple/StockQuote.composite delete mode 100644 java/sca/itest/spring/src/main/resources/implementation/policies/Calculator.composite delete mode 100644 java/sca/itest/spring/src/main/resources/implementation/policies/CalculatorJass.config delete mode 100644 java/sca/itest/spring/src/main/resources/implementation/policies/CalculatorLogMessages.properties delete mode 100644 java/sca/itest/spring/src/main/resources/implementation/policies/definitions.xml delete mode 100644 java/sca/itest/spring/src/main/resources/org/apache/tuscany/sca/itest/spring/SpringDelegationHelloWorld.composite delete mode 100644 java/sca/itest/spring/src/main/resources/org/apache/tuscany/sca/itest/spring/SpringHelloWorld.composite delete mode 100644 java/sca/itest/spring/src/main/resources/spring/annotations/Calculator.composite delete mode 100644 java/sca/itest/spring/src/test/java/context/access/CalculatorClient.java delete mode 100644 java/sca/itest/spring/src/test/java/context/access/ContextAccessTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/context/imports/CalculatorClient.java delete mode 100644 java/sca/itest/spring/src/test/java/context/imports/ContextImportsTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/context/multiple/MultipleContextTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/context/multiple/StockQuoteServer.java delete mode 100644 java/sca/itest/spring/src/test/java/implementation/policies/CalculatorClient.java delete mode 100644 java/sca/itest/spring/src/test/java/implementation/policies/ImplementationPoliciesTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/AbstractHelloWorldTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/AbstractSCATestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/HelloWorld.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/HelloWorldProxy.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/SpringDelegationHelloWorldTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/SpringHelloWorldTestCase.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/TestHelloWorldBean.java delete mode 100644 java/sca/itest/spring/src/test/java/org/apache/tuscany/sca/itest/spring/TestHelloWorldDelegatorBean.java delete mode 100644 java/sca/itest/spring/src/test/java/spring/annotations/CalculatorClient.java delete mode 100644 java/sca/itest/spring/src/test/java/spring/annotations/SpringAnnotationsTestCase.java delete mode 100644 java/sca/itest/transaction/pom.xml delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountNotFoundException.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountService.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/AccountServiceImpl.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/CheckingAccountServiceImpl.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/OverDraftException.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/SavingsAccountServiceImpl.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/TransferService.java delete mode 100644 java/sca/itest/transaction/src/main/java/org/apache/tuscany/sca/itest/transaction/TransferServiceImpl.java delete mode 100644 java/sca/itest/transaction/src/main/resources/accounts.composite delete mode 100644 java/sca/itest/transaction/src/main/resources/definitions.xml delete mode 100644 java/sca/itest/transaction/src/main/resources/log4j.properties delete mode 100644 java/sca/itest/transaction/src/test/java/org/apache/tuscany/sca/itest/transaction/ConcurrentXAResourceTestCase.java delete mode 100644 java/sca/itest/transaction/src/test/java/org/apache/tuscany/sca/itest/transaction/TransactionTestCase.java delete mode 100644 java/sca/itest/validation/pom.xml delete mode 100644 java/sca/itest/validation/src/main/java/binding/ejb/account/Customer.java delete mode 100644 java/sca/itest/validation/src/main/java/binding/ejb/account/CustomerImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/binding/ejb/calculator/AddService.java delete mode 100644 java/sca/itest/validation/src/main/java/binding/ejb/calculator/AddServiceHome.java delete mode 100644 java/sca/itest/validation/src/main/java/binding/jms/HelloWorldService.java delete mode 100644 java/sca/itest/validation/src/main/java/binding/jms/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/AddService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/AddServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/AddServiceImplWithServiceName.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/CalculatorClient.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/CalculatorService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/DivideService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/DivideServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/MultiplyService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/PropertyService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/PropertyServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/SubtractService.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/SubtractServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/calculator/warning/SubtractServiceImplWithServiceName.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/AddService.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/AddServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/CalculatorClient.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/CalculatorService.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/DivideService.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/DivideServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/MultiplyService.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/MultiplyServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/SubtractService.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/java/SubtractServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/spring/HelloWorld.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/spring/HelloWorldProxy.java delete mode 100644 java/sca/itest/validation/src/main/java/impl/spring/TestHelloWorldBean.java delete mode 100644 java/sca/itest/validation/src/main/java/interfacejava/xml/CalculatorService.java delete mode 100644 java/sca/itest/validation/src/main/java/interfacejava/xml/CalculatorServiceImpl.java delete mode 100644 java/sca/itest/validation/src/main/resources/ComponentReferenceTargetNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateComponentName/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateImplementationPropertyName/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateImplementationPropertyName/dummyImplementation.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateImplementationReferenceName/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateImplementationReferenceName/dummyImplementation.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicatePropertyName/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/DuplicateReferenceName/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/META-INF/sca/SpringHelloWorld-context.xml delete mode 100644 java/sca/itest/validation/src/main/resources/MultipleBindingsForService/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/NoComponentImplementation/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/NoCompositeNamespace/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/NoMatchingBinding/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PromotedReferenceNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PromotedServiceNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PropertyAttribute/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PropertyAttribute/CalculatorNullMustSupply.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PropertyAttribute/CalculatorOverrideManyAttribute.composite delete mode 100644 java/sca/itest/validation/src/main/resources/PropertyNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ReferenceIncompatibleComponentInterface/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ReferenceIncompatibleInterface/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ReferenceIncompatibleMultiplicity/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ReferenceNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ReferenceWithoutTargets/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/ServiceNotFoundForComponentService/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/UnresolvedComponentImplementation/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/XsdValidation/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/ContributionReadException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/PolicyImplValidationException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/PolicyServiceValidationException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/UnexpectedBindingElement/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/UnexpectedImplementationElement/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/assemblyxml/UnexpectedInterfaceElement/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/InvalidWsdlElementAttr/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/MustUseWsdlBinding/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlBindingDoesNotMatch/helloworldwsjms.composite delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlPortTypeDoesNotMatch/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlPortTypeDoesNotMatch/helloworldwsclient.composite delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/binding/wsxml/WsdlServiceDoesNotMatch/helloworldwsjms.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingejb/UnknownEJBSessionType/account.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingejb/UnknownEJBVersion/account.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessActivationSpec/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessDestinationType/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessHeaders/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessResourceAdapter/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseActivationSpec/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseConnectionFactory/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/DoesntProcessResponseDestinationType/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/InvalidCorrelationScheme/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/InvalidJMSDeliveryMode/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/InvalidJMSPriority/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/InvalidResponseDestinationType/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/MissingActivationSpecName/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/MissingConnectionFactoryName/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/MissingResponseActivationSpec/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/MissingResponseConnectionFactory/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/MustStartWithSchema/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/UnexpectedElement/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/UnexpectedResponseElement/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/bindingjms/UnknownTokenInURI/service.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/java/AttributePackageMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/namespace/AttributeNameSpaceMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/resource/AttributeURIMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/resource/AttributeURIMissing/META-INF/sca-contribution.xml delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/xml/AttributeCompositeMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/xml/AttributeCompositeMissing/sca-contribution.xml delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/xml/MultipleCompositeErrors/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/contribution/xml/MultipleCompositeErrors/sca-contribution.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/AttributeUnrecognizedNamespace/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/AttributeWithoutNamespace/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/BPELProcessNotFound/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/CannotResolveWSDLReference/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/MyRolePartnerRoleNull/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkHasBothAttr/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkNoMatchingType/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/deploy.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.bpel delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/bpel/PartnerLinkTypeNoRoles/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/impl/ejb/EJBLinkAttributeMissing/ejb.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/java/ClassNotFoundException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/java/ContributionResolveException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/osgi/CouldNotLocateOSGiBundle/OSGiTestService.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/osgi/CouldNotLocateOSGiBundle/osgitest.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/osgi/MissingComponentTypeFile/osgitest.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/osgi/PropertyShouldSpecifySR/OSGiTestService.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/osgi/PropertyShouldSpecifySR/osgitest.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/resource/CouldNotResolveLocation/resource.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/resource/LocationAttributeMissing/resource.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/spring/ContributionResolveException/SpringHelloWorld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/spring/LocationAttributeMissing/SpringHelloWorld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/SpringHelloWorld-context.xml delete mode 100644 java/sca/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/SpringHelloWorld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/spring/UnableToResolveComponentType/TestHelloWorldBean.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/impl/widget/CouldNotResolveLocation/widget.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/widget/LocationAttributeMissing/widget.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/xquery/CouldNotLocateFile/HelloWorld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/impl/xquery/LocationAttributeMissing/HelloWorld.composite delete mode 100644 java/sca/itest/validation/src/main/resources/interfacejava/xml/ClassNotFoundException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/interfacejava/xml/ClassNotFoundException/CalculatorServiceImpl.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/interfacejava/xml/ContributionResolveException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/interfacejava/xml/ContributionResolveException/CalculatorServiceImpl.componentType delete mode 100644 java/sca/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/helloworld-interface.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/interfacewsdl/xml/InvalidWSDLInterfaceAttr/helloworld-service.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworld.wsdl delete mode 100644 java/sca/itest/validation/src/main/resources/interfacewsdl/xml/WsdlInterfaceDoesNotMatch/helloworldwsjms.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/security/ClassNotFoundException/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/security/ClassNotFoundException/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/security/RequiredAttributeRolesMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/security/RequiredAttributeRolesMissing/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/AlwaysProvidedIntentNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/AlwaysProvidedIntentNotFound/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/ErrorInPolicyIntentDefinition/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/ErrorInPolicyIntentDefinition/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/IntentNotSpecified/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/IntentNotSpecified/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/MayProvideIntentNotFound/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/MayProvideIntentNotFound/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/RequiredAttributeMissing/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/RequiredAttributeMissing/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/UnableToMapPolicies/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/UnableToMapPolicies/definitions.xml delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/UnrecognizedIntentAttachPointType/Calculator.composite delete mode 100644 java/sca/itest/validation/src/main/resources/policy/xml/UnrecognizedIntentAttachPointType/definitions.xml delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/ContributionReadException.java delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/PolicyImplValidationException.java delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/PolicyServiceValidationException.java delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/UnexpectedBindingElement.java delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/UnexpectedImplementationElement.java delete mode 100644 java/sca/itest/validation/src/test/java/assembly/xml/UnexpectedInterfaceElement.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/ejb/UnknownEJBSessionTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/ejb/UnknownEJBVersionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessActivationSpecTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessDestinationTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessHeadersTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessResourceAdapterTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessResponseActivationSpecTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessResponseConnectionFactoryTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/DoesntProcessResponseDestinationTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/InvalidCorrelationSchemeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/InvalidJMSDeliveryModeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/InvalidJMSPriorityTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/InvalidResponseDestinationTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/MissingActivationSpecNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/MissingConnectionFactoryNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/MissingResponseActivationSpecTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/MissingResponseConnectionFactoryTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/MustStartWithSchemaTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/UnexpectedElementTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/UnexpectedResponseElementTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/jms/UnknownTokenInURITestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/wsxml/InvalidWsdlElementAttrTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/wsxml/MustUseWsdlBindingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/wsxml/WsdlBindingDoesNotMatchTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/wsxml/WsdlPortTypeDoesNotMatchTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/binding/wsxml/WsdlServiceDoesNotMatchTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ComponentReferenceTargetNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/DuplicateComponentNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationPropertyNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/DuplicateImplementationReferenceNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/DuplicatePropertyNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/DuplicateReferenceNameTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/MultipleBindingsForServiceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/NoComponentImplementationTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/NoCompositeNamespaceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/NoMatchingBindingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PromotedReferenceNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PromotedServiceNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeMustSupplyNullTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PropertyAttributeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PropertyNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/PropertyOverrideManyAttributeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleComponentInterfaceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleInterfaceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ReferenceIncompatibleMultiplicityTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ReferenceNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ReferenceWithoutTargetsTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/ServiceNotFoundForComponentServiceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/UnresolvedComponentImplementationTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/calculator/warning/XSDValidationTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/contribution/java/AttributePackageMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/contribution/namespace/AttributeNameSpaceMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/contribution/resource/AttributeURIMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/contribution/xml/AttributeCompositeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/contribution/xml/MultipleCompositeErrorsTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/domain/CustomCompositeBuilder.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/AttributeUnrecognizedNamespaceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/AttributeWithoutNamespaceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/BPELProcessNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/CannotResolveWSDLReferenceTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/MyRolePartnerRoleNullTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/PartnerLinkHasBothAttrTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/PartnerLinkNoMatchingTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/bpel/PartnerLinkTypeNoRolesTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/ejb/EJBLinkAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/java/ClassNotFoundExceptionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/java/ContributionResolveExceptionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/resource/CouldNotResolveLocationTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/resource/LocationAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/spring/ContributionResolveExceptionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/spring/LocationAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/spring/UnableToResolveComponentTypeTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/widget/CouldNotResolveLocationTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/widget/LocationAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/xquery/CouldNotLocateFileTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/impl/xquery/LocationAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/interfacejava/xml/ClassNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/interfacejava/xml/ContributionResolveExceptionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/interfacewsdl/xml/InvalidWSDLInterfaceAttrTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/interfacewsdl/xml/WsdlInterfaceDoesNotMatchTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/AlwaysProvidedIntentNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/ErrorInPolicyIntentDefinitionTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/IntentNotSpecifiedTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/MayProvideIntentNotFoundTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/RequiredAttributeMissingTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/UnableToMapPoliciesTestCase.java delete mode 100644 java/sca/itest/validation/src/test/java/policy/xml/UnrecognizedIntentAttachPointTypeTestCase.java delete mode 100644 java/sca/itest/ws-void-args-return/pom.xml delete mode 100644 java/sca/itest/ws-void-args-return/src/main/java/voidtest/Bean.java delete mode 100644 java/sca/itest/ws-void-args-return/src/main/java/voidtest/HelloWorldImpl.java delete mode 100644 java/sca/itest/ws-void-args-return/src/main/java/voidtest/HelloWorldService.java delete mode 100644 java/sca/itest/ws-void-args-return/src/main/java/voidtest/TestClient.java delete mode 100644 java/sca/itest/ws-void-args-return/src/main/java/voidtest/TestClientImpl.java delete mode 100644 java/sca/itest/ws-void-args-return/src/main/resources/voidtest.composite delete mode 100644 java/sca/itest/ws-void-args-return/src/test/java/voidtest/VoidArgsReturnTestCase.java delete mode 100644 java/sca/itest/wsdl-multiple/pom.xml delete mode 100644 java/sca/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldCallback.java delete mode 100644 java/sca/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldClientImpl.java delete mode 100644 java/sca/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/wsdl-multiple/src/main/java/helloworld/HelloWorldServiceImpl.java delete mode 100644 java/sca/itest/wsdl-multiple/src/main/resources/auto-wsdl.composite delete mode 100644 java/sca/itest/wsdl-multiple/src/main/resources/manual-wsdl.composite delete mode 100644 java/sca/itest/wsdl-multiple/src/main/resources/wsdl/helloworld.HelloWorldCallback.wsdl delete mode 100644 java/sca/itest/wsdl-multiple/src/main/resources/wsdl/helloworld.HelloWorldService.wsdl delete mode 100644 java/sca/itest/wsdl-multiple/src/test/java/org/apache/tuscany/sca/itest/AutoWSDLTestCase.java delete mode 100644 java/sca/itest/wsdl-multiple/src/test/java/org/apache/tuscany/sca/itest/ManualWSDLTestCase.java delete mode 100644 java/sca/itest/wsdl/pom.xml delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountDataService.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountDataServiceImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/AccountServiceClientImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component2aImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component2bImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component3aImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/Component3bImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/bigbank/account/services/accountdata/CustomerIdService.java delete mode 100644 java/sca/itest/wsdl/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/wsdl/src/main/java/helloworld/HelloWorldServiceComponent.java delete mode 100644 java/sca/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component2aImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component2bImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component3aImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/java/org/apache/tuscany/sca/itest/Component3bImpl.java delete mode 100644 java/sca/itest/wsdl/src/main/resources/SDOWSDLTest.composite delete mode 100644 java/sca/itest/wsdl/src/main/resources/WSDLTest.composite delete mode 100644 java/sca/itest/wsdl/src/main/resources/wsdl/AccountService.wsdl delete mode 100644 java/sca/itest/wsdl/src/main/resources/wsdl/Hello.xsd delete mode 100644 java/sca/itest/wsdl/src/main/resources/wsdl/helloworld.wsdl delete mode 100644 java/sca/itest/wsdl/src/test/java/org/apache/tuscany/sca/itest/SDOWSDLTestCase.java delete mode 100644 java/sca/itest/wsdl/src/test/java/org/apache/tuscany/sca/itest/WSDLTestCase.java delete mode 100644 java/sca/itest/wsdl2java/pom.xml delete mode 100644 java/sca/itest/wsdl2java/src/test/resources/AccountService.wsdl delete mode 100644 java/sca/itest/wsdl2java/src/test/resources/EchoService.wsdl delete mode 100644 java/sca/itest/wsdl2java/src/test/resources/EchoService.xsd delete mode 100644 java/sca/itest/wsdl2java/src/test/resources/StockExceptionTest.wsdl delete mode 100644 java/sca/itest/wsdlless/pom.xml delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountDataService.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountDataServiceImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/AccountServiceClientImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component2aImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component2bImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component3aImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/Component3bImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/bigbank/account/services/accountdata/CustomerIdService.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/helloworld/HelloWorldImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/helloworld/HelloWorldService.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/helloworld/HelloWorldServiceComponent.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component2aImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component2bImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component3aImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/org/apache/tuscany/sca/itest/Component3bImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/service/AnObject.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/service/MoreComplexObject.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/service/SomeService.java delete mode 100644 java/sca/itest/wsdlless/src/main/java/service/SomeServiceImpl.java delete mode 100644 java/sca/itest/wsdlless/src/main/resources/SDOWSDLTest.composite delete mode 100644 java/sca/itest/wsdlless/src/main/resources/WSDLTest.composite delete mode 100644 java/sca/itest/wsdlless/src/main/resources/some.composite delete mode 100644 java/sca/itest/wsdlless/src/main/resources/wsdl/AccountService.wsdl delete mode 100644 java/sca/itest/wsdlless/src/main/resources/wsdl/helloworld.wsdl delete mode 100644 java/sca/itest/wsdlless/src/test/java/org/apache/tuscany/sca/itest/SDOWSDLTestCase.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/org/apache/tuscany/sca/itest/WSDLTestCase.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/SomeComponentTestCase.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/AnObject.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/GetUsingMoreComplexObject.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/GetUsingMoreComplexObjectResponse.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/GetUsingString.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/GetUsingStringResponse.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/MoreComplexObject.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/ObjectFactory.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/SomeService.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/SomeServiceService.java delete mode 100644 java/sca/itest/wsdlless/src/test/java/service/generated/package-info.java (limited to 'java/sca') diff --git a/java/sca/contrib/itest/admin/README b/java/sca/contrib/itest/admin/README new file mode 100644 index 0000000000..c4e96d7af0 --- /dev/null +++ b/java/sca/contrib/itest/admin/README @@ -0,0 +1,28 @@ +This is a simple test compiled to test simple features of SCA + +There are interfaces to different services that have been included + +1. MyListService +2. MyListServiceByYear +3. MyService +4. MyServiceByDate +5. MyTotalservice + +The service that has been used in the tests primarily is MyService/MyTotalService. +in the test cases. + +There are three test cases and three composites (MySimppleService,Iteration1,Iteration3). + +1. MySimpleServiceTestCase - Checks if the components in MySimpleService.composite are initialized properly. + It tries to call simple functions implemented in MySimpleServiceImpl. + +2. MyTotalServiceTestCase - Initializes the components in the Iteration3Composite.composite file. + tries to call simple functions implemented in MyTotalServiceImpl. + +3. MySimpleServiceInRecursiveTestCase - Initializes the components in the Iteration1Composite.composite file. + It initializes its components using implementation:composite tag in the + composite file which points to MySimpleService.composite. + The test case recursively calls functions initialized in MySimpleService.composite. + + + diff --git a/java/sca/contrib/itest/admin/pom.xml b/java/sca/contrib/itest/admin/pom.xml new file mode 100644 index 0000000000..e179926bf1 --- /dev/null +++ b/java/sca/contrib/itest/admin/pom.xml @@ -0,0 +1,60 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + tuscany-itest-admin + Apache Tuscany Admin Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-core-databinding + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-databinding-sdo + 2.0-SNAPSHOT + compile + + + + diff --git a/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListService.java b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListService.java new file mode 100644 index 0000000000..f081537dab --- /dev/null +++ b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListService.java @@ -0,0 +1,9 @@ +package org.apache.tuscany.sca.itest.admin; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface MyListService { + String[] getHolidays(); + String getYear(); +} diff --git a/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceByYear.java b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceByYear.java new file mode 100644 index 0000000000..b4224e286e --- /dev/null +++ b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceByYear.java @@ -0,0 +1,8 @@ +package org.apache.tuscany.sca.itest.admin; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface MyListServiceByYear { + String[] getHolidays(int year); +} diff --git a/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceImpl.java b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceImpl.java new file mode 100644 index 0000000000..550303d856 --- /dev/null +++ b/java/sca/contrib/itest/admin/src/main/java/org/apache/tuscany/sca/itest/admin/MyListServiceImpl.java @@ -0,0 +1,69 @@ +package org.apache.tuscany.sca.itest.admin; + + +import java.util.List; + +import org.oasisopen.sca.annotation.Property; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +import org.apache.tuscany.sca.itest.admin.MyListService; +import org.apache.tuscany.sca.itest.admin.MyListServiceByYear; + +@Service(interfaces={MyListService.class,MyListServiceByYear.class}) + +public class MyListServiceImpl implements MyListService,MyListServiceByYear +{ + + // This is multiplicity=1:n + @Reference(name="myListServiceList",required=true) + public List myListServicesList; + + // This is multiplicity=0:n + @Reference(name="myListServiceArray",required=false) + public MyListService[] myListServicesArray; + + @Property(name="serviceYear") + protected String year = "2006"; + + public String[] getHolidays() + { + return getHolidays(new Integer(year).intValue()); + } + + public String[] getHolidays(int year) + { + MyListService myService; + if (myListServicesList!=null) + { + for (int i=0; i=0 && index + + + + Raleigh + 2008 + + Durham + 2009 + + + + + + + + Durham + 2009 + + + diff --git a/java/sca/contrib/itest/admin/src/test/resources/Iteration3Composite.composite b/java/sca/contrib/itest/admin/src/test/resources/Iteration3Composite.composite new file mode 100644 index 0000000000..dd06d030d6 --- /dev/null +++ b/java/sca/contrib/itest/admin/src/test/resources/Iteration3Composite.composite @@ -0,0 +1,68 @@ + + + + + Raleigh + 2008 + + + + + + + + CARY + 2007 + + + + + + + + + + + + + + + + + + + + + Durham + 2009 + + + + + + + + Durham + 2009 + + diff --git a/java/sca/contrib/itest/admin/src/test/resources/MySimpleService.composite b/java/sca/contrib/itest/admin/src/test/resources/MySimpleService.composite new file mode 100644 index 0000000000..a1f8abb8da --- /dev/null +++ b/java/sca/contrib/itest/admin/src/test/resources/MySimpleService.composite @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + Raleigh + 2008 + + + + + + + + CARY + 2007 + + + + + + + + + diff --git a/java/sca/contrib/itest/binding-sca-jms/client/pom.xml b/java/sca/contrib/itest/binding-sca-jms/client/pom.xml new file mode 100644 index 0000000000..2e24179309 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/pom.xml @@ -0,0 +1,63 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + itest-binidng-sca-jms + 2.0-SNAPSHOT + ../../pom.xml + + itest-binding-sca-jms-client + + + + org.apache.tuscany.sca + tuscany-node-impl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-sca-jms + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.2 + test + + + + + ${artifactId} + + + diff --git a/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyClientImpl.java b/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyClientImpl.java new file mode 100644 index 0000000000..3a546dcf72 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyClientImpl.java @@ -0,0 +1,32 @@ +/* + * 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 itest; + +import org.oasisopen.sca.annotation.Reference; + +public class MyClientImpl implements MyService { + + @Reference public MyService delegate; + + public String sayHello(String s) { + return "Hi " + delegate.sayHello(s); + } + +} diff --git a/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyService.java b/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyService.java new file mode 100644 index 0000000000..b1daa53c86 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/src/main/java/itest/MyService.java @@ -0,0 +1,28 @@ +/* + * 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 itest; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface MyService { + + String sayHello(String s); +} diff --git a/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..8c311553c3 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/MyClient.composite b/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/MyClient.composite new file mode 100644 index 0000000000..81aa3ed98d --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/src/main/resources/MyClient.composite @@ -0,0 +1,29 @@ + + + + + + + + + + diff --git a/java/sca/contrib/itest/binding-sca-jms/client/src/test/java/itest/MyClientTestCase.java b/java/sca/contrib/itest/binding-sca-jms/client/src/test/java/itest/MyClientTestCase.java new file mode 100644 index 0000000000..5c56dbaf84 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/client/src/test/java/itest/MyClientTestCase.java @@ -0,0 +1,39 @@ +package itest; + + + +import junit.framework.Assert; + +import org.apache.tuscany.sca.node.SCAClient; +import org.apache.tuscany.sca.node.SCAContribution; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; +import org.junit.Test; + +/** + * Runs a distributed domain in a single VM by using and in memory + * implementation of the distributed domain + */ +public class MyClientTestCase { + + @Test + public void testCalculator() throws Exception { + + SCANode serviceNode = SCANodeFactory.newInstance().createSCANode("MyService.composite", new SCAContribution("bla2", "../service/target/itest-binding-sca-jms-service.jar")); + + SCANode clientNode = SCANodeFactory.newInstance().createSCANodeFromClassLoader("MyClient.composite", null); + try { + + serviceNode.start(); + clientNode.start(); + + MyService service = ((SCAClient)clientNode).getService(MyService.class, "MyClientComponent"); + + Assert.assertEquals("Hi Hello petra", service.sayHello("petra")); + + } finally { + clientNode.stop(); + serviceNode.stop(); + } + } +} diff --git a/java/sca/contrib/itest/binding-sca-jms/pom.xml b/java/sca/contrib/itest/binding-sca-jms/pom.xml new file mode 100644 index 0000000000..9da74604f5 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/pom.xml @@ -0,0 +1,36 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-binidng-sca-jms + pom + Apache Tuscany SCA JMS SCA Binding Integration Tests + + + service + client + + diff --git a/java/sca/contrib/itest/binding-sca-jms/service/pom.xml b/java/sca/contrib/itest/binding-sca-jms/service/pom.xml new file mode 100644 index 0000000000..5b0677b0e6 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/pom.xml @@ -0,0 +1,63 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + itest-binidng-sca-jms + 2.0-SNAPSHOT + ../../pom.xml + + itest-binding-sca-jms-service + + + + org.apache.tuscany.sca + tuscany-node-impl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-sca-jms + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.2 + test + + + + + ${artifactId} + + + diff --git a/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyService.java b/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyService.java new file mode 100644 index 0000000000..b1daa53c86 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyService.java @@ -0,0 +1,28 @@ +/* + * 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 itest; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface MyService { + + String sayHello(String s); +} diff --git a/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyServiceImpl.java b/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyServiceImpl.java new file mode 100644 index 0000000000..d0f8dcc393 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/src/main/java/itest/MyServiceImpl.java @@ -0,0 +1,28 @@ +/* + * 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 itest; + +public class MyServiceImpl implements MyService { + + public String sayHello(String s) { + return "Hello " + s; + } + +} diff --git a/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..8c311553c3 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/MyService.composite b/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/MyService.composite new file mode 100644 index 0000000000..03ac786809 --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/src/main/resources/MyService.composite @@ -0,0 +1,28 @@ + + + + + + + + + diff --git a/java/sca/contrib/itest/binding-sca-jms/service/src/test/java/itest/MyServiceTestCase.java b/java/sca/contrib/itest/binding-sca-jms/service/src/test/java/itest/MyServiceTestCase.java new file mode 100644 index 0000000000..cb79ae050a --- /dev/null +++ b/java/sca/contrib/itest/binding-sca-jms/service/src/test/java/itest/MyServiceTestCase.java @@ -0,0 +1,34 @@ +package itest; + + + +import junit.framework.Assert; + +import org.apache.tuscany.sca.node.SCAClient; +import org.apache.tuscany.sca.node.SCANode; +import org.apache.tuscany.sca.node.SCANodeFactory; +import org.junit.Test; + +/** + * Runs a distributed domain in a single VM by using and in memory + * implementation of the distributed domain + */ +public class MyServiceTestCase { + + @Test + public void testCalculator() throws Exception { + + SCANode node = SCANodeFactory.newInstance().createSCANodeFromClassLoader("MyService.composite", null); + try { + + node.start(); + + MyService service = ((SCAClient)node).getService(MyService.class, "MyServiceComponent"); + + Assert.assertEquals("Hello petra", service.sayHello("petra")); + + } finally { + node.stop(); + } + } +} diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/pom.xml b/java/sca/contrib/itest/bpel/helloworld-reference/pom.xml new file mode 100644 index 0000000000..1e662708d7 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/pom.xml @@ -0,0 +1,210 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + itest-bpel + 2.0-SNAPSHOT + ../../pom.xml + + itest-bpel-helloworld-reference + Apache Tuscany SCA HelloWorld Reference BPEL iTest + + + + apache.incubator + http://people.apache.org/repo/m2-incubating-repository + + + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-bpel-ode + 2.0-SNAPSHOT + runtime + + + + org.apache.ode + ode-dao-jpa-ojpa-derby + 1.1 + zip + + + + org.apache.tuscany.sdo + tuscany-sdo-impl + 1.1.1 + + + + xerces + xercesImpl + 2.8.0 + + + + junit + junit + 4.5 + test + + + + + ${artifactId} + + + org.apache.maven.plugins + maven-surefire-plugin + + 2.3.1 + + false + false + true + + + + org.apache.maven.plugins + maven-dependency-plugin + + + unpack + generate-sources + + unpack + + + + + org.apache.ode + ode-dao-jpa-ojpa-derby + 1.1 + zip + true + ${project.build.directory}/test-classes/ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsService.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsService.java new file mode 100644 index 0000000000..d7dff093f9 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsService.java @@ -0,0 +1,31 @@ +/* + * 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 greetings; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * This is the business interface of the HelloWorld greetings service. + */ +@Remotable +public interface GreetingsService { + + public String getGreetings(String name); +} + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsServiceImpl.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsServiceImpl.java new file mode 100644 index 0000000000..5ecf5494be --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsServiceImpl.java @@ -0,0 +1,33 @@ +/* + * 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 greetings; + +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(GreetingsService.class) +public class GreetingsServiceImpl implements GreetingsService { + + public String getGreetings(String name) { + return "Hello " + name; + } + +} diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsTestCase.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsTestCase.java new file mode 100644 index 0000000000..8dea2715bf --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/greetings/GreetingsTestCase.java @@ -0,0 +1,60 @@ +/* + * 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 greetings; + +import java.io.IOException; +import java.net.Socket; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * Tests the Greetings service + * + * @version $Rev$ $Date$ + */ +public class GreetingsTestCase extends TestCase { + + private SCADomain scaDomain; + GreetingsService greetingsService = null; + + /** + * @throws java.lang.Exception + */ + @Override + protected void setUp() throws Exception { + scaDomain = SCADomain.newInstance("greetings/greetings.composite"); + greetingsService = scaDomain.getService(GreetingsService.class, "GreetingsServiceComponent"); + } + + /** + * @throws java.lang.Exception + */ + @Override + protected void tearDown() throws Exception { + scaDomain.close(); + } + + public void testInvoke() { + String response = greetingsService.getGreetings("Luciano"); + assertEquals("Hello Luciano", response); + } +} diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldService.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldService.java new file mode 100644 index 0000000000..f46893481b --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldService.java @@ -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 helloworld; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for the helloworld service + */ +@Remotable +public interface HelloWorldService { + public String hello(String name); +} diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldServiceImpl.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldServiceImpl.java new file mode 100644 index 0000000000..a687534bb2 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldServiceImpl.java @@ -0,0 +1,47 @@ +/* + * 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 greetings.GreetingsService; + +import org.oasisopen.sca.annotation.Reference; + +/** + * The HelloWorld service implementation + */ +public class HelloWorldServiceImpl implements HelloWorldService { + + protected GreetingsService greetingsService; + + public GreetingsService getGreetingsService() { + System.out.println("Got Injected greetingsService"); + return greetingsService; + } + + @Reference + public void setGreetingsService(GreetingsService greetingsService) { + System.out.println("Injected greetingsService"); + this.greetingsService = greetingsService; + } + + public String hello(String name) { + System.out.println("Calling greeting services getGreetings"); + return greetingsService.getGreetings(name); + } +} \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldTestCase.java b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldTestCase.java new file mode 100644 index 0000000000..bdfedee2f8 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/java/helloworld/HelloWorldTestCase.java @@ -0,0 +1,55 @@ +/* + * 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 junit.framework.TestCase; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * Tests the BPEL Helloworld Service + * + * @version $Rev$ $Date$ + */ +public class HelloWorldTestCase extends TestCase { + private SCADomain scaDomain; + + /** + * @throws java.lang.Exception + */ + @Override + protected void setUp() throws Exception { + scaDomain = SCADomain.newInstance("helloworld/helloworld.composite"); + } + + /** + * @throws java.lang.Exception + */ + @Override + protected void tearDown() throws Exception { + scaDomain.close(); + } + + public void testServiceInvocation() { + HelloWorldService bpelService = scaDomain.getService(HelloWorldService.class, "HelloWorldService"); + String response = bpelService.hello("Luciano"); + assertEquals("Hello Luciano", response); + } +} diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.composite b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.composite new file mode 100644 index 0000000000..dfec43e8e1 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.composite @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.wsdl b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.wsdl new file mode 100644 index 0000000000..e768707ccd --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/greetings/greetings.wsdl @@ -0,0 +1,87 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/deploy.xml b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/deploy.xml new file mode 100644 index 0000000000..25d676bcfc --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/deploy.xml @@ -0,0 +1,35 @@ + + + + + + true + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.bpel b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.bpel new file mode 100644 index 0000000000..5ec2cc9f2e --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.bpel @@ -0,0 +1,84 @@ + + + + + + + + + + + + + + + + + + + + + + + + + $helloMessage.TestPart + $greetingsRequest.parameters + + + + + + + + $greetingsResponse.parameters/greetings:getGreetingsReturn + $helloResponse.TestPart + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.componentType b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.componentType new file mode 100644 index 0000000000..13d12e32a0 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.componentType @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.composite b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.composite new file mode 100644 index 0000000000..504e2ccc5d --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.composite @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.wsdl b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.wsdl new file mode 100644 index 0000000000..0f51b96b27 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/helloworld/helloworld.wsdl @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/log4j.properties b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/log4j.properties new file mode 100644 index 0000000000..4e13380e0b --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-reference/src/test/resources/log4j.properties @@ -0,0 +1,36 @@ +# +# 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. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=OFF, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=OFF +log4j.category.org.hibernate.type=OFF +log4j.category.org.objectweb=OFF +log4j.category.org.apache.ode.axis2=OFF +log4j.category.org.apache.ode.bpel.engine=OFF +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=OFF +log4j.category.org.apache.ode.bpel.epr=OFF +log4j.category.org.apache.tuscany.sca.implementation.bpel=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.ode=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.provider=DEBUG + +# Console appender +log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender +log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout +log4j.appender.CONSOLE.layout.ConversionPattern=[%p] - %C{1}.%M(%L) | %m%n diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/pom.xml b/java/sca/contrib/itest/bpel/helloworld-ws/pom.xml new file mode 100644 index 0000000000..a676177e56 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/pom.xml @@ -0,0 +1,176 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + itest-bpel + 2.0-SNAPSHOT + ../../pom.xml + + itest-bpel-helloworld-ws + Apache Tuscany SCA HelloWorld BPEL iTest + + + + apache.incubator + http://people.apache.org/repo/m2-incubating-repository + + + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-bpel-ode + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sdo + tuscany-sdo-impl + 1.1.1 + + + + xerces + xercesImpl + 2.8.1 + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + + ${artifactId} + + + org.apache.maven.plugins + maven-surefire-plugin + + 2.3.1 + + false + false + true + + + + org.apache.maven.plugins + maven-dependency-plugin + + + unpack + test-compile + + unpack + + + + + org.apache.ode + ode-dao-jpa-ojpa-derby + 1.1 + zip + true + ${project.build.directory}/test-classes/ + + + + + + + + org.apache.tuscany.sdo + tuscany-sdo-plugin + 1.1.1 + + + generate-bpel-helloworld + generate-sources + + ${basedir}/src/test/resources/helloworld/helloworld.wsdl + ${basedir}/target/wsdl2java-source + HelloWorld + true + true + true + + + generate + + + + + + org.apache.tuscany.sca + tuscany-maven-wsdl2java + 2.0-SNAPSHOT + + + + + + ${basedir}/src/test/resources/helloworld/helloworld.wsdl + + + + + generate + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorld.java b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorld.java new file mode 100644 index 0000000000..0999e97065 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorld.java @@ -0,0 +1,45 @@ +/* + * 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.implementation.bpel.example.helloworld.HelloPortType; +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + */ +public class HelloWorld { + private HelloPortType helloService; + + public HelloWorld() { + super(); + } + + @Reference + public void setHelloService(HelloPortType helloService){ + this.helloService = helloService; + } + + public String hello(String hello) throws java.rmi.RemoteException { + System.out.println(">>> Invoking helloService.hello with : " + hello); + return this.helloService.hello(hello); + } + +} diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorldTestCase.java b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorldTestCase.java new file mode 100644 index 0000000000..6971151a77 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/java/helloworld/HelloWorldTestCase.java @@ -0,0 +1,64 @@ +/* + * 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 java.io.IOException; +import java.net.Socket; + +import junit.framework.TestCase; + +import org.apache.tuscany.implementation.bpel.example.helloworld.HelloPortType; +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * Tests the BPEL Helloworld Service + * + * @version $Rev$ $Date$ + */ +public class HelloWorldTestCase extends TestCase { + + private SCADomain scaDomain; + + /** + * @throws java.lang.Exception + */ + @Override + protected void setUp() throws Exception { + scaDomain = SCADomain.newInstance("helloworld/helloworld.composite"); + } + + /** + * @throws java.lang.Exception + */ + @Override + protected void tearDown() throws Exception { + scaDomain.close(); + } + + public void testPing() throws IOException { + new Socket("127.0.0.1", 8085); + } + + public void testServiceInvocation() throws Exception { + HelloPortType bpelService = scaDomain.getService(HelloPortType.class, "BPELHelloWorldServiceComponent"); + String response = bpelService.hello("Hello"); + assertEquals("Hello World", response); + } +} diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/deploy.xml b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/deploy.xml new file mode 100644 index 0000000000..9bd95b2c58 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/deploy.xml @@ -0,0 +1,31 @@ + + + + + + true + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.bpel b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.bpel new file mode 100644 index 0000000000..8cf91adc2c --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.bpel @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + concat($tmpVar,' World') + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.componentType b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.componentType new file mode 100644 index 0000000000..2b360111cb --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.componentType @@ -0,0 +1,30 @@ + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.composite b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.composite new file mode 100644 index 0000000000..f864f45613 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.composite @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.wsdl b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.wsdl new file mode 100644 index 0000000000..610bda3cc4 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/helloworld/helloworld.wsdl @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/log4j.properties b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/log4j.properties new file mode 100644 index 0000000000..37f66e4189 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld-ws/src/test/resources/log4j.properties @@ -0,0 +1,36 @@ +# +# 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. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=OFF, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=OFF +log4j.category.org.hibernate.type=OFF +log4j.category.org.objectweb=OFF +log4j.category.org.apache.ode.axis2=OFF +log4j.category.org.apache.ode.bpel.engine=OFF +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=OFF +log4j.category.org.apache.ode.bpel.epr=OFF +log4j.category.org.apache.tuscany.sca.implementation.bpel=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.ode=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.provider=DEBUG + +# Console appender +log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender +log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout +log4j.appender.CONSOLE.layout.ConversionPattern=[%p] - %C{1}.%M(%L) | %m%n diff --git a/java/sca/contrib/itest/bpel/helloworld/pom.xml b/java/sca/contrib/itest/bpel/helloworld/pom.xml new file mode 100644 index 0000000000..9eae937361 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/pom.xml @@ -0,0 +1,162 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + itest-bpel + 2.0-SNAPSHOT + ../../pom.xml + + itest-bpel-helloworld + Apache Tuscany SCA HelloWorld BPEL iTest + + + + apache.incubator + http://people.apache.org/repo/m2-incubating-repository + + + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-bpel-ode + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sdo + tuscany-sdo-impl + 1.1.1 + + + + xerces + xercesImpl + 2.8.1 + + + + junit + junit + 4.5 + test + + + + + ${artifactId} + + + org.apache.maven.plugins + maven-surefire-plugin + + 2.3.1 + + false + false + true + + + + org.apache.maven.plugins + maven-dependency-plugin + + + unpack + test-compile + + unpack + + + + + org.apache.ode + ode-dao-jpa-ojpa-derby + 1.1 + zip + true + ${project.build.directory}/test-classes/ + + + + + + + + org.apache.tuscany.sdo + tuscany-sdo-plugin + 1.1.1 + + + generate-bpel-helloworld + generate-sources + + ${basedir}/src/test/resources/helloworld/helloworld.wsdl + ${basedir}/target/wsdl2java-source + HelloWorld + true + true + true + + + generate + + + + + + org.apache.tuscany.sca + tuscany-maven-wsdl2java + 2.0-SNAPSHOT + + + + + + ${basedir}/src/test/resources/helloworld/helloworld.wsdl + + + + + generate + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorld.java b/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorld.java new file mode 100644 index 0000000000..0999e97065 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorld.java @@ -0,0 +1,45 @@ +/* + * 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.implementation.bpel.example.helloworld.HelloPortType; +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + */ +public class HelloWorld { + private HelloPortType helloService; + + public HelloWorld() { + super(); + } + + @Reference + public void setHelloService(HelloPortType helloService){ + this.helloService = helloService; + } + + public String hello(String hello) throws java.rmi.RemoteException { + System.out.println(">>> Invoking helloService.hello with : " + hello); + return this.helloService.hello(hello); + } + +} diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorldTestCase.java b/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorldTestCase.java new file mode 100644 index 0000000000..76fcd35c2d --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/java/helloworld/HelloWorldTestCase.java @@ -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 junit.framework.TestCase; + +import org.apache.tuscany.implementation.bpel.example.helloworld.HelloPortType; +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * Tests the BPEL Helloworld Service + * + * @version $Rev$ $Date$ + */ +public class HelloWorldTestCase extends TestCase { + + private SCADomain scaDomain; + + /** + * @throws java.lang.Exception + */ + @Override + protected void setUp() throws Exception { + scaDomain = SCADomain.newInstance("helloworld/helloworld.composite"); + } + + /** + * @throws java.lang.Exception + */ + @Override + protected void tearDown() throws Exception { + scaDomain.close(); + } + + public void testServiceInvocation() throws Exception { + HelloPortType bpelService = scaDomain.getService(HelloPortType.class, "BPELHelloWorldService"); + String response = bpelService.hello("Hello"); + assertEquals("Hello World", response); + } + + public void testReferenceInvocation() throws Exception { + HelloWorld bpelService = scaDomain.getService(HelloWorld.class, "BPELHelloWorld"); + String response = bpelService.hello("Hello"); + assertEquals("Hello World", response); + } +} diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/deploy.xml b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/deploy.xml new file mode 100644 index 0000000000..9bd95b2c58 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/deploy.xml @@ -0,0 +1,31 @@ + + + + + + true + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.bpel b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.bpel new file mode 100644 index 0000000000..8cf91adc2c --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.bpel @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + concat($tmpVar,' World') + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.componentType b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.componentType new file mode 100644 index 0000000000..2b360111cb --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.componentType @@ -0,0 +1,30 @@ + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.composite b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.composite new file mode 100644 index 0000000000..f6b12fb14b --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.composite @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.wsdl b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.wsdl new file mode 100644 index 0000000000..610bda3cc4 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/helloworld/helloworld.wsdl @@ -0,0 +1,82 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/bpel/helloworld/src/test/resources/log4j.properties b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/log4j.properties new file mode 100644 index 0000000000..37f66e4189 --- /dev/null +++ b/java/sca/contrib/itest/bpel/helloworld/src/test/resources/log4j.properties @@ -0,0 +1,36 @@ +# +# 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. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=OFF, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=OFF +log4j.category.org.hibernate.type=OFF +log4j.category.org.objectweb=OFF +log4j.category.org.apache.ode.axis2=OFF +log4j.category.org.apache.ode.bpel.engine=OFF +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=OFF +log4j.category.org.apache.ode.bpel.epr=OFF +log4j.category.org.apache.tuscany.sca.implementation.bpel=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.ode=DEBUG +log4j.category.org.apache.tuscany.sca.implementation.bpel.provider=DEBUG + +# Console appender +log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender +log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout +log4j.appender.CONSOLE.layout.ConversionPattern=[%p] - %C{1}.%M(%L) | %m%n diff --git a/java/sca/contrib/itest/bpel/pom.xml b/java/sca/contrib/itest/bpel/pom.xml new file mode 100644 index 0000000000..d6909735db --- /dev/null +++ b/java/sca/contrib/itest/bpel/pom.xml @@ -0,0 +1,37 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-bpel + pom + Apache Tuscany SCA BPEL Integration Tests + + + helloworld + helloworld-ws + helloworld-reference + + diff --git a/java/sca/contrib/itest/builder/pom.xml b/java/sca/contrib/itest/builder/pom.xml new file mode 100644 index 0000000000..b8dfd95783 --- /dev/null +++ b/java/sca/contrib/itest/builder/pom.xml @@ -0,0 +1,99 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-builder + Apache Tuscany SCA Builder Integration Test + + + + org.apache.tuscany.sca + tuscany-sca-api + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-workspace-impl + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-binding-ws-xml + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-binding-sca-xml + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-assembly + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-core-databinding + 2.0-SNAPSHOT + test + + + + xerces + xercesImpl + 2.8.1 + test + + + + junit + junit + 4.5 + test + + + + + + ${artifactId} + + diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDImpl.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDImpl.java new file mode 100644 index 0000000000..fb23a4e60f --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDImpl.java @@ -0,0 +1,45 @@ +/* + * 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.itest.builder; + +import java.util.List; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * Implementation class for ComponentD. + * + * @version $Rev$ $Date$ + */ +@Service(interfaces={Service3.class, Service3a.class}) +public class ComponentDImpl implements Service3, Service3a { + + @Reference + protected Service3a reference3; + + public String getGreetings(String name) { + return "Hello, " + name + "!"; + } + + public String getGreetings2(String name) { + return "Goodbye, " + name + "!"; + } + +} diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDReferenceMultiplicityImpl.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDReferenceMultiplicityImpl.java new file mode 100644 index 0000000000..5ee020e181 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentDReferenceMultiplicityImpl.java @@ -0,0 +1,48 @@ +/* + * 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.itest.builder; + +import java.util.List; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * Implementation class for ComponentD. + * + * @version $Rev: 678875 $ $Date: 2008-07-22 21:01:07 +0100 (Tue, 22 Jul 2008) $ + */ +@Service(interfaces={Service3.class, Service3a.class}) +public class ComponentDReferenceMultiplicityImpl implements Service3, Service3a { + + @Reference + protected Service3a reference3; + + @Reference + protected List reference3a; + + public String getGreetings(String name) { + return "Hello, " + name + "!"; + } + + public String getGreetings2(String name) { + return "Goodbye, " + name + "!"; + } + +} diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentEImpl.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentEImpl.java new file mode 100644 index 0000000000..2d8a37d5f0 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentEImpl.java @@ -0,0 +1,36 @@ +/* + * 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.itest.builder; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * Implementation class for ComponentD. + * + * @version $Rev: 678875 $ $Date: 2008-07-22 21:01:07 +0100 (Tue, 22 Jul 2008) $ + */ +@Service(interfaces={Service3.class}) +public class ComponentEImpl implements Service3 { + + + public String getGreetings(String name) { + return "Hello, " + name + " from ComponentE"; + } +} diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentFImpl.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentFImpl.java new file mode 100644 index 0000000000..4fdaac1fb1 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/ComponentFImpl.java @@ -0,0 +1,36 @@ +/* + * 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.itest.builder; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * Implementation class for ComponentD. + * + * @version $Rev: 678875 $ $Date: 2008-07-22 21:01:07 +0100 (Tue, 22 Jul 2008) $ + */ +@Service(interfaces={Service3.class}) +public class ComponentFImpl implements Service3 { + + + public String getGreetings(String name) { + return "Hello, " + name + " from ComponentF"; + } +} diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3.java new file mode 100644 index 0000000000..1feb08b876 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3.java @@ -0,0 +1,33 @@ +/* + * 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.itest.builder; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * Interface for Service3 in ComponentD. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface Service3 { + + String getGreetings(String name); + +} diff --git a/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3a.java b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3a.java new file mode 100644 index 0000000000..3a872376ea --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/java/org/apache/tuscany/sca/itest/builder/Service3a.java @@ -0,0 +1,33 @@ +/* + * 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.itest.builder; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * Interface for Service3a in ComponentD. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface Service3a { + + String getGreetings2(String name); + +} diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario1/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario1/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..256d01be58 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario1/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1.composite new file mode 100644 index 0000000000..5c2a98ab40 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1.composite @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1a.composite new file mode 100644 index 0000000000..21b5897aa1 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario1/scenario1a.composite @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario10/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario10/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..083079ba42 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario10/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10.composite new file mode 100644 index 0000000000..c24b7f0046 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10.composite @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10a.composite new file mode 100644 index 0000000000..27a73d5c41 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario10/scenario10a.composite @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario10/service3.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario10/service3.wsdl new file mode 100644 index 0000000000..14edcc00e6 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario10/service3.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario11/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario11/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..a6e4b65970 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario11/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11.composite new file mode 100644 index 0000000000..3a94152e6a --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11.composite @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11a.composite new file mode 100644 index 0000000000..6130c68651 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario11/scenario11a.composite @@ -0,0 +1,64 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario11/service3.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario11/service3.wsdl new file mode 100644 index 0000000000..14edcc00e6 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario11/service3.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario12/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario12/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..125bdc5e53 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario12/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12.composite new file mode 100644 index 0000000000..aabd445e23 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12.composite @@ -0,0 +1,58 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12a.composite new file mode 100644 index 0000000000..a2ccc47c28 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario12/scenario12a.composite @@ -0,0 +1,64 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario13/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario13/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..c906c6c5b0 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario13/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13.composite new file mode 100644 index 0000000000..ed59cd2adf --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13.composite @@ -0,0 +1,58 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13a.composite new file mode 100644 index 0000000000..41150f78fd --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario13/scenario13a.composite @@ -0,0 +1,64 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario2/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario2/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..6fa901c4df --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario2/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2.composite new file mode 100644 index 0000000000..66f88294ff --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2.composite @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2a.composite new file mode 100644 index 0000000000..db1af4743f --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario2/scenario2a.composite @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario3/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario3/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..f5899ab1f0 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario3/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3.composite new file mode 100644 index 0000000000..4b37c19e4e --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3.composite @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3a.composite new file mode 100644 index 0000000000..fedd79ff3d --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario3/scenario3a.composite @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario4/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario4/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..642245ea7e --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario4/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4.composite new file mode 100644 index 0000000000..1bb876b33d --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4.composite @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4a.composite new file mode 100644 index 0000000000..55e13700a6 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario4/scenario4a.composite @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario5/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario5/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..92da17179f --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario5/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5.composite new file mode 100644 index 0000000000..403e19b087 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5.composite @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5a.composite new file mode 100644 index 0000000000..0e37ded0e4 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenario5a.composite @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenarios.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenarios.wsdl new file mode 100644 index 0000000000..7480419231 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario5/scenarios.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario6/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario6/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..42d45b0b98 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario6/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6.composite new file mode 100644 index 0000000000..1c89139905 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6.composite @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6a.composite new file mode 100644 index 0000000000..853703a353 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenario6a.composite @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenarios.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenarios.wsdl new file mode 100644 index 0000000000..7480419231 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario6/scenarios.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario7/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario7/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..44c471cc65 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario7/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7.composite new file mode 100644 index 0000000000..6b1ac24cec --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7.composite @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7a.composite new file mode 100644 index 0000000000..8e0cebbdd5 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenario7a.composite @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenarios.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenarios.wsdl new file mode 100644 index 0000000000..7480419231 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario7/scenarios.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario8/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario8/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..7cb09d0a74 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario8/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8.composite new file mode 100644 index 0000000000..26e5ee33fa --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8.composite @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8a.composite new file mode 100644 index 0000000000..4fa0712199 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenario8a.composite @@ -0,0 +1,50 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenarios.wsdl b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenarios.wsdl new file mode 100644 index 0000000000..7480419231 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario8/scenarios.wsdl @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario9/META-INF/sca-contribution.xml b/java/sca/contrib/itest/builder/src/main/resources/scenario9/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..6e0908702b --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario9/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9.composite new file mode 100644 index 0000000000..3fce35470e --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9.composite @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9a.composite b/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9a.composite new file mode 100644 index 0000000000..6e86c547b3 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/main/resources/scenario9/scenario9a.composite @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/BuilderTestCase.java b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/BuilderTestCase.java new file mode 100644 index 0000000000..1f45cb4a66 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/BuilderTestCase.java @@ -0,0 +1,805 @@ +/* + * 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.itest.builder; + +import javax.wsdl.Definition; +import javax.wsdl.Port; +import javax.xml.namespace.QName; +import junit.framework.TestCase; +import org.apache.tuscany.sca.assembly.Binding; +import org.apache.tuscany.sca.assembly.Component; +import org.apache.tuscany.sca.assembly.ComponentReference; +import org.apache.tuscany.sca.assembly.ComponentService; +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.assembly.Reference; +import org.apache.tuscany.sca.assembly.SCABinding; +import org.apache.tuscany.sca.assembly.Service; +import org.apache.tuscany.sca.binding.ws.WebServiceBinding; +import org.apache.tuscany.sca.interfacedef.java.JavaInterfaceContract; +import org.apache.tuscany.sca.interfacedef.wsdl.WSDLInterfaceContract; + +/** + * Load and build some composites and inspect the results. + * + * @version $Rev$ $Date$ + */ +public class BuilderTestCase extends TestCase { + private CustomCompositeBuilder customBuilder; + + @Override + protected void setUp() throws Exception { + } + + @Override + protected void tearDown() throws Exception { + } + + + // Scenario 1: on outer composite service CompositeA/Service1 + public void testScenario1() throws Exception { + System.out.println("====>Running testScenario1"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario1.composite", "TestContribution", "src/main/resources/scenario1/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario1Results(false); + } + + public void testScenario1NonWiring() throws Exception { + System.out.println("====>Running testScenario1NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario1.composite", "TestContribution", "src/main/resources/scenario1/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario1Results(true); + } + + private void checkScenario1Results(boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + if (!nonWiring) { + // Should create component service $promoted$Service1 on innermost component + // ComponentD, with and uri="/Service1" + // No other services on ComponentD should have + WebServiceBinding wsBinding = null; + for (ComponentService service : componentD.getServices()) { + WebServiceBinding wsb = service.getBinding(WebServiceBinding.class); + if ("$promoted$Service1".equals(service.getName())) { + wsBinding = wsb; + } else { + assert wsb == null; + } + } + assert "/Service1".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/$promoted$Service1 with endpoint uri="/Service1" + Definition def = wsBinding.getWSDLDocument(); + javax.wsdl.Service svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + Port port = svc.getPort("Service3Port"); + assert "/Service1".equals(TestUtils.getPortAddress(port)); + } else { + // Should not create component service $promoted$Service1 on innermost component ComponentD + // No component services on ComponentD should have + for (ComponentService service : componentD.getServices()) { + assert !"$promoted$Service1".equals(service.getName()); + assert service.getBinding(WebServiceBinding.class) == null; + } + } + + // No services on ComponentB should have + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + for (ComponentService service : componentB.getServices()) { + assert service.getBinding(WebServiceBinding.class) == null; + } + + // No services on CompositeC should have + Composite compositeC = TestUtils.getComposite(domainComposite, new QName("http://scenario1", "CompositeC")); + for (Service service : compositeC.getServices()) { + assert service.getBinding(WebServiceBinding.class) == null; + } + + if (nonWiring) { + // Should not add a WSDL document to domain composite service Service1 + WebServiceBinding wsBinding = null; + for (Service service : domainComposite.getServices()) { + if ("Service1".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert wsBinding.getWSDLDocument() == null; + } + } + + // Scenario 2: on outer component service ComponentB/Service2 + public void testScenario2() throws Exception { + System.out.println("====>Running testScenario2"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario2.composite", "TestContribution", "src/main/resources/scenario2/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario2and3Results("http://scenario2", false); + } + + public void testScenario2NonWiring() throws Exception { + System.out.println("====>Running testScenario2NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario2.composite", "TestContribution", "src/main/resources/scenario2/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario2and3Results("http://scenario2", true); + } + + private void checkScenario2and3Results(String namespace, boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + // Should create WSDL document for ComponentB/Service2 with endpoint uri="/ComponentB/Service2" + // No other services on ComponentB should have + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + WebServiceBinding wsBinding = null; + for (ComponentService service : componentB.getServices()) { + WebServiceBinding wsb = service.getBinding(WebServiceBinding.class); + if ("Service2".equals(service.getName())) { + wsBinding = wsb; + } else { + assert wsb == null; + } + } + Definition def = wsBinding.getWSDLDocument(); + javax.wsdl.Service svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + Port port = svc.getPort("Service3Port"); + assert "/ComponentB/Service2".equals(TestUtils.getPortAddress(port)); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + if (!nonWiring) { + // Should create component service $promoted$ComponentB$slash$Service2 on innermost component + // ComponentD, with and uri="/ComponentB/Service2" + wsBinding = null; + for (ComponentService service : componentD.getServices()) { + if ("$promoted$ComponentB$slash$Service2".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert "/ComponentB/Service2".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/$promoted$ComponentB$slash$Service2 with endpoint uri="/ComponentB/Service2" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + port = svc.getPort("Service3Port"); + assert "/ComponentB/Service2".equals(TestUtils.getPortAddress(port)); + } else { + // Should not create component service $promoted$ComponentB$slash$Service2 on innermost component ComponentD + for (ComponentService service : componentD.getServices()) { + assert !"$promoted$ComponentB$slash$Service2".equals(service.getName()); + } + } + + // Should add to outer composite service CompositeA/Service1 + wsBinding = null; + for (Service service : domainComposite.getServices()) { + if ("Service1".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert wsBinding != null; + if (nonWiring) { + // Should not add a WSDL document to domain composite service Service1 + assert wsBinding.getWSDLDocument() == null; + } + + if (!nonWiring) { + // Should create component service $promoted$Service1 on innermost component + // ComponentD, with and uri="/Service1" + wsBinding = null; + for (ComponentService service : componentD.getServices()) { + if ("$promoted$Service1".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert "/Service1".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/$promoted$Service1 with endpoint uri="/Service1" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + port = svc.getPort("Service3Port"); + assert "/Service1".equals(TestUtils.getPortAddress(port)); + } else { + // Should not create component service $promoted$.Service1 on innermost component ComponentD + for (ComponentService service : componentD.getServices()) { + assert !"$promoted$Service1".equals(service.getName()); + } + } + + // No services on ComponentD should have , except for $promoted$Service1 + // and $promoted$ComponentB$slash$Service2 + for (ComponentService service : componentD.getServices()) { + if (!"$promoted$Service1".equals(service.getName()) && + !"$promoted$ComponentB$slash$Service2".equals(service.getName())) { + assert service.getBinding(WebServiceBinding.class) == null; + } + } + + // No services on CompositeC should have , except for Service2 in Scenario 3 + Composite compositeC = TestUtils.getComposite(domainComposite, new QName(namespace, "CompositeC")); + for (Service service : compositeC.getServices()) { + if ("http://scenario3".equals(namespace) && "Service2".equals(service.getName())) { + assert service.getBinding(WebServiceBinding.class) != null; + } else { + assert service.getBinding(WebServiceBinding.class) == null; + } + } + } + + // Scenario 3: on inner composite service CompositeC/Service2 + public void testScenario3() throws Exception { + System.out.println("====>Running testScenario3"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario3.composite", "TestContribution", "src/main/resources/scenario3/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario2and3Results("http://scenario3", false); + } + + public void testScenario3NonWiring() throws Exception { + System.out.println("====>Running testScenario3NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario3.composite", "TestContribution", "src/main/resources/scenario3/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario2and3Results("http://scenario3", true); + } + + // Scenario 4: on inner component service ComponentD/Service3 + public void testScenario4() throws Exception { + System.out.println("====>Running testScenario4"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario4.composite", "TestContribution", "src/main/resources/scenario4/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario4Results(false); + } + + public void testScenario4NonWiring() throws Exception { + System.out.println("====>Running testScenario4NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario4.composite", "TestContribution", "src/main/resources/scenario4/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario4Results(true); + } + + private void checkScenario4Results(boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + // Should create WSDL document for ComponentD/Service3 with endpoint uri="/ComponentD/Service3" + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + WebServiceBinding wsBinding = null; + for (ComponentService service : componentD.getServices()) { + if ("Service3".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + Definition def = wsBinding.getWSDLDocument(); + javax.wsdl.Service svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + Port port = svc.getPort("Service3Port"); + assert "/ComponentB/ComponentD/Service3".equals(TestUtils.getPortAddress(port)); + + // Should add to inner composite service CompositeC/Service2 + // No other services on CompositeC should have + Composite compositeC = TestUtils.getComposite(domainComposite, new QName("http://scenario4", "CompositeC")); + wsBinding = null; + for (Service service : compositeC.getServices()) { + WebServiceBinding wsb = service.getBinding(WebServiceBinding.class); + if ("Service2".equals(service.getName())) { + wsBinding = wsb; + } else { + assert wsb == null; + } + } + assert "/ComponentB/Service2".equals(wsBinding.getURI()); + + // Should add to outer component service ComponentB/Service2 + // Should create WSDL document for ComponentB/Service2 with endpoint uri="/ComponentB/Service2" + // No other services on ComponentB should have + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + wsBinding = null; + for (ComponentService service : componentB.getServices()) { + WebServiceBinding wsb = service.getBinding(WebServiceBinding.class); + if ("Service2".equals(service.getName())) { + wsBinding = wsb; + } else { + assert wsb == null; + } + } + assert "/ComponentB/Service2".equals(wsBinding.getURI()); + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + port = svc.getPort("Service3Port"); + assert "/ComponentB/Service2".equals(TestUtils.getPortAddress(port)); + + if (!nonWiring) { + // Should create component service $promoted$ComponentB$slash$Service2 on innermost component + // ComponentD, with and uri="/ComponentB/Service2" + wsBinding = null; + for (ComponentService service : componentD.getServices()) { + if ("$promoted$ComponentB$slash$Service2".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert "/ComponentB/Service2".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/$promoted$ComponentB$slash$Service2 with endpoint uri="/ComponentB/Service2" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + port = svc.getPort("Service3Port"); + assert "/ComponentB/Service2".equals(TestUtils.getPortAddress(port)); + } else { + // Should not create component service $promoted$ComponentB$slash$Service2 on innermost component ComponentD + for (ComponentService service : componentD.getServices()) { + assert !"$promoted$ComponentB$slash$Service2".equals(service.getName()); + } + } + + // Should add to outer composite service CompositeA/Service1 + wsBinding = null; + for (Service service : domainComposite.getServices()) { + if ("Service1".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert wsBinding != null; + if (nonWiring) { + // Should not add a WSDL document to domain composite service Service1 + assert wsBinding.getWSDLDocument() == null; + } + + if (!nonWiring) { + // Should create component service $promoted$Service1 on innermost component + // ComponentD, with and uri="/Service1" + wsBinding = null; + for (ComponentService service : componentD.getServices()) { + if ("$promoted$Service1".equals(service.getName())) { + wsBinding = service.getBinding(WebServiceBinding.class); + } + } + assert "/Service1".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/$promoted$Service1 with endpoint uri="/Service1" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://builder.itest.sca.tuscany.apache.org/", "Service3Service")); + port = svc.getPort("Service3Port"); + assert "/Service1".equals(TestUtils.getPortAddress(port)); + } else { + // Should not create component service $promoted$.Service1 on innermost component ComponentD + for (ComponentService service : componentD.getServices()) { + assert !"$promoted$Service1".equals(service.getName()); + } + } + + // No services on ComponentD should have , except for Service3, + // $promoted$.Service1 and $promoted$.ComponentB.Service2 + for (ComponentService service : componentD.getServices()) { + if (!"Service3".equals(service.getName()) && + !"$promoted$Service1".equals(service.getName()) && + !"$promoted$ComponentB$slash$Service2".equals(service.getName())) { + assert service.getBinding(WebServiceBinding.class) == null; + } + } + } + + // Scenario 5: and on outer composite reference CompositeA/reference1 + public void testScenario5() throws Exception { + System.out.println("====>Running testScenario5"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario5.composite", "TestContribution", "src/main/resources/scenario5/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario5Results(false); + } + + public void testScenario5NonWiring() throws Exception { + System.out.println("====>Running testScenario5NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario5.composite", "TestContribution", "src/main/resources/scenario5/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario5Results(true); + } + + private void checkScenario5Results(boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + // Should not add to any outer component references + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + for (ComponentReference reference : componentB.getReferences()) { + assert reference.getBinding(WebServiceBinding.class) == null; + } + + Definition def; + javax.wsdl.Service svc; + Port port; + WebServiceBinding wsBinding; + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + if (!nonWiring) { + // Should add to inner component reference ComponentD/reference3 with uri="http://foo.com/bar" + // Should set on inner component reference ComponentD/reference3 + wsBinding = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getInterfaceContract(wsBinding) instanceof WSDLInterfaceContract; + } + } + assert "http://foo.com/bar".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/reference3 with endpoint uri="http://foo.com/bar" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://scenarios/ComponentD/reference3", "Service3aService")); + port = svc.getPort("Service3aPort"); + assert "http://foo.com/bar".equals(TestUtils.getPortAddress(port)); + } else { + // Should not add to any inner component references + for (ComponentReference reference : componentD.getReferences()) { + assert reference.getBinding(WebServiceBinding.class) == null; + } + } + + // Should not add or to inner composite reference CompositeC/reference2 + Composite compositeC = TestUtils.getComposite(domainComposite, new QName("http://scenario5", "CompositeC")); + for (Reference reference : compositeC.getReferences()) { + assert reference.getBinding(WebServiceBinding.class) == null; + assert reference.getInterfaceContract() instanceof JavaInterfaceContract; + } + } + + // Scenario 6: and on outer component reference ComponentB/reference2 + public void testScenario6() throws Exception { + System.out.println("====>Running testScenario6"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario6.composite", "TestContribution", "src/main/resources/scenario6/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario6and7Results("http://scenario6", false); + } + + public void testScenario6NonWiring() throws Exception { + System.out.println("====>Running testScenario6NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario6.composite", "TestContribution", "src/main/resources/scenario6/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario6and7Results("http://scenario6", true); + } + + private void checkScenario6and7Results(String namespace, boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + // Should remove target= on ComponentB/reference2 (for Scenario 6) or + // CompositeC/reference2 (for Scenario 7), and add uri="http://foo.com/bar" + // to the element on ComponentB/reference2 + // For nonWiring, ComponentB/reference2 should have target= + // and no uri= should be added + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + WebServiceBinding wsBinding = null; + for (ComponentReference reference : componentB.getReferences()) { + if ("reference2".equals(reference.getName())) { + if (!nonWiring) { + assert reference.getTargets().size() == 0; + } else { + assert reference.getTargets().size() == 1; + } + wsBinding = reference.getBinding(WebServiceBinding.class); + } + } + if (!nonWiring) { + assert "http://foo.com/bar".equals(wsBinding.getURI()); + } else { + assert wsBinding.getURI() == null; + } + + Definition def; + javax.wsdl.Service svc; + Port port; + if (!nonWiring) { + // Should create WSDL document for ComponentB/reference2 with endpoint uri="http://foo.com/bar" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://scenarios/ComponentB/reference2", "Service3aService")); + port = svc.getPort("Service3aPort"); + assert "http://foo.com/bar".equals(TestUtils.getPortAddress(port)); + } + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + if (!nonWiring) { + // Should add to inner component reference ComponentD/reference3 with uri="http://foo.com/bar" + // Should set on inner component reference ComponentD/reference3 + wsBinding = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getBindings().size() == 1; + assert reference.getInterfaceContract(wsBinding) instanceof WSDLInterfaceContract; + } + } + assert "http://foo.com/bar".equals(wsBinding.getURI()); + + // Should create WSDL document for ComponentD/reference3 with endpoint uri="http://foo.com/bar" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://scenarios/ComponentB/reference2", "Service3aService")); + port = svc.getPort("Service3aPort"); + assert "http://foo.com/bar".equals(TestUtils.getPortAddress(port)); + } else { + // Should not add to any inner component references + for (ComponentReference reference : componentD.getReferences()) { + assert reference.getBinding(WebServiceBinding.class) == null; + } + } + + // No references on CompositeC should have or , except for + // reference2 in Scenario 7 + Composite compositeC = TestUtils.getComposite(domainComposite, new QName(namespace, "CompositeC")); + for (Reference reference : compositeC.getReferences()) { + if ("http://scenario7".equals(namespace) && "reference2".equals(reference.getName())) { + assert reference.getBinding(WebServiceBinding.class)!= null; + assert reference.getInterfaceContract() instanceof WSDLInterfaceContract; + } else { + assert reference.getBinding(WebServiceBinding.class) == null; + assert reference.getInterfaceContract() instanceof JavaInterfaceContract; + } + } + + // Should add and to outer composite reference CompositeA/reference1 + wsBinding = null; + for (Reference reference : domainComposite.getReferences()) { + if ("reference1".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getInterfaceContract() instanceof WSDLInterfaceContract; + } + } + assert wsBinding.getURI() == null; + + // Should not add a WSDL document to domain composite reference reference1 + assert wsBinding.getWSDLDocument() == null; + } + + // Scenario 7: and on inner composite reference CompositeC/reference2 + public void testScenario7() throws Exception { + System.out.println("====>Running testScenario7"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario7.composite", "TestContribution", "src/main/resources/scenario7/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario6and7Results("http://scenario7", false); + } + + public void testScenario7NonWiring() throws Exception { + System.out.println("====>Running testScenario7NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario7.composite", "TestContribution", "src/main/resources/scenario7/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario6and7Results("http://scenario7", true); + } + + // Scenario 8: and on inner component reference ComponentD/reference3 + public void testScenario8() throws Exception { + System.out.println("====>Running testScenario8"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario8.composite", "TestContribution", "src/main/resources/scenario8/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario8Results(false); + } + + public void testScenario8NonWiring() throws Exception { + System.out.println("====>Running testScenario8NonWiring"); + customBuilder = new CustomCompositeBuilder(true); + customBuilder.loadContribution("scenario8.composite", "TestContribution", "src/main/resources/scenario8/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario8Results(true); + } + + private void checkScenario8Results(boolean nonWiring) { + Composite domainComposite = customBuilder.getDomainComposite(); + + // Should replace target= on ComponentD/reference3 by uri="http://foo.com/bar" on + // For nonWiring, the original target= is preserved and there is no uri= + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + WebServiceBinding wsBinding = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3".equals(reference.getName())) { + if (!nonWiring) { + assert reference.getTargets().size() == 0; + } else { + assert reference.getTargets().size() == 1; + } + wsBinding = reference.getBinding(WebServiceBinding.class); + } + } + if (!nonWiring) { + assert "http://foo.com/bar".equals(wsBinding.getURI()); + } else { + assert wsBinding.getURI() == null; + } + + Definition def; + javax.wsdl.Service svc; + Port port; + if (!nonWiring) { + // Should create WSDL document for ComponentD/reference3 with endpoint uri="http://foo.com/bar" + def = wsBinding.getWSDLDocument(); + svc = def.getService(new QName("http://scenarios/ComponentD/reference3", "Service3aService")); + port = svc.getPort("Service3aPort"); + assert "http://foo.com/bar".equals(TestUtils.getPortAddress(port)); + } + + // Should add and to inner composite reference CompositeC/reference2 + Composite compositeC = TestUtils.getComposite(domainComposite, new QName("http://scenario8", "CompositeC")); + wsBinding = null; + for (Reference reference : compositeC.getReferences()) { + if ("reference2".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getInterfaceContract() instanceof WSDLInterfaceContract; + } + } + assert wsBinding.getURI() == null; + + // Should add and to outer component reference ComponentB/reference2 + Component componentB = TestUtils.getComponent(domainComposite, "ComponentB"); + wsBinding = null; + for (ComponentReference reference : componentB.getReferences()) { + if ("reference2".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getInterfaceContract() instanceof WSDLInterfaceContract; + } + } + assert wsBinding.getURI() == null; + + // Should add and to outer composite reference CompositeA/reference1 + wsBinding = null; + for (Reference reference : domainComposite.getReferences()) { + if ("reference1".equals(reference.getName())) { + wsBinding = reference.getBinding(WebServiceBinding.class); + assert reference.getInterfaceContract() instanceof WSDLInterfaceContract; + } + } + assert wsBinding.getURI() == null; + + // Should not add a WSDL document to domain composite reference reference1 + assert wsBinding.getWSDLDocument() == null; + } + + // Scenario 9: target in reference CDR3A and binding.ws uri= at CAR1A + public void testScenario9() throws Exception { + System.out.println("====>Running testScenario9"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario9.composite", "TestContribution", "src/main/resources/scenario9/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario9Results(); + } + + private void checkScenario9Results() { + Composite domainComposite = customBuilder.getDomainComposite(); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + ComponentReference componentRef = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3a".equals(reference.getName())) { + componentRef = reference; + assertTrue(reference.getBindings().size() == 2); + assertTrue(reference.getBindings().get(0) instanceof SCABinding); + assertTrue(reference.getBindings().get(1) instanceof WebServiceBinding); + } + } + assertTrue(componentRef != null); + } + + // Scenario 10: targets in references CBR2A and CDR3A and binding.ws at CBR2A + public void testScenario10() throws Exception { + System.out.println("====>Running testScenario10"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario10.composite", "TestContribution", "src/main/resources/scenario10/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario10And11Results(); + } + + // Scenario 11: targets in references CBR2A and CDR3A and binding.ws at CCR2A + public void testScenario11() throws Exception { + System.out.println("====>Running testScenario11"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario11.composite", "TestContribution", "src/main/resources/scenario11/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario10And11Results(); + } + + private void checkScenario10And11Results() { + Composite domainComposite = customBuilder.getDomainComposite(); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + ComponentReference componentRef = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3a".equals(reference.getName())) { + componentRef = reference; + assertTrue(reference.getBindings().size() == 2); + Binding binding1 = reference.getBindings().get(0); + assertTrue(binding1 instanceof SCABinding); + assertTrue(reference.getInterfaceContract(binding1) instanceof JavaInterfaceContract); + Binding binding2 = reference.getBindings().get(1); + assertTrue(binding2 instanceof WebServiceBinding); + assertTrue(reference.getInterfaceContract(binding2) instanceof WSDLInterfaceContract); + } + } + assertTrue(componentRef != null); + } + + // Scenario 12: targets in references CBR2A and CDR3A and binding.ws at CDR3A + public void testScenario12() throws Exception { + System.out.println("====>Running testScenario12"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario12.composite", "TestContribution", "src/main/resources/scenario12/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario12Results(); + } + + private void checkScenario12Results() { + Composite domainComposite = customBuilder.getDomainComposite(); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + ComponentReference componentRef = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3a".equals(reference.getName())) { + componentRef = reference; + assertTrue(reference.getBindings().size() == 2); + assertTrue(reference.getBindings().get(0) instanceof WebServiceBinding); + assertTrue(reference.getBindings().get(1) instanceof WebServiceBinding); + } + } + assertTrue(componentRef != null); + } + + // Scenario 13: target in reference CDR3A + public void testScenario13() throws Exception { + System.out.println("====>Running testScenario13"); + customBuilder = new CustomCompositeBuilder(false); + customBuilder.loadContribution("scenario13.composite", "TestContribution", "src/main/resources/scenario13/"); + //TestUtils.printResults(customBuilder); + TestUtils.checkProblems(customBuilder); + checkScenario13Results(); + } + + private void checkScenario13Results() { + Composite domainComposite = customBuilder.getDomainComposite(); + + Component componentD = TestUtils.getComponent(domainComposite, "ComponentD"); + ComponentReference componentRef = null; + for (ComponentReference reference : componentD.getReferences()) { + if ("reference3a".equals(reference.getName())) { + componentRef = reference; + assertTrue(reference.getBindings().size() == 1); + assertTrue(reference.getBindings().get(0) instanceof WebServiceBinding); + } + } + assertTrue(componentRef != null); + } + +} diff --git a/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CompositeBuilderNonWiringImpl.java b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CompositeBuilderNonWiringImpl.java new file mode 100644 index 0000000000..c9339c1545 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CompositeBuilderNonWiringImpl.java @@ -0,0 +1,153 @@ +/* + * 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.itest.builder; + +import java.util.logging.Logger; + +import org.apache.tuscany.sca.assembly.AssemblyFactory; +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.assembly.DefaultEndpointFactory; +import org.apache.tuscany.sca.assembly.EndpointFactory; +import org.apache.tuscany.sca.assembly.SCABindingFactory; +import org.apache.tuscany.sca.assembly.builder.CompositeBuilder; +import org.apache.tuscany.sca.assembly.builder.CompositeBuilderException; +import org.apache.tuscany.sca.core.ExtensionPointRegistry; +import org.apache.tuscany.sca.definitions.Definitions; +import org.apache.tuscany.sca.interfacedef.InterfaceContractMapper; +import org.apache.tuscany.sca.monitor.Monitor; +import org.apache.tuscany.sca.policy.IntentAttachPointTypeFactory; + +/** + * Test version of org.apache.tuscany.sca.assembly.builder.impl.builder.CompositeBuilderImpl + * + * This class should be identical to CompositeBuilderImpl except for omitting the + * following builders: + * componentWireBuilder + * compositeReferenceWireBuilder + * compositePromotedServiceBuilder + * It omits the component wiring step and the special processing that's performed + * for composite service and reference promotion. + * + * @version $Rev$ $Date$ + */ +public class CompositeBuilderNonWiringImpl implements CompositeBuilder { + private static final Logger logger = Logger.getLogger(CompositeBuilderNonWiringImpl.class.getName()); + private CompositeBuilder compositeIncludeBuilder; + private CompositeBuilder compositeCloneBuilder; + private CompositeBuilder componentConfigurationBuilder; + private CompositeBuilder compositeServiceConfigurationBuilder; + private CompositeBuilder compositeReferenceConfigurationBuilder; + private CompositeBuilder compositeBindingURIBuilder; + private CompositeBuilder componentServicePromotionBuilder; + private CompositeBuilder compositePromotionBuilder; + private CompositeBuilder compositePolicyBuilder; + private CompositeBuilder componentServiceBindingBuilder; + private CompositeBuilder componentReferenceBindingBuilder; + + /** + * Constructs a new composite builder. + * + * @param assemblyFactory + * @param scaBindingFactory + * @param intentAttachPointTypeFactory + * @param interfaceContractMapper + * @param monitor + */ + public CompositeBuilderNonWiringImpl(AssemblyFactory assemblyFactory, + SCABindingFactory scaBindingFactory, + IntentAttachPointTypeFactory intentAttachPointTypeFactory, + InterfaceContractMapper interfaceContractMapper) { + this(assemblyFactory, null, scaBindingFactory, intentAttachPointTypeFactory, interfaceContractMapper); + } + + /** + * Constructs a new composite builder. + * + * @param assemblyFactory + * @param scaBindingFactory + * @param endpointFactory + * @param intentAttachPointTypeFactory + * @param interfaceContractMapper + * @param policyDefinitions + * @param monitor + */ + public CompositeBuilderNonWiringImpl(AssemblyFactory assemblyFactory, + EndpointFactory endpointFactory, + SCABindingFactory scaBindingFactory, + IntentAttachPointTypeFactory intentAttachPointTypeFactory, + InterfaceContractMapper interfaceContractMapper) { + + if (endpointFactory == null){ + endpointFactory = new DefaultEndpointFactory(); + } + + compositeIncludeBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositeIncludeBuilderImpl(); + compositeCloneBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositeCloneBuilderImpl(); + componentConfigurationBuilder = new org.apache.tuscany.sca.assembly.builder.impl.ComponentConfigurationBuilderImpl(assemblyFactory, scaBindingFactory, interfaceContractMapper); + compositeServiceConfigurationBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositeServiceConfigurationBuilderImpl(assemblyFactory); + compositeReferenceConfigurationBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositeReferenceConfigurationBuilderImpl(assemblyFactory); + compositeBindingURIBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositeBindingURIBuilderImpl(assemblyFactory, scaBindingFactory, interfaceContractMapper); + compositePromotionBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositePromotionBuilderImpl(assemblyFactory, endpointFactory, interfaceContractMapper); + compositePolicyBuilder = new org.apache.tuscany.sca.assembly.builder.impl.CompositePolicyBuilderImpl(assemblyFactory, endpointFactory, interfaceContractMapper); + componentServiceBindingBuilder = new org.apache.tuscany.sca.assembly.builder.impl.ComponentServiceBindingBuilderImpl(); + componentReferenceBindingBuilder = new org.apache.tuscany.sca.assembly.builder.impl.ComponentReferenceBindingBuilderImpl(); + } + + public String getID() { + return "org.apache.tuscany.sca.assembly.builder.CompositeBuilderNonWiring"; + } + + public void build(Composite composite, Definitions definitions, Monitor monitor) throws CompositeBuilderException { + + // Collect and fuse includes + compositeIncludeBuilder.build(composite, definitions, monitor); + + // Expand nested composites + compositeCloneBuilder.build(composite, definitions, monitor); + + // Configure all components + componentConfigurationBuilder.build(composite, definitions, monitor); + + // Connect composite services/references to promoted services/references + compositePromotionBuilder.build(composite, definitions, monitor); + + // Compute the policies across the model hierarchy + compositePolicyBuilder.build(composite, definitions, monitor); + + // Configure composite services + compositeServiceConfigurationBuilder.build(composite, definitions, monitor); + + // Configure composite references + compositeReferenceConfigurationBuilder.build(composite, definitions, monitor); + + // Configure binding URIs + compositeBindingURIBuilder.build(composite, definitions, monitor); + + // Build component service binding-related information + componentServiceBindingBuilder.build(composite, definitions, monitor); + + // Build component reference binding-related information + componentReferenceBindingBuilder.build(composite, definitions, monitor); + + // Fuse nested composites + //FIXME do this later + //cloneBuilder.fuseCompositeImplementations(composite); + } + +} diff --git a/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CustomCompositeBuilder.java b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CustomCompositeBuilder.java new file mode 100644 index 0000000000..5f5fe43d89 --- /dev/null +++ b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/CustomCompositeBuilder.java @@ -0,0 +1,207 @@ +/* + * 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.itest.builder; + +import java.io.File; +import java.net.URI; +import java.net.URL; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.xml.namespace.QName; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLOutputFactory; + +import org.apache.tuscany.sca.assembly.AssemblyFactory; +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.assembly.SCABindingFactory; +import org.apache.tuscany.sca.assembly.builder.CompositeBuilder; +import org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl; +import org.apache.tuscany.sca.assembly.xml.Constants; +import org.apache.tuscany.sca.contribution.Artifact; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.processor.ExtensibleStAXArtifactProcessor; +import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor; +import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessorExtensionPoint; +import org.apache.tuscany.sca.contribution.processor.URLArtifactProcessor; +import org.apache.tuscany.sca.contribution.processor.URLArtifactProcessorExtensionPoint; +import org.apache.tuscany.sca.contribution.resolver.ExtensibleModelResolver; +import org.apache.tuscany.sca.contribution.resolver.ModelResolverExtensionPoint; +import org.apache.tuscany.sca.core.DefaultExtensionPointRegistry; +import org.apache.tuscany.sca.core.ExtensionPointRegistry; +import org.apache.tuscany.sca.core.FactoryExtensionPoint; +import org.apache.tuscany.sca.core.ModuleActivator; +import org.apache.tuscany.sca.core.ModuleActivatorExtensionPoint; +import org.apache.tuscany.sca.core.UtilityExtensionPoint; +import org.apache.tuscany.sca.definitions.Definitions; +import org.apache.tuscany.sca.interfacedef.InterfaceContractMapper; +import org.apache.tuscany.sca.monitor.Monitor; +import org.apache.tuscany.sca.monitor.MonitorFactory; +import org.apache.tuscany.sca.policy.IntentAttachPointTypeFactory; +import org.apache.tuscany.sca.workspace.Workspace; +import org.apache.tuscany.sca.workspace.WorkspaceFactory; +import org.apache.tuscany.sca.workspace.builder.ContributionBuilder; +import org.apache.tuscany.sca.workspace.builder.impl.ContributionDependencyBuilderImpl; + +public class CustomCompositeBuilder { + private URLArtifactProcessor contributionProcessor; + private ModelResolverExtensionPoint modelResolvers; + private FactoryExtensionPoint modelFactories; + private WorkspaceFactory workspaceFactory; + private AssemblyFactory assemblyFactory; + private XMLOutputFactory outputFactory; + private StAXArtifactProcessor xmlProcessor; + private ContributionBuilder contributionDependencyBuilder; + private CompositeBuilder domainCompositeBuilder; + private static Workspace workspace; + private List policyDefinitions; + private Monitor monitor; + private Composite domainComposite; + private boolean nonWiring; + + public CustomCompositeBuilder(boolean nonWiring) { + this.nonWiring = nonWiring; + } + + private void init() { + + // Create extension point registry + ExtensionPointRegistry extensionPoints = new DefaultExtensionPointRegistry(); + + // Create a monitor + UtilityExtensionPoint utilities = extensionPoints.getExtensionPoint(UtilityExtensionPoint.class); + MonitorFactory monitorFactory = utilities.getUtility(MonitorFactory.class); + monitor = monitorFactory.createMonitor(); + + // Initialize the Tuscany module activators + ModuleActivatorExtensionPoint moduleActivators = extensionPoints.getExtensionPoint(ModuleActivatorExtensionPoint.class); + for (ModuleActivator activator : moduleActivators.getModuleActivators()) { + activator.start(extensionPoints); + } + + // Get XML input/output factories + modelFactories = extensionPoints.getExtensionPoint(FactoryExtensionPoint.class); + XMLInputFactory inputFactory = modelFactories.getFactory(XMLInputFactory.class); + outputFactory = modelFactories.getFactory(XMLOutputFactory.class); + + // Get contribution workspace and assembly model factories + workspaceFactory = modelFactories.getFactory(WorkspaceFactory.class); + assemblyFactory = modelFactories.getFactory(AssemblyFactory.class); + + // Create XML artifact processors + StAXArtifactProcessorExtensionPoint xmlProcessorExtensions = extensionPoints.getExtensionPoint(StAXArtifactProcessorExtensionPoint.class); + xmlProcessor = new ExtensibleStAXArtifactProcessor(xmlProcessorExtensions, inputFactory, outputFactory, monitor); + + // Create contribution content processor + URLArtifactProcessorExtensionPoint docProcessorExtensions = extensionPoints.getExtensionPoint(URLArtifactProcessorExtensionPoint.class); + contributionProcessor = docProcessorExtensions.getProcessor(Contribution.class); + + // Get the model resolvers + modelResolvers = extensionPoints.getExtensionPoint(ModelResolverExtensionPoint.class); + + // Create a contribution dependency builder + contributionDependencyBuilder = new ContributionDependencyBuilderImpl(null); + + // Create a composite builder + SCABindingFactory scaBindingFactory = modelFactories.getFactory(SCABindingFactory.class); + IntentAttachPointTypeFactory attachPointTypeFactory = modelFactories.getFactory(IntentAttachPointTypeFactory.class); + InterfaceContractMapper contractMapper = utilities.getUtility(InterfaceContractMapper.class); + if (nonWiring) { + domainCompositeBuilder = new CompositeBuilderNonWiringImpl(assemblyFactory, scaBindingFactory, attachPointTypeFactory, contractMapper); + } else { + domainCompositeBuilder = new CompositeBuilderImpl(assemblyFactory, scaBindingFactory, attachPointTypeFactory, contractMapper); + } + } + + public void loadContribution(String compositeURL, String sourceURI, String sourceURL) throws Exception { + init(); + + // Create workspace model + workspace = workspaceFactory.createWorkspace(); + workspace.setModelResolver(new ExtensibleModelResolver(workspace, modelResolvers, modelFactories)); + + // Read the test contribution + URI artifactURI = URI.create(sourceURI); + URL artifactURL = new File(sourceURL).toURI().toURL(); + URL contributionURL = new File(compositeURL).toURI().toURL(); + Contribution testContribution = contributionProcessor.read(contributionURL, artifactURI, artifactURL); + workspace.getContributions().add(testContribution); + + // Build the contribution dependencies + Set resolved = new HashSet(); + for (Contribution contribution: workspace.getContributions()) { + contributionDependencyBuilder.build(contribution, workspace, monitor); + + // Resolve contributions + for (Contribution dependency: contribution.getDependencies()) { + if (!resolved.contains(dependency)) { + resolved.add(dependency); + contributionProcessor.resolve(dependency, workspace.getModelResolver()); + } + } + } + + // Create a composite model for the domain + domainComposite = assemblyFactory.createComposite(); + domainComposite.setName(new QName(Constants.SCA10_NS, "domain")); + + // Add all deployables to it, normally the domain administrator would select + // the deployables to include + domainComposite.getIncludes().addAll(workspace.getDeployables()); + + // Build the domain composite and wire the components included in it + domainCompositeBuilder.build(domainComposite, null, monitor); + } + + /** + * Returns the delegating model processor. + * @return the delegating model processor + */ + public StAXArtifactProcessor getModelProcessor() { + return xmlProcessor; + } + + /** + * Returns the XML output factory. + * @return the XML output factory + */ + public XMLOutputFactory getOutputFactory() { + return outputFactory; + } + + /** + * Returns the domain composite. + * @return the domain composite model object + */ + public Composite getDomainComposite() { + return domainComposite; + } + + /** + * Returns the monitor. + * @return the monitor instance + */ + public Monitor getMonitor() { + return monitor; + } + +} diff --git a/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/TestUtils.java b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/TestUtils.java new file mode 100644 index 0000000000..9bff4d394e --- /dev/null +++ b/java/sca/contrib/itest/builder/src/test/java/org/apache/tuscany/sca/itest/builder/TestUtils.java @@ -0,0 +1,203 @@ +/* + * 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.itest.builder; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import javax.wsdl.Definition; +import javax.wsdl.Port; +import javax.wsdl.WSDLException; +import javax.wsdl.extensions.soap.SOAPAddress; +import javax.wsdl.extensions.soap12.SOAP12Address; +import javax.wsdl.factory.WSDLFactory; +import javax.wsdl.xml.WSDLWriter; +import javax.xml.namespace.QName; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.stream.XMLStreamWriter; +import junit.framework.TestCase; +import org.apache.tuscany.sca.assembly.Binding; +import org.apache.tuscany.sca.assembly.Component; +import org.apache.tuscany.sca.assembly.ComponentService; +import org.apache.tuscany.sca.assembly.ComponentReference; +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.assembly.Contract; +import org.apache.tuscany.sca.assembly.Implementation; +import org.apache.tuscany.sca.assembly.Reference; +import org.apache.tuscany.sca.assembly.Service; +import org.apache.tuscany.sca.binding.ws.WebServiceBinding; +import org.apache.tuscany.sca.contribution.processor.StAXArtifactProcessor; +import org.apache.tuscany.sca.monitor.Monitor; +import org.apache.tuscany.sca.monitor.Problem; +import org.apache.xml.serialize.OutputFormat; +import org.apache.xml.serialize.XMLSerializer; +import org.w3c.dom.Document; + +/** + * Static utility methods for use by test cases. + * + * @version $Rev$ $Date$ + */ +public class TestUtils { + + protected static void checkProblems(CustomCompositeBuilder customBuilder) throws Exception { + boolean problems = false; + for (Problem problem : customBuilder.getMonitor().getProblems()) { + if (problem.getCause() != null) { + problem.getCause().printStackTrace(); + } + problems = true; + } + assert !problems; + } + + protected static String getPortAddress(Port port) { + Object ext = port.getExtensibilityElements().get(0); + if (ext instanceof SOAPAddress) { + return ((SOAPAddress)ext).getLocationURI(); + } + if (ext instanceof SOAP12Address) { + return ((SOAP12Address)ext).getLocationURI(); + } + return null; + } + + protected static Component getComponent(Composite composite, String name) { + for (Component component : composite.getComponents()) { + if (name.equals(component.getName())) { + return component; + } + // process implementation composites recursively + Implementation impl = component.getImplementation(); + if (impl instanceof Composite) { + Component comp = getComponent((Composite)impl, name); + if (comp != null) { + return comp; + } + } + } + return null; + } + + protected static Composite getComposite(Composite composite, QName name) { + if (name.equals(composite.getName())) { + return composite; + } + for (Component component : composite.getComponents()) { + // process implementation composites recursively + Implementation impl = component.getImplementation(); + if (impl instanceof Composite) { + Composite comp = getComposite((Composite)impl, name); + if (comp != null) { + return comp; + } + } + } + return null; + } + + protected static void printResults(CustomCompositeBuilder customBuilder) throws Exception { + for (Problem problem : customBuilder.getMonitor().getProblems()) { + if (problem.getCause() != null) { + problem.getCause().printStackTrace(); + } + } + Composite domainComposite = customBuilder.getDomainComposite(); + printComposite(domainComposite, customBuilder); + } + + private static void printComposite(Composite composite, CustomCompositeBuilder customBuilder) throws Exception { + // process implementation composites recursively + for (Component component : composite.getComponents()) { + Implementation implementation = component.getImplementation(); + if (implementation instanceof Composite) { + printComposite((Composite)implementation, customBuilder); + } + } + + // write out the SCDL + writeSCDL(composite, customBuilder); + + // find all the component service and reference bindings + for (Component component : composite.getComponents()) { + for (ComponentService componentService : component.getServices()) { + for (Binding binding : componentService.getBindings()) { + if (binding instanceof WebServiceBinding) { + writeWSDL(component, componentService, ((WebServiceBinding)binding).getWSDLDocument()); + } + } + } + for (ComponentReference componentReference : component.getReferences()) { + for (Binding binding : componentReference.getBindings()) { + if (binding instanceof WebServiceBinding) { + writeWSDL(component, componentReference, ((WebServiceBinding)binding).getWSDLDocument()); + } + } + } + } + + // find all the composite service and reference bindings + for (Service service : composite.getServices()) { + for (Binding binding : service.getBindings()) { + if (binding instanceof WebServiceBinding) { + writeWSDL(null, service, ((WebServiceBinding)binding).getWSDLDocument()); + } + } + } + for (Reference reference : composite.getReferences()) { + for (Binding binding : reference.getBindings()) { + if (binding instanceof WebServiceBinding) { + writeWSDL(null, reference, ((WebServiceBinding)binding).getWSDLDocument()); + } + } + } + } + + private static void writeSCDL(Composite composite, CustomCompositeBuilder customBuilder) throws Exception { + // Print out a composite + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + XMLStreamWriter writer = customBuilder.getOutputFactory().createXMLStreamWriter(bos); + customBuilder.getModelProcessor().write(composite, writer); + + // Parse and write again to pretty format it + DocumentBuilder documentBuilder = DocumentBuilderFactory.newInstance().newDocumentBuilder(); + Document document = documentBuilder.parse(new ByteArrayInputStream(bos.toByteArray())); + OutputFormat format = new OutputFormat(); + format.setIndenting(true); + format.setIndent(2); + XMLSerializer serializer = new XMLSerializer(System.out, format); + System.out.println("-->Runtime SCDL model for composite " + composite.getName()); + serializer.serialize(document); + } + + private static void writeWSDL(Component component, Contract contract, Definition definition) { + if (definition == null) { + System.out.println("-->No generated WSDL for " + (component != null ? component.getName() : "") + "/" + contract.getName()); + } else { + try { + System.out.println("-->Generated WSDL for " + (component != null ? component.getName() : "") + "/" + contract.getName()); + WSDLWriter writer = WSDLFactory.newInstance().newWSDLWriter(); + writer.writeWSDL(definition, System.out); + } catch (WSDLException e) { + // ignore + } + } + } + +} diff --git a/java/sca/contrib/itest/callablereferences-ws/pom.xml b/java/sca/contrib/itest/callablereferences-ws/pom.xml new file mode 100644 index 0000000000..a231c4d741 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/pom.xml @@ -0,0 +1,59 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-callablereferences-ws + Apache Tuscany Test for Callable References over Web Services + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClient.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClient.java new file mode 100644 index 0000000000..ecf1ac27e1 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClient.java @@ -0,0 +1,26 @@ +/* + * 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 com.example; + +public interface ExampleClient { + + void runTest(); + + void sayHello(String name); +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClientImpl.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClientImpl.java new file mode 100644 index 0000000000..9a486b3be0 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleClientImpl.java @@ -0,0 +1,59 @@ +/* + * 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 com.example; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(ExampleClient.class) +@Scope("COMPOSITE") +public class ExampleClientImpl implements ExampleClient { + + private ExampleService myService; + + @Context + protected ComponentContext context; + + @Reference + public void setMyService(ExampleService myService) { + this.myService = myService; + } + + public void runTest() { + ServiceReference ref = context.createSelfReference(ExampleClient.class); + ref.getService().sayHello("Jack"); + CallableReference result = myService.hello("Jill", ref); + if (result != null) { + ((CallableReference)result).getService().sayHello("John"); + } + result = myService.hello("Jane", null); + if (result != null) { + ((CallableReference)result).getService().sayHello("Jim"); + } + } + + public void sayHello(String name) { + System.out.println("Hello, client " + name + "!"); + } +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleService.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleService.java new file mode 100644 index 0000000000..9264def0dc --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleService.java @@ -0,0 +1,30 @@ +/* + * 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 com.example; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface ExampleService { + + CallableReference hello(String name, ServiceReference ref); + +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleServiceImpl.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleServiceImpl.java new file mode 100644 index 0000000000..22aecc8b27 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/com/example/ExampleServiceImpl.java @@ -0,0 +1,33 @@ +/* + * 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 com.example; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ServiceReference; + +public class ExampleServiceImpl implements ExampleService { + + public CallableReference hello(String name, ServiceReference ref) { + if (ref != null) { + ((ServiceReference)ref).getService().sayHello(name); + } + return (CallableReference)ref; + } + +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Alpha.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Alpha.java new file mode 100644 index 0000000000..6ecf3d662e --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Alpha.java @@ -0,0 +1,26 @@ +/* + * 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.itest.callablerefwsreturn; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface Alpha { + boolean run(); +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/AlphaImpl.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/AlphaImpl.java new file mode 100644 index 0000000000..64a11f0bf3 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/AlphaImpl.java @@ -0,0 +1,96 @@ +/* + * 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.itest.callablerefwsreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.Conversation; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(Alpha.class) +@Scope("COMPOSITE") +public class AlphaImpl implements Alpha { + @Reference + public Beta beta; + + @Context + protected ComponentContext componentContext; + + Object conversationId0 = null; + + public boolean run() { + CallableReference gammaRef = null; + try { + Object conversationId1 = null; + Object conversationId2 = null; + + // it is expected that this call returns a reference to Gamma that + // reuses the established Conversation + gammaRef = beta.getRef(); + + // no Conversation exists + Conversation con = gammaRef.getConversation(); + if (con == null) { + System.out.println("Alpha1: Conversation to gamma is null"); + } else { + System.out + .println("Alpha1: Conversation to gamma exists. conversationId=" + + con.getConversationID()); + conversationId1 = con.getConversationID(); + } + + // this call should reuse a Conversation, but as none exists it + // creates a new conversation + gammaRef.getService().doSomething(); + gammaRef.getService().doSomething(); + gammaRef.getService().doSomething(); + + con = gammaRef.getConversation(); + if (con == null) { + System.out.println("Alpha2: Conversation to gamma is null"); + } else { + System.out + .println("Alpha2: Conversation to gamma exists. conversationId=" + + con.getConversationID()); + conversationId2 = con.getConversationID(); + } + + boolean testPassed = conversationId1.equals(conversationId2); + + if (conversationId0 == null){ + conversationId0 = conversationId1; + return testPassed; + } else { + return testPassed && (!conversationId0.equals(conversationId1)); + } + + } catch (Exception e) { + e.printStackTrace(); + return false; + } finally { + if (gammaRef != null) { + gammaRef.getService().stop(); + } + } + } + +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Beta.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Beta.java new file mode 100644 index 0000000000..9861b0a85e --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Beta.java @@ -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 org.apache.tuscany.sca.itest.callablerefwsreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface Beta { + CallableReference getRef(); +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/BetaImpl.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/BetaImpl.java new file mode 100644 index 0000000000..c870cd87fe --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/BetaImpl.java @@ -0,0 +1,46 @@ +/* + * 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.itest.callablerefwsreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(Beta.class) +@Scope("COMPOSITE") +public class BetaImpl implements Beta { + @Context + protected ComponentContext componentContext; + + @Reference + public Gamma gamma; + + public CallableReference getRef() { + ServiceReference gammaRef = componentContext + .getServiceReference(Gamma.class, "gamma"); + Gamma g = gammaRef.getService(); + g.start(); + return gammaRef; + } + +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Gamma.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Gamma.java new file mode 100644 index 0000000000..ee9d0f0b26 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/Gamma.java @@ -0,0 +1,34 @@ +/* + * 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.itest.callablerefwsreturn; + +import org.oasisopen.sca.annotation.Conversational; +import org.oasisopen.sca.annotation.EndsConversation; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +@Conversational +public interface Gamma { + int start(); + + void doSomething(); + + @EndsConversation + void stop(); +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/GammaImpl.java b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/GammaImpl.java new file mode 100644 index 0000000000..9a4f31d79d --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/java/org/apache/tuscany/sca/itest/callablerefwsreturn/GammaImpl.java @@ -0,0 +1,49 @@ +/* + * 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.itest.callablerefwsreturn; + +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(Gamma.class) +@Scope("CONVERSATION") +public class GammaImpl implements Gamma { + @ConversationID + protected String conversationId; + + public GammaImpl() { + System.out.println("GammaImpl:GammaImpl(), conversationId=" + + conversationId); + } + + public int start() { + System.out.println("Gamma:start(), conversationId=" + conversationId); + return 1; + } + + public void doSomething() { + System.out.println("Gamma:doSomething(), conversationId=" + + conversationId); + } + + public void stop() { + System.out.println("Gamma:stop(), conversationId=" + conversationId); + } +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/resources/CallableReferenceWsReturnTest.composite b/java/sca/contrib/itest/callablereferences-ws/src/main/resources/CallableReferenceWsReturnTest.composite new file mode 100644 index 0000000000..3d782a0b84 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/resources/CallableReferenceWsReturnTest.composite @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/callablereferences-ws/src/main/resources/example.composite b/java/sca/contrib/itest/callablereferences-ws/src/main/resources/example.composite new file mode 100644 index 0000000000..ea0819a32e --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/main/resources/example.composite @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/callablereferences-ws/src/test/java/com/example/ExampleTestCase.java b/java/sca/contrib/itest/callablereferences-ws/src/test/java/com/example/ExampleTestCase.java new file mode 100644 index 0000000000..310e31fb02 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/test/java/com/example/ExampleTestCase.java @@ -0,0 +1,44 @@ +/* + * 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 com.example; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +public class ExampleTestCase extends TestCase { + + private SCADomain scaDomain; + private ExampleClient client; + + @Override + protected void setUp() throws Exception { + scaDomain = SCADomain.newInstance("example.composite"); + client = scaDomain.getService(ExampleClient.class, "ExampleClientComponent"); + } + + @Override + protected void tearDown() throws Exception { + scaDomain.close(); + } + + public void test() throws Exception { + client.runTest(); + } +} diff --git a/java/sca/contrib/itest/callablereferences-ws/src/test/java/org/apache/tuscany/sca/itest/callablerefws/CallableReferenceReturnTestCase.java b/java/sca/contrib/itest/callablereferences-ws/src/test/java/org/apache/tuscany/sca/itest/callablerefws/CallableReferenceReturnTestCase.java new file mode 100644 index 0000000000..66fb2ef96c --- /dev/null +++ b/java/sca/contrib/itest/callablereferences-ws/src/test/java/org/apache/tuscany/sca/itest/callablerefws/CallableReferenceReturnTestCase.java @@ -0,0 +1,49 @@ +/* + * 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.itest.callablerefws; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.itest.callablerefwsreturn.Alpha; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.BeforeClass; +import org.junit.Test; + +public class CallableReferenceReturnTestCase { + private static SCADomain domain; + private static Alpha alpha; + + @BeforeClass + public static void init() throws Exception { + domain = SCADomain.newInstance("CallableReferenceWsReturnTest.composite"); + alpha = domain.getService(Alpha.class, "Alpha"); + } + + @AfterClass + public static void destroy() throws Exception { + domain.close(); + } + + @Test + public void testCallableReferenceReturn() { + Assert.assertTrue(alpha.run()); + Assert.assertTrue(alpha.run()); + } + +} diff --git a/java/sca/contrib/itest/callablereferences/pom.xml b/java/sca/contrib/itest/callablereferences/pom.xml new file mode 100644 index 0000000000..ae12f41535 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/pom.xml @@ -0,0 +1,81 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-callablereferences + Apache Tuscany SCA Callable References Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-node-impl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + test + + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-binding-sca-axis2 + 2.0-SNAPSHOT + test + + + diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponent.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponent.java new file mode 100644 index 0000000000..33783be887 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponent.java @@ -0,0 +1,39 @@ +/* + * 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.itest.callableref; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface AComponent { + String foo(); + + String fooB(); + String fooB1(); + + String fooC(); + String fooC1(); + + String fooStringD(); + String fooD(); + + String fooBC(); + + String invokeDReference(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponentImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponentImpl.java new file mode 100644 index 0000000000..f99051cd5f --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/AComponentImpl.java @@ -0,0 +1,114 @@ +/* + * 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.itest.callableref; + +import java.io.ByteArrayOutputStream; +import java.io.ObjectOutputStream; + +import org.apache.tuscany.sca.databinding.impl.XSDDataTypeConverter.Base64Binary; +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +@Service(AComponent.class) +public class AComponentImpl implements AComponent { + + @Context + protected ComponentContext componentContext; + + @Reference(name = "bReference") + protected BComponent b; + + @Reference + protected CComponent cReference; + + @Reference + protected ServiceReference cServiceReference; + + @Reference(required=false) + protected DComponent dReference; + + protected DComponent dReference1; + + @Reference(name = "dReference1") + public void setDReference(DComponent dReference) { + this.dReference1 = dReference; + } + + public String foo() { + return "AComponent"; + } + + public String fooB() { + return b.foo(); + } + + public String fooB1() { + CallableReference bRef = componentContext.cast(b); + return bRef.getService().foo(); + } + + public String fooC() { + return cReference.foo(); + } + + public String fooC1() { + return cServiceReference.getService().foo(); + } + + public String fooBC() { + CallableReference cReference = componentContext.getServiceReference(CComponent.class, "cReference"); + return b.fooC(cReference); + } + + public String fooD() { + CallableReference aReference = componentContext.createSelfReference(AComponent.class); + return dReference1.foo(aReference); + } + + /** + * A test case to work out what needs to be done in a transformer to get the + * CallableReference across the wire. Left here for interest in case anyone + * is looking for how to get at the innards of CallableReferences + */ + public String fooStringD() { + CallableReference aReference = componentContext.createSelfReference(AComponent.class); + ByteArrayOutputStream bos = null; + + try { + bos = new ByteArrayOutputStream(); + ObjectOutputStream oos = new ObjectOutputStream(bos); + oos.writeObject(aReference); + } catch (Exception ex) { + System.out.println(ex.toString()); + return null; + } + + String aReferenceString = Base64Binary.encode(bos.toByteArray()); + return dReference1.fooString(aReferenceString); + } + + public String invokeDReference() { + return dReference.foo(null); + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponent.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponent.java new file mode 100644 index 0000000000..1cf3029d82 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponent.java @@ -0,0 +1,30 @@ +/* + * 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.itest.callableref; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface BComponent { + + String foo(); + + String fooC(CallableReference cComponent); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponentImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponentImpl.java new file mode 100644 index 0000000000..084572b6e5 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/BComponentImpl.java @@ -0,0 +1,38 @@ +/* + * 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.itest.callableref; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Service; + +@Service(BComponent.class) +public class BComponentImpl implements BComponent { + + public BComponentImpl() { + } + + public String foo() { + return "BComponent"; + } + + public String fooC(CallableReference cReference) { + return "B" + cReference.getService().foo(); + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponent.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponent.java new file mode 100644 index 0000000000..059f42c4d3 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponent.java @@ -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 org.apache.tuscany.sca.itest.callableref; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface CComponent { + + String foo(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponentImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponentImpl.java new file mode 100644 index 0000000000..76fdd61191 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/CComponentImpl.java @@ -0,0 +1,30 @@ +/* + * 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.itest.callableref; + +import org.oasisopen.sca.annotation.Service; + +@Service(CComponent.class) +public class CComponentImpl implements CComponent { + + public String foo() { + return "CComponent"; + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponent.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponent.java new file mode 100644 index 0000000000..8b2988b700 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponent.java @@ -0,0 +1,30 @@ +/* + * 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.itest.callableref; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface DComponent { + + String foo(CallableReference aReference); + + String fooString(String aReferenceString); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponentImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponentImpl.java new file mode 100644 index 0000000000..a43b3818c5 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callableref/DComponentImpl.java @@ -0,0 +1,65 @@ +/* + * 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.itest.callableref; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; + +import org.apache.tuscany.sca.databinding.impl.XSDDataTypeConverter.Base64Binary; +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.RequestContext; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Service; + +@Service(DComponent.class) +public class DComponentImpl implements DComponent { + + @Context + protected RequestContext requestContext; + + public String foo(CallableReference aReference) { + try { + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + ObjectOutputStream oos = new ObjectOutputStream(bos); + oos.writeObject(aReference); + ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(bos.toByteArray())); + Object obj = ois.readObject(); + aReference = (CallableReference) obj; + } catch (Exception e) { + e.printStackTrace(); + } + System.out.println("Invoking service: " + requestContext.getServiceName()); + return "D" + aReference.getService().foo(); + } + + public String fooString(String aReferenceString) { + CallableReference aReference = null; + try { + ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(Base64Binary.decode(aReferenceString))); + Object obj = ois.readObject(); + aReference = (CallableReference) obj; + } catch (Exception e) { + e.printStackTrace(); + } + System.out.println("Invoking service: " + requestContext.getServiceName()); + return "D" + aReference.getService().foo(); + } +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalService.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalService.java new file mode 100644 index 0000000000..33bc49e4d8 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalService.java @@ -0,0 +1,68 @@ +/* + * 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.itest.callablerefconversational; + +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Conversational; + +/** + * Simple conversational Service that is used to testing the method + * ComponentContext.createSelfReference() + * + * @version $Date$ $Revision$ + */ +@Conversational +public interface ConversationalService { + /** + * Default value for the user data + */ + String DEFAULT_USER_DATA = "NOT SET"; + + /** + * Retrieves the conversation ID for this Service + * + * @return The conversation ID for this Service + */ + Object getConversationID(); + + /** + * Creates a self reference to this Service + * + * @return A self reference to this Service + */ + ServiceReference createSelfRef(); + + /** + * Sets some user data on the instance + * + * @param a_Data Some data + * + * @See {@link #getUserData()} + */ + void setUserData(String a_Data); + + /** + * Gets some user data on the instance + * + * @return Some data + * + * @See {@link #setUserData(String)} + */ + String getUserData(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalServiceImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalServiceImpl.java new file mode 100644 index 0000000000..36bafba562 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefconversational/ConversationalServiceImpl.java @@ -0,0 +1,111 @@ +/* + * 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.itest.callablerefconversational; + +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +/** + * Simple conversational Service that is used to testing the method + * ComponentContext.createSelfReference() + * + * @version $Date$ $Revision$ + */ +@Service(ConversationalService.class) +@Scope("CONVERSATION") +public class ConversationalServiceImpl implements ConversationalService { + + /** + * The Conversation ID + */ + private Object m_ConversationID; + + /** + * Reference to the ComponentContext. + */ + @Context + protected ComponentContext m_Ctx; + + /** + * Some user data + */ + private String m_UserData = DEFAULT_USER_DATA; + + /** + * Constructor + */ + public ConversationalServiceImpl() { + System.out.println("New instance of " + this + " created"); + } + + /** + * Used to inject the Conversation ID + * + * @param a_ConversationID the Conversation ID + */ + @ConversationID + public void setConversationID(Object a_ConversationID) { + m_ConversationID = a_ConversationID; + System.out.println("Converstation ID set on " + this + " to " + a_ConversationID); + } + + /** + * Retrieves the conversation ID for this Service + * + * @return The conversation ID for this Service + */ + public Object getConversationID() { + return m_ConversationID; + } + + /** + * Creates a self reference to this Service + * + * @return A self reference to this Service + */ + public ServiceReference createSelfRef() { + return m_Ctx.createSelfReference(ConversationalService.class); + } + + /** + * Sets some user data on the instance + * + * @param a_Data Some data + * + * @See {@link #getUserData()} + */ + public void setUserData(String a_Data) { + m_UserData = a_Data; + } + + /** + * Gets some user data on the instance + * + * @return Some data + * + * @See {@link #setUserData(String)} + */ + public String getUserData() { + return m_UserData; + } +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Alpha.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Alpha.java new file mode 100644 index 0000000000..bf5a2e65cc --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Alpha.java @@ -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 org.apache.tuscany.sca.itest.callablerefreturn; + +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface Alpha +{ + boolean run(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/AlphaImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/AlphaImpl.java new file mode 100644 index 0000000000..59fed12279 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/AlphaImpl.java @@ -0,0 +1,86 @@ +/* + * 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.itest.callablerefreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.Conversation; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; + +@Scope("COMPOSITE") +public class AlphaImpl implements Alpha { + @Reference + public Beta beta; + + @Context + protected ComponentContext componentContext; + + public boolean run() { + CallableReference gammaRef = null; + try { + Object conversationId1 = null; + Object conversationId2 = null; + + // it is expected that this call returns a reference to Gamma that + // reuses the established Conversation + gammaRef = beta.getRef(); + + // no Conversation exists + Conversation con = gammaRef.getConversation(); + if (con == null) { + System.out.println("Alpha: Conversation to gamma is null"); + } else { + System.out + .println("Alpha: Conversation to gamma exists. conversationId=" + + con.getConversationID()); + conversationId1 = con.getConversationID(); + } + + // this call should reuse a Conversation, but as none exists it + // creates a new conversation + gammaRef.getService().doSomething(); + con = gammaRef.getConversation(); + if (con == null) { + System.out.println("Alpha: Conversation to gamma is null"); + } else { + System.out + .println("Alpha: Conversation to gamma exists. conversationId=" + + con.getConversationID()); + conversationId2 = con.getConversationID(); + } + + if ((conversationId1 == null) || (conversationId2 == null)) { + return false; + } + + boolean testPassed = conversationId1.equals(conversationId2); + return testPassed; + } catch (Exception e) { + e.printStackTrace(); + return false; + } finally { + if (gammaRef != null) { + gammaRef.getService().stop(); + } + } + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Beta.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Beta.java new file mode 100644 index 0000000000..b8dd1c5640 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Beta.java @@ -0,0 +1,28 @@ +/* + * 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.itest.callablerefreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +public interface Beta +{ + CallableReference getRef(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/BetaImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/BetaImpl.java new file mode 100644 index 0000000000..8425425c16 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/BetaImpl.java @@ -0,0 +1,44 @@ +/* + * 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.itest.callablerefreturn; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; + +@Scope("COMPOSITE") +public class BetaImpl implements Beta +{ + @Context + protected ComponentContext componentContext; + + @Reference + public Gamma gamma; + + public CallableReference getRef() + { + ServiceReference gammaRef = componentContext.getServiceReference(Gamma.class, "gamma"); + gammaRef.getService().start(); + return gammaRef; + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Gamma.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Gamma.java new file mode 100644 index 0000000000..445fb7bf7f --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/Gamma.java @@ -0,0 +1,35 @@ +/* + * 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.itest.callablerefreturn; + +import org.oasisopen.sca.annotation.Conversational; +import org.oasisopen.sca.annotation.EndsConversation; +import org.oasisopen.sca.annotation.Remotable; + +@Remotable +@Conversational +public interface Gamma +{ + void start(); + + void doSomething(); + + @EndsConversation + void stop(); +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/GammaImpl.java b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/GammaImpl.java new file mode 100644 index 0000000000..0670629bae --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/java/org/apache/tuscany/sca/itest/callablerefreturn/GammaImpl.java @@ -0,0 +1,47 @@ +/* + * 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.itest.callablerefreturn; + +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Scope; + +@Scope("CONVERSATION") +public class GammaImpl implements Gamma +{ + @ConversationID + protected String conversationId; + + + public void start() + { + System.out.println("Gamma:start(), conversationId=" + conversationId); + } + + + public void doSomething() + { + System.out.println("Gamma:doSomething(), conversationId=" + conversationId); + } + + + public void stop() + { + System.out.println("Gamma:stop(), conversationId=" + conversationId); + } +} diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceConversationalTest.composite b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceConversationalTest.composite new file mode 100644 index 0000000000..0bf8f7ef1e --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceConversationalTest.composite @@ -0,0 +1,29 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceReturnTest.composite b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceReturnTest.composite new file mode 100644 index 0000000000..5b3add1e61 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceReturnTest.composite @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceTest.composite b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceTest.composite new file mode 100644 index 0000000000..49b75f56e4 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/CallableReferenceTest.composite @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/CompositeA.composite b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/CompositeA.composite new file mode 100644 index 0000000000..9216f44191 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/CompositeA.composite @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/META-INF/sca-contribution.xml b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..95021f72a4 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeA/META-INF/sca-contribution.xml @@ -0,0 +1,22 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/CompositeB.composite b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/CompositeB.composite new file mode 100644 index 0000000000..42d739564c --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/CompositeB.composite @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/META-INF/sca-contribution.xml b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..2edda61601 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/main/resources/nodeB/META-INF/sca-contribution.xml @@ -0,0 +1,22 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceConversationalTestCase.java b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceConversationalTestCase.java new file mode 100644 index 0000000000..fb3a5d79b9 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceConversationalTestCase.java @@ -0,0 +1,109 @@ +/* + * 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.itest.callableref; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.itest.callablerefconversational.ConversationalService; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; +import org.oasisopen.sca.ServiceReference; + +/** + * Simple test case that creates a ServiceReference to a Conversational Component + * using ComponentContext.createSelfReference() + *

+ * This test case is for TUSCANY-2208 + * + * @version $Date$ $Revision$ + */ +public class CallableReferenceConversationalTestCase { + private static SCADomain domain; + private static ConversationalService acomponent; + + @BeforeClass + public static void init() throws Exception { + domain = SCADomain.newInstance("CallableReferenceConversationalTest.composite"); + Assert.assertNotNull(domain); + acomponent = domain.getService(ConversationalService.class, "ConversationalComponent"); + } + + @AfterClass + public static void destroy() throws Exception { + if (domain != null) { + domain.close(); + } + } + + /** + * This is a dummy test so that this Unit Test has a test so it will build. + * Once TUSCANY-2208 is fixed, this dummy test method can be removed + */ + @Test + public void dummyTestRemoveWhenTuscany2208IsFixed() { + } + + /** + * Tests creating Self References and validate them with Conversation IDs + */ + // Disabled until TUSCANY-2208 is fixed + // @Test + public void testCreateSelfRefUsingConvID() { + Assert.assertNotNull(acomponent); + + final Object origConvID = acomponent.getConversationID(); + Assert.assertNotNull(origConvID); + final ServiceReference ref = acomponent.createSelfRef(); + Assert.assertNotNull(ref); + + final ConversationalService resolvedRef = ref.getService(); + Assert.assertNotNull(resolvedRef); + final Object newConvID = resolvedRef.getConversationID(); + Assert.assertNotNull(newConvID); + + Assert.assertEquals(origConvID, newConvID); + } + + /** + * Tests creating Self References and validate them with user specified data + */ + // Disabled until TUSCANY-2208 is fixed + // @Test + public void testCreateSelfRefUsingUserData() { + Assert.assertNotNull(acomponent); + + final String origUserData = acomponent.getUserData(); + Assert.assertEquals(ConversationalService.DEFAULT_USER_DATA, origUserData); + + final String userData = "Some new user data set at " + System.currentTimeMillis(); + acomponent.setUserData(userData); + + final ServiceReference ref = acomponent.createSelfRef(); + Assert.assertNotNull(ref); + + final ConversationalService resolvedRef = ref.getService(); + Assert.assertNotNull(resolvedRef); + final String newUserData = resolvedRef.getUserData(); + Assert.assertNotNull(newUserData); + + Assert.assertEquals(userData, newUserData); + } +} diff --git a/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java new file mode 100644 index 0000000000..927e91a8bc --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceRemoteTestCase.java @@ -0,0 +1,145 @@ +/* + * 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.itest.callableref; + + +import static junit.framework.Assert.assertEquals; + +import java.io.File; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + + +/** + * Runs a distributed domain in a single VM by using and in memory + * implementation of the distributed domain + */ +public class CallableReferenceRemoteTestCase { + + private static Node nodeA; + private static Node nodeB; + + private static AComponent acomponent; + + @BeforeClass + public static void init() throws Exception { + + try { + + System.out.println("Setting up nodes"); + + NodeFactory nodeFactory = NodeFactory.newInstance(); + nodeA = nodeFactory.createNode(new File("src/main/resources/nodeA/CompositeA.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/nodeA").toURL().toString())); + + + nodeB = nodeFactory.createNode(new File("src/main/resources/nodeB/CompositeB.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/nodeB").toURL().toString())); + + + nodeA.start(); + nodeB.start(); + + acomponent = ((Client)nodeA).getService(AComponent.class, "AComponent/AComponent"); + + } catch (Throwable ex) { + System.out.println(ex.toString()); + // Print detailed cause information. + ex.printStackTrace(); + StringBuffer sb = new StringBuffer(); + Throwable cause = ex.getCause(); + while ( cause != null ) { + sb.append( " " ); + System.out.println( sb.toString() + "Cause: " + cause ); + if (cause instanceof java.lang.reflect.InvocationTargetException) + System.out.println( sb.toString() + "Target Exception: " + ((java.lang.reflect.InvocationTargetException)cause).getTargetException() ); + cause = cause.getCause(); + } + } + } + + @AfterClass + public static void destroy() throws Exception { + // stop the nodes and hence the domains they contain + nodeA.stop(); + nodeB.stop(); + } + + //@Test + public void testKeepServerRunning1() throws Exception { + System.out.println("press enter to continue"); + System.in.read(); + } + + @Test + public void testBReference() { + assertEquals("BComponent", acomponent.fooB()); + } + + @Test + public void testBCast() { + assertEquals("BComponent", acomponent.fooB1()); + } + + @Test + public void testCReference() { + assertEquals("CComponent", acomponent.fooC()); + } + + @Test + public void testCServiceReference() { + assertEquals("CComponent", acomponent.fooC1()); + } + + @Test + public void testDReferenceString() { + assertEquals("DAComponent", acomponent.fooStringD()); + } + + @Test + public void testDReference() { + assertEquals("DAComponent", acomponent.fooD()); + } + + + @Test + public void testBCReference() { + assertEquals("BCComponent", acomponent.fooBC()); + } + + @Test + public void testRequiredFalseReference() { + try { + acomponent.invokeDReference(); + } catch (Exception e) { + Assert.assertTrue(true); + } + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceReturnTestCase.java b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceReturnTestCase.java new file mode 100644 index 0000000000..f2d8fe5d64 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceReturnTestCase.java @@ -0,0 +1,48 @@ +/* + * 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.itest.callableref; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.itest.callablerefreturn.Alpha; +import org.junit.AfterClass; +import org.junit.Assert; +import org.junit.BeforeClass; +import org.junit.Test; + +public class CallableReferenceReturnTestCase { + private static SCADomain domain; + private static Alpha alpha; + + @BeforeClass + public static void init() throws Exception { + domain = SCADomain.newInstance("CallableReferenceReturnTest.composite"); + alpha = domain.getService(Alpha.class, "Alpha"); + } + + @AfterClass + public static void destroy() throws Exception { + domain.close(); + } + + @Test + public void testCallableReferenceReturn() { + Assert.assertTrue(alpha.run()); + } + +} diff --git a/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceTestCase.java b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceTestCase.java new file mode 100644 index 0000000000..d785a6a397 --- /dev/null +++ b/java/sca/contrib/itest/callablereferences/src/test/java/org/apache/tuscany/sca/itest/callableref/CallableReferenceTestCase.java @@ -0,0 +1,83 @@ +/* + * 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.itest.callableref; + +import static junit.framework.Assert.assertEquals; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class CallableReferenceTestCase { + private static SCADomain domain; + private static AComponent acomponent; + + @BeforeClass + public static void init() throws Exception { + domain = SCADomain.newInstance("CallableReferenceTest.composite"); + acomponent = domain.getService(AComponent.class, "AComponent"); + } + + @AfterClass + public static void destroy() throws Exception { + domain.close(); + } + + @Test + public void testBReference() { + assertEquals("BComponent", acomponent.fooB()); + } + + @Test + public void testBCast() { + assertEquals("BComponent", acomponent.fooB1()); + } + + @Test + public void testCReference() { + assertEquals("CComponent", acomponent.fooC()); + } + + @Test + public void testCServiceReference() { + assertEquals("CComponent", acomponent.fooC1()); + } + + @Test + public void testDReference() { + assertEquals("DAComponent", acomponent.fooD()); + } + + @Test + public void testBCReference() { + assertEquals("BCComponent", acomponent.fooBC()); + } + + @Test + public void testRequiredFalseReference() { + try { + acomponent.invokeDReference(); + } catch (Exception e) { + Assert.assertTrue(true); + } + } + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/build-jar.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/build-jar.xml new file mode 100644 index 0000000000..299ce6864f --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/build-jar.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/pom.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/pom.xml new file mode 100644 index 0000000000..55076f0f5e --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/pom.xml @@ -0,0 +1,203 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-classloader-classes + Apache Tuscany Contribution ClassLoader Test : Contribution Classes + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + + + itest-contribution-classloader-classes + + + org.apache.maven.plugins + maven-antrun-plugin + 1.1 + + + + ant + ant-trax + 1.6.5 + + + + + + create-jar + generate-test-sources + + run + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/Customer.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/Customer.java new file mode 100644 index 0000000000..8cadb2420e --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/Customer.java @@ -0,0 +1,35 @@ +/* + * 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 supplychain.customer; + +import org.oasisopen.sca.annotation.OneWay; + +/** + * This is the business interface of the Customer service component. + */ +public interface Customer { + + public void purchaseGoods(); + + @OneWay + public void notifyShipment(String order); + + public int outstandingOrderCount(); + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java new file mode 100644 index 0000000000..6a4bb82953 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/customer/JavaCustomerComponentImpl.java @@ -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 supplychain.customer; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +import supplychain.retailer.Retailer; + +/** + * This class implements the Customer service component (POJO implementation). + */ +@Service(Customer.class) +@Scope("COMPOSITE") +public class JavaCustomerComponentImpl implements Customer { + + private static int outstandingOrderCount; + + private Retailer retailer; + + public JavaCustomerComponentImpl() { + System.out.println("Created " + this.getClass().getName() + + " using: " + this.getClass().getClassLoader()); + } + + @Reference + public void setRetailer(Retailer retailer) { + this.retailer = retailer; + } + + public void purchaseGoods() { + outstandingOrderCount++; + retailer.submitOrder("Order"); + } + + public void notifyShipment(String order) { + outstandingOrderCount--; + System.out.print("Work thread " + Thread.currentThread() + " - "); + System.out.println(order); + } + + public int outstandingOrderCount() { + return outstandingOrderCount; + } + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/illegal/JavaCustomerComponentImpl.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/illegal/JavaCustomerComponentImpl.java new file mode 100644 index 0000000000..3c88ac9272 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/illegal/JavaCustomerComponentImpl.java @@ -0,0 +1,74 @@ +/* + * 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 supplychain.illegal; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +import supplychain.customer.Customer; +import supplychain.retailer.JavaRetailerComponentImpl; +import supplychain.retailer.Retailer; +import supplychain.warehouse.JavaWarehouseComponentImpl; +import supplychain.warehouse.Warehouse; + +/** + * This class implements the Customer service component (POJO implementation). + */ +@Service(Customer.class) +@Scope("COMPOSITE") +public class JavaCustomerComponentImpl implements Customer { + + private static int outstandingOrderCount; + + private Retailer retailer; + + public JavaCustomerComponentImpl() { + System.out.println("Created " + this.getClass().getName() + + " using: " + this.getClass().getClassLoader()); + } + + @Reference + public void setRetailer(Retailer retailer) { + this.retailer = retailer; + } + + public void purchaseGoods() { + + Retailer retailerImpl = new JavaRetailerComponentImpl(); + System.out.println("Created a retailer from Customer " + retailerImpl); + + Warehouse warehouseImpl = new JavaWarehouseComponentImpl(); + System.out.println("Created a warehouse from Customer " + warehouseImpl); + + outstandingOrderCount++; + retailer.submitOrder("Order"); + } + + public void notifyShipment(String order) { + outstandingOrderCount--; + System.out.print("Work thread " + Thread.currentThread() + " - "); + System.out.println(order); + } + + public int outstandingOrderCount() { + return outstandingOrderCount; + } + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java new file mode 100644 index 0000000000..e8342ee7b9 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/JavaRetailerComponentImpl.java @@ -0,0 +1,61 @@ +/* + * 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 supplychain.retailer; + + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +import supplychain.warehouse.Warehouse; + +/** + * This class implements the Retailer service component (POJO implementation). + */ +@Service(Retailer.class) +@Scope("STATELESS") +public class JavaRetailerComponentImpl implements Retailer { + + private Warehouse warehouse; + + public JavaRetailerComponentImpl() { + System.out.println("Created " + this.getClass().getName() + + " using: " + this.getClass().getClassLoader()); + } + + @Reference + public void setWarehouse(Warehouse warehouse) { + this.warehouse = warehouse; + } + + + public Warehouse getWarehouse() { + return warehouse; + } + + public void submitOrder(String order) { + + warehouse.fulfillOrder(order + ", submitted"); + + } + + + + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/Retailer.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/Retailer.java new file mode 100644 index 0000000000..1e87d59af1 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/retailer/Retailer.java @@ -0,0 +1,28 @@ +/* + * 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 supplychain.retailer; + +/** + * This is the business interface of the Retailer service component. + */ +public interface Retailer { + + public void submitOrder(String order); + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java new file mode 100644 index 0000000000..cf016617a6 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/JavaShipperComponentImpl.java @@ -0,0 +1,52 @@ +/* + * 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 supplychain.shipper; + + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +import supplychain.customer.Customer; + +/** + * This class implements the Shipper service component (POJO implementation). + */ +@Service(Shipper.class) +@Scope("COMPOSITE") +public class JavaShipperComponentImpl implements Shipper { + + private Customer customer; + + public JavaShipperComponentImpl() { + System.out.println("Created " + this.getClass().getCanonicalName() + + " using: " + this.getClass().getClassLoader()); + } + + @Reference + public void setCustomer(Customer customer) { + this.customer = customer; + } + + public void processShipment(String order) { + customer.notifyShipment(order + ", shipped"); + } + + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/Shipper.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/Shipper.java new file mode 100644 index 0000000000..2514928c10 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/shipper/Shipper.java @@ -0,0 +1,28 @@ +/* + * 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 supplychain.shipper; + +/** + * This is the business interface of the Shipper service component. + */ +public interface Shipper { + + public void processShipment(String order); + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java new file mode 100644 index 0000000000..e81a11e55a --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/JavaWarehouseComponentImpl.java @@ -0,0 +1,47 @@ +/* + * 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 supplychain.warehouse; + +import org.oasisopen.sca.annotation.Scope; + +import supplychain.shipper.Shipper; + +/** + * This class implements the Warehouse service component (POJO implementation). + */ +@Scope("STATELESS") +public class JavaWarehouseComponentImpl implements Warehouse { + + private Shipper shipper; + + public JavaWarehouseComponentImpl() { + System.out.println("Created " + this.getClass().getCanonicalName() + + " using: " + this.getClass().getClassLoader()); + } + + public void setShipper(Shipper shipper) { + this.shipper = shipper; + } + + public void fulfillOrder(String order) { + shipper.processShipment(order + ", fulfilled"); + } + + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java new file mode 100644 index 0000000000..6f1f6b8730 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/java/supplychain/warehouse/Warehouse.java @@ -0,0 +1,28 @@ +/* + * 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 supplychain.warehouse; + +/** + * This is the business interface of the Warehouse service component. + */ +public interface Warehouse { + + public void fulfillOrder(String order); + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/complete-supplychain-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/complete-supplychain-sca-contribution.xml new file mode 100644 index 0000000000..714d1826e1 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/complete-supplychain-sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-impl-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-impl-sca-contribution.xml new file mode 100644 index 0000000000..7f7dc969e2 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-impl-sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-interface-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-interface-sca-contribution.xml new file mode 100644 index 0000000000..7f7dc969e2 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-interface-sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml new file mode 100644 index 0000000000..8a2bec308f --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/customer-sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal-customer-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal-customer-sca-contribution.xml new file mode 100644 index 0000000000..c77c4c1c7e --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal-customer-sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal1-supplychain-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal1-supplychain-sca-contribution.xml new file mode 100644 index 0000000000..210a68011f --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal1-supplychain-sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal2-supplychain-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal2-supplychain-sca-contribution.xml new file mode 100644 index 0000000000..d118cceef9 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/illegal2-supplychain-sca-contribution.xml @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml new file mode 100644 index 0000000000..d37b6659da --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/retailer-sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml new file mode 100644 index 0000000000..77b28d9023 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/shipper-sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml new file mode 100644 index 0000000000..8ec290a831 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/supplychain-sca-contribution.xml @@ -0,0 +1,30 @@ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml new file mode 100644 index 0000000000..1398416978 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/META-INF/warehouse-sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/illegalsupplychain.composite b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/illegalsupplychain.composite new file mode 100644 index 0000000000..db1f0d34e7 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/illegalsupplychain.composite @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/supplychain.composite b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/supplychain.composite new file mode 100644 index 0000000000..5be79b741a --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/supplychain.composite @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/warehouse/JavaWarehouseComponentImpl.componentType b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/warehouse/JavaWarehouseComponentImpl.componentType new file mode 100644 index 0000000000..a76fae8090 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-classes/src/main/resources/supplychain/warehouse/JavaWarehouseComponentImpl.componentType @@ -0,0 +1,28 @@ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-test/pom.xml b/java/sca/contrib/itest/contribution-classloader/contribution-test/pom.xml new file mode 100644 index 0000000000..dfa0efd5d5 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-test/pom.xml @@ -0,0 +1,53 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-classloader-test + Apache Tuscany Contribution Classloader tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionTestCase.java b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionTestCase.java new file mode 100644 index 0000000000..18fc2bbc88 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionTestCase.java @@ -0,0 +1,373 @@ +/* + * 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.test.contribution; + + +import java.lang.reflect.InvocationTargetException; +import java.lang.reflect.Method; +import java.net.URLClassLoader; + +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.processor.ContributionResolveException; +import org.apache.tuscany.sca.contribution.resolver.ClassReference; +import org.junit.After; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; + +/* + * + * Contribution ClassLoading integration tests + */ + +public class ContributionTestCase { + + private SupplyChain supplyChain; + + + @Before + public void setUp() throws Exception { + supplyChain = new SupplyChain(); + } + + + @After + public void tearDown() throws Exception { + + supplyChain.tearDown(); + + } + + + /** + * Test static ClassLoading for classes that are visible from contribution + * + * @throws Exception + */ + public void staticClassLoadingTestForVisibleClasses() throws Exception { + + Contribution customerContribution = supplyChain.getContribution("Customer"); + ClassReference customerClassRef = new ClassReference("supplychain.customer.Customer"); + customerClassRef = customerContribution.getModelResolver().resolveModel(ClassReference.class, customerClassRef); + Class customerClass = customerClassRef.getJavaClass(); + + Class customerClassFromContribution = customerContribution.getClassLoader().loadClass("supplychain.customer.Customer"); + Assert.assertEquals(customerClass, customerClassFromContribution); + + Object customer = supplyChain.getCustomer(customerClass); + + Method m = customerClass.getMethod("purchaseGoods"); + m.invoke(customer); + + + m = customerClass.getMethod("outstandingOrderCount"); + + int retries = 10; + int outstandingCount = 1; + while (retries-- > 0) { + + outstandingCount = (int)(Integer)m.invoke(customer); + if (outstandingCount == 0) + break; + else + Thread.sleep(100); + } + Assert.assertEquals(0, outstandingCount); + + + } + + + /** + * Test dynamic ClassLoading for classes that are visible from contribution + * + * @throws Exception + */ + public void dynamicClassLoadingTestForVisibleClasses() throws Exception { + + Contribution customerContribution = supplyChain.getContribution("Customer"); + Contribution retailerContribution = supplyChain.getContribution("Retailer"); + Contribution warehouseContribution = supplyChain.getContribution("Warehouse"); + Contribution shipperContribution = supplyChain.getContribution("Shipper"); + Contribution supplyChainContribution = supplyChain.getContribution("SupplyChain"); + + ClassReference customerClassRef = new ClassReference("supplychain.customer.Customer"); + customerClassRef = customerContribution.getModelResolver().resolveModel(ClassReference.class, customerClassRef); + Class customerClass = customerClassRef.getJavaClass(); + + Class customerClassFromContribution = customerContribution.getClassLoader().loadClass("supplychain.customer.Customer"); + Assert.assertEquals(customerClass, customerClassFromContribution); + + Object customer = supplyChain.getCustomer(customerClass); + Assert.assertTrue(customerClass.isInstance(customer)); + + ClassReference retailerClassRef = new ClassReference("supplychain.retailer.Retailer"); + retailerClassRef = retailerContribution.getModelResolver().resolveModel(ClassReference.class, retailerClassRef); + Class retailerClass = retailerClassRef.getJavaClass(); + + Class retailerClassFromContribution = retailerContribution.getClassLoader().loadClass("supplychain.retailer.Retailer"); + Assert.assertEquals(retailerClass, retailerClassFromContribution); + + Class retailerClassFromCustomer = customerContribution.getClassLoader().loadClass("supplychain.retailer.Retailer"); + Assert.assertEquals(retailerClass, retailerClassFromCustomer); + + ClassReference warehouseClassRef = new ClassReference("supplychain.warehouse.Warehouse"); + warehouseClassRef = warehouseContribution.getModelResolver().resolveModel(ClassReference.class, warehouseClassRef); + Class warehouseClass = warehouseClassRef.getJavaClass(); + + Class warehouseClassFromContribution = warehouseContribution.getClassLoader().loadClass("supplychain.warehouse.Warehouse"); + Assert.assertEquals(warehouseClass, warehouseClassFromContribution); + + Class warehouseClassFromRetailer = retailerContribution.getClassLoader().loadClass("supplychain.warehouse.Warehouse"); + Assert.assertEquals(warehouseClass, warehouseClassFromRetailer); + + ClassReference shipperClassRef = new ClassReference("supplychain.shipper.Shipper"); + shipperClassRef = shipperContribution.getModelResolver().resolveModel(ClassReference.class, shipperClassRef); + Class shipperClass = shipperClassRef.getJavaClass(); + + Class shipperClassFromContribution = shipperContribution.getClassLoader().loadClass("supplychain.shipper.Shipper"); + Assert.assertEquals(shipperClass, shipperClassFromContribution); + + Class shipperClassFromWarehouse = shipperContribution.getClassLoader().loadClass("supplychain.shipper.Shipper"); + Assert.assertEquals(shipperClass, shipperClassFromWarehouse); + + Class customerClassFromShipper = shipperContribution.getClassLoader().loadClass("supplychain.customer.Customer"); + Assert.assertEquals(customerClass, customerClassFromShipper); + + Class customerClassFromSupplyChain = supplyChainContribution.getClassLoader().loadClass("supplychain.customer.Customer"); + Assert.assertEquals(customerClass, customerClassFromSupplyChain); + Class retailerClassFromSupplyChain = supplyChainContribution.getClassLoader().loadClass("supplychain.retailer.Retailer"); + Assert.assertEquals(retailerClass, retailerClassFromSupplyChain); + Class warehouseClassFromSupplyChain = supplyChainContribution.getClassLoader().loadClass("supplychain.warehouse.Warehouse"); + Assert.assertEquals(warehouseClass, warehouseClassFromSupplyChain); + Class shipperClassFromSupplyChain = supplyChainContribution.getClassLoader().loadClass("supplychain.shipper.Shipper"); + Assert.assertEquals(shipperClass, shipperClassFromSupplyChain); + + } + + /** + * Test dynamic ClassLoading for classes that are visible from contribution + * + * @throws Exception + */ + public void dynamicClassLoadingTestForNonImportedClasses() throws Exception { + + Contribution customerContribution = supplyChain.getContribution("Customer"); + Contribution shipperContribution = supplyChain.getContribution("Shipper"); + + Class customerClass = customerContribution.getClassLoader().loadClass("supplychain.customer.Customer"); + Class shipperClass = shipperContribution.getClassLoader().loadClass("supplychain.shipper.Shipper"); + + try { + customerClass.getClassLoader().loadClass("supplychain.warehouse.Warehouse"); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + try { + customerClass.getClassLoader().loadClass("supplychain.shipper.JavaShipperComponentImpl"); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + + try { + Class.forName("supplychain.warehouse.Warehouse", true, customerClass.getClassLoader()); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + try { + Class.forName("supplychain.shipper.JavaShipperComponentImpl", true, customerClass.getClassLoader()); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + + try { + shipperClass.getClassLoader().loadClass("supplychain.warehouse.JavaWarehouseComponentImpl"); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + try { + shipperClass.getClassLoader().loadClass("supplychain.retailer.Retailer"); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + + try { + Class.forName("supplychain.warehouse.JavaWarehouseComponentImpl", true, shipperClass.getClassLoader()); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + try { + Class.forName("supplychain.retailer.Retailer", true, shipperClass.getClassLoader()); + Assert.fail("Non-imported class loaded incorrectly"); + } catch (ClassNotFoundException e) { + } + + + } + + + /** + * This test ensures that classes from imported packages can be statically loaded + * from other contributions even though the classes are not on CLASSPATH or on the + * parent ClassLoader, or the thread context ClassLoader. + * + * @throws Exception + */ + @Test + public void testValidStaticClassLoading() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader()); + + staticClassLoadingTestForVisibleClasses(); + } + + /** + * This test ensures that all imported classes are loaded from the exporting contributions + * rather than the parent classLoader. If any of the interface classes were incorrectly loaded + * through the parent ClassLoader, LinkageError should result. + * + * @throws Exception + */ + @Test + public void testValidStaticClassLoadingWithContributionsInParentClassLoader() throws Exception { + + + URLClassLoader parentClassLoader = new URLClassLoader( + supplyChain.getContributionURLs(), + this.getClass().getClassLoader()); + + supplyChain.setUp(parentClassLoader); + + staticClassLoadingTestForVisibleClasses(); + } + + + /** + * This test ensures that classes from imported packages can be dynamically loaded from + * other contributions even though the classes are not on CLASSPATH or on the + * parent ClassLoader, or the thread context ClassLoader. + * + * @throws Exception + */ + @Test + public void testValidDynamicClassLoading() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader()); + + dynamicClassLoadingTestForVisibleClasses(); + } + + /** + * This test ensures that all imported classes are dynamically loaded from the exporting + * contributions rather than the parent classLoader. If any of the interface classes were + * incorrectly loaded through the parent, NoClassDefFoundError or LinkageError should result. + * + * @throws Exception + */ + @Test + public void testValidDynamicClassLoadingWithContributionsInParentClassLoader() throws Exception { + + + URLClassLoader parentClassLoader = new URLClassLoader( + supplyChain.getContributionURLs(), + this.getClass().getClassLoader()); + + supplyChain.setUp(parentClassLoader); + + dynamicClassLoadingTestForVisibleClasses(); + } + + @Test + public void testIllegalStaticClassLoading1() throws Exception { + // FIXME we have commented this code as we are not throwing exceptions anymore + // need to deal with monitor logs to catch the errors. + + /*try { + supplyChain.setUp(this.getClass().getClassLoader(), SupplyChain.SUPPLYCHAIN_ILLEGAL_1); + + Assert.fail("Composite containing unresolved references resolved incorrectly"); + } catch (ContributionResolveException e) { + }*/ + } + + @Test + public void testIllegalStaticClassLoading2() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader(), SupplyChain.SUPPLYCHAIN_ILLEGAL_2); + + Contribution customerContribution = supplyChain.getContribution("Customer"); + ClassReference customerClassRef = new ClassReference("supplychain.customer.Customer"); + customerClassRef = customerContribution.getModelResolver().resolveModel(ClassReference.class, customerClassRef); + Class customerClass = customerClassRef.getJavaClass(); + + Object customer = supplyChain.getCustomer(customerClass); + + try { + Method m = customerClass.getMethod("purchaseGoods"); + m.invoke(customer); + + Assert.fail("Classloading exception not thrown as expected"); + } catch (InvocationTargetException e) { + + Throwable cause = e.getCause(); + Assert.assertTrue(cause instanceof NoClassDefFoundError); + Assert.assertTrue(cause.getMessage().indexOf("JavaWarehouseComponentImpl") > -1); } + + } + + /** + * This test ensures that classes from imported packages can be dynamically loaded from + * other contributions even though the classes are not on CLASSPATH or on the + * parent ClassLoader, or the thread context ClassLoader. + * + * @throws Exception + */ + @Test + public void testIllegalDynamicClassLoading() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader()); + + dynamicClassLoadingTestForNonImportedClasses(); + } + + + /** + * Self-contained contribution containing composites, componentType files and implementations + * should not require import/export statements for these files to find each other or for Tuscany + * to load these files. + * @throws Exception + */ + @Test + public void testSelfContainedContribution() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader(), SupplyChain.SUPPLYCHAIN_SELFCONTAINED); + + staticClassLoadingTestForVisibleClasses(); + } + + @Test + public void testContributionsWithSplitPackage() throws Exception { + + supplyChain.setUp(this.getClass().getClassLoader(), SupplyChain.SUPPLYCHAIN_SPLITPACKAGE); + + staticClassLoadingTestForVisibleClasses(); + + dynamicClassLoadingTestForNonImportedClasses(); + } +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/SupplyChain.java b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/SupplyChain.java new file mode 100644 index 0000000000..1ec7aaaa3a --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/SupplyChain.java @@ -0,0 +1,231 @@ +/* + * 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.test.contribution; + + +import java.io.File; +import java.net.URL; +import java.util.Hashtable; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; +import org.junit.Assert; + +/* + * + * Contribution ClassLoading integration tests + */ + +public class SupplyChain { + + public static final int SUPPLYCHAIN = 0; + public static final int SUPPLYCHAIN_ILLEGAL_1 = 1; + public static final int SUPPLYCHAIN_ILLEGAL_2 = 2; + public static final int SUPPLYCHAIN_SELFCONTAINED = 3; + public static final int SUPPLYCHAIN_SPLITPACKAGE = 4; + + private String folderName = "../contribution-classes/target/classes"; + + private String customerJarName = "Customer"; + private String retailerJarName = "Retailer"; + private String warehouseJarName = "Warehouse"; + private String shipperJarName = "Shipper"; + private String supplychainJarName = "SupplyChain"; + private String illegalSupplyChain1JarName = "IllegalSupplyChain1"; + private String illegalSupplyChain2JarName = "IllegalSupplyChain2"; + private String illegalCustomerJarName = "IllegalCustomer"; + private String completeSupplychainJarName = "CompleteSupplyChain"; + private String customerInterfaceJarName = "CustomerInterface"; + private String customerImplJarName = "CustomerImpl"; + + + private EmbeddedSCADomain domain; + private ContributionService contributionService; + private int supplyChainVersion; + + private Hashtable contributions = new Hashtable(); + + private URL customerContribURL; + private URL retailerContribURL; + private URL warehouseContribURL; + private URL shipperContribURL; + private URL supplyChainContribURL; + private URL illegalSupplyChain1ContribURL; + private URL illegalSupplyChain2ContribURL; + private URL illegalCustomerContribURL; + private URL completeSupplyChainContribURL; + private URL customerInterfaceContribURL; + private URL customerImplContribURL; + + public SupplyChain() throws Exception { + + customerContribURL = new File(folderName + "/" + customerJarName + ".jar").toURI().toURL(); + retailerContribURL = new File(folderName + "/" + retailerJarName + ".jar").toURI().toURL(); + warehouseContribURL = new File(folderName + "/" + warehouseJarName + ".jar").toURI().toURL(); + shipperContribURL = new File(folderName + "/" + shipperJarName + ".jar").toURI().toURL(); + supplyChainContribURL = new File(folderName + "/" + supplychainJarName + ".jar").toURI().toURL(); + illegalSupplyChain1ContribURL = new File(folderName + "/" + illegalSupplyChain1JarName + ".jar").toURI().toURL(); + illegalSupplyChain2ContribURL = new File(folderName + "/" + illegalSupplyChain2JarName + ".jar").toURI().toURL(); + illegalCustomerContribURL = new File(folderName + "/" + illegalCustomerJarName + ".jar").toURI().toURL(); + completeSupplyChainContribURL = new File(folderName + "/" + completeSupplychainJarName + ".jar").toURI().toURL(); + customerInterfaceContribURL = new File(folderName + "/" + customerInterfaceJarName + ".jar").toURI().toURL(); + customerImplContribURL = new File(folderName + "/" + customerImplJarName + ".jar").toURI().toURL(); + } + + public void setUp(ClassLoader parentClassLoader) throws Exception { + this.setUp(parentClassLoader, SUPPLYCHAIN); + } + + public void setUp(ClassLoader parentClassLoader, int supplyChainVersion) throws Exception { + + this.supplyChainVersion = supplyChainVersion; + + Thread.currentThread().setContextClassLoader(parentClassLoader); + + //Create an embedded SCA domain + domain = new EmbeddedSCADomain(parentClassLoader, "http://localhost"); + + //Start the domain + domain.start(); + + this.contributionService = domain.getContributionService(); + + addContributions(supplyChainVersion); + } + + protected void addContributions(int supplyChainVersion) throws Exception { + + Contribution contribution; + + if (supplyChainVersion != SUPPLYCHAIN_SELFCONTAINED) { + contribution = contributionService.contribute("Shipper", shipperContribURL, true); + contributions.put("Shipper", contribution); + contribution = contributionService.contribute("Warehouse", warehouseContribURL, true); + contributions.put("Warehouse", contribution); + contribution = contributionService.contribute("Retailer", retailerContribURL, true); + contributions.put("Retailer", contribution); + } + + switch (supplyChainVersion) { + case SUPPLYCHAIN: + contribution = contributionService.contribute("Customer", customerContribURL, true); + contributions.put("Customer", contribution); + + contribution = contributionService.contribute("SupplyChain", supplyChainContribURL, true); + contributions.put("SupplyChain", contribution); + break; + case SUPPLYCHAIN_ILLEGAL_1: + contribution = contributionService.contribute("Customer", customerContribURL, true); + contributions.put("Customer", contribution); + + contribution = contributionService.contribute("SupplyChain", illegalSupplyChain1ContribURL, true); + contributions.put("SupplyChain", contribution); + break; + case SUPPLYCHAIN_ILLEGAL_2: + contribution = contributionService.contribute("Customer", illegalCustomerContribURL, true); + contributions.put("Customer", contribution); + + contribution = contributionService.contribute("SupplyChain", illegalSupplyChain2ContribURL, true); + contributions.put("SupplyChain", contribution); + break; + case SUPPLYCHAIN_SELFCONTAINED: + contribution = contributionService.contribute("SupplyChain", completeSupplyChainContribURL, true); + contributions.put("SupplyChain", contribution); + break; + case SUPPLYCHAIN_SPLITPACKAGE: + contribution = contributionService.contribute("Customer", customerInterfaceContribURL, true); + contributions.put("Customer", contribution); + + contribution = contributionService.contribute("CustomerImpl", customerImplContribURL, true); + contributions.put("CustomerImpl", contribution); + + contribution = contributionService.contribute("SupplyChain", supplyChainContribURL, true); + contributions.put("SupplyChain", contribution); + break; + } + + // SUPPLYCHAIN_ILLEGAL_1 should throw an exception when the composite is resolved, and hence + // should not get this far. + Assert.assertTrue(supplyChainVersion != SUPPLYCHAIN_ILLEGAL_1); + + + for (Contribution c : contributions.values()) { + + for (Composite deployable : c.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + } + + // Start Components from my composite + for (Composite deployable : contributions.get("SupplyChain").getDeployables() ) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + } + + public void tearDown() throws Exception { + + if (domain == null) + return; + + for (String contributionURI : contributions.keySet()) { + contributionService.remove(contributionURI); + } + + + if (contributions.get("SupplyChain") != null) { + // Stop Components from my composite + for (Composite deployable : contributions.get("SupplyChain").getDeployables() ) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + } + + domain.stop(); + + domain.close(); + } + + public Contribution getContribution(String uri) { + if (supplyChainVersion == SUPPLYCHAIN_SELFCONTAINED) + return contributions.get("SupplyChain"); + else + return contributions.get(uri); + } + + public Object getCustomer(Class customerClass) { + return domain.getService(customerClass, "CustomerComponent"); + } + + public URL[] getContributionURLs() { + return new URL[] { + customerContribURL, + retailerContribURL, + warehouseContribURL, + shipperContribURL, + supplyChainContribURL + }; + } + + +} diff --git a/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/TuscanyClassloadingTestCaseFIXME.java b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/TuscanyClassloadingTestCaseFIXME.java new file mode 100644 index 0000000000..9918ce8fca --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/contribution-test/src/test/java/org/apache/tuscany/sca/test/contribution/TuscanyClassloadingTestCaseFIXME.java @@ -0,0 +1,381 @@ +/* + * 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.test.contribution; + +import java.io.File; +import java.io.FileNotFoundException; +import java.io.IOException; +import java.lang.reflect.Constructor; +import java.lang.reflect.Method; +import java.net.URL; +import java.net.URLClassLoader; +import java.util.ArrayList; +import java.util.HashSet; +import java.util.List; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.extensibility.ServiceDiscovery; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; +import org.junit.After; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; +import org.oasisopen.sca.ServiceReference; + +/* + * + * Contribution ClassLoading integration tests + */ + +//FIXME This test case needs some serious rework! +// First it is very dependent on the names of the Tuscany runtime JARs +// and this is going to be difficult to maintain +// Second its usage of reflection requires the Tuscany implementation classes +// to be made public and this breaks isolation between modules. +public class TuscanyClassloadingTestCaseFIXME { + + // private static final int SCA_API = 1; + // private static final int TUSCANY_CORE_SPI = 2; + // private static final int TUSCANY_RUNTIME = 3; + // private static final int TUSCANY_EXTENSIONS = 4; + // private static final int TUSCANY_DEPENDENCIES = 0; + + private static final String[] scaApiJars = {"sca-api"}; + private static final String[] tuscanyCoreSpiJars = + {"core-spi", "interface", "interface-java", "interface-wsdl", "assembly", "policy", "databinding", + "contribution", "definitions"}; + private static final String[] tuscanyRuntimeJars = + { + + "binding-sca-xml", "binding-sca", "assembly-java-dsl", "assembly-xml", "assembly-xsd", "contribution-impl", + "contribution-java", "contribution-namespace", "core-databinding", "core-spring", "core", "definitions-xml", + "domain-api", "domain-impl", "domain", "extension-helper", "host-embedded", "interface-java-xml", + "interface-wsdl-xml", "java2wsdl", "node-api", "node-impl", "node", "osgi-runtime", "policy-logging", + "policy-security", "policy-transaction", "policy-xml", "wsdl2java"}; + private static final String[] tuscanyExtensionJars = + {"binding-dwr", "binding-ejb", "binding-feed", "binding-http", "binding-jms", "binding-jsonrpc", + "binding-notification", "binding-rmi", "binding-sca-axis2", "binding-ws-axis2", "binding-ws-xml", + "binding-ws", "databinding-axiom", "databinding-fastinfoset", "databinding-jaxb", "databinding-json", + "databinding-saxon", "databinding-sdo-axiom", "databinding-sdo", "databinding-xmlbeans", "host-http", + "host-jetty", "host-rmi", "host-tomcat", "host-webapp", "implementation-das.jar", "implementation-data.jar", + "implementation-java-runtime", "implementation-java-xml", "implementation-java", + "implementation-node-runtime", "implementation-node-xml", "implementation-node", + "implementation-notification", "implementation-osgi", "implementation-resource", "implementation-script", + "implementation-spring", "implementation-xquery", "contribution-osgi"}; + + private Class embeddedDomainClass; + Object domain; + + @Before + public void setUp() throws Exception { + + embeddedDomainClass = getEmbeddedDomainClass(); + + Constructor c = embeddedDomainClass.getConstructor(ClassLoader.class, String.class); + // Create an embedded domain + domain = c.newInstance(embeddedDomainClass.getClassLoader(), "http://localhost"); + + // Start the domain + invokeNoArgsMethod(domain, "start"); + + } + + @After + public void tearDown() throws Exception { + + // Stop the domain + invokeNoArgsMethod(domain, "stop"); + + } + + /** + * Create a ClassLoader hierarchy for Tuscany runtime + * Dependencies <- SCA-API <- Core-SPI+ Runtime <- Extensions + * Load the embedded SCA domain class using the runtime ClassLoader + * + * @return embedded SCA domain class + * @throws Exception + */ + private Class getEmbeddedDomainClass() throws Exception { + + URL[] scaApiUrls; + URL[] runtimeUrls; + URL[] extensionUrls; + URL[] dependencyUrls; + + // When the test is run under Eclipse, the ClassLoader for the test is + // sun.misc.Launcher$AppClassLoader. The first code path is taken. + // When the test is run under Maven, the ClassLoader for the test is + // org.apache.maven.surefire.booter.IsolatedClassLoader, which is a subclass + // of URLClassLoader. The second code path is taken. + if (!(this.getClass().getClassLoader() instanceof URLClassLoader)) { + String classPath = System.getProperty("java.class.path"); + String[] classPathEntries = classPath.split(System.getProperty("path.separator")); + HashSet dependentJars = new HashSet(); + for (int i = 0; i < classPathEntries.length; i++) { + dependentJars.add(classPathEntries[i]); + } + + scaApiUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars, scaApiJars); + runtimeUrls = + getTuscanyClassLoaderURLs(classPathEntries, dependentJars, tuscanyCoreSpiJars, tuscanyRuntimeJars); + extensionUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars, tuscanyExtensionJars); + dependencyUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars); + } else { + HashSet dependentJars = new HashSet(); + URL[] classPathEntries = ((URLClassLoader)this.getClass().getClassLoader()).getURLs(); + for (int i = 0; i < classPathEntries.length; i++) { + dependentJars.add(classPathEntries[i]); + } + scaApiUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars, scaApiJars); + runtimeUrls = + getTuscanyClassLoaderURLs(classPathEntries, dependentJars, tuscanyCoreSpiJars, tuscanyRuntimeJars); + extensionUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars, tuscanyExtensionJars); + dependencyUrls = getTuscanyClassLoaderURLs(classPathEntries, dependentJars); + + } + + boolean useSingleClassLoader = + (scaApiUrls == null || scaApiUrls.length == 0) || (runtimeUrls == null || runtimeUrls.length == 0) + || (extensionUrls == null || extensionUrls.length == 0) + || (dependencyUrls == null || dependencyUrls.length == 0); + + if (useSingleClassLoader) { + return EmbeddedSCADomain.class; + } else { + + ClassLoader dependencyLoader = new URLClassLoader(dependencyUrls, null); + ClassLoader scaApiLoader = new URLClassLoader(scaApiUrls, dependencyLoader); + ClassLoader runtimeClassLoader = new URLClassLoader(runtimeUrls, scaApiLoader); + ClassLoader extensionClassLoader = new URLClassLoader(extensionUrls, runtimeClassLoader); + + Class serviceDiscoveryClass = runtimeClassLoader.loadClass(ServiceDiscovery.class.getName()); + Method getInstanceMethod = serviceDiscoveryClass.getMethod("getInstance"); + Object serviceDiscoveryObj = getInstanceMethod.invoke(null); + Method registerClassLoaderMethod = + serviceDiscoveryClass.getMethod("registerClassLoader", ClassLoader.class); + registerClassLoaderMethod.invoke(serviceDiscoveryObj, extensionClassLoader); + + Thread.currentThread().setContextClassLoader(extensionClassLoader); + + return runtimeClassLoader.loadClass(EmbeddedSCADomain.class.getName()); + + } + + } + + /** + * From the list of entries in the test ClassLoader, match + * Tuscany jars corresponding to a ClassLoader, and return the list + * of matching entries as URLs. + * This method is used when the test is run under eclipse, using CLASSPATH + * based application ClassLoader. + * + * @param classPathEntries List of entries on CLASSPATH + * @param dependentJars Complete set of jars, remove jars corresponding to this + * ClassLoader from the set. + * @param jars List of Tuscany jars corresponding to this ClassLoader + * @return Matching URLs for the ClassLoader + * @throws IOException + */ + private URL[] getTuscanyClassLoaderURLs(String[] classPathEntries, HashSet dependentJars, String[]... jars) + throws IOException { + + String pathSeparator = System.getProperty("file.separator"); + HashSet classPathEntrySet; + + if (jars.length == 0) + classPathEntrySet = dependentJars; + else { + classPathEntrySet = new HashSet(); + + for (int i = 0; i < classPathEntries.length; i++) { + + String classPathEntry = classPathEntries[i]; + for (int j = 0; j < jars.length; j++) { + String[] jarList = jars[j]; + if (jarList != null) { + for (int k = 0; k < jarList.length; k++) { + String jarName = "tuscany-" + jarList[k]; + String alternateJarName = "modules" + pathSeparator + jarList[k]; + if (classPathEntry.indexOf(jarName) >= 0 || classPathEntry.indexOf(alternateJarName) >= 0) { + classPathEntrySet.add(classPathEntry); + dependentJars.remove(classPathEntry); + } + } + } + } + } + + } + ArrayList urls = new ArrayList(); + + for (String fileName : classPathEntrySet) { + File file = new File((String)fileName); + if (!file.exists()) { + throw new FileNotFoundException(fileName); + + } else { + urls.add(file.toURL()); + + } + } + + return (URL[])urls.toArray(new URL[urls.size()]); + } + + /** + * From the list of URLs of the test ClassLoader, match + * Tuscany jars corresponding to a ClassLoader, and return the matching URLs + * This method is used when the test is run under Maven. The test ClassLoader is + * org.apache.maven.surefire.booter.IsolatedClassLoader, which is a subclass + * of URLClassLoader + * + * @param classPathEntries List of URLs from the test ClassLoader + * @param dependentJars Complete set of jars, remove jars corresponding to this + * ClassLoader from the set. + * @param jars List of Tuscany jars corresponding to this ClassLoader + * @return Matching URLs for the ClassLoader + * @throws IOException + */ + private URL[] getTuscanyClassLoaderURLs(URL[] classPathEntries, HashSet dependentJars, String[]... jars) + throws IOException { + + String pathSeparator = System.getProperty("file.separator"); + HashSet classPathEntrySet; + + if (jars.length == 0) + classPathEntrySet = dependentJars; + else { + classPathEntrySet = new HashSet(); + + for (int i = 0; i < classPathEntries.length; i++) { + + URL classPathEntry = classPathEntries[i]; + String classPathEntryStr = classPathEntry.getPath(); + for (int j = 0; j < jars.length; j++) { + String[] jarList = jars[j]; + if (jarList != null) { + for (int k = 0; k < jarList.length; k++) { + String jarName = "tuscany-" + jarList[k]; + String alternateJarName = "modules" + pathSeparator + jarList[k]; + if (classPathEntryStr.indexOf(jarName) >= 0 || classPathEntryStr.indexOf(alternateJarName) >= 0) { + classPathEntrySet.add(classPathEntry); + dependentJars.remove(classPathEntry); + } + } + } + } + } + + } + return (URL[])classPathEntrySet.toArray(new URL[classPathEntrySet.size()]); + } + + private Object invokeNoArgsMethod(Object obj, String methodName) throws Exception { + + return obj.getClass().getMethod(methodName).invoke(obj); + } + + private Object invokeOneArgMethod(Object obj, String methodName, Class argType, Object arg) throws Exception { + + return obj.getClass().getMethod(methodName, argType).invoke(obj, arg); + } + + /** + * + * Load Tuscany runtime using multiple ClassLoaders, and run supplychain + * test. + * + * @throws Exception + */ + @SuppressWarnings("unchecked") + @Test + public void test() throws Exception { + + ClassLoader runtimeClassloader = embeddedDomainClass.getClassLoader(); + + if (runtimeClassloader == this.getClass().getClassLoader()) { + System.out.println("Runtime and test loaded using the same classloader " + runtimeClassloader); + } else { + System.out + .println("Running test using separate Tuscany classloaders, runtime classloader=" + runtimeClassloader); + ClassLoader apiClassLoader = + runtimeClassloader.loadClass(ServiceReference.class.getName()).getClassLoader(); + Assert.assertTrue(apiClassLoader != runtimeClassloader); + + try { + runtimeClassloader.loadClass("org.apache.tuscany.sca.implementation.java.JavaImplementation"); + Assert.fail("Loaded extension class incorrectly from runtimeClassLoader"); + } catch (ClassNotFoundException e) { + } + + } + + // Contribute supplychain (as single contribution) + Object contributionService = invokeNoArgsMethod(domain, "getContributionService"); + Method contributeMethod = + contributionService.getClass().getMethod("contribute", String.class, URL.class, boolean.class); + + String folderName = "../contribution-classes/target/classes"; + String supplychainJarName = "CompleteSupplyChain"; + URL supplyChainContribURL = new File(folderName + "/" + supplychainJarName + ".jar").toURL(); + Object contribution = contributeMethod.invoke(contributionService, "SupplyChain", supplyChainContribURL, true); + + Object composite = ((List)invokeNoArgsMethod(contribution, "getDeployables")).get(0); + Object domainComposite = invokeNoArgsMethod(domain, "getDomainComposite"); + List includes = (List)invokeNoArgsMethod(domainComposite, "getIncludes"); + includes.add(composite); + //Object compositeBuilder = invokeNoArgsMethod(domain, "getCompositeBuilder"); + Object compositeActivator = invokeNoArgsMethod(domain, "getCompositeActivator"); + + Class compositeClass = embeddedDomainClass.getClassLoader().loadClass(Composite.class.getName()); + invokeOneArgMethod(domain, "buildComposite", compositeClass, composite); + invokeOneArgMethod(compositeActivator, "activate", compositeClass, composite); + invokeOneArgMethod(compositeActivator, "start", compositeClass, composite); + + // Get customer service + Method getClassLoaderMethod = contribution.getClass().getMethod("getClassLoader"); + ClassLoader classLoader = (ClassLoader)getClassLoaderMethod.invoke(contribution); + + Class customerClass = classLoader.loadClass("supplychain.customer.Customer"); + Method getServiceMethod = embeddedDomainClass.getMethod("getService", Class.class, String.class); + Object customer = getServiceMethod.invoke(domain, customerClass, "CustomerComponent"); + + // Invoke purchaseGoods + Method m = customerClass.getMethod("purchaseGoods"); + m.invoke(customer); + + m = customerClass.getMethod("outstandingOrderCount"); + + int retries = 10; + int outstandingCount = 1; + while (retries-- > 0) { + + outstandingCount = (int)(Integer)m.invoke(customer); + if (outstandingCount == 0) + break; + else + Thread.sleep(100); + } + Assert.assertEquals(0, outstandingCount); + + } + +} diff --git a/java/sca/contrib/itest/contribution-classloader/pom.xml b/java/sca/contrib/itest/contribution-classloader/pom.xml new file mode 100644 index 0000000000..7e94f897b8 --- /dev/null +++ b/java/sca/contrib/itest/contribution-classloader/pom.xml @@ -0,0 +1,51 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-classloader + pom + Apache Tuscany Contribution ClassLoader Integration Tests + + + contribution-classes + contribution-test + + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-contribution-impl + 2.0-SNAPSHOT + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/pom.xml b/java/sca/contrib/itest/contribution-import-export/export-composite/pom.xml new file mode 100644 index 0000000000..094987318a --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/pom.xml @@ -0,0 +1,67 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-export-composite + Apache Tuscany SCA Contribution Export Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/Hello.java b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/Hello.java new file mode 100644 index 0000000000..32b024bccb --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/Hello.java @@ -0,0 +1,30 @@ +/* + * 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 hello; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * This is the business interface of the Hello service. + */ +@Remotable +public interface Hello { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/HelloImpl.java b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/HelloImpl.java new file mode 100644 index 0000000000..0c60e62d35 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/java/hello/HelloImpl.java @@ -0,0 +1,33 @@ +/* + * 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 hello; + +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(Hello.class) +public class HelloImpl implements Hello { + + public String getGreetings(String name) { + return "Hello " + name; + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..3c14560a56 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/hello.composite b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/hello.composite new file mode 100644 index 0000000000..636b7111d9 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/src/main/resources/hello.composite @@ -0,0 +1,31 @@ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-composite/src/test/java/org/apache/tuscany/sca/test/contribution/HelloTestCase.java b/java/sca/contrib/itest/contribution-import-export/export-composite/src/test/java/org/apache/tuscany/sca/test/contribution/HelloTestCase.java new file mode 100644 index 0000000000..72b77564d2 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-composite/src/test/java/org/apache/tuscany/sca/test/contribution/HelloTestCase.java @@ -0,0 +1,91 @@ +/* + * 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.test.contribution; + +import hello.Hello; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.URL; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * Tests that the helloworld server is available + */ +public class HelloTestCase extends TestCase { + private ClassLoader cl; + private EmbeddedSCADomain domain; + + @Override + protected void setUp() throws Exception { + // Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + // Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + URL helloURL = getContributionURL(Hello.class); + + // File helloContrib = new File("./target/classes/"); + // URL helloURL = helloContrib.toURL(); + Contribution consumerContribution = + contributionService.contribute("http://import-export/hello", helloURL, false); + Composite consumerComposite = consumerContribution.getDeployables().get(0); + domain.getDomainComposite().getIncludes().add(consumerComposite); + domain.buildComposite(consumerComposite); + + // Start Components from my composite + domain.getCompositeActivator().activate(consumerComposite); + domain.getCompositeActivator().start(consumerComposite); + } + + private URL getContributionURL(Class cls) throws MalformedURLException { + String flag = "/" + cls.getName().replace('.', '/') + ".class"; + URL url = cls.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length() + 1); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } + + public void testHello() throws IOException { + Hello hello = domain.getService(Hello.class, "HelloServiceComponent"); + assertNotNull(hello); + assertEquals(hello.getGreetings("lresende"), "Hello lresende"); + } + + @Override + public void tearDown() throws Exception { + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/export-java/pom.xml b/java/sca/contrib/itest/contribution-import-export/export-java/pom.xml new file mode 100644 index 0000000000..7050d77a67 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-java/pom.xml @@ -0,0 +1,67 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-export-java + Apache Tuscany SCA Contribution Java Export Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-java/src/main/java/helloworld/HelloWorldService.java b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/java/helloworld/HelloWorldService.java new file mode 100644 index 0000000000..134da7e34b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/java/helloworld/HelloWorldService.java @@ -0,0 +1,30 @@ +/* + * 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.oasisopen.sca.annotation.Remotable; + +/** + * This is the business interface of the HelloWorld greetings service. + */ +@Remotable +public interface HelloWorldService { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..dc33dfa560 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/helloworld/HelloWorldImpl.componentType b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/helloworld/HelloWorldImpl.componentType new file mode 100644 index 0000000000..5a14b41650 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-java/src/main/resources/helloworld/HelloWorldImpl.componentType @@ -0,0 +1,30 @@ + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/export-resource/pom.xml b/java/sca/contrib/itest/contribution-import-export/export-resource/pom.xml new file mode 100644 index 0000000000..1202328b00 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-resource/pom.xml @@ -0,0 +1,31 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-export-resource + Apache Tuscany SCA Contribution Resource Export Integration Tests + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..f11eacb416 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/ufservices/store.html b/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/ufservices/store.html new file mode 100644 index 0000000000..1ff281373a --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-resource/src/main/resources/ufservices/store.html @@ -0,0 +1,27 @@ + + + +Store + + + +

Sample Store Page

+ + diff --git a/java/sca/contrib/itest/contribution-import-export/export-wsdl/pom.xml b/java/sca/contrib/itest/contribution-import-export/export-wsdl/pom.xml new file mode 100644 index 0000000000..51f9efd932 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-wsdl/pom.xml @@ -0,0 +1,31 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-export-wsdl + Apache Tuscany SCA Contribution WSDL Export Integration Tests + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..b7394ec14b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.wsdl b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.wsdl new file mode 100644 index 0000000000..9b31363e1a --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.wsdl @@ -0,0 +1,76 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.xsd b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.xsd new file mode 100644 index 0000000000..d3c83b08c6 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/export-wsdl/src/main/resources/helloworld.xsd @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/pom.xml b/java/sca/contrib/itest/contribution-import-export/import-composite/pom.xml new file mode 100644 index 0000000000..be3d2f1fb0 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/pom.xml @@ -0,0 +1,73 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-import-composite + Apache Tuscany SCA Contribution Import Integration Tests + + + + org.apache.tuscany.sca + itest-contribution-export-composite + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldImpl.java b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldImpl.java new file mode 100644 index 0000000000..05bd7b7138 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldImpl.java @@ -0,0 +1,38 @@ +/* + * 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 hello.Hello; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(HelloWorldService.class) +public class HelloWorldImpl implements HelloWorldService { + @Reference + protected Hello helloServiceRef; + + public String getGreetings(String name) { + return helloServiceRef.getGreetings(name); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldServer.java b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldServer.java new file mode 100644 index 0000000000..3d43290380 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldServer.java @@ -0,0 +1,46 @@ +/* + * 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 java.io.IOException; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * This server program shows how to create an SCA runtime, and start it which + * activates the helloworld Web service endpoint. + */ +public class HelloWorldServer { + + public static void main(String[] args) { + + SCADomain scaDomain = SCADomain.newInstance("helloworldws.composite"); + + try { + System.out.println("HelloWorld server started (press enter to shutdown)"); + System.in.read(); + } catch (IOException e) { + e.printStackTrace(); + } + + scaDomain.close(); + System.out.println("HelloWorld server stopped"); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldService.java b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldService.java new file mode 100644 index 0000000000..134da7e34b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/java/helloworld/HelloWorldService.java @@ -0,0 +1,30 @@ +/* + * 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.oasisopen.sca.annotation.Remotable; + +/** + * This is the business interface of the HelloWorld greetings service. + */ +@Remotable +public interface HelloWorldService { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..9f3f5be452 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,27 @@ + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.wsdl b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.wsdl new file mode 100644 index 0000000000..9b31363e1a --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.wsdl @@ -0,0 +1,76 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.xsd b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.xsd new file mode 100644 index 0000000000..d3c83b08c6 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworld.xsd @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworldws.composite b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworldws.composite new file mode 100644 index 0000000000..e2f852ff7e --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/main/resources/helloworldws.composite @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-composite/src/test/java/org/apache/tuscany/test/contribution/HelloWorldServerTestCase.java b/java/sca/contrib/itest/contribution-import-export/import-composite/src/test/java/org/apache/tuscany/test/contribution/HelloWorldServerTestCase.java new file mode 100644 index 0000000000..1176a89143 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-composite/src/test/java/org/apache/tuscany/test/contribution/HelloWorldServerTestCase.java @@ -0,0 +1,126 @@ +/* + * 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.test.contribution; + +import hello.Hello; +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.Socket; +import java.net.URL; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * Tests that the helloworld server is available + */ +public class HelloWorldServerTestCase extends TestCase { + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution helloWorldContribution; + private Contribution compositeContribution; + + @Override + protected void setUp() throws Exception { + //Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + //Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + // File compositeContribLocation = new File("../export-composite/target/classes"); + // URL compositeContribURL = compositeContribLocation.toURL(); + URL compositeContribURL = getContributionURL(Hello.class); + compositeContribution = + contributionService.contribute("http://import-export/export-composite", compositeContribURL, false); + for (Composite deployable : compositeContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + +// File helloWorldContribLocation = new File("./target/classes/"); +// URL helloWorldContribURL = helloWorldContribLocation.toURL(); + URL helloWorldContribURL = getContributionURL(HelloWorldService.class); + helloWorldContribution = + contributionService.contribute("http://import-export/helloworld", helloWorldContribURL, false); + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + // Start Components from my composite + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + } + + private URL getContributionURL(Class cls) throws MalformedURLException { + String flag = "/" + cls.getName().replace('.', '/') + ".class"; + URL url = cls.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length() + 1); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } + + public void testPing() throws IOException { + new Socket("127.0.0.1", 8085); + } + + public void testServiceCall() throws IOException { + HelloWorldService helloWorldService = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent/HelloWorldService"); + assertNotNull(helloWorldService); + + assertEquals("Hello Smith", helloWorldService.getGreetings("Smith")); + } + + @Override + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://import-export/helloworld"); + contributionService.remove("http://import-export/export-composite"); + + //Stop Components from my composite + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + + domain.stop(); + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-java/pom.xml b/java/sca/contrib/itest/contribution-import-export/import-java/pom.xml new file mode 100644 index 0000000000..13d9a7ce58 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-java/pom.xml @@ -0,0 +1,73 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-import-java + Apache Tuscany SCA Contribution Java Import Java Integration Tests + + + + org.apache.tuscany.sca + itest-contribution-export-java + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-java/src/main/java/helloworld/HelloWorldImpl.java b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/java/helloworld/HelloWorldImpl.java new file mode 100644 index 0000000000..2186c00e57 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/java/helloworld/HelloWorldImpl.java @@ -0,0 +1,33 @@ +/* + * 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.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(HelloWorldService.class) +public class HelloWorldImpl implements HelloWorldService { + + public String getGreetings(String name) { + return "Hello " + name; + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..224e2c4d79 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/helloworldws.composite b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/helloworldws.composite new file mode 100644 index 0000000000..9b650e4acc --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-java/src/main/resources/helloworldws.composite @@ -0,0 +1,29 @@ + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-java/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java b/java/sca/contrib/itest/contribution-import-export/import-java/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java new file mode 100644 index 0000000000..431988cc04 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-java/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java @@ -0,0 +1,127 @@ +/* + * 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.test.contribution; + +import helloworld.HelloWorldImpl; +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.URL; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * Tests that the helloworld server is available + */ +public class HelloWorldServerTestCase extends TestCase { + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution helloWorldContribution; + private Contribution javaContribution; + + @Override + protected void setUp() throws Exception { + //Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + //Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + //File javaContribLocation = new File("../export-java/target/classes"); + //URL javaContribURL = javaContribLocation.toURL(); + URL javaContribURL = getContributionURL(HelloWorldService.class); + javaContribution = contributionService.contribute("http://import-export/export-java", javaContribURL, false); + for (Composite deployable : javaContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + //File helloWorldContribLocation = new File("./target/classes/"); + //URL helloWorldContribURL = helloWorldContribLocation.toURL(); + URL helloWorldContribURL = getContributionURL(HelloWorldImpl.class); + helloWorldContribution = contributionService.contribute("http://import-export/helloworld", helloWorldContribURL, false); + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + // Start Components from my composite + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + } + + private URL getContributionURL(Class cls) throws MalformedURLException { + String flag = "/" + cls.getName().replace('.', '/') + ".class"; + URL url = cls.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length() + 1); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } + + public void testPing() throws IOException { + HelloWorldService helloWorldService = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent/HelloWorldService"); + assertNotNull(helloWorldService); + assertEquals("Hello test", helloWorldService.getGreetings("test")); + } + + public void testServiceCall() throws IOException { + HelloWorldService helloWorldService = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent/HelloWorldService"); + assertNotNull(helloWorldService); + + assertEquals("Hello Smith", helloWorldService.getGreetings("Smith")); + } + + @Override + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://import-export/helloworld"); + contributionService.remove("http://import-export/export-java"); + + // Stop Components from my composite + for (Composite deployable : helloWorldContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + + domain.stop(); + + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-resource/pom.xml b/java/sca/contrib/itest/contribution-import-export/import-resource/pom.xml new file mode 100644 index 0000000000..6adf9effe5 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-resource/pom.xml @@ -0,0 +1,102 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-import-resource + Apache Tuscany SCA Contribution Resource Import Java Integration Tests + + + + + org.apache.tuscany.sca + itest-contribution-export-resource + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-http + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-binding-http-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-resource-runtime + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-contribution-resource + 2.0-SNAPSHOT + test + + + + javax.servlet + servlet-api + 2.5 + provided + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..ac6d7becb3 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/store.composite b/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/store.composite new file mode 100644 index 0000000000..bb5a7b764f --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-resource/src/main/resources/store.composite @@ -0,0 +1,33 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-resource/src/test/java/org/apache/tuscany/sca/test/contribution/StoreTestCase.java b/java/sca/contrib/itest/contribution-import-export/import-resource/src/test/java/org/apache/tuscany/sca/test/contribution/StoreTestCase.java new file mode 100644 index 0000000000..1b7542b7d9 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-resource/src/test/java/org/apache/tuscany/sca/test/contribution/StoreTestCase.java @@ -0,0 +1,129 @@ +/* + * 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.test.contribution; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.Socket; +import java.net.URL; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * Tests that the helloworld server is available + */ +public class StoreTestCase extends TestCase { + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution storeContribution; + private Contribution resourceContribution; + + @Override + protected void setUp() throws Exception { + //Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + //Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + URL javaContribURL = getContributionURL(cl, "ufservices/store.html"); + resourceContribution = contributionService.contribute("http://import-export/export-resource", javaContribURL, false); + for (Composite deployable : resourceContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + URL storeContributionURL = getContributionURL(cl, "store.composite"); + + storeContribution = + contributionService.contribute("http://import-export/store", storeContributionURL, false); + for (Composite deployable : storeContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + // Start Components from my composite + for (Composite deployable : storeContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + } + + public void testPing() throws IOException { + new Socket("127.0.0.1", 8085); + } + + + @Override + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://import-export/store"); + contributionService.remove("http://import-export/export-resource"); + + // Stop Components from my composite + for (Composite deployable : storeContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + + domain.stop(); + + domain.close(); + } + + + /** + * Utility methods + */ + + + private URL getContributionURL(ClassLoader cl, Class cls) throws MalformedURLException { + String flag = "/" + cls.getName().replace('.', '/') + ".class"; + URL url = cl.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length() + 1); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } + + private URL getContributionURL(ClassLoader cl, String uri) throws MalformedURLException { + URL url = cl.getResource(uri); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - uri.length()); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/pom.xml b/java/sca/contrib/itest/contribution-import-export/import-wsdl/pom.xml new file mode 100644 index 0000000000..265376216b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/pom.xml @@ -0,0 +1,73 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-import-wsdl + Apache Tuscany SCA Contribution WSDL Import Integration Tests + + + + org.apache.tuscany.sca + itest-contribution-export-wsdl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + junit + junit + 4.5 + test + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldImpl.java b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldImpl.java new file mode 100644 index 0000000000..2186c00e57 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldImpl.java @@ -0,0 +1,33 @@ +/* + * 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.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(HelloWorldService.class) +public class HelloWorldImpl implements HelloWorldService { + + public String getGreetings(String name) { + return "Hello " + name; + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldServer.java b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldServer.java new file mode 100644 index 0000000000..3d43290380 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldServer.java @@ -0,0 +1,46 @@ +/* + * 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 java.io.IOException; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * This server program shows how to create an SCA runtime, and start it which + * activates the helloworld Web service endpoint. + */ +public class HelloWorldServer { + + public static void main(String[] args) { + + SCADomain scaDomain = SCADomain.newInstance("helloworldws.composite"); + + try { + System.out.println("HelloWorld server started (press enter to shutdown)"); + System.in.read(); + } catch (IOException e) { + e.printStackTrace(); + } + + scaDomain.close(); + System.out.println("HelloWorld server stopped"); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldService.java b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldService.java new file mode 100644 index 0000000000..134da7e34b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/java/helloworld/HelloWorldService.java @@ -0,0 +1,30 @@ +/* + * 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.oasisopen.sca.annotation.Remotable; + +/** + * This is the business interface of the HelloWorld greetings service. + */ +@Remotable +public interface HelloWorldService { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..d46fe0b57c --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/META-INF/sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/helloworldws.composite b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/helloworldws.composite new file mode 100644 index 0000000000..5008a2ea5b --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/main/resources/helloworldws.composite @@ -0,0 +1,33 @@ + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java new file mode 100644 index 0000000000..5c40606e50 --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/import-wsdl/src/test/java/org/apache/tuscany/sca/test/contribution/HelloWorldServerTestCase.java @@ -0,0 +1,137 @@ +/* + * 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.test.contribution; + +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.MalformedURLException; +import java.net.Socket; +import java.net.URL; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * Tests that the helloworld server is available + */ +public class HelloWorldServerTestCase extends TestCase { + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution wsdlContribution; + private Contribution consumerContribution; + + @Override + protected void setUp() throws Exception { + // Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + //Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + // File wsdlContribLocation = new File("../export-wsdl/target/classes"); + // URL wsdlContribURL = wsdlContribLocation.toURL(); + URL wsdlContribURL = getContributionURL(getClass().getClassLoader(), "helloworld.wsdl"); + wsdlContribution = contributionService.contribute("http://import-export/export-wsdl", wsdlContribURL, false); + for (Composite deployable : wsdlContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + // File helloWorldContribLocation = new File("./target/classes/"); + // URL helloWorldContribURL = helloWorldContribLocation.toURL(); + URL helloWorldContribURL = getContributionURL(HelloWorldService.class); + consumerContribution = + contributionService.contribute("http://import-export/helloworld", helloWorldContribURL, false); + for (Composite deployable : consumerContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + // Start Components from my composite + for (Composite deployable : consumerContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + } + + public void testPing() throws IOException { + new Socket("127.0.0.1", 8085); + } + + private URL getContributionURL(Class cls) throws MalformedURLException { + String flag = "/" + cls.getName().replace('.', '/') + ".class"; + URL url = cls.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length() + 1); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + return url; + } + + private URL getContributionURL(ClassLoader cl, String flag) throws MalformedURLException { + URL url = cl.getResource(flag); + String root = url.toExternalForm(); + root = root.substring(0, root.length() - flag.length()); + if (root.startsWith("jar:") && root.endsWith("!/")) { + root = root.substring(4, root.length() - 2); + } + url = new URL(root); + // System.out.println(url); + return url; + } + + public void testServiceCall() throws IOException { + HelloWorldService helloWorldService = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent/HelloWorldService"); + assertNotNull(helloWorldService); + + assertEquals("Hello Smith", helloWorldService.getGreetings("Smith")); + } + + @Override + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://import-export/helloworld"); + contributionService.remove("http://import-export/export-wsdl"); + + // Stop Components from my composite + for (Composite deployable : consumerContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + + domain.stop(); + + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-import-export/pom.xml b/java/sca/contrib/itest/contribution-import-export/pom.xml new file mode 100644 index 0000000000..36858e953e --- /dev/null +++ b/java/sca/contrib/itest/contribution-import-export/pom.xml @@ -0,0 +1,56 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-import-export + pom + Apache Tuscany SCA Contribution Import/Export Integration Tests + + + export-composite + export-java + export-resource + export-wsdl + import-composite + import-java + import-resource + import-wsdl + + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-contribution-impl + 2.0-SNAPSHOT + + + diff --git a/java/sca/contrib/itest/contribution-multiple/pom.xml b/java/sca/contrib/itest/contribution-multiple/pom.xml new file mode 100644 index 0000000000..5ff78b3d48 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/pom.xml @@ -0,0 +1,51 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution-multiple + Apache Tuscany SCA Multiple Contribution Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-contribution-impl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/Hello.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/Hello.java new file mode 100644 index 0000000000..7e574a7db3 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/Hello.java @@ -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 hello; + +/** + * This is the business interface of the Hello service. + */ +public interface Hello { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/HelloImpl.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/HelloImpl.java new file mode 100644 index 0000000000..7cd950453d --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/hello/HelloImpl.java @@ -0,0 +1,33 @@ +/* + * 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 hello; + +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(Hello.class) +public class HelloImpl implements Hello { + + public String getGreetings(String name) { + return "Hello " + name; + } + +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldImpl.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldImpl.java new file mode 100644 index 0000000000..e90d10dc24 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldImpl.java @@ -0,0 +1,38 @@ +/* + * 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 hello.Hello; + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements the HelloWorld service. + */ +@Service(HelloWorldService.class) +public class HelloWorldImpl implements HelloWorldService { + @Reference + protected Hello helloServiceRef; + + public String getGreetings(String name) { + return helloServiceRef.getGreetings(name); + } + +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldService.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldService.java new file mode 100644 index 0000000000..5251fc0a45 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/helloworld/HelloWorldService.java @@ -0,0 +1,28 @@ +/* + * 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; + + +/** + * This is the business interface of the HelloWorld greetings service. + */ +public interface HelloWorldService { + + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionCycleTestCaseFIXME.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionCycleTestCaseFIXME.java new file mode 100644 index 0000000000..ec5123eb2d --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionCycleTestCaseFIXME.java @@ -0,0 +1,121 @@ +/* + * 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 test; + +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.URL; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +import junit.framework.TestCase; + +/** + * Test multiple contributions scenario + * + * FIXME This test case causes a StackOverflowException instead of + * reporting an error when a composite is not found, as there's a + * dependency cycle in the test contributions and the model resolvers + * do not handle import cycles properly. + * + */ +public class ContributionCycleTestCaseFIXME extends TestCase { + + private String helloContribution_dir = "target/test-classes/contribution-cycle-export"; + private String helloWorldContribution_one_dir = "target/test-classes/contribution-cycle-import"; + + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution helloContribution; + private Contribution helloWorldContribution_one; + + protected void setUp() throws Exception { + URL helloContribution_URL = new java.io.File(helloContribution_dir).toURI().toURL(); + URL helloWorldContribution_one_URL = new java.io.File(helloWorldContribution_one_dir).toURI().toURL(); + + // Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + // Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + helloContribution = + contributionService.contribute("http://contribution-multiple/helloworld", helloContribution_URL, false); + + for (Composite deployable : helloContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + for (Composite deployable : helloContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + + helloWorldContribution_one = + contributionService.contribute("http://contribution-multiple/helloworld_one", helloWorldContribution_one_URL, false); + for (Composite deployable : helloWorldContribution_one.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + for (Composite deployable : helloWorldContribution_one.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + + } + + public void testServiceCall() throws IOException { + HelloWorldService helloWorldService_one = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent_one/HelloWorldService"); + assertNotNull(helloWorldService_one); + + assertEquals("Hello Smith", helloWorldService_one.getGreetings("Smith")); + + } + + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://contribution-multiple/helloworld"); + contributionService.remove("http://contribution-multiple/helloworld_one"); + + // Stop Components from my composite + for (Composite deployable : helloWorldContribution_one.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + for (Composite deployable : helloContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + // domain.stop(); + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionMultipleTestCaseFIXME.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionMultipleTestCaseFIXME.java new file mode 100644 index 0000000000..133c98f357 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionMultipleTestCaseFIXME.java @@ -0,0 +1,131 @@ +/* + * 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 test; + +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.URL; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +import junit.framework.TestCase; + +/** + * Test multiple contribution scenario + * Contributed by TUSCANY-1718 + */ +public class ContributionMultipleTestCaseFIXME extends TestCase { + + private String helloContribution_dir = "target/test-classes/contribution-export"; + private String helloWorldContribution_one_dir = "target/test-classes/contribution-import-one"; + private String helloWorldContribution_two_dir = "target/test-classes/contribution-import-two"; + + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution helloContribution; + private Contribution helloWorldContribution_one; + private Contribution helloWorldContribution_two; + + protected void setUp() throws Exception { + URL helloContribution_URL = new java.io.File(helloContribution_dir).toURI().toURL(); + URL helloWorldContribution_one_URL = new java.io.File(helloWorldContribution_one_dir).toURI().toURL(); + URL helloWorldContribution_two_URL = new java.io.File(helloWorldContribution_two_dir).toURI().toURL(); + + // Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + // Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + helloContribution = + contributionService.contribute("http://contribution-multiple/helloworld", helloContribution_URL, false); + + helloWorldContribution_one = + contributionService.contribute("http://contribution-multiple/helloworld_one", helloWorldContribution_one_URL, false); + + helloWorldContribution_two = + contributionService.contribute("http://contribution-multiple/helloworld_two", helloWorldContribution_two_URL, false); + + for (Composite deployable : helloContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + } + + for (Composite deployable : helloWorldContribution_one.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + } + + for (Composite deployable : helloWorldContribution_two.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + } + + domain.buildComposite(domain.getDomainComposite()); + domain.getCompositeActivator().activate(domain.getDomainComposite()); + domain.getCompositeActivator().start(domain.getDomainComposite()); + + } + + public void testServiceCall() throws IOException { + HelloWorldService helloWorldService_one = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent_one/HelloWorldService"); + assertNotNull(helloWorldService_one); + + assertEquals("Hello Smith", helloWorldService_one.getGreetings("Smith")); + + HelloWorldService helloWorldService_two = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent_two/HelloWorldService"); + assertNotNull(helloWorldService_two); + + assertEquals("Hello Smith", helloWorldService_two.getGreetings("Smith")); + + } + + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://contribution-multiple/helloworld"); + contributionService.remove("http://contribution-multiple/helloworld_one"); + contributionService.remove("http://contribution-multiple/helloworld_two"); + + // Stop Components from my composite + for (Composite deployable : helloWorldContribution_two.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + for (Composite deployable : helloWorldContribution_one.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + for (Composite deployable : helloContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + // domain.stop(); + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionTestCase.java b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionTestCase.java new file mode 100644 index 0000000000..790b6fed98 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/java/test/ContributionTestCase.java @@ -0,0 +1,145 @@ +/* + * 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 test; + +import helloworld.HelloWorldService; + +import java.io.IOException; +import java.net.URL; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +import junit.framework.TestCase; + +/** + * Test multiple contribution scenario + * Contributed by TUSCANY-1756 + */ +public class ContributionTestCase extends TestCase { + + private String helloContribution_dir = "target/test-classes/contribution-export"; + //private String helloWorldContribution_one_dir = "target/test-classes/contribution-import-one"; + private String helloWorldContribution_two_dir = "target/test-classes/contribution-import-two"; + + private ClassLoader cl; + private EmbeddedSCADomain domain; + private Contribution helloContribution; + //private Contribution helloWorldContribution_one; + private Contribution helloWorldContribution_two; + + protected void setUp() throws Exception { + URL helloContribution_URL = new java.io.File(helloContribution_dir).toURI().toURL(); + //URL helloWorldContribution_one_URL = new java.io.File(helloWorldContribution_one_dir).toURI().toURL(); + URL helloWorldContribution_two_URL = new java.io.File(helloWorldContribution_two_dir).toURI().toURL(); + + // Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + // Start the domain + domain.start(); + + // Contribute the SCA contribution + ContributionService contributionService = domain.getContributionService(); + + helloContribution = + contributionService.contribute("http://contribution-multiple/helloworld", helloContribution_URL, false); + + //helloWorldContribution_one = + // contributionService.contribute("http://contribution-multiple/helloworld_one", helloWorldContribution_one_URL, false); + + helloWorldContribution_two = + contributionService.contribute("http://contribution-multiple/helloworld_two", helloWorldContribution_two_URL, false); + + for (Composite deployable : helloContribution.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + //for (Composite deployable : helloWorldContribution_one.getDeployables()) { + // domain.getDomainComposite().getIncludes().add(deployable); + // domain.buildComposite(deployable); + //} + + for (Composite deployable : helloWorldContribution_two.getDeployables()) { + domain.getDomainComposite().getIncludes().add(deployable); + domain.buildComposite(deployable); + } + + for (Composite deployable : helloContribution.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + + //for (Composite deployable : helloWorldContribution_one.getDeployables()) { + // domain.getCompositeActivator().activate(deployable); + // domain.getCompositeActivator().start(deployable); + //} + + for (Composite deployable : helloWorldContribution_two.getDeployables()) { + domain.getCompositeActivator().activate(deployable); + domain.getCompositeActivator().start(deployable); + } + + } + + public void testServiceCall() throws IOException { + //HelloWorldService helloWorldService_one = + //domain.getService(HelloWorldService.class, "HelloWorldServiceComponent_one/HelloWorldService"); + //assertNotNull(helloWorldService_one); + + //assertEquals("Hello Smith", helloWorldService_one.getGreetings("Smith")); + + HelloWorldService helloWorldService_two = + domain.getService(HelloWorldService.class, "HelloWorldServiceComponent_two/HelloWorldService"); + assertNotNull(helloWorldService_two); + + assertEquals("Hello Smith", helloWorldService_two.getGreetings("Smith")); + + } + + public void tearDown() throws Exception { + ContributionService contributionService = domain.getContributionService(); + + // Remove the contribution from the in-memory repository + contributionService.remove("http://contribution-multiple/helloworld"); + //contributionService.remove("http://contribution-multiple/helloworld_one"); + contributionService.remove("http://contribution-multiple/helloworld_two"); + + // Stop Components from my composite + for (Composite deployable : helloWorldContribution_two.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + //for (Composite deployable : helloWorldContribution_one.getDeployables()) { + // domain.getCompositeActivator().stop(deployable); + // domain.getCompositeActivator().deactivate(deployable); + //} + for (Composite deployable : helloContribution.getDeployables()) { + domain.getCompositeActivator().stop(deployable); + domain.getCompositeActivator().deactivate(deployable); + } + // domain.stop(); + domain.close(); + } + +} diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..8b76783c3d --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/META-INF/sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/hello.composite b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/hello.composite new file mode 100644 index 0000000000..aeeab337fa --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-export/hello.composite @@ -0,0 +1,31 @@ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..bfbf74373a --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/META-INF/sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/helloworld_one.composite b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/helloworld_one.composite new file mode 100644 index 0000000000..7a8003577e --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-cycle-import/helloworld_one.composite @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..bea6f39932 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/META-INF/sca-contribution.xml @@ -0,0 +1,25 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/hello.composite b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/hello.composite new file mode 100644 index 0000000000..aeeab337fa --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-export/hello.composite @@ -0,0 +1,31 @@ + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..bfbf74373a --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/META-INF/sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/helloworld_one.composite b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/helloworld_one.composite new file mode 100644 index 0000000000..45cb504ea4 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-one/helloworld_one.composite @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/META-INF/sca-contribution.xml b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..cbabdcd4fc --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/META-INF/sca-contribution.xml @@ -0,0 +1,26 @@ + + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/helloworld_two.composite b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/helloworld_two.composite new file mode 100644 index 0000000000..4c9225de34 --- /dev/null +++ b/java/sca/contrib/itest/contribution-multiple/src/test/resources/contribution-import-two/helloworld_two.composite @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution/pom.xml b/java/sca/contrib/itest/contribution/pom.xml new file mode 100644 index 0000000000..1fe5207ad5 --- /dev/null +++ b/java/sca/contrib/itest/contribution/pom.xml @@ -0,0 +1,52 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-contribution + Apache Tuscany SCA Contribution Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-contribution-impl + 2.0-SNAPSHOT + + + + diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/AddService.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/AddService.java new file mode 100644 index 0000000000..4e72f92fda --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/AddService.java @@ -0,0 +1,32 @@ +/* + * 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 calculator; + +/** + * It is an Interface which has method declarations. Methods which are to be accessed as a service are declared in this + * interface. Implementation for these methods is provided in AddServiceImpl Class + */ +public interface AddService { + + /** + * This is an add method which takes 2 parameters of double type and returns the sum of two parameters + */ + double add(double n1, double n2); + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/AddServiceImpl.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/AddServiceImpl.java new file mode 100644 index 0000000000..e9c635e3c8 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/AddServiceImpl.java @@ -0,0 +1,30 @@ +/* + * 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 calculator; + +/** + * An implementation of the Add service + */ +public class AddServiceImpl implements AddService { + + public double add(double n1, double n2) { + return n1 + n2; + } + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorClient.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorClient.java new file mode 100644 index 0000000000..719ad69eef --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorClient.java @@ -0,0 +1,46 @@ +/* + * 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 calculator; + +import org.apache.tuscany.sca.host.embedded.SCADomain; + +/** + * This client program shows how to create an SCA runtime, start it, + * and locate and invoke a SCA component + */ +public class CalculatorClient { + public static void main(String[] args) throws Exception { + + SCADomain domain = SCADomain.newInstance("calculator/Calculator.composite"); + + CalculatorService calculatorService = domain.getService(CalculatorService.class, + "CalculatorServiceComponent"); + + // Calculate + System.out.println("3 + 2=" + calculatorService.add(3, 2)); + System.out.println("3 - 2=" + calculatorService.subtract(3, 2)); + System.out.println("3 * 2=" + calculatorService.multiply(3, 2)); + System.out.println("3 / 2=" + calculatorService.divide(3, 2)); + + domain.close(); + + } + +} \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorService.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorService.java new file mode 100644 index 0000000000..f288af0174 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorService.java @@ -0,0 +1,35 @@ +/* + * 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 calculator; + +/** + * This is a Calculator service interface. All the methods which are to be accessed as a service are declared in this + * interface but not the implementation of those methods. + */ +public interface CalculatorService { + + double add(double n1, double n2); + + double subtract(double n1, double n2); + + double multiply(double n1, double n2); + + double divide(double n1, double n2); + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorServiceImpl.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorServiceImpl.java new file mode 100644 index 0000000000..d3fa7a8f41 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/CalculatorServiceImpl.java @@ -0,0 +1,70 @@ +/* + * 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 calculator; + +import org.oasisopen.sca.annotation.Reference; + + +/** + * An implementation of the Calculator service. + */ +public class CalculatorServiceImpl implements CalculatorService { + + private AddService addService; + private SubtractService subtractService; + private MultiplyService multiplyService; + private DivideService divideService; + + @Reference + public void setAddService(AddService addService) { + this.addService = addService; + } + + @Reference + public void setSubtractService(SubtractService subtractService) { + this.subtractService = subtractService; + } + + @Reference + public void setDivideService(DivideService divideService) { + this.divideService = divideService; + } + + @Reference + public void setMultiplyService(MultiplyService multiplyService) { + this.multiplyService = multiplyService; + } + + public double add(double n1, double n2) { + return addService.add(n1, n2); + } + + public double subtract(double n1, double n2) { + return subtractService.subtract(n1, n2); + } + + public double multiply(double n1, double n2) { + return multiplyService.multiply(n1, n2); + } + + public double divide(double n1, double n2) { + return divideService.divide(n1, n2); + } + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideService.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideService.java new file mode 100644 index 0000000000..ad99418f5b --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideService.java @@ -0,0 +1,32 @@ +/* + * 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 calculator; + +/** + * This is an interface for Divide Service which has divide method declared which is implemented in DivideServiceImpl + * class + */ +public interface DivideService { + + /** + * This is a divide method which takes 2 parameters of double type and returns the result of division + */ + double divide(double n1, double n2); + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideServiceImpl.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideServiceImpl.java new file mode 100644 index 0000000000..8c33862f6d --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/DivideServiceImpl.java @@ -0,0 +1,30 @@ +/* + * 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 calculator; + +/** + * An implementation of the Divide service. + */ +public class DivideServiceImpl implements DivideService { + + public double divide(double n1, double n2) { + return n1 / n2; + } + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyService.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyService.java new file mode 100644 index 0000000000..3987b0a54f --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyService.java @@ -0,0 +1,33 @@ +/* + * 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 calculator; + +/** + * This is an interface for Multiply Service which has multiply method declared which is implemented in + * MultiplyServiceImpl class + */ +public interface MultiplyService { + + /** + * This is a multiply method which takes 2 parameters of double type and returns the result of multiplication of the + * two parameters + */ + double multiply(double n1, double n2); + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyServiceImpl.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyServiceImpl.java new file mode 100644 index 0000000000..c7fbc73c00 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/MultiplyServiceImpl.java @@ -0,0 +1,30 @@ +/* + * 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 calculator; + +/** + * An implementation of the Multiply service. + */ +public class MultiplyServiceImpl implements MultiplyService { + + public double multiply(double n1, double n2) { + return n1 * n2; + } + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractService.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractService.java new file mode 100644 index 0000000000..25e0ed6ca7 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractService.java @@ -0,0 +1,33 @@ +/* + * 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 calculator; + +/** + * This is an interface for Subtract Service which has subtract method declared which is implemented in + * SubtractServiceImpl class + */ + +public interface SubtractService { + + /** + * This is a subtract method which takes 2 parameters of double type and returns the result of subtraction. + */ + double subtract(double n1, double n2); + +} diff --git a/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractServiceImpl.java b/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractServiceImpl.java new file mode 100644 index 0000000000..1a7f145ad8 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/java/calculator/SubtractServiceImpl.java @@ -0,0 +1,30 @@ +/* + * 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 calculator; + +/** + * An implementation of the subtract service. + */ +public class SubtractServiceImpl implements SubtractService { + + public double subtract(double n1, double n2) { + return n1 - n2; + } + +} diff --git a/java/sca/contrib/itest/contribution/src/main/resources/ContributionTest.composite b/java/sca/contrib/itest/contribution/src/main/resources/ContributionTest.composite new file mode 100644 index 0000000000..d814e439e2 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/resources/ContributionTest.composite @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/contribution/src/main/resources/calculator/Calculator.composite b/java/sca/contrib/itest/contribution/src/main/resources/calculator/Calculator.composite new file mode 100644 index 0000000000..657a2f95d8 --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/resources/calculator/Calculator.composite @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/contribution/src/main/resources/calculator/sca-contribution.xml b/java/sca/contrib/itest/contribution/src/main/resources/calculator/sca-contribution.xml new file mode 100644 index 0000000000..e95796d83a --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/main/resources/calculator/sca-contribution.xml @@ -0,0 +1,24 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/contribution/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionServiceTestCase.java b/java/sca/contrib/itest/contribution/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionServiceTestCase.java new file mode 100644 index 0000000000..97b2e5d6ed --- /dev/null +++ b/java/sca/contrib/itest/contribution/src/test/java/org/apache/tuscany/sca/test/contribution/ContributionServiceTestCase.java @@ -0,0 +1,218 @@ +/* + * 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.test.contribution; + +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.net.URL; +import java.security.AccessController; +import java.security.PrivilegedAction; +import java.security.PrivilegedActionException; +import java.security.PrivilegedExceptionAction; +import java.util.List; + +import javax.xml.namespace.QName; + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.assembly.Composite; +import org.apache.tuscany.sca.assembly.DefaultAssemblyFactory; +import org.apache.tuscany.sca.contribution.Artifact; +import org.apache.tuscany.sca.contribution.Contribution; +import org.apache.tuscany.sca.contribution.service.ContributionService; +import org.apache.tuscany.sca.contribution.service.util.FileHelper; +import org.apache.tuscany.sca.contribution.service.util.IOHelper; +import org.apache.tuscany.sca.host.embedded.impl.EmbeddedSCADomain; + +/** + * This is more intended to be a integration test then a unit test. * + */ +public class ContributionServiceTestCase extends TestCase { + private static final String CONTRIBUTION_001_ID = "contribution001/"; + private static final String CONTRIBUTION_002_ID = "contribution002/"; + private static final String JAR_CONTRIBUTION = "/repository/sample-calculator.jar"; + private static final String FOLDER_CONTRIBUTION = "target/classes/"; + + private ClassLoader cl; + private EmbeddedSCADomain domain; + private ContributionService contributionService; + + /** + * setUp() is a method in JUnit Frame Work which is executed before all others methods in the class extending + * unit.framework.TestCase. So this method is used to create a test Embedded SCA Domain, to start the SCA Domain and + * to get a reference to the contribution service + */ + + @Override + protected void setUp() throws Exception { + //Create a test embedded SCA domain + cl = getClass().getClassLoader(); + domain = new EmbeddedSCADomain(cl, "http://localhost"); + + //Start the domain + domain.start(); + + //get a reference to the contribution service + contributionService = domain.getContributionService(); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contrututionId with the value retrieved from the SCA runtime. + */ + public void testContributeJAR() throws Exception { + URL contributionLocation = getClass().getResource(JAR_CONTRIBUTION); + //URL contributionLocation = new URL("file:/D:/dev/Opensource/Apache/Tuscany/source/java/sca/samples/calculator/target/sample-calculator.jar"); + String contributionId = CONTRIBUTION_001_ID; + contributionService.contribute(contributionId, contributionLocation, false); + assertNotNull(contributionService.getContribution(contributionId)); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contrututionId with the value retrieved from the SCA runtime using + * contributionService. + */ + public void testStoreContributionPackageInRepository() throws Exception { + URL contributionLocation = getClass().getResource(JAR_CONTRIBUTION); + String contributionId = CONTRIBUTION_001_ID; + contributionService.contribute(contributionId, contributionLocation, true); + + assertTrue(FileHelper.toFile(new URL(contributionService.getContribution(contributionId).getLocation())) + .exists()); + + assertNotNull(contributionId); + + Contribution contributionModel = contributionService.getContribution(contributionId); + + File contributionFile = FileHelper.toFile(new URL(contributionModel.getLocation())); + assertTrue(contributionFile.exists()); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contrututionId with the value retrieved from the SCA runtime using + * contributionService. + */ + public void testStoreContributionStreamInRepository() throws Exception { + URL contributionLocation = getClass().getResource(JAR_CONTRIBUTION); + String contributionId = CONTRIBUTION_001_ID; + + InputStream contributionStream = contributionLocation.openStream(); + try { + contributionService.contribute(contributionId, contributionLocation, contributionStream); + } finally { + IOHelper.closeQuietly(contributionStream); + } + + assertTrue(FileHelper.toFile(new URL(contributionService.getContribution(contributionId).getLocation())) + .exists()); + + assertNotNull(contributionId); + + Contribution contributionModel = contributionService.getContribution(contributionId); + + File contributionFile = FileHelper.toFile(new URL(contributionModel.getLocation())); + assertTrue(contributionFile.exists()); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contributionId1,contributionId2 with the value retrieved from the SCA + * runtime using contributionService. + */ + public void testStoreDuplicatedContributionInRepository() throws Exception { + URL contributionLocation = getClass().getResource(JAR_CONTRIBUTION); + String contributionId1 = CONTRIBUTION_001_ID; + contributionService.contribute(contributionId1, contributionLocation, true); + assertNotNull(contributionService.getContribution(contributionId1)); + String contributionId2 = CONTRIBUTION_002_ID; + contributionService.contribute(contributionId2, contributionLocation, true); + assertNotNull(contributionService.getContribution(contributionId2)); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contributionId with the value retrieved from the SCA runtime using + * contributionService. + */ + public void testContributeFolder() throws Exception { + final File rootContributionFolder = new File(FOLDER_CONTRIBUTION); + String contributionId = CONTRIBUTION_001_ID; + //first rename the sca-contribution metadata file + //File calculatorMetadataFile = new File("target/classes/calculator/sca-contribution.xml"); + //File metadataDirectory = new File("target/classes/META-INF/"); + //if (!metadataDirectory.exists()) { + // FileHelper.forceMkdir(metadataDirectory); + //} + //FileHelper.copyFileToDirectory(calculatorMetadataFile, metadataDirectory); + + // Requires permission to read user.dir property. Requires PropertyPermision in security policy. + URL contributionFolderURL; + try { + contributionFolderURL = AccessController.doPrivileged(new PrivilegedExceptionAction() { + public URL run() throws IOException { + return rootContributionFolder.toURL(); + } + }); + } catch (PrivilegedActionException e) { + throw (IOException)e.getException(); + } + contributionService.contribute(contributionId, contributionFolderURL, false); + assertNotNull(contributionService.getContribution(contributionId)); + } + + /** + * Method prefixed with 'test' is a test method where testing logic is written using various assert methods. This + * test verifies the string assigned to contributionId, artifactId with the value retrieved from the SCA runtime + * using contributionService. + */ + public void testAddDeploymentComposites() throws Exception { + URL contributionLocation = getClass().getResource(JAR_CONTRIBUTION); + String contributionId = CONTRIBUTION_001_ID; + Contribution contribution = contributionService.contribute(contributionId, contributionLocation, false); + assertNotNull(contributionService.getContribution(contributionId)); + + String artifactId = "contributionComposite.composite"; + Composite composite = (new DefaultAssemblyFactory()).createComposite(); + composite.setName(new QName(null, "contributionComposite")); + composite.setURI("contributionComposite.composite"); + + contributionService.addDeploymentComposite(contribution, composite); + + List deployables = contributionService.getContribution(contributionId).getDeployables(); + Composite composite1 = (Composite)deployables.get(deployables.size() - 1); + assertEquals("contributionComposite", composite1.getName().toString()); + + Artifact artifact = null; + contribution = contributionService.getContribution(contributionId); + String id = artifactId.toString(); + for (Artifact a : contribution.getArtifacts()) { + if (id.equals(a.getURI())) { + artifact = a; + break; + } + } + Composite composite2 = (Composite)artifact.getModel(); + assertEquals("contributionComposite", composite2.getName().toString()); + } + +} diff --git a/java/sca/contrib/itest/contribution/src/test/resources/deployables/sample-calculator.jar b/java/sca/contrib/itest/contribution/src/test/resources/deployables/sample-calculator.jar new file mode 100644 index 0000000000..0ca3a1b781 Binary files /dev/null and b/java/sca/contrib/itest/contribution/src/test/resources/deployables/sample-calculator.jar differ diff --git a/java/sca/contrib/itest/contribution/src/test/resources/repository/sample-calculator.jar b/java/sca/contrib/itest/contribution/src/test/resources/repository/sample-calculator.jar new file mode 100644 index 0000000000..0ca3a1b781 Binary files /dev/null and b/java/sca/contrib/itest/contribution/src/test/resources/repository/sample-calculator.jar differ diff --git a/java/sca/contrib/itest/conversations-ws/pom.xml b/java/sca/contrib/itest/conversations-ws/pom.xml new file mode 100644 index 0000000000..2789d3eee7 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/pom.xml @@ -0,0 +1,60 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-conversations-ws + Apache Tuscany SCA Conversations Over binding.ws Integration Tests + + + + + + org.apache.tuscany.sca + tuscany-node-impl + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/BusinessException.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/BusinessException.java new file mode 100644 index 0000000000..9cd88620e3 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/BusinessException.java @@ -0,0 +1,41 @@ +/* + * 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.itest.conversational; + +public class BusinessException extends Exception { + + private String message; + + public BusinessException() { + super(); + } + + public BusinessException(String message) { + super(message); + setMessage(message); + } + + public String getMessage() { + return message; + } + + public void setMessage(String message) { + this.message = message; + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationIdService.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationIdService.java new file mode 100644 index 0000000000..b6c694c8a9 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationIdService.java @@ -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.tuscany.sca.itest.conversational; + +import org.oasisopen.sca.annotation.Conversational; + +@Conversational +public interface ConversationIdService { + + String getCIDField(); + String getCIDSetter(); +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalCallback.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalCallback.java new file mode 100644 index 0000000000..b6645aec23 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalCallback.java @@ -0,0 +1,50 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.annotation.Conversational; +import org.oasisopen.sca.annotation.EndsConversation; +import org.oasisopen.sca.annotation.Remotable; + + +/** + * The callback interface used when testing conversational callbacks + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Remotable +@Conversational +public interface ConversationalCallback { + + // public void init(); + + // public void destroy(); + + public void initializeCount(int count); + + public void incrementCount(); + + public int retrieveCount(); + + public void businessException() throws BusinessException; + + @EndsConversation + public String endConversation(); + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalClient.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalClient.java new file mode 100644 index 0000000000..772602568c --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalClient.java @@ -0,0 +1,50 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The client for the conversational itest. Is implemented by clients + * offering both stateless and stateful callbacks + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Remotable +public interface ConversationalClient { + + public int runConversationFromInjectedReference(); + public int runConversationFromInjectedReference2(); + public int runConversationFromServiceReference(); + public int runConversationWithUserDefinedConversationId(); + public String runConversationCheckUserDefinedConversationId(); + public int runConversationCheckingScope(); + public int runConversationWithCallback(); + public int runConversationHavingPassedReference(); + public String runConversationBusinessException(); + public String runConversationBusinessExceptionCallback(); + public int runConversationCallingEndedConversation(); + public int runConversationCallingEndedConversationCallback(); + public String runConversationCallingEndedConversationCheckConversationId(); + public String runConversationCallingEndedConversationCallbackCheckConversationId(); + public int runConversationAgeTimeout(); + public int runConversationIdleTimeout(); + public int runConversationPrincipleError(); +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalReferenceClient.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalReferenceClient.java new file mode 100644 index 0000000000..481ed7b388 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalReferenceClient.java @@ -0,0 +1,36 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Remotable; + +/** + * The client that calls into an existing conversation by accepting + * a reference to that conversation + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Remotable +public interface ConversationalReferenceClient { + + public void incrementCount(CallableReference conversationalService); + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalService.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalService.java new file mode 100644 index 0000000000..c9d46b9072 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalService.java @@ -0,0 +1,58 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.Conversational; +import org.oasisopen.sca.annotation.EndsConversation; +import org.oasisopen.sca.annotation.Remotable; + + +/** + * The service interface used when testing conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Remotable +@Conversational +@Callback(ConversationalCallback.class) +public interface ConversationalService { + + public void initializeCount(int count); + + public void incrementCount(); + + public int retrieveCount(); + + //public void businessException() throws BusinessException; + + public void initializeCountCallback(int count); + + public void incrementCountCallback(); + + public int retrieveCountCallback(); + + //public void businessExceptionCallback() throws BusinessException; + + @EndsConversation + public String endConversation(); + + public String endConversationCallback(); + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalServiceNonConversationalCallback.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalServiceNonConversationalCallback.java new file mode 100644 index 0000000000..b46cb831df --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/ConversationalServiceNonConversationalCallback.java @@ -0,0 +1,59 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.Conversational; +import org.oasisopen.sca.annotation.EndsConversation; +import org.oasisopen.sca.annotation.Remotable; + + +/** + * The service interface used when testing conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Remotable +@Conversational +@Callback(NonConversationalCallback.class) +public interface ConversationalServiceNonConversationalCallback { + + + public void initializeCount(int count); + + public void incrementCount(); + + public int retrieveCount(); + + public void businessException() throws BusinessException; + + public void initializeCountCallback(int count); + + public void incrementCountCallback(); + + public int retrieveCountCallback(); + + public void businessExceptionCallback() throws BusinessException; + + @EndsConversation + public String endConversation(); + + public String endConversationCallback(); + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallback.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallback.java new file mode 100644 index 0000000000..4c3809676c --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallback.java @@ -0,0 +1,42 @@ +/* + * 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.itest.conversational; + +import org.oasisopen.sca.annotation.Remotable; + + +/** + * The callback interface used when testing conversational callbacks + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Remotable +public interface NonConversationalCallback { + + public void initializeCount(int count); + + public void incrementCount(); + + public int retrieveCount(); + + public void businessException() throws BusinessException; + + public String endConversation(); + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationAgeComponentImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationAgeComponentImpl.java new file mode 100644 index 0000000000..2d048a76b5 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationAgeComponentImpl.java @@ -0,0 +1,76 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(ConversationalService.class) +@Scope("CONVERSATION") +@ConversationAttributes(maxAge="1 seconds") +public class ConversationAgeComponentImpl implements ConversationalService { + + private int count; + + public void businessException() throws BusinessException { + } + + public void businessExceptionCallback() throws BusinessException { + } + + public void destroy() { + } + + public String endConversation() { + return null; + } + + public String endConversationCallback() { + return null; + } + + public void incrementCount() { + } + + public void incrementCountCallback() { + } + + public void init() { + } + + public void initializeCount(int count) { + this.count = count; + } + + public void initializeCountCallback(int count) { + } + + public int retrieveCount() { + return count; + } + + public int retrieveCountCallback() { + return 0; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationIdComponentImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationIdComponentImpl.java new file mode 100644 index 0000000000..34b8fbe9d0 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationIdComponentImpl.java @@ -0,0 +1,48 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.ConversationIdService; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(ConversationIdService.class) +@Scope("CONVERSATION") +public class ConversationIdComponentImpl implements ConversationIdService { + + @ConversationID + public String cid; + + private String setterCid; + + public String getCIDField() { + return cid; + } + public String getCIDSetter() { + return setterCid; + } + + + @ConversationID + public void setCID(String cid) { + this.setterCid = cid; + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationMaxIdleComponentImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationMaxIdleComponentImpl.java new file mode 100644 index 0000000000..0d3ca8d350 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationMaxIdleComponentImpl.java @@ -0,0 +1,76 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +@Service(ConversationalService.class) +@Scope("CONVERSATION") +@ConversationAttributes(maxIdleTime="1 seconds") +public class ConversationMaxIdleComponentImpl implements ConversationalService { + + private int count; + + public void businessException() throws BusinessException { + } + + public void businessExceptionCallback() throws BusinessException { + } + + public void destroy() { + } + + public String endConversation() { + return null; + } + + public String endConversationCallback() { + return null; + } + + public void incrementCount() { + } + + public void incrementCountCallback() { + } + + public void init() { + } + + public void initializeCount(int count) { + this.count = count; + } + + public void initializeCountCallback(int count) { + } + + public int retrieveCount() { + return count; + } + + public int retrieveCountCallback() { + return 0; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulImpl.java new file mode 100644 index 0000000000..db3bcabe02 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulImpl.java @@ -0,0 +1,322 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.ConversationalClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalReferenceClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +/** + * The client for the conversational itest which presents a stateful + * callback interface + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Service(interfaces={ConversationalClient.class}) +@Scope("CONVERSATION") +@ConversationAttributes(maxAge="10 minutes", + maxIdleTime="5 minutes", + singlePrincipal=false) +public class ConversationalClientStatefulImpl implements ConversationalClient, ConversationalCallback { + + @Context + protected ComponentContext componentContext; + + @Reference + protected ConversationalService conversationalService; + + @Reference + protected ConversationalService conversationalService2; + + @Reference + protected ConversationalReferenceClient conversationalReferenceClient; + + private int clientCount = 0; + private int callbackCount = 0; + + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + // From ConversationalClient + public int runConversationFromInjectedReference(){ + calls.append("runConversationFromInjectedReference,"); + conversationalService.initializeCount(1); + conversationalService.incrementCount(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromInjectedReference2(){ + calls.append("runConversationFromInjectedReference2,"); + + conversationalService2.initializeCount(1); + conversationalService2.incrementCount(); + + // stick in a call to the first reference to + // make sure the two references don't clash + conversationalService.initializeCount(1); + + clientCount = conversationalService2.retrieveCount(); + conversationalService2.endConversation(); + + // end the conversation through the first reference + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromServiceReference(){ + calls.append("runConversationFromServiceReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public int runConversationWithUserDefinedConversationId(){ + calls.append("runConversationWithUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation1"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public String runConversationCheckUserDefinedConversationId(){ + calls.append("runConversationCheckUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation2"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + + String clientConversationId = serviceReference.getConversationID().toString(); + String serverConversationId = callableReference.endConversation(); + + if (clientConversationId.equals("MyConversation2") && + serverConversationId.equals("MyConversation2") ) { + return clientConversationId; + } else { + return "client = " + clientConversationId + + "server = " + serverConversationId; + } + + } + public int runConversationCheckingScope(){ + calls.append("runConversationCheckingScope,"); + // run a conversation + return runConversationFromInjectedReference(); + + // test will then use a static method to find out how many times + // init/destroy were called + } + public int runConversationWithCallback(){ + calls.append("runConversationWithCallback,"); + callbackCount = 2; + conversationalService.initializeCountCallback(1); + conversationalService.incrementCountCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + + return clientCount; + } + public int runConversationHavingPassedReference(){ + calls.append("runConversationHavingPassedReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + conversationalReferenceClient.incrementCount(serviceReference); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + serviceReference.getConversation().end(); + + return clientCount; + } + public String runConversationBusinessException(){ + calls.append("runConversationbusinessException,"); + try { + conversationalService.initializeCount(1); +// conversationalService.businessException(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public String runConversationBusinessExceptionCallback(){ + calls.append("runConversationbusinessExceptionCallback,"); + try { + conversationalService.initializeCountCallback(1); +// conversationalService.businessExceptionCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public int runConversationCallingEndedConversation(){ + calls.append("runConversationCallingEndedConversation,"); + conversationalService.initializeCount(1); + conversationalService.endConversation(); + return conversationalService.retrieveCount(); + } + + public int runConversationCallingEndedConversationCallback(){ + calls.append("runConversationCallingEndedConversationCallback,"); + conversationalService.initializeCountCallback(1); + conversationalService.endConversationCallback(); + return conversationalService.retrieveCountCallback(); + } + + public String runConversationCallingEndedConversationCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public String runConversationCallingEndedConversationCallbackCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCallbackCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversationCallback(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public int runConversationAgeTimeout(){ + calls.append("runConversationAgeTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationIdleTimeout(){ + calls.append("runConversationIdleTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationPrincipleError(){ + calls.append("runConversationPrincipleError,"); + // TODO - when policy framework is done + return clientCount; + } + + + // From ConversationalCallback + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + callbackCount += count; + } + + public void incrementCount(){ + calls.append("incrementCount,"); + callbackCount++; + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + return callbackCount; + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public String endConversation(){ + calls.append("endConversation,"); + callbackCount = 0; + return null; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulNonConversationalCallbackImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulNonConversationalCallbackImpl.java new file mode 100644 index 0000000000..e25f367cf6 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatefulNonConversationalCallbackImpl.java @@ -0,0 +1,311 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalReferenceClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.apache.tuscany.sca.itest.conversational.NonConversationalCallback; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + +/** + * The client for the conversational itest which presents a stateful + * callback interface + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Service(interfaces={ConversationalClient.class}) +@Scope("CONVERSATION") +@ConversationAttributes(maxAge="10 minutes", + maxIdleTime="5 minutes", + singlePrincipal=false) +public class ConversationalClientStatefulNonConversationalCallbackImpl implements ConversationalClient, NonConversationalCallback { + + @Context + protected ComponentContext componentContext; + + @Reference + protected ConversationalService conversationalService; + + @Reference + protected ConversationalService conversationalService2; + + @Reference + protected ConversationalReferenceClient conversationalReferenceClient; + + private int clientCount = 0; + private int callbackCount = 0; + + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + // From ConversationalClient + public int runConversationFromInjectedReference(){ + calls.append("runConversationFromInjectedReference,"); + conversationalService.initializeCount(1); + conversationalService.incrementCount(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromInjectedReference2(){ + calls.append("runConversationFromInjectedReference2,"); + + conversationalService2.initializeCount(1); + conversationalService2.incrementCount(); + + // stick in a call to the first reference to + // make sure the two references don't clash + conversationalService.initializeCount(1); + + clientCount = conversationalService2.retrieveCount(); + conversationalService2.endConversation(); + + // end the conversation through the first reference + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromServiceReference(){ + calls.append("runConversationFromServiceReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public int runConversationWithUserDefinedConversationId(){ + calls.append("runConversationWithUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation1"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public String runConversationCheckUserDefinedConversationId(){ + calls.append("runConversationCheckUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation2"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + return callableReference.endConversation(); + + } + public int runConversationCheckingScope(){ + calls.append("runConversationCheckingScope,"); + // run a conversation + return runConversationFromInjectedReference(); + + // test will then use a static method to find out how many times + // init/destroy were called + } + public int runConversationWithCallback(){ + calls.append("runConversationWithCallback,"); + callbackCount = 2; + conversationalService.initializeCountCallback(1); + conversationalService.incrementCountCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + + return clientCount; + } + public int runConversationHavingPassedReference(){ + calls.append("runConversationHavingPassedReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + conversationalReferenceClient.incrementCount(serviceReference); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public String runConversationBusinessException(){ + calls.append("runConversationbusinessException,"); + try { + conversationalService.initializeCount(1); +// conversationalService.businessException(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public String runConversationBusinessExceptionCallback(){ + calls.append("runConversationbusinessExceptionCallback,"); + try { + conversationalService.initializeCountCallback(1); +// conversationalService.businessExceptionCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public String runConversationCallingEndedConversationCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public String runConversationCallingEndedConversationCallbackCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCallbackCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversationCallback(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public int runConversationCallingEndedConversation(){ + calls.append("runConversationCallingEndedConversation,"); + conversationalService.initializeCount(1); + conversationalService.endConversation(); + return conversationalService.retrieveCount(); + } + + public int runConversationCallingEndedConversationCallback(){ + calls.append("runConversationCallingEndedConversationCallback,"); + conversationalService.initializeCountCallback(1); + conversationalService.endConversationCallback(); + return conversationalService.retrieveCountCallback(); + } + + public int runConversationAgeTimeout(){ + calls.append("runConversationAgeTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationIdleTimeout(){ + calls.append("runConversationIdleTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationPrincipleError(){ + calls.append("runConversationPrincipleError,"); + // TODO - when policy framework is done + return clientCount; + } + + + // From ConversationalCallback + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + callbackCount += count; + } + + public void incrementCount(){ + calls.append("incrementCount,"); + callbackCount++; + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + return callbackCount; + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public String endConversation(){ + calls.append("endConversation,"); + return null; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatelessImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatelessImpl.java new file mode 100644 index 0000000000..3ac259ed7c --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalClientStatelessImpl.java @@ -0,0 +1,318 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.ConversationalClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalReferenceClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; +import org.oasisopen.sca.annotation.Context; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * The client for the conversational itest which presents a stateful + * callback interface + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Service(interfaces={ConversationalClient.class}) +public class ConversationalClientStatelessImpl implements ConversationalClient, ConversationalCallback { + + @Context + protected ComponentContext componentContext; + + @Reference + protected ConversationalService conversationalService; + + @Reference + protected ConversationalService conversationalService2; + + @Reference + protected ConversationalReferenceClient conversationalReferenceClient; + + private int clientCount = 0; + private int callbackCount = 0; + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + // From ConversationalClient + public int runConversationFromInjectedReference(){ + calls.append("runConversationFromInjectedReference,"); + conversationalService.initializeCount(1); + conversationalService.incrementCount(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromInjectedReference2(){ + calls.append("runConversationFromInjectedReference2,"); + + // now test the second reference + conversationalService2.initializeCount(1); + conversationalService2.incrementCount(); + + // stick in a call to the first reference to + // make sure the two references don't clash + conversationalService.initializeCount(1); + + clientCount = conversationalService2.retrieveCount(); + conversationalService2.endConversation(); + + // end the conversation through the first reference + conversationalService.endConversation(); + + return clientCount; + } + public int runConversationFromServiceReference(){ + calls.append("runConversationFromServiceReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public int runConversationWithUserDefinedConversationId(){ + calls.append("runConversationWithUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation1"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + // serviceReference.getConversation().end(); + + return clientCount; + } + public String runConversationCheckUserDefinedConversationId(){ + calls.append("runConversationCheckUserDefinedConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation2"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + + String clientConversationId = serviceReference.getConversationID().toString(); + String serverConfersationId = callableReference.endConversation(); + + if (clientConversationId.equals("MyConversation2") && + serverConfersationId.equals("MyConversation2") ) { + return clientConversationId; + } else { + return "client = " + clientConversationId + + "server = " + serverConfersationId; + } + } + public int runConversationCheckingScope(){ + calls.append("runConversationCheckingScope,"); + // run a conversation + return runConversationFromInjectedReference(); + + // test will then use a static method to find out how many times + // init/destroy were called + } + public int runConversationWithCallback(){ + calls.append("runConversationWithCallback,"); + conversationalService.initializeCountCallback(1); + conversationalService.incrementCountCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + + return clientCount; + } + + public int runConversationHavingPassedReference(){ + calls.append("runConversationHavingPassedReference,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + conversationalReferenceClient.incrementCount(serviceReference); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + serviceReference.getConversation().end(); + + return clientCount; + } + + public String runConversationBusinessException(){ + calls.append("runConversationbusinessException,"); + try { + conversationalService.initializeCount(1); +// conversationalService.businessException(); + clientCount = conversationalService.retrieveCount(); + conversationalService.endConversation(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public String runConversationBusinessExceptionCallback(){ + calls.append("runConversationbusinessExceptionCallback,"); + try { + conversationalService.initializeCountCallback(1); +// conversationalService.businessExceptionCallback(); + clientCount = conversationalService.retrieveCountCallback(); + conversationalService.endConversationCallback(); + } catch(Exception ex) { + return ex.getMessage(); + } + + return "No Exception Returned"; + } + + public int runConversationCallingEndedConversation(){ + calls.append("runConversationCallingEndedConversation,"); + conversationalService.initializeCount(1); + conversationalService.endConversation(); + return conversationalService.retrieveCount(); + } + + public int runConversationCallingEndedConversationCallback(){ + calls.append("runConversationCallingEndedConversationCallback,"); + conversationalService.initializeCountCallback(1); + conversationalService.endConversationCallback(); + return conversationalService.retrieveCountCallback(); + } + + public String runConversationCallingEndedConversationCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversation(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public String runConversationCallingEndedConversationCallbackCheckConversationId(){ + calls.append("runConversationCallingEndedConversationCallbackCheckConversationId,"); + ServiceReference serviceReference = componentContext.getServiceReference(ConversationalService.class, + "conversationalService"); + serviceReference.setConversationID("MyConversation3"); + + ConversationalService callableReference = serviceReference.getService(); + + callableReference.initializeCount(1); + callableReference.incrementCount(); + clientCount = callableReference.retrieveCount(); + callableReference.endConversationCallback(); + + if (serviceReference.getConversation() ==null ) { + return null; + } else { + return serviceReference.getConversation().getConversationID().toString(); + } + } + + public int runConversationAgeTimeout(){ + calls.append("runConversationAgeTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationIdleTimeout(){ + calls.append("runConversationIdleTimeout,"); + // done in other testing + return clientCount; + } + public int runConversationPrincipleError(){ + calls.append("runConversationPrincipleError,"); + // TODO - when policy framework is done + return clientCount; + } + + + // From ConversationalCallback + @Init + public void init(){ + calls.append("init,"); + + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + callbackCount = 0; + } + + public void incrementCount(){ + calls.append("incrementCount,"); + callbackCount++; + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + return callbackCount; + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public String endConversation(){ + calls.append("endConversation,"); + callbackCount = 0; + return null; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalReferenceClientImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalReferenceClientImpl.java new file mode 100644 index 0000000000..1abe9e51c3 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalReferenceClientImpl.java @@ -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 org.apache.tuscany.sca.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.ConversationalReferenceClient; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.CallableReference; +import org.oasisopen.sca.annotation.Service; + +/** + * A client component that accepts a reference to an ongoing conversation + * and takes part in that conversation + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ + +@Service(interfaces={ConversationalReferenceClient.class}) +public class ConversationalReferenceClientImpl implements ConversationalReferenceClient{ + + public void incrementCount(CallableReference conversationalService){ + ConversationalService callableReference = conversationalService.getService(); + + callableReference.incrementCount(); + } + + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceRequestImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceRequestImpl.java new file mode 100644 index 0000000000..fc485b6c4b --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceRequestImpl.java @@ -0,0 +1,124 @@ +/* + * 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.itest.conversational.impl; + +import java.util.HashMap; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + + +/** + * The service used when testing stateful conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Service(ConversationalService.class) +@Scope("REQUEST") +public class ConversationalServiceRequestImpl implements ConversationalService { + + @ConversationID + protected String conversationId; + + @Callback + protected ConversationalCallback conversationalCallback; + + // static area in which to hold conversational data + private static HashMap conversationalState = new HashMap(); + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + Integer conversationalCount = new Integer(count); + conversationalState.put(conversationId, conversationalCount); + } + + public void incrementCount(){ + calls.append("incrementCount,"); + Integer conversationalCount = conversationalState.get(conversationId); + conversationalCount++; + conversationalState.put(conversationId, conversationalCount); + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + Integer count = conversationalState.get(conversationId); + if (count != null){ + return count.intValue(); + } else { + return -999; + } + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public void initializeCountCallback(int count){ + calls.append("initializeCountCallback,"); + initializeCount(count); + conversationalCallback.initializeCount(count); + } + + public void incrementCountCallback(){ + calls.append("incrementCountCallback,"); + incrementCount(); + conversationalCallback.incrementCount(); + } + + public int retrieveCountCallback(){ + calls.append("retrieveCountCallback,"); + return conversationalCallback.retrieveCount(); + } + + public void businessExceptionCallback() throws BusinessException { + calls.append("businessExceptionCallback,"); + conversationalCallback.businessException(); + } + + public String endConversation(){ + calls.append("endConversation,"); + conversationalState.remove(conversationId); + return conversationId; + } + + public String endConversationCallback(){ + calls.append("endConversationCallback,"); + return conversationalCallback.endConversation(); + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulImpl.java new file mode 100644 index 0000000000..a783e79cae --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulImpl.java @@ -0,0 +1,119 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + + +/** + * The service used when testing stateful conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Service(ConversationalService.class) +@Scope("CONVERSATION") +@ConversationAttributes(maxAge="10 minutes", + maxIdleTime="5 minutes", + singlePrincipal=false) +public class ConversationalServiceStatefulImpl implements ConversationalService { + + @ConversationID + protected String conversationId; + + @Callback + protected ConversationalCallback conversationalCallback; + + // local count - accumulates during the conversation + private int count = 0; + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + this.count = count; + } + + public void incrementCount(){ + calls.append("incrementCount,"); + count++; + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + return count; + } + + public void businessException() throws BusinessException { + calls.append("businessException,"); + throw new BusinessException("Business Exception"); + } + + public void initializeCountCallback(int count){ + calls.append("initializeCountCallback,"); + this.count = count; + conversationalCallback.initializeCount(count); + } + + public void incrementCountCallback(){ + calls.append("incrementCountCallback,"); + count++; + conversationalCallback.incrementCount(); + } + + public int retrieveCountCallback(){ + calls.append("retrieveCountCallback,"); + return conversationalCallback.retrieveCount(); + } + + public void businessExceptionCallback() throws BusinessException { + calls.append("businessExceptionCallback,"); + conversationalCallback.businessException(); + } + + public String endConversation(){ + calls.append("endConversation,"); + count = 0; + return conversationId; + } + + public String endConversationCallback(){ + calls.append("endConversationCallback,"); + return conversationalCallback.endConversation(); + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulNonConversationalCallbackImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulNonConversationalCallbackImpl.java new file mode 100644 index 0000000000..5f34de66b3 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatefulNonConversationalCallbackImpl.java @@ -0,0 +1,118 @@ +/* + * 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.itest.conversational.impl; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalServiceNonConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.NonConversationalCallback; +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.ConversationAttributes; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Scope; +import org.oasisopen.sca.annotation.Service; + + +/** + * The service used when testing stateful conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Service(ConversationalServiceNonConversationalCallback.class) +@Scope("CONVERSATION") +@ConversationAttributes(maxAge="10 minutes", + maxIdleTime="5 minutes", + singlePrincipal=false) +public class ConversationalServiceStatefulNonConversationalCallbackImpl implements ConversationalServiceNonConversationalCallback { + + @ConversationID + protected String conversationId; + + @Callback + protected NonConversationalCallback nonConversationalCallback; + + // local count - accumulates during the conversation + private int count = 0; + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + this.count = count; + } + + public void incrementCount(){ + calls.append("incrementCount,"); + count++; + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + return count; + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public void initializeCountCallback(int count){ + calls.append("initializeCountCallback,"); + this.count = count; + nonConversationalCallback.initializeCount(count); + } + + public void incrementCountCallback(){ + calls.append("incrementCountCallback,"); + count++; + nonConversationalCallback.incrementCount(); + } + + public int retrieveCountCallback(){ + calls.append("retrieveCountCallback,"); + return nonConversationalCallback.retrieveCount(); + } + + public void businessExceptionCallback() throws BusinessException { + calls.append("businessExceptionCallback,"); + nonConversationalCallback.businessException(); + } + + public String endConversation(){ + calls.append("endConversation,"); + count = 0; + return conversationId; + } + + public String endConversationCallback(){ + calls.append("endConversationCallback,"); + return nonConversationalCallback.endConversation(); + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessImpl.java new file mode 100644 index 0000000000..02a2fb1d4d --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessImpl.java @@ -0,0 +1,122 @@ +/* + * 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.itest.conversational.impl; + +import java.util.HashMap; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalCallback; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.Callback; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Destroy; +import org.oasisopen.sca.annotation.Init; +import org.oasisopen.sca.annotation.Service; + + +/** + * The service used when testing stateful conversations + * + * @version $Rev: 537240 $ $Date: 2007-05-11 18:35:03 +0100 (Fri, 11 May 2007) $ + */ +@Service(ConversationalService.class) +public class ConversationalServiceStatelessImpl implements ConversationalService { + + @ConversationID + protected String conversationId; + + @Callback + protected ConversationalCallback conversationalCallback; + + // static area in which to hold conversational data + private static HashMap conversationalState = new HashMap(); + + // a static member variable that records the number of times this service is called + public static StringBuffer calls = new StringBuffer(); + + @Init + public void init(){ + calls.append("init,"); + } + + @Destroy + public void destroy(){ + calls.append("destroy,"); + } + + public void initializeCount(int count){ + calls.append("initializeCount,"); + Integer conversationalCount = new Integer(count); + conversationalState.put(conversationId, conversationalCount); + } + + public void incrementCount(){ + calls.append("incrementCount,"); + Integer conversationalCount = conversationalState.get(conversationId); + conversationalCount++; + conversationalState.put(conversationId, conversationalCount); + } + + public int retrieveCount(){ + calls.append("retrieveCount,"); + Integer count = conversationalState.get(conversationId); + if (count != null){ + return count.intValue(); + } else { + return -999; + } + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public void initializeCountCallback(int count){ + calls.append("initializeCountCallback,"); + initializeCount(count); + conversationalCallback.initializeCount(count); + } + + public void incrementCountCallback(){ + calls.append("incrementCountCallback,"); + incrementCount(); + conversationalCallback.incrementCount(); + } + + public int retrieveCountCallback(){ + calls.append("retrieveCountCallback,"); + return conversationalCallback.retrieveCount(); + } + + public void businessExceptionCallback() throws BusinessException { + calls.append("businessExceptionCallback,"); + conversationalCallback.businessException(); + } + + public String endConversation(){ + calls.append("endConversation,"); + conversationalState.remove(conversationId); + return conversationId; + } + + public String endConversationCallback(){ + calls.append("endConversationCallback,"); + return conversationalCallback.endConversation(); + } +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessScopeImpl.java b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessScopeImpl.java new file mode 100644 index 0000000000..4550e3eaa1 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/java/org/apache/tuscany/sca/itest/conversational/impl/ConversationalServiceStatelessScopeImpl.java @@ -0,0 +1,94 @@ +/* + * 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.itest.conversational.impl; + +import java.util.HashMap; +import java.util.Map; + +import org.apache.tuscany.sca.itest.conversational.BusinessException; +import org.apache.tuscany.sca.itest.conversational.ConversationalService; +import org.oasisopen.sca.annotation.ConversationID; +import org.oasisopen.sca.annotation.Service; + +@Service(ConversationalService.class) +public class ConversationalServiceStatelessScopeImpl implements ConversationalService { + + @ConversationID + protected String cid; + + static Map state = new HashMap(); + + public void destroy() { + // TODO Auto-generated method stub + + } + + public String endConversation() { + state.remove(cid); + return cid; + } + + public String endConversationCallback() { + // TODO Auto-generated method stub + return null; + + } + + public void incrementCount() { + state.put(cid, Integer.valueOf(state.get(cid)+1)); + } + + public void businessException() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public void incrementCountCallback() { + // TODO Auto-generated method stub + + } + + public void init() { + // TODO Auto-generated method stub + + } + + public void initializeCount(int count) { + state.put(cid, Integer.valueOf(count)); + } + + public void initializeCountCallback(int count) { + // TODO Auto-generated method stub + + } + + public void businessExceptionCallback() throws BusinessException { + throw new BusinessException("Business Exception"); + } + + public int retrieveCount() { + return state.get(cid); + } + + public int retrieveCountCallback() { + // TODO Auto-generated method stub + return 0; + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/META-INF/sca-contribution.xml b/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..d5a1ff7410 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/META-INF/sca-contribution.xml @@ -0,0 +1,22 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/conversational.composite b/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/conversational.composite new file mode 100644 index 0000000000..c4da99145d --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/resources/Conversational/conversational.composite @@ -0,0 +1,169 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/ConversationalServiceStateful.wsdl b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/ConversationalServiceStateful.wsdl new file mode 100644 index 0000000000..20a92c9dc7 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/ConversationalServiceStateful.wsdl @@ -0,0 +1,383 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/META-INF/sca-contribution.xml b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/META-INF/sca-contribution.xml new file mode 100644 index 0000000000..73d078674c --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/META-INF/sca-contribution.xml @@ -0,0 +1,22 @@ + + + + + \ No newline at end of file diff --git a/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/conversationalWSDL.composite b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/conversationalWSDL.composite new file mode 100644 index 0000000000..9c6b0a2b34 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/main/resources/ConversationalWSDL/conversationalWSDL.composite @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java new file mode 100644 index 0000000000..6c3cbe462c --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/ConversationWSDLTestCase.java @@ -0,0 +1,75 @@ +/* + * 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.itest.conversational; + + +import java.io.File; + + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.After; +import org.junit.Assert; +import org.junit.Before; +import org.junit.Test; + +public class ConversationWSDLTestCase { + + private Node node; + private ConversationalClient conversationalStatelessClientStatefulService; + + @Before + public void setUp() throws Exception { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/ConversationalWSDL/conversationalWSDL.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/ConversationalWSDL").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, "ConversationalStatelessClientStatefulService"); + + + ConversationalClientStatelessImpl.calls = new StringBuffer(); + } + + @After + public void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatefulService = null; + } + + @Test + public void testStatelessStatefulConversationFromInjectedReference() { + int count = conversationalStatelessClientStatefulService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + //@Test + public void testKeepServerRunning() throws Exception { + System.out.println("press enter to continue"); + System.in.read(); + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java new file mode 100644 index 0000000000..051b6b9fc1 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/NonConversationalCallbackTestCase.java @@ -0,0 +1,198 @@ +/* + * 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.itest.conversational; + +import java.io.File; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class NonConversationalCallbackTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + // stateful client non conversational callback stateful service tests + // ================================================================== + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationFromInjectedReference() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationFromInjectedReference2() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationFromInjectedReference2(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationFromServiceReference() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationWithUserDefinedConversationId() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationCheckingScope() { + resetCallStack(); + ConversationalServiceStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,incrementCount,retrieveCount,endConversation,destroy,", + ConversationalServiceStatefulNonConversationalCallbackImpl.calls.toString()); + } + + //@Test + public void testStatefulNonConversationalCallbackStatefulConversationWithCallback() { + resetCallStack(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationWithCallback(); + Assert.assertEquals(0, count); + + Assert.assertEquals("init,runConversationWithCallback,init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,", + ConversationalClientStatefulNonConversationalCallbackImpl.calls.toString()); + } + + //@Test + public void testStatefulNonConversationalCallbackStatefulConversationHavingPassedReference() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationHavingPassedReference(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationCallingEndedConversation() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCallingEndedConversation(); + Assert.assertEquals(0, count); + } + + //@Test + public void testStatefulNonConversationalCallbackStatefulConversationCallingEndedConversationCallback() { + int count = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatefulNonConversationalCallbackStatefulConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + //@Test + public void testStatefulNonConversationalCallbackStatefulConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatefulClientNonConversationalCallbackStatelessService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals("MyConversation3", id); + } + + + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java new file mode 100644 index 0000000000..b9530c132b --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/RequestScopeTestCase.java @@ -0,0 +1,209 @@ +/* + * 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.itest.conversational; + +import java.io.File; + + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceRequestImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class RequestScopeTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + // stateless client request scope service tests + // ============================================ + @Test + public void testStatelessRequestConversationFromInjectedReference() { + int count = conversationalStatelessClientRequestService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + //@Test + public void testStatelessRequestConversationFromInjectedReference2() { + int count = conversationalStatelessClientRequestService.runConversationFromInjectedReference2(); + Assert.assertEquals(1, count); + } + + @Test + public void testStatelessRequestConversationFromServiceReference() { + int count = conversationalStatelessClientRequestService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessRequestConversationWithUserDefinedConversationId() { + int count = conversationalStatelessClientRequestService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + + //@Test + public void testStatelessRequestConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatelessClientRequestService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + //@Test + public void testStatelessRequestConversationCheckingScope() { + resetCallStack(); + ConversationalServiceRequestImpl.calls = new StringBuffer(); + conversationalStatelessClientRequestService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,incrementCount,retrieveCount,endConversation,", + ConversationalServiceRequestImpl.calls.toString()); + //init,initializeCount,init,incrementCount,init,retrieveCount,init,endConversation, + } + + @Test + public void testStatelessRequestConversationWithCallback() { + resetCallStack(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + int count = conversationalStatelessClientRequestService.runConversationWithCallback(); + Assert.assertEquals(0, count); + + Assert.assertEquals("init,runConversationWithCallback,init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,destroy,", + ConversationalClientStatelessImpl.calls.toString()); + } + + //@Test + public void testStatelessRequestConversationHavingPassedReference() { + int count = conversationalStatelessClientRequestService.runConversationHavingPassedReference(); + Assert.assertEquals(3, count); + } + + //@Test + public void testStatelessRequestConversationBusinessException() { + String message = conversationalStatelessClientRequestService.runConversationBusinessException(); + Assert.assertEquals("Business Exception", message); + } + + //@Test + public void testStatelessRequestConversationBusinessExceptionCallback() { + String message = conversationalStatelessClientRequestService.runConversationBusinessExceptionCallback(); + Assert.assertEquals("Business Exception", message); + } + + @Test + public void testStatelessRequestConversationCallingEndedConversation() { + int count = conversationalStatelessClientRequestService.runConversationCallingEndedConversation(); + Assert.assertEquals(-999, count); + } + + @Test + public void testStatelessRequestConversationCallingEndedConversationCallback() { + int count = conversationalStatelessClientRequestService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatelessRequestConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatelessClientRequestService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + //@Test + public void testStatelessRequestConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatelessClientRequestService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals(null, id); + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java new file mode 100644 index 0000000000..1e5f6adcf1 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatefulTestCase.java @@ -0,0 +1,193 @@ +/* + * 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.itest.conversational; + +import java.io.File; + + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class StatefulStatefulTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + // stateful client stateful service tests + // ====================================== + @Test + public void testStatefulStatefulConversationFromInjectedReference() { + int count = conversationalStatefulClientStatefulService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatefulConversationFromInjectedReference2() { + int count = conversationalStatefulClientStatefulService.runConversationFromInjectedReference2(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatefulConversationFromServiceReference() { + int count = conversationalStatefulClientStatefulService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatefulConversationWithUserDefinedConversationId() { + int count = conversationalStatefulClientStatefulService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatefulConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatefulClientStatefulService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + @Test + public void testStatefulStatefulConversationCheckingScope() { + resetCallStack(); + conversationalStatefulClientStatefulService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,incrementCount,retrieveCount,endConversation,destroy,", + ConversationalServiceStatefulImpl.calls.toString()); + } + + @Test + public void testStatefulStatefulConversationWithCallback() { + resetCallStack(); + int count = conversationalStatefulClientStatefulService.runConversationWithCallback(); + Assert.assertEquals(4, count); + + Assert.assertEquals("init,runConversationWithCallback,initializeCount,incrementCount,retrieveCount,endConversation,destroy,", + ConversationalClientStatefulImpl.calls.toString()); + } + + //@Test + public void testStatefulStatefulConversationHavingPassedReference() { + int count = conversationalStatefulClientStatefulService.runConversationHavingPassedReference(); + Assert.assertEquals(3, count); + } + + @Test + public void testStatefulStatefulConversationCallingEndedConversation() { + int count = conversationalStatefulClientStatefulService.runConversationCallingEndedConversation(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatefulStatefulConversationCallingEndedConversationCallback() { + int count = conversationalStatefulClientStatefulService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatefulStatefulConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatefulClientStatefulService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + @Test + public void testStatefulStatefulConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatefulClientStatefulService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals(null, id); + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java new file mode 100644 index 0000000000..8a110477b5 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatefulStatelessTestCase.java @@ -0,0 +1,193 @@ +/* + * 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.itest.conversational; + +import java.io.File; + + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class StatefulStatelessTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + // stateful client stateless service tests + // ======================================= + @Test + public void testStatefulStatelessConversationFromInjectedReference() { + int count = conversationalStatefulClientStatelessService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatelessConversationFromInjectedReference2() { + int count = conversationalStatefulClientStatelessService.runConversationFromInjectedReference2(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatelessConversationFromServiceReference() { + int count = conversationalStatefulClientStatelessService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatelessConversationWithUserDefinedConversationId() { + int count = conversationalStatefulClientStatelessService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatefulStatelessConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatefulClientStatelessService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + @Test + public void testStatefulStatelessConversationCheckingScope() { + resetCallStack(); + conversationalStatefulClientStatelessService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,", + ConversationalServiceStatelessImpl.calls.toString()); + } + + @Test + public void testStatefulStatelessConversationWithCallback() { + resetCallStack(); + int count = conversationalStatefulClientStatelessService.runConversationWithCallback(); + Assert.assertEquals(4, count); + + Assert.assertEquals("init,runConversationWithCallback,initializeCount,incrementCount,retrieveCount,endConversation,destroy,", + ConversationalClientStatefulImpl.calls.toString()); + } + + //@Test + public void testStatefulStatelessConversationHavingPassedReference() { + int count = conversationalStatefulClientStatelessService.runConversationHavingPassedReference(); + Assert.assertEquals(3, count); + } + + @Test + public void testStatefulStatelessConversationCallingEndedConversation() { + int count = conversationalStatefulClientStatelessService.runConversationCallingEndedConversation(); + Assert.assertEquals(-999, count); + } + + @Test + public void testStatefulStatelessConversationCallingEndedConversationCallback() { + int count = conversationalStatefulClientStatelessService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatefulStatelessConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatefulClientStatelessService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + @Test + public void testStatefulStatelessConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatefulClientStatelessService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals(null, id); + } + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java new file mode 100644 index 0000000000..79ac9262c6 --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatefulTestCase.java @@ -0,0 +1,205 @@ +/* + * 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.itest.conversational; + +import java.io.File; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class StatelessStatefulTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + // stateless client stateful service tests + // ======================================= + @Test + public void testStatelessStatefulConversationFromInjectedReference() { + int count = conversationalStatelessClientStatefulService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatefulConversationFromInjectedReference2() { + int count = conversationalStatelessClientStatefulService.runConversationFromInjectedReference2(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatefulConversationFromServiceReference() { + int count = conversationalStatelessClientStatefulService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatefulConversationWithUserDefinedConversationId() { + int count = conversationalStatelessClientStatefulService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatefulConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatelessClientStatefulService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + @Test + public void testStatelessStatefulConversationCheckingScope() { + resetCallStack(); + conversationalStatelessClientStatefulService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,incrementCount,retrieveCount,endConversation,destroy,", + ConversationalServiceStatefulImpl.calls.toString()); + } + + @Test + public void testStatelessStatefulConversationWithCallback() { + resetCallStack(); + int count = conversationalStatelessClientStatefulService.runConversationWithCallback(); + Assert.assertEquals(0, count); + + Assert.assertEquals("init,runConversationWithCallback,init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,destroy,", + ConversationalClientStatelessImpl.calls.toString()); + } + + //@Test + public void testStatelessStatefulConversationHavingPassedReference() { + int count = conversationalStatelessClientStatefulService.runConversationHavingPassedReference(); + Assert.assertEquals(3, count); + } + + //@Test + public void testStatelessStatefulConversationBusinessException() { + String message = conversationalStatelessClientStatefulService.runConversationBusinessException(); + Assert.assertEquals("Business Exception", message); + } + + //@Test + public void testStatelessStatefulConversationBusinessExceptionCallback() { + String message = conversationalStatelessClientStatefulService.runConversationBusinessExceptionCallback(); + Assert.assertEquals("Business Exception", message); + } + + @Test + public void testStatelessStatefulConversationCallingEndedConversation() { + int count = conversationalStatelessClientStatefulService.runConversationCallingEndedConversation(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatelessStatefulConversationCallingEndedConversationCallback() { + int count = conversationalStatelessClientStatefulService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatelessStatefulConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatelessClientStatefulService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + //@Test + public void testStatelessStatefulConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatelessClientStatefulService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals(null, id); + } + + +} diff --git a/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java new file mode 100644 index 0000000000..9aebae9ced --- /dev/null +++ b/java/sca/contrib/itest/conversations-ws/src/test/java/org/apache/tuscany/sca/itest/conversational/StatelessStatelessTestCase.java @@ -0,0 +1,192 @@ +/* + * 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.itest.conversational; + +import java.io.File; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatefulNonConversationalCallbackImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalClientStatelessImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatefulImpl; +import org.apache.tuscany.sca.itest.conversational.impl.ConversationalServiceStatelessImpl; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Contribution; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +public class StatelessStatelessTestCase { + + private static Node node; + private static ConversationalClient conversationalStatelessClientStatelessService; + private static ConversationalClient conversationalStatelessClientStatefulService; + private static ConversationalClient conversationalStatefulClientStatelessService; + private static ConversationalClient conversationalStatefulClientStatefulService; + private static ConversationalClient conversationalStatelessClientRequestService; + private static ConversationalClient conversationalStatefulClientNonConversationalCallbackStatelessService; + + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createNode(new File("src/main/resources/Conversational/conversational.composite").toURL().toString(), + new Contribution("TestContribution", + new File("src/main/resources/Conversational").toURL().toString())); + + + node.start(); + + conversationalStatelessClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatelessService"); + + conversationalStatelessClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientStatefulService"); + + conversationalStatefulClientStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatelessService"); + + conversationalStatefulClientStatefulService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientStatefulService"); + conversationalStatelessClientRequestService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatelessClientRequestService"); + conversationalStatefulClientNonConversationalCallbackStatelessService = ((Client)node).getService(ConversationalClient.class, + "ConversationalStatefulClientNonConversationalCallbackStatefulService"); + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + + } catch(Exception ex) { + System.err.println(ex.toString()); + } + + } + + @AfterClass + public static void tearDown() throws Exception { + node.stop(); + conversationalStatelessClientStatelessService = null; + conversationalStatelessClientStatefulService = null; + conversationalStatefulClientStatelessService = null; + conversationalStatefulClientStatefulService = null; + conversationalStatelessClientRequestService = null; + conversationalStatefulClientNonConversationalCallbackStatelessService = null; + } + + private static void resetCallStack() { + + // reset the place where we record the sequence of calls passing + // through each component instance + ConversationalServiceStatelessImpl.calls = new StringBuffer(); + ConversationalServiceStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatelessImpl.calls = new StringBuffer(); + ConversationalClientStatefulImpl.calls = new StringBuffer(); + ConversationalClientStatefulNonConversationalCallbackImpl.calls = new StringBuffer(); + + } + + + // stateless client stateless service tests + // ======================================== + + @Test + public void testStatelessStatelessConversationFromInjectedReference() { + int count = conversationalStatelessClientStatelessService.runConversationFromInjectedReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatelessConversationFromInjectedReference2() { + int count = conversationalStatelessClientStatelessService.runConversationFromInjectedReference2(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatelessConversationFromServiceReference() { + int count = conversationalStatelessClientStatelessService.runConversationFromServiceReference(); + Assert.assertEquals(2, count); + } + + @Test + public void testStatelessStatelessConversationWithUserDefinedConversationId() { + int count = conversationalStatelessClientStatelessService.runConversationWithUserDefinedConversationId(); + Assert.assertEquals(2, count); + } + @Test + public void testStatelessStatelessConversationCheckUserDefinedConversationId() { + String conversationId = conversationalStatelessClientStatelessService.runConversationCheckUserDefinedConversationId(); + Assert.assertEquals("MyConversation2", conversationId); + } + + @Test + public void testStatelessStatelessConversationCheckingScope() { + resetCallStack(); + conversationalStatelessClientStatelessService.runConversationCheckingScope(); + Assert.assertEquals("init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,", + ConversationalServiceStatelessImpl.calls.toString()); + } + + @Test + public void testStatelessStatelessConversationWithCallback() { + resetCallStack(); + int count = conversationalStatelessClientStatelessService.runConversationWithCallback(); + Assert.assertEquals(0, count); + + Assert.assertEquals("init,runConversationWithCallback,init,initializeCount,destroy,init,incrementCount,destroy,init,retrieveCount,destroy,init,endConversation,destroy,destroy,", + ConversationalClientStatelessImpl.calls.toString()); + } + //@Test + public void testStatelessStatelessConversationHavingPassedReference() { + int count = conversationalStatelessClientStatelessService.runConversationHavingPassedReference(); + Assert.assertEquals(3, count); + } + + @Test + public void testStatelessStatelessConversationCallingEndedConversation() { + int count = conversationalStatelessClientStatelessService.runConversationCallingEndedConversation(); + Assert.assertEquals(-999, count); + } + + @Test + public void testStatelessStatelessConversationCallingEndedConversationCallback() { + int count = conversationalStatelessClientStatelessService.runConversationCallingEndedConversationCallback(); + Assert.assertEquals(0, count); + } + + @Test + public void testStatelessStatelessConversationCallingEndedConversationCheckConversationId() { + String id = conversationalStatelessClientStatelessService.runConversationCallingEndedConversationCheckConversationId(); + Assert.assertEquals(null, id); + } + + //@Test + public void testStatelessStatelessConversationCallingEndedConversationCallbackCheckConversationId() { + String id = conversationalStatelessClientStatelessService.runConversationCallingEndedConversationCallbackCheckConversationId(); + Assert.assertEquals(null, id); + } + +} diff --git a/java/sca/contrib/itest/corba/pom.xml b/java/sca/contrib/itest/corba/pom.xml new file mode 100644 index 0000000000..f1dd2a9187 --- /dev/null +++ b/java/sca/contrib/itest/corba/pom.xml @@ -0,0 +1,169 @@ + + + + 4.0.0 + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + itest-corba-binding + Apache Tuscany SCA CORBA Binding Integration Tests + + + + org.apache.tuscany.sca + tuscany-host-embedded + 2.0-SNAPSHOT + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-corba-runtime + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-host-corba-jse + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-host-corba-jse-tns + 2.0-SNAPSHOT + test + + + + org.apache.tuscany.sca + tuscany-binding-sca + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-binding-sca-corba + 2.0-SNAPSHOT + runtime + + + + + + org.apache.tuscany.sca + tuscany-databinding-axiom + 2.0-SNAPSHOT + runtime + + + + org.apache.tuscany.sca + tuscany-databinding-sdo + 2.0-SNAPSHOT + compile + + + + junit + junit + 4.5 + compile + + + + + + + org.codehaus.mojo + build-helper-maven-plugin + 1.0 + + + add-source + generate-sources + + add-test-source + + + + target/sdo-source + + + + + + + org.apache.tuscany.sdo + tuscany-sdo-plugin + 1.1.1 + + + generate-scenariofour-sdo + generate-sources + + + ${basedir}/src/test/resources/scenariofour.xsd + + + org.apache.tuscany.sca.test.corba.scenariofour + + ScenarioFour + true + true + true + + + generate + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFiveTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFiveTestCase.java new file mode 100644 index 0000000000..46e214eac3 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFiveTestCase.java @@ -0,0 +1,51 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.fail; + +import org.apache.tuscany.sca.host.corba.jse.tns.TnsDefaultCorbaHost; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.types.ScenarioFive; +import org.apache.tuscany.sca.test.corba.types.ScenarioFiveComponent; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + * Tests usage of TNS JSE Corba host + */ +public class ScenarioFiveTestCase { + + @Test + public void test_providedNameServer() { + TestCorbaHost.setCorbaHost(new TnsDefaultCorbaHost()); + try { + // just make sure we can obtain and use the reference with success + SCADomain domain = SCADomain.newInstance("ScenarioFive.composite"); + ScenarioFive scenarioFive = + domain.getService(ScenarioFiveComponent.class, "ScenarioFive").getScenarioFive(); + scenarioFive.doNothing(); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFourTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFourTestCase.java new file mode 100644 index 0000000000..cba8c823e8 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioFourTestCase.java @@ -0,0 +1,149 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.apache.tuscany.sca.host.corba.naming.TransientNameServer; +import org.apache.tuscany.sca.host.corba.naming.TransientNameService; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.scenariofour.ScenarioFourFactory; +import org.apache.tuscany.sca.test.corba.scenariofour.ScenarioFourSdo; +import org.apache.tuscany.sca.test.corba.types.ScenarioFour; +import org.apache.tuscany.sca.test.corba.types.ScenarioFourComponent; +import org.apache.tuscany.sca.test.corba.types.ScenarioFourException; +import org.apache.tuscany.sca.test.corba.types.ScenarioFourStruct; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + * Tests SCA default binding over CORBA binding + */ +public class ScenarioFourTestCase { + + // note that those values are also used in resources/*.composite file + private static SCADomain domain; + private static ScenarioFourComponent scenarioFourComponent; + private static ScenarioFour scenarioFour; + private static TransientNameServer server; + private static final int ORB_INITIAL_PORT = 5080; + + /** + * Initial configuration + */ + @BeforeClass + public static void setUp() { + TestCorbaHost.setCorbaHost(new DefaultCorbaHost()); + try { + server = new TransientNameServer("localhost", ORB_INITIAL_PORT, TransientNameService.DEFAULT_SERVICE_NAME); + Thread t = server.start(); + if (t == null) { + Assert.fail("The naming server cannot be started"); + } + // obtain domain + domain = SCADomain.newInstance("ScenarioFour.composite"); + scenarioFourComponent = domain.getService(ScenarioFourComponent.class, "ScenarioFour"); + scenarioFour = scenarioFourComponent.getScenarioFour(); + } catch (Exception e) { + e.printStackTrace(); + } + } + + /** + * Test cleanup + */ + @AfterClass + public static void tearDown() { + server.stop(); + } + + /** + * General tests for passing JAXB objects + */ + @Test + public void test_generalJAXB() { + try { + ScenarioFourStruct input = new ScenarioFourStruct(); + input.field1 = "Test"; + input.field2 = 1; + input.field3 = new double[1]; + ScenarioFourStruct output = scenarioFour.setStruct(input); + assertTrue(input.equals(output)); + } catch (Exception e) { + e.printStackTrace(); + Assert.fail(e.getMessage()); + } + } + + /** + * Test for JAXB exceptions + */ + @Test + public void test_exceptionsJAXB() { + try { + scenarioFour.exceptionTest(); + fail(); + } catch (ScenarioFourException e) { + assertTrue(ScenarioFourException.DEFAULT_CONTENT.equals(e.getContent())); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * General test for passing SDO objects + */ + @Test + public void test_generalSDO() { + try { + ScenarioFourSdo scenarioFourSdo = ScenarioFourFactory.INSTANCE.createScenarioFourSdo(); + scenarioFourSdo.setMessage("Test1"); + scenarioFourSdo.setSymbol("Test2"); + ScenarioFourSdo result = scenarioFour.passScenarioFourStruct(scenarioFourSdo); + assertTrue(scenarioFourSdo.getMessage().equals(result.getMessage()) && scenarioFourSdo.getSymbol() + .equals(result.getSymbol())); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests reusing local name server with multiple bindings + */ + @Test + public void test_nameServerReuse() { + try { + ScenarioFour scenarioFour = + domain.getService(ScenarioFourComponent.class, "ScenarioFourReuse").getScenarioFour(); + ScenarioFourStruct struct = new ScenarioFourStruct(); + scenarioFour.setStruct(struct); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioOneTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioOneTestCase.java new file mode 100644 index 0000000000..0135c04495 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioOneTestCase.java @@ -0,0 +1,371 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.apache.tuscany.sca.host.corba.naming.TransientNameServer; +import org.apache.tuscany.sca.host.corba.naming.TransientNameService; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.generated.Color; +import org.apache.tuscany.sca.test.corba.generated.InnerStruct; +import org.apache.tuscany.sca.test.corba.generated.RichStruct; +import org.apache.tuscany.sca.test.corba.generated.ScenarioOne; +import org.apache.tuscany.sca.test.corba.generated.ScenarioOneHelper; +import org.apache.tuscany.sca.test.corba.generated.ScenarioOneOperations; +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; +import org.apache.tuscany.sca.test.corba.types.ScenarioOneServant; +import org.apache.tuscany.sca.test.corba.types.TColor; +import org.apache.tuscany.sca.test.corba.types.TInnerStruct; +import org.apache.tuscany.sca.test.corba.types.TRichStruct; +import org.apache.tuscany.sca.test.corba.types.TScenarioOne; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; +import org.omg.CORBA.ORB; +import org.omg.CosNaming.NameComponent; +import org.omg.CosNaming.NamingContext; +import org.omg.CosNaming.NamingContextHelper; + +/** + * @version $Rev$ $Date$ + * This test class contains three main tests:
+ * 1. Tuscany is being used as a consumer of some non-Tuscany CORBA service
+ * 2. Tuscany is being used as a service provider, which will be consumed by + * non-Tuscany CORBA client
+ * 3. Tuscany is being used as a service provider, which will be consumed by + * Tuscany client
+ * But that's not all, there are some other variations. Tuscany CORBA binding + * supports using Java interface generated by IDLJ, also it supports interfaces + * provided by user - I combined those cases in each test.
+ */ +public class ScenarioOneTestCase { + + // note that those values are also used in resources/*.composite file + private static int ORB_INITIAL_PORT = 5060; + private static String SERVICE_NAME = "ScenarioOne"; + + private static SCADomain domain; + + private static TransientNameServer server; + private static ORB orb; + + /** + * Sets up name service, creates and registers traditional CORBA service, + * obtains SCADomain + */ + @BeforeClass + public static void setUp() { + TestCorbaHost.setCorbaHost(new DefaultCorbaHost()); + try { + try { + server = + new TransientNameServer("localhost", ORB_INITIAL_PORT, TransientNameService.DEFAULT_SERVICE_NAME); + Thread t = server.start(); + if (t == null) { + Assert.fail("The naming server cannot be started"); + } + orb = server.getORB(); + } catch (Throwable e) { + e.printStackTrace(); + Assert.fail(e.getMessage()); + } + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioOne scenarioOne = new ScenarioOneServant(); + ncRef.rebind(path, scenarioOne); + // obtain domain + domain = SCADomain.newInstance("ScenarioOne.composite"); + } catch (Exception e) { + e.printStackTrace(); + } + } + + /** + * Kills previously spawned name service. + */ + @AfterClass + public static void tearDown() { + server.stop(); + } + + /** + * Creates nicely filled structure for user provided interface. + * + * @return + */ + private static TRichStruct getTRichStruct() { + int[][] intArr = new int[][] { {1, 2}, {3, 4}}; + TInnerStruct innerStruct = new TInnerStruct(intArr, "Test", TColor.green); + String[] strSeq = {"i", "Test"}; + return new TRichStruct(innerStruct, strSeq, 1); + + } + + /** + * Creates nicely filled structure for generated interface. + * + * @return + */ + private static RichStruct getRichStruct() { + int[][] intArr = new int[][] { {1, 2}, {3, 4}}; + InnerStruct innerStruct2 = new InnerStruct(intArr, "Test", Color.green); + String[] strSeq = {"i", "Test"}; + return new RichStruct(innerStruct2, strSeq, 1); + } + + /** + * Compares String arrays + * + * @param arg1 + * @param arg2 + * @return + */ + private boolean areSrringArraysEqual(String[] arg1, String[] arg2) { + try { + for (int i = 0; i < arg1.length; i++) { + if (!arg1[i].equals(arg2[i])) { + return false; + } + } + } catch (Exception e) { + return false; + } + return true; + } + + /** + * Compares two dimensional int arrays + * + * @param arg1 + * @param arg2 + * @return + */ + private boolean areTwoDimIntArraysEqual(int[][] arg1, int[][] arg2) { + try { + for (int i = 0; i < arg1.length; i++) { + for (int j = 0; j < arg1[i].length; j++) { + if (arg1[i][j] != arg2[i][j]) { + return false; + } + } + } + } catch (Exception e) { + return false; + } + return true; + } + + private boolean equalTo(TInnerStruct arg1, TInnerStruct arg2) { + return (arg1.color.value() == arg2.color.value() && arg1.stringField.equals(arg2.stringField) && areTwoDimIntArraysEqual(arg1.twoDimLongSequence, + arg2.twoDimLongSequence)); + } + + private boolean equalTo(InnerStruct arg1, InnerStruct arg2) { + return (arg1.color.value() == arg2.color.value() && arg1.stringField.equals(arg2.stringField) && areTwoDimIntArraysEqual(arg1.twoDimLongSequence, + arg2.twoDimLongSequence)); + } + + private boolean equalTo(TRichStruct arg1, TRichStruct arg2) { + return (equalTo(arg1.innerStruct, arg2.innerStruct) && arg2.longField == arg1.longField && areSrringArraysEqual(arg1.stringSequence, + arg2.stringSequence)); + } + + private boolean equalTo(RichStruct arg1, RichStruct arg2) { + return (equalTo(arg1.innerStruct, arg2.innerStruct) && arg2.longField == arg1.longField && areSrringArraysEqual(arg1.stringSequence, + arg2.stringSequence)); + } + + /** + * Helper method used several times for various components. Executes several + * tests using Tuscany reference binding. This helper uses generated Java + * interface. + * + * @param componentName + */ + private void testClientUsingGeneratedInterface(String componentName) { + ScenarioOneOperations component = domain.getService(ScenarioOneOperations.class, componentName); + RichStruct richStruct = getRichStruct(); + + try { + RichStruct result = component.setRichStruct(richStruct); + assertTrue(equalTo(result, richStruct)); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + + try { + richStruct.longField = 0; + component.setRichStruct(richStruct); + fail(); + } catch (Exception e) { + assertTrue(e instanceof UnexpectedException); + } + + try { + richStruct.longField = 1; + richStruct.innerStruct.color = Color.red; + component.setRichStruct(richStruct); + } catch (Exception e) { + assertTrue(e instanceof WrongColor); + } + } + + /** + * Helper method used several times for various components. Executes several + * tests using Tuscany reference binding. This helper uses user provided + * Java interface. + * + * @param componentName + */ + private void testClientUsingUserProvidedInterface(String componentName) { + TScenarioOne component = domain.getService(TScenarioOne.class, componentName); + TRichStruct tRichStruct = getTRichStruct(); + + try { + TRichStruct result = component.setRichStruct(tRichStruct); + assertTrue(equalTo(result, tRichStruct)); + } catch (Exception e) { + fail(); + } + + try { + tRichStruct.longField = 0; + component.setRichStruct(tRichStruct); + fail(); + } catch (Exception e) { + assertTrue(e instanceof UnexpectedException); + } + + try { + tRichStruct.longField = 1; + tRichStruct.innerStruct.color = TColor.red; + component.setRichStruct(tRichStruct); + } catch (Exception e) { + assertTrue(e instanceof WrongColor); + } + } + + public void testServiceUsingGeneratedClient(String serviceName) { + try { + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(serviceName, ""); + NameComponent path[] = {nc}; + ScenarioOne so = ScenarioOneHelper.narrow(ncRef.resolve(path)); + + RichStruct richStruct = getRichStruct(); + RichStruct result = so.setRichStruct(richStruct); + assertTrue(equalTo(result, richStruct)); + + try { + richStruct.innerStruct.color = Color.red; + result = so.setRichStruct(richStruct); + fail(); + } catch (Exception e) { + assertTrue(e instanceof WrongColor); + } + + try { + richStruct.innerStruct.color = Color.green; + richStruct.longField = 0; + result = so.setRichStruct(richStruct); + fail(); + } catch (Exception e) { + assertTrue(e instanceof UnexpectedException); + } + + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Service is exposed in traditional way (using CORBA API from JDK). + * Reference is obtained from Tuscany. + */ + @Test + public void test_TraditionalService_TuscanyClient() { + + // Client is using user provided interface + testClientUsingUserProvidedInterface("ScenarioOne"); + + // Client is using generated interface + testClientUsingGeneratedInterface("ScenarioOneGenerated"); + } + + /** + * Service is exposed by Tuscany. Reference is obtained in traditional way. + * (using CORBA API from JDK) + * + * @throws Exception + */ + @Test + public void test_TuscanyService_TraditionalClient() throws Exception { + + // tests service which uses user provided interface + testServiceUsingGeneratedClient("ScenarioOneTuscany"); + + // tests service which uses generated interface + testServiceUsingGeneratedClient("ScenarioOneTuscanyGenerated"); + } + + /** + * Service is exposed by Tuscany. Reference is obtained from Tuscany. There + * are 4 combinations (basing on if we are using generated or user provided + * interfaces, both on service and reference side). + */ + @Test + public void test_TuscanyService_TuscanyClient() { + + // Client is using user provided interface, service is using user + // provided interface. + testClientUsingUserProvidedInterface("TU2TS1"); + + // Client is using user provided interface, service is using generated + // interface. + testClientUsingUserProvidedInterface("TU2TS2"); + + // Client is using generated interface, service is using user provided + // interface. + testClientUsingGeneratedInterface("TG2TS1"); + + // Client is using generated interface, service is using generated + // interface. + testClientUsingGeneratedInterface("TG2TS2"); + } + + /** + * Tests using reference obtained by corbaname URI + */ + @Test + public void test_serviceAndReferenceByURI() { + testClientUsingUserProvidedInterface("UriBinding"); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioSixTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioSixTestCase.java new file mode 100644 index 0000000000..b7309d68a0 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioSixTestCase.java @@ -0,0 +1,228 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.apache.tuscany.sca.host.corba.naming.TransientNameServer; +import org.apache.tuscany.sca.host.corba.naming.TransientNameService; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct; +import org.apache.tuscany.sca.test.corba.generated.InnerUnion; +import org.apache.tuscany.sca.test.corba.generated.RichUnion; +import org.apache.tuscany.sca.test.corba.generated.ScenarioSix; +import org.apache.tuscany.sca.test.corba.generated.ScenarioSixHelper; +import org.apache.tuscany.sca.test.corba.types.ScenarioSixServant; +import org.apache.tuscany.sca.test.corba.types.TAnnotatedStruct; +import org.apache.tuscany.sca.test.corba.types.TInnerUnion; +import org.apache.tuscany.sca.test.corba.types.TRichUnion; +import org.apache.tuscany.sca.test.corba.types.TScenarioSix; +import org.apache.tuscany.sca.test.corba.types.TScenarioSixComponent; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; +import org.omg.CORBA.ORB; +import org.omg.CosNaming.NameComponent; +import org.omg.CosNaming.NamingContext; +import org.omg.CosNaming.NamingContextHelper; + +/** + * Tests using enhanced Java interfaces (annotations) + * + * @version $Rev$ $Date$ + */ +public class ScenarioSixTestCase { + + // note that those values are also used in resources/*.composite file + private static int ORB_INITIAL_PORT = 5050; + private static String SERVICE_NAME = "ScenarioSix"; + private static String TUSCANY_SERVICE_NAME = "ScenarioSixTuscany"; + + private static SCADomain domain; + + private static TransientNameServer server; + private static ORB orb; + + /** + * Sets up name service, creates and registers traditional CORBA service, + * obtains SCADomain + */ + @BeforeClass + public static void setUp() { + TestCorbaHost.setCorbaHost(new DefaultCorbaHost()); + try { + try { + server = + new TransientNameServer("localhost", ORB_INITIAL_PORT, TransientNameService.DEFAULT_SERVICE_NAME); + Thread t = server.start(); + if (t == null) { + Assert.fail("The naming server cannot be started"); + } + orb = server.getORB(); + } catch (Throwable e) { + e.printStackTrace(); + Assert.fail(e.getMessage()); + } + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioSix scenarioSix = new ScenarioSixServant(); + ncRef.rebind(path, scenarioSix); + // obtain domain + domain = SCADomain.newInstance("ScenarioSix.composite"); + } catch (Exception e) { + e.printStackTrace(); + } + } + + /** + * Kills previously spawned name service. + */ + @AfterClass + public static void tearDown() { + server.stop(); + } + + private boolean areArraysEqual(String[][] arr1, String[][] arr2) { + for (int i = 0; i < arr1.length; i++) { + for (int j = 0; j < arr1[i].length; j++) { + if (!arr1[i][j].equals(arr2[i][j])) { + return false; + } + } + } + return true; + } + + private String[][] getStringArray() { + String[][] result = { {"Hello", "World"}, {"Hi", "Again"}}; + return result; + } + + /** + * Tests passing arrays. Tuscany acts as a client, servant object is served + * in a traditional way + */ + @Test + public void test_arraysPassing_tuscanyAsClient() { + try { + TScenarioSix ref = domain.getService(TScenarioSixComponent.class, "ScenarioSix").getScenarioSix(); + String[][] arrayArg = getStringArray(); + String[][] arrayRes = ref.passStringArray(arrayArg); + assertTrue(areArraysEqual(arrayArg, arrayRes)); + TAnnotatedStruct structArg = new TAnnotatedStruct(); + structArg.stringArray = getStringArray(); + TAnnotatedStruct structRes = ref.passAnnotatedStruct(structArg); + assertTrue(areArraysEqual(structArg.stringArray, structRes.stringArray)); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests passing arrays. Servant object is served by Tuscany and it is + * accessed by traditional Corba client + */ + @Test + public void test_arraysPassing_tuscanyAsService() { + try { + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(TUSCANY_SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioSix ref = ScenarioSixHelper.narrow(ncRef.resolve(path)); + String[][] stringArg = getStringArray(); + String[][] stringRes = ref.passStringArray(stringArg); + assertTrue(areArraysEqual(stringArg, stringRes)); + AnnotatedStruct structArg = new AnnotatedStruct(); + structArg.stringArray = getStringArray(); + AnnotatedStruct structRes = ref.passAnnotatedStruct(structArg); + assertTrue(areArraysEqual(structArg.stringArray, structRes.stringArray)); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests passing unions. Tuscany acts as a client, servant object is served + * in a traditional way + */ + @Test + public void test_unionsPassing_tuscanyAsClient() { + try { + TScenarioSix ref = domain.getService(TScenarioSixComponent.class, "ScenarioSix").getScenarioSix(); + TRichUnion arg = new TRichUnion(); + TInnerUnion inner = new TInnerUnion(); + inner.setY(10f); + arg.setIu(inner); + TRichUnion result = ref.passRichUnion(arg); + assertEquals(arg.getIu().getY(), result.getIu().getY(), 0.0f); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + try { + TScenarioSix ref = domain.getService(TScenarioSixComponent.class, "ScenarioSix").getScenarioSix(); + TRichUnion arg = new TRichUnion(); + arg.setY(15f); + TRichUnion result = ref.passRichUnion(arg); + assertEquals(arg.getY(), result.getY(), 0.0f); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests passing unions. Servant object is served by Tuscany and it is + * accessed by traditional Corba client + */ + @Test + public void test_unionsPassing_tuscanyAsService() { + try { + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(TUSCANY_SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioSix ref = ScenarioSixHelper.narrow(ncRef.resolve(path)); + RichUnion arg = new RichUnion(); + InnerUnion inner = new InnerUnion(); + inner.y(20f); + arg.iu(inner); + RichUnion result = ref.passRichUnion(arg); + assertEquals(arg.iu().y(), result.iu().y(), 0.0f); + arg = new RichUnion(); + arg.y(15f); + result = ref.passRichUnion(arg); + assertEquals(arg.y(), result.y(), 0.0f); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioThreeTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioThreeTestCase.java new file mode 100644 index 0000000000..a738c6f211 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioThreeTestCase.java @@ -0,0 +1,130 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.fail; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.apache.tuscany.sca.host.corba.naming.TransientNameServer; +import org.apache.tuscany.sca.host.corba.naming.TransientNameService; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.types.TScenarioThree; +import org.apache.tuscany.sca.test.corba.types.TScenarioThreeComponent; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + * Tests various mapping scenarios. + */ +public class ScenarioThreeTestCase { + + // note that those values are also used in resources/*.composite file + private static int ORB_INITIAL_PORT = 5060; + private static SCADomain domain; + private static TransientNameServer server; + + /** + * Sets up name service, creates and registers traditional CORBA service, + * obtains SCADomain + */ + @BeforeClass + public static void setUp() { + TestCorbaHost.setCorbaHost(new DefaultCorbaHost()); + try { + try { + server = + new TransientNameServer("localhost", ORB_INITIAL_PORT, TransientNameService.DEFAULT_SERVICE_NAME); + Thread t = server.start(); + if (t == null) { + Assert.fail("The naming server cannot be started"); + } + } catch (Throwable e) { + e.printStackTrace(); + Assert.fail(e.getMessage()); + } + // obtain domain + domain = SCADomain.newInstance("ScenarioThree.composite"); + } catch (Exception e) { + e.printStackTrace(); + } + } + + /** + * Kills previously spawned name service. + */ + @AfterClass + public static void tearDown() { + server.stop(); + } + + /** + * Tests mapping for getters and setters + */ + @Test + public void test_getterSetter() { + try { + TScenarioThree ref = + domain.getService(TScenarioThreeComponent.class, "ScenarioThreeReference").getScenarioThree(); + ref.getIntField(); + ref.setIntField(1); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests mapping the same operation names but with different cases + */ + @Test + public void test_nameCase() { + try { + TScenarioThree ref = + domain.getService(TScenarioThreeComponent.class, "ScenarioThreeReference").getScenarioThree(); + assertEquals(0, ref.caseDifferent()); + assertEquals(1, ref.CaseDifferent()); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests mappings for operations with overloaded names + */ + @Test + public void test_overloadedNames() { + try { + TScenarioThree ref = + domain.getService(TScenarioThreeComponent.class, "ScenarioThreeReference").getScenarioThree(); + ref.overloadedName(); + ref.overloadedName(""); + ref.overloadedName("", 0); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioTwoTestCase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioTwoTestCase.java new file mode 100644 index 0000000000..008212bdbe --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/ScenarioTwoTestCase.java @@ -0,0 +1,139 @@ +/* + * 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.test.corba; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.fail; +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.apache.tuscany.sca.host.corba.naming.TransientNameServer; +import org.apache.tuscany.sca.host.corba.naming.TransientNameService; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.test.corba.generated.ScenarioTwo; +import org.apache.tuscany.sca.test.corba.generated.ScenarioTwoHelper; +import org.apache.tuscany.sca.test.corba.types.ScenarioTwoServant; +import org.apache.tuscany.sca.test.corba.types.TScenarioTwo; +import org.apache.tuscany.sca.test.corba.types.TScenarioTwoComponent; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; +import org.omg.CORBA.ORB; +import org.omg.CosNaming.NameComponent; +import org.omg.CosNaming.NamingContext; +import org.omg.CosNaming.NamingContextHelper; + +/** + * @version $Rev$ $Date$ + * Tests attribute get/set mapping using cooperation between traditional CORBA + * and Tuscany CORBA + */ +public class ScenarioTwoTestCase { + + // note that those values are also used in resources/*.composite file + private static int ORB_INITIAL_PORT = 5060; + + private static SCADomain domain; + + private static TransientNameServer server; + private static ORB orb; + private static String TUSCANY_SERVICE_NAME = "ScenarioTwo"; + private static String GENERATED_SERVICE_NAME = "ScenarioTwoGenerated"; + + /** + * Sets up name service, creates and registers traditional CORBA service, + * obtains SCADomain + */ + @BeforeClass + public static void setUp() { + TestCorbaHost.setCorbaHost(new DefaultCorbaHost()); + try { + try { + server = + new TransientNameServer("localhost", ORB_INITIAL_PORT, TransientNameService.DEFAULT_SERVICE_NAME); + Thread t = server.start(); + if (t == null) { + Assert.fail("The naming server cannot be started"); + } + orb = server.getORB(); + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(GENERATED_SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioTwo scenarioTwo = new ScenarioTwoServant(); + ncRef.rebind(path, scenarioTwo); + } catch (Throwable e) { + e.printStackTrace(); + Assert.fail(e.getMessage()); + } + // obtain domain + domain = SCADomain.newInstance("ScenarioTwo.composite"); + } catch (Exception e) { + e.printStackTrace(); + } + } + + /** + * Kills previously spawned name service. + */ + @AfterClass + public static void tearDown() { + server.stop(); + } + + /** + * Tests using objects attribute (which is server in traditional way) by + * Tuscany CORBA binding + */ + @Test + public void test_tuscanyGetSetAttribute() { + try { + TScenarioTwo ref = domain.getService(TScenarioTwoComponent.class, "ScenarioTwo").getScenarioTwo(); + String strVal = "Whatever"; + ref.setStringField(strVal); + assertEquals(strVal, ref.getStringField()); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + + /** + * Tests using objects attribute (which is served by Tuscany) in traditional + * way (by idlj generated code) + */ + @Test + public void test_getneratedGetSetAttribute() { + try { + orb = server.getORB(); + org.omg.CORBA.Object objRef = orb.resolve_initial_references("NameService"); + NamingContext ncRef = NamingContextHelper.narrow(objRef); + NameComponent nc = new NameComponent(TUSCANY_SERVICE_NAME, ""); + NameComponent path[] = {nc}; + ScenarioTwo st = ScenarioTwoHelper.narrow(ncRef.resolve(path)); + st.stringField(""); + assertEquals("", st.stringField()); + } catch (Exception e) { + e.printStackTrace(); + fail(); + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHost.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHost.java new file mode 100644 index 0000000000..bd1ce8cb49 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHost.java @@ -0,0 +1,56 @@ +/* + * 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.test.corba; + +import org.apache.tuscany.sca.host.corba.CorbaHost; +import org.apache.tuscany.sca.host.corba.CorbaHostException; +import org.apache.tuscany.sca.host.corba.jse.DefaultCorbaHost; +import org.omg.CORBA.Object; + +/** + * @version $Rev$ $Date$ + * Mock Corba host which proxies to configured Corba host + */ +public class TestCorbaHost implements CorbaHost { + + private static CorbaHost corbaHost = new DefaultCorbaHost(); + + /** + * Configures environment to use given Corba host + * + * @param corbaHost Corba host to use + */ + public static void setCorbaHost(CorbaHost corbaHost) { + TestCorbaHost.corbaHost = corbaHost; + } + + public Object lookup(String arg0) throws CorbaHostException { + return TestCorbaHost.corbaHost.lookup(arg0); + } + + public void registerServant(String arg0, Object arg1) throws CorbaHostException { + TestCorbaHost.corbaHost.registerServant(arg0, arg1); + } + + public void unregisterServant(String arg0) throws CorbaHostException { + TestCorbaHost.corbaHost.unregisterServant(arg0); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHostModuleActivator.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHostModuleActivator.java new file mode 100644 index 0000000000..c25372c837 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/TestCorbaHostModuleActivator.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba; + +import org.apache.tuscany.sca.core.ExtensionPointRegistry; +import org.apache.tuscany.sca.core.ModuleActivator; +import org.apache.tuscany.sca.host.corba.CorbaHostExtensionPoint; + +/** + * @version $Rev$ $Date$ + * Registers TestCorbaHost as a Corba host extension. + */ +public class TestCorbaHostModuleActivator implements ModuleActivator { + + public void start(ExtensionPointRegistry extensionPointRegistry) { + CorbaHostExtensionPoint chep = extensionPointRegistry.getExtensionPoint(CorbaHostExtensionPoint.class); + chep.getCorbaHosts().add(0, new TestCorbaHost()); + } + + public void stop(ExtensionPointRegistry extensionPointRegistry) { + + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java new file mode 100644 index 0000000000..abcec43d0e --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java @@ -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 org.apache.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +public final class AnnotatedStruct implements org.omg.CORBA.portable.IDLEntity +{ + public String stringArray[][] = null; + + public AnnotatedStruct () + { + } // ctor + + public AnnotatedStruct (String[][] _stringArray) + { + stringArray = _stringArray; + } // ctor + +} // class AnnotatedStruct diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java new file mode 100644 index 0000000000..171a7919a2 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java @@ -0,0 +1,97 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +abstract public class AnnotatedStructHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/AnnotatedStruct/AnnotatedStruct:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + private static boolean __active = false; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + synchronized (org.omg.CORBA.TypeCode.class) + { + if (__typeCode == null) + { + if (__active) + { + return org.omg.CORBA.ORB.init().create_recursive_tc ( _id ); + } + __active = true; + org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [1]; + org.omg.CORBA.TypeCode _tcOf_members0 = null; + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_string_tc (0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_array_tc (2, _tcOf_members0 ); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_array_tc (2, _tcOf_members0 ); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.id (), "StringArray", _tcOf_members0); + _members0[0] = new org.omg.CORBA.StructMember ( + "stringArray", + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_struct_tc (org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.id (), "AnnotatedStruct", _members0); + __active = false; + } + } + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct value = new org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct (); + value.stringArray = org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.read (istream); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct value) + { + org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.write (ostream, value.stringArray); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java new file mode 100644 index 0000000000..5f2dc56033 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/AnnotatedStructHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +public final class AnnotatedStructHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct value = null; + + public AnnotatedStructHolder () + { + } + + public AnnotatedStructHolder (org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/Color.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/Color.java new file mode 100644 index 0000000000..24a628d406 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/Color.java @@ -0,0 +1,61 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/Color.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public class Color implements org.omg.CORBA.portable.IDLEntity +{ + private int __value; + private static int __size = 3; + private static org.apache.tuscany.sca.test.corba.generated.Color[] __array = new org.apache.tuscany.sca.test.corba.generated.Color [__size]; + + public static final int _red = 0; + public static final org.apache.tuscany.sca.test.corba.generated.Color red = new org.apache.tuscany.sca.test.corba.generated.Color(_red); + public static final int _yellow = 1; + public static final org.apache.tuscany.sca.test.corba.generated.Color yellow = new org.apache.tuscany.sca.test.corba.generated.Color(_yellow); + public static final int _green = 2; + public static final org.apache.tuscany.sca.test.corba.generated.Color green = new org.apache.tuscany.sca.test.corba.generated.Color(_green); + + public int value () + { + return __value; + } + + public static org.apache.tuscany.sca.test.corba.generated.Color from_int (int value) + { + if (value >= 0 && value < __size) + return __array[value]; + else + throw new org.omg.CORBA.BAD_PARAM (); + } + + protected Color (int value) + { + __value = value; + __array[__value] = this; + } +} // class Color diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHelper.java new file mode 100644 index 0000000000..da37f28e39 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHelper.java @@ -0,0 +1,72 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ColorHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class ColorHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/Color:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.Color that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.Color extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_enum_tc (org.apache.tuscany.sca.test.corba.generated.ColorHelper.id (), "Color", new String[] { "red", "yellow", "green"} ); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.Color read (org.omg.CORBA.portable.InputStream istream) + { + return org.apache.tuscany.sca.test.corba.generated.Color.from_int (istream.read_long ()); + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.Color value) + { + ostream.write_long (value.value ()); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHolder.java new file mode 100644 index 0000000000..7b2466f791 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ColorHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/ColorHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class ColorHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.Color value = null; + + public ColorHolder () + { + } + + public ColorHolder (org.apache.tuscany.sca.test.corba.generated.Color initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.ColorHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.ColorHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.ColorHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStruct.java new file mode 100644 index 0000000000..27052a1549 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStruct.java @@ -0,0 +1,47 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerStruct.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class InnerStruct implements org.omg.CORBA.portable.IDLEntity +{ + public int twoDimLongSequence[][] = null; + public String stringField = null; + public org.apache.tuscany.sca.test.corba.generated.Color color = null; + + public InnerStruct () + { + } // ctor + + public InnerStruct (int[][] _twoDimLongSequence, String _stringField, org.apache.tuscany.sca.test.corba.generated.Color _color) + { + twoDimLongSequence = _twoDimLongSequence; + stringField = _stringField; + color = _color; + } // ctor + +} // class InnerStruct diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java new file mode 100644 index 0000000000..57daa51f42 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java @@ -0,0 +1,112 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerStructHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class InnerStructHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/InnerStruct/InnerStruct:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.InnerStruct that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.InnerStruct extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + private static boolean __active = false; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + synchronized (org.omg.CORBA.TypeCode.class) + { + if (__typeCode == null) + { + if (__active) + { + return org.omg.CORBA.ORB.init().create_recursive_tc ( _id ); + } + __active = true; + org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [3]; + org.omg.CORBA.TypeCode _tcOf_members0 = null; + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_sequence_tc (0, _tcOf_members0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.id (), "LongSequence", _tcOf_members0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_sequence_tc (0, _tcOf_members0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.id (), "TwoDimLongSequence", _tcOf_members0); + _members0[0] = new org.omg.CORBA.StructMember ( + "twoDimLongSequence", + _tcOf_members0, + null); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_string_tc (0); + _members0[1] = new org.omg.CORBA.StructMember ( + "stringField", + _tcOf_members0, + null); + _tcOf_members0 = org.apache.tuscany.sca.test.corba.generated.ColorHelper.type (); + _members0[2] = new org.omg.CORBA.StructMember ( + "color", + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_struct_tc (org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.id (), "InnerStruct", _members0); + __active = false; + } + } + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.InnerStruct read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.InnerStruct value = new org.apache.tuscany.sca.test.corba.generated.InnerStruct (); + value.twoDimLongSequence = org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.read (istream); + value.stringField = istream.read_string (); + value.color = org.apache.tuscany.sca.test.corba.generated.ColorHelper.read (istream); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.InnerStruct value) + { + org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.write (ostream, value.twoDimLongSequence); + ostream.write_string (value.stringField); + org.apache.tuscany.sca.test.corba.generated.ColorHelper.write (ostream, value.color); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java new file mode 100644 index 0000000000..88fef0b4fb --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerStructHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class InnerStructHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.InnerStruct value = null; + + public InnerStructHolder () + { + } + + public InnerStructHolder (org.apache.tuscany.sca.test.corba.generated.InnerStruct initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnion.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnion.java new file mode 100644 index 0000000000..40c017dd29 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnion.java @@ -0,0 +1,112 @@ +package org.apache.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerUnion.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public final class InnerUnion implements org.omg.CORBA.portable.IDLEntity +{ + private int ___x; + private float ___y; + private int __discriminator; + private boolean __uninitialized = true; + + public InnerUnion () + { + } + + public int discriminator () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + return __discriminator; + } + + public int x () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyx (__discriminator); + return ___x; + } + + public void x (int value) + { + __discriminator = 1; + ___x = value; + __uninitialized = false; + } + + public void x (int discriminator, int value) + { + verifyx (discriminator); + __discriminator = discriminator; + ___x = value; + __uninitialized = false; + } + + private void verifyx (int discriminator) + { + if (discriminator != 1) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public float y () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyy (__discriminator); + return ___y; + } + + public void y (float value) + { + __discriminator = 2; + ___y = value; + __uninitialized = false; + } + + public void y (int discriminator, float value) + { + verifyy (discriminator); + __discriminator = discriminator; + ___y = value; + __uninitialized = false; + } + + private void verifyy (int discriminator) + { + if (discriminator != 2) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public void _default () + { + __discriminator = -2147483648; + __uninitialized = false; + } + + public void _default (int discriminator) + { + verifyDefault( discriminator ) ; + __discriminator = discriminator ; + __uninitialized = false; + } + + private void verifyDefault( int value ) + { + switch (value) { + case 1: + case 2: + throw new org.omg.CORBA.BAD_OPERATION() ; + + default: + return; + } + } + +} // class InnerUnion diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java new file mode 100644 index 0000000000..6ec067521e --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java @@ -0,0 +1,106 @@ +package org.apache.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerUnionHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +abstract public class InnerUnionHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/InnerUnion/InnerUnion:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.InnerUnion that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.InnerUnion extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + org.omg.CORBA.TypeCode _disTypeCode0; + _disTypeCode0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + org.omg.CORBA.UnionMember[] _members0 = new org.omg.CORBA.UnionMember [2]; + org.omg.CORBA.TypeCode _tcOf_members0; + org.omg.CORBA.Any _anyOf_members0; + + // Branch for x (case label 1) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)1); + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + _members0[0] = new org.omg.CORBA.UnionMember ( + "x", + _anyOf_members0, + _tcOf_members0, + null); + + // Branch for y (case label 2) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)2); + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_float); + _members0[1] = new org.omg.CORBA.UnionMember ( + "y", + _anyOf_members0, + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_union_tc (org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.id (), "InnerUnion", _disTypeCode0, _members0); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.InnerUnion read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.InnerUnion value = new org.apache.tuscany.sca.test.corba.generated.InnerUnion (); + int _dis0 = (int)0; + _dis0 = istream.read_long (); + switch (_dis0) + { + case 1: + int _x = (int)0; + _x = istream.read_long (); + value.x (_x); + break; + case 2: + float _y = (float)0; + _y = istream.read_float (); + value.y (_y); + break; + default: + value._default( _dis0 ) ; + break; + } + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.InnerUnion value) + { + ostream.write_long (value.discriminator ()); + switch (value.discriminator ()) + { + case 1: + ostream.write_long (value.x ()); + break; + case 2: + ostream.write_float (value.y ()); + break; + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java new file mode 100644 index 0000000000..8955f81694 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java @@ -0,0 +1,38 @@ +package org.apache.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/InnerUnionHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public final class InnerUnionHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.InnerUnion value = null; + + public InnerUnionHolder () + { + } + + public InnerUnionHolder (org.apache.tuscany.sca.test.corba.generated.InnerUnion initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java new file mode 100644 index 0000000000..940b391499 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java @@ -0,0 +1,79 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/LongSequenceHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class LongSequenceHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/LongSequence:1.0"; + + public static void insert (org.omg.CORBA.Any a, int[] that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static int[] extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + __typeCode = org.omg.CORBA.ORB.init ().create_sequence_tc (0, __typeCode); + __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.id (), "LongSequence", __typeCode); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static int[] read (org.omg.CORBA.portable.InputStream istream) + { + int value[] = null; + int _len0 = istream.read_long (); + value = new int[_len0]; + istream.read_long_array (value, 0, _len0); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, int[] value) + { + ostream.write_long (value.length); + ostream.write_long_array (value, 0, value.length); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java new file mode 100644 index 0000000000..63a11dc56a --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java @@ -0,0 +1,58 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/LongSequenceHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class LongSequenceHolder implements org.omg.CORBA.portable.Streamable +{ + public int value[] = null; + + public LongSequenceHolder () + { + } + + public LongSequenceHolder (int[] initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStruct.java new file mode 100644 index 0000000000..8c0bfc9e39 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStruct.java @@ -0,0 +1,47 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/RichStruct.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class RichStruct implements org.omg.CORBA.portable.IDLEntity +{ + public org.apache.tuscany.sca.test.corba.generated.InnerStruct innerStruct = null; + public String stringSequence[] = null; + public int longField = (int)0; + + public RichStruct () + { + } // ctor + + public RichStruct (org.apache.tuscany.sca.test.corba.generated.InnerStruct _innerStruct, String[] _stringSequence, int _longField) + { + innerStruct = _innerStruct; + stringSequence = _stringSequence; + longField = _longField; + } // ctor + +} // class RichStruct diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java new file mode 100644 index 0000000000..72ff55a711 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java @@ -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.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/RichStructHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class RichStructHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/RichStruct/RichStruct:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.RichStruct that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.RichStruct extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + private static boolean __active = false; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + synchronized (org.omg.CORBA.TypeCode.class) + { + if (__typeCode == null) + { + if (__active) + { + return org.omg.CORBA.ORB.init().create_recursive_tc ( _id ); + } + __active = true; + org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [3]; + org.omg.CORBA.TypeCode _tcOf_members0 = null; + _tcOf_members0 = org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.type (); + _members0[0] = new org.omg.CORBA.StructMember ( + "innerStruct", + _tcOf_members0, + null); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_string_tc (0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_sequence_tc (0, _tcOf_members0); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.id (), "StringSequence", _tcOf_members0); + _members0[1] = new org.omg.CORBA.StructMember ( + "stringSequence", + _tcOf_members0, + null); + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + _members0[2] = new org.omg.CORBA.StructMember ( + "longField", + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_struct_tc (org.apache.tuscany.sca.test.corba.generated.RichStructHelper.id (), "RichStruct", _members0); + __active = false; + } + } + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.RichStruct read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.RichStruct value = new org.apache.tuscany.sca.test.corba.generated.RichStruct (); + value.innerStruct = org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.read (istream); + value.stringSequence = org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.read (istream); + value.longField = istream.read_long (); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.RichStruct value) + { + org.apache.tuscany.sca.test.corba.generated.InnerStructHelper.write (ostream, value.innerStruct); + org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.write (ostream, value.stringSequence); + ostream.write_long (value.longField); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java new file mode 100644 index 0000000000..8a063b8b9d --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/RichStructHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class RichStructHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.RichStruct value = null; + + public RichStructHolder () + { + } + + public RichStructHolder (org.apache.tuscany.sca.test.corba.generated.RichStruct initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.RichStructHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.RichStructHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.RichStructHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnion.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnion.java new file mode 100644 index 0000000000..4a3376c476 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnion.java @@ -0,0 +1,177 @@ +package org.apache.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/RichUnion.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public final class RichUnion implements org.omg.CORBA.portable.IDLEntity +{ + private int ___x; + private float ___y; + private String ___z; + private org.apache.tuscany.sca.test.corba.generated.InnerUnion ___iu; + private boolean ___a; + private int __discriminator; + private boolean __uninitialized = true; + + public RichUnion () + { + } + + public int discriminator () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + return __discriminator; + } + + public int x () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyx (__discriminator); + return ___x; + } + + public void x (int value) + { + __discriminator = 1; + ___x = value; + __uninitialized = false; + } + + public void x (int discriminator, int value) + { + verifyx (discriminator); + __discriminator = discriminator; + ___x = value; + __uninitialized = false; + } + + private void verifyx (int discriminator) + { + if (discriminator != 1) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public float y () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyy (__discriminator); + return ___y; + } + + public void y (float value) + { + __discriminator = 2; + ___y = value; + __uninitialized = false; + } + + public void y (int discriminator, float value) + { + verifyy (discriminator); + __discriminator = discriminator; + ___y = value; + __uninitialized = false; + } + + private void verifyy (int discriminator) + { + if (discriminator != 2) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public String z () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyz (__discriminator); + return ___z; + } + + public void z (String value) + { + __discriminator = 3; + ___z = value; + __uninitialized = false; + } + + public void z (int discriminator, String value) + { + verifyz (discriminator); + __discriminator = discriminator; + ___z = value; + __uninitialized = false; + } + + private void verifyz (int discriminator) + { + if (discriminator != 3) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public org.apache.tuscany.sca.test.corba.generated.InnerUnion iu () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifyiu (__discriminator); + return ___iu; + } + + public void iu (org.apache.tuscany.sca.test.corba.generated.InnerUnion value) + { + __discriminator = 4; + ___iu = value; + __uninitialized = false; + } + + public void iu (int discriminator, org.apache.tuscany.sca.test.corba.generated.InnerUnion value) + { + verifyiu (discriminator); + __discriminator = discriminator; + ___iu = value; + __uninitialized = false; + } + + private void verifyiu (int discriminator) + { + if (discriminator != 4) + throw new org.omg.CORBA.BAD_OPERATION (); + } + + public boolean a () + { + if (__uninitialized) + throw new org.omg.CORBA.BAD_OPERATION (); + verifya (__discriminator); + return ___a; + } + + public void a (boolean value) + { + __discriminator = -2147483648; + ___a = value; + __uninitialized = false; + } + + public void a (int discriminator, boolean value) + { + verifya (discriminator); + __discriminator = discriminator; + ___a = value; + __uninitialized = false; + } + + private void verifya (int discriminator) + { + if (discriminator == 1 || discriminator == 2 || discriminator == 3 || discriminator == 4) + throw new org.omg.CORBA.BAD_OPERATION (); + } + +} // class RichUnion diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java new file mode 100644 index 0000000000..9b89d7f98a --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java @@ -0,0 +1,157 @@ +package org.apache.tuscany.sca.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/RichUnionHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +abstract public class RichUnionHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/RichUnion/RichUnion:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.RichUnion that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.RichUnion extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + org.omg.CORBA.TypeCode _disTypeCode0; + _disTypeCode0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + org.omg.CORBA.UnionMember[] _members0 = new org.omg.CORBA.UnionMember [5]; + org.omg.CORBA.TypeCode _tcOf_members0; + org.omg.CORBA.Any _anyOf_members0; + + // Branch for x (case label 1) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)1); + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + _members0[0] = new org.omg.CORBA.UnionMember ( + "x", + _anyOf_members0, + _tcOf_members0, + null); + + // Branch for y (case label 2) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)2); + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_float); + _members0[1] = new org.omg.CORBA.UnionMember ( + "y", + _anyOf_members0, + _tcOf_members0, + null); + + // Branch for z (case label 3) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)3); + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_string_tc (0); + _members0[2] = new org.omg.CORBA.UnionMember ( + "z", + _anyOf_members0, + _tcOf_members0, + null); + + // Branch for iu (case label 4) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_long ((int)4); + _tcOf_members0 = org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.type (); + _members0[3] = new org.omg.CORBA.UnionMember ( + "iu", + _anyOf_members0, + _tcOf_members0, + null); + + // Branch for a (Default case) + _anyOf_members0 = org.omg.CORBA.ORB.init ().create_any (); + _anyOf_members0.insert_octet ((byte)0); // default member label + _tcOf_members0 = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_boolean); + _members0[4] = new org.omg.CORBA.UnionMember ( + "a", + _anyOf_members0, + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_union_tc (org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.id (), "RichUnion", _disTypeCode0, _members0); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.RichUnion read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.RichUnion value = new org.apache.tuscany.sca.test.corba.generated.RichUnion (); + int _dis0 = (int)0; + _dis0 = istream.read_long (); + switch (_dis0) + { + case 1: + int _x = (int)0; + _x = istream.read_long (); + value.x (_x); + break; + case 2: + float _y = (float)0; + _y = istream.read_float (); + value.y (_y); + break; + case 3: + String _z = null; + _z = istream.read_string (); + value.z (_z); + break; + case 4: + org.apache.tuscany.sca.test.corba.generated.InnerUnion _iu = null; + _iu = org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.read (istream); + value.iu (_iu); + break; + default: + boolean _a = false; + _a = istream.read_boolean (); + value.a (_dis0, _a); + break; + } + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.RichUnion value) + { + ostream.write_long (value.discriminator ()); + switch (value.discriminator ()) + { + case 1: + ostream.write_long (value.x ()); + break; + case 2: + ostream.write_float (value.y ()); + break; + case 3: + ostream.write_string (value.z ()); + break; + case 4: + org.apache.tuscany.sca.test.corba.generated.InnerUnionHelper.write (ostream, value.iu ()); + break; + default: + ostream.write_boolean (value.a ()); + break; + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java new file mode 100644 index 0000000000..3c1a1c9a83 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java @@ -0,0 +1,38 @@ +package org.apache.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/RichUnionHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public final class RichUnionHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.RichUnion value = null; + + public RichUnionHolder () + { + } + + public RichUnionHolder (org.apache.tuscany.sca.test.corba.generated.RichUnion initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java new file mode 100644 index 0000000000..13f294b871 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java @@ -0,0 +1,32 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioOne.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public interface ScenarioOne extends ScenarioOneOperations, org.omg.CORBA.Object, org.omg.CORBA.portable.IDLEntity +{ +} // interface ScenarioOne diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java new file mode 100644 index 0000000000..66cc1d1e82 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java @@ -0,0 +1,104 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioOneHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class ScenarioOneHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioOne:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.ScenarioOne that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioOne extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (org.apache.tuscany.sca.test.corba.generated.ScenarioOneHelper.id (), "ScenarioOne"); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioOne read (org.omg.CORBA.portable.InputStream istream) + { + return narrow (istream.read_Object (_ScenarioOneStub.class)); + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.ScenarioOne value) + { + ostream.write_Object ((org.omg.CORBA.Object) value); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioOne narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioOne) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioOne)obj; + else if (!obj._is_a (id ())) + throw new org.omg.CORBA.BAD_PARAM (); + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioOneStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioOneStub (); + stub._set_delegate(delegate); + return stub; + } + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioOne unchecked_narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioOne) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioOne)obj; + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioOneStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioOneStub (); + stub._set_delegate(delegate); + return stub; + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java new file mode 100644 index 0000000000..f14394b400 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioOneHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class ScenarioOneHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.ScenarioOne value = null; + + public ScenarioOneHolder () + { + } + + public ScenarioOneHolder (org.apache.tuscany.sca.test.corba.generated.ScenarioOne initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.ScenarioOneHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.ScenarioOneHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.ScenarioOneHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java new file mode 100644 index 0000000000..56388624d7 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java @@ -0,0 +1,33 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioOneOperations.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public interface ScenarioOneOperations +{ + org.apache.tuscany.sca.test.corba.generated.RichStruct setRichStruct (org.apache.tuscany.sca.test.corba.generated.RichStruct richStruct) throws org.apache.tuscany.sca.test.corba.generated.WrongColor, org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +} // interface ScenarioOneOperations diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java new file mode 100644 index 0000000000..1897d0682c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java @@ -0,0 +1,32 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioSix.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +public interface ScenarioSix extends ScenarioSixOperations, org.omg.CORBA.Object, org.omg.CORBA.portable.IDLEntity +{ +} // interface ScenarioSix diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java new file mode 100644 index 0000000000..c8c88ef91d --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java @@ -0,0 +1,104 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioSixHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +abstract public class ScenarioSixHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioSix:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.ScenarioSix that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioSix extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (org.apache.tuscany.sca.test.corba.generated.ScenarioSixHelper.id (), "ScenarioSix"); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioSix read (org.omg.CORBA.portable.InputStream istream) + { + return narrow (istream.read_Object (_ScenarioSixStub.class)); + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.ScenarioSix value) + { + ostream.write_Object ((org.omg.CORBA.Object) value); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioSix narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioSix) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioSix)obj; + else if (!obj._is_a (id ())) + throw new org.omg.CORBA.BAD_PARAM (); + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioSixStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioSixStub (); + stub._set_delegate(delegate); + return stub; + } + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioSix unchecked_narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioSix) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioSix)obj; + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioSixStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioSixStub (); + stub._set_delegate(delegate); + return stub; + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java new file mode 100644 index 0000000000..5540b98c21 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioSixHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +public final class ScenarioSixHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.ScenarioSix value = null; + + public ScenarioSixHolder () + { + } + + public ScenarioSixHolder (org.apache.tuscany.sca.test.corba.generated.ScenarioSix initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.ScenarioSixHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.ScenarioSixHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.ScenarioSixHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java new file mode 100644 index 0000000000..648144299c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java @@ -0,0 +1,35 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioSixOperations.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public interface ScenarioSixOperations +{ + String[][] passStringArray (String[][] arg); + org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct passAnnotatedStruct (org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct arg); + org.apache.tuscany.sca.test.corba.generated.RichUnion passRichUnion (org.apache.tuscany.sca.test.corba.generated.RichUnion arg); +} // interface ScenarioSixOperations diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java new file mode 100644 index 0000000000..b57e098a56 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java @@ -0,0 +1,34 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioTwo.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +public interface ScenarioTwo extends ScenarioTwoOperations, org.omg.CORBA.Object, org.omg.CORBA.portable.IDLEntity +{ +} // interface ScenarioTwo diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java new file mode 100644 index 0000000000..8ddfa10575 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java @@ -0,0 +1,106 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +abstract public class ScenarioTwoHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioTwo:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.ScenarioTwo that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioTwo extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_interface_tc (org.apache.tuscany.sca.test.corba.generated.ScenarioTwoHelper.id (), "ScenarioTwo"); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioTwo read (org.omg.CORBA.portable.InputStream istream) + { + return narrow (istream.read_Object (_ScenarioTwoStub.class)); + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.ScenarioTwo value) + { + ostream.write_Object ((org.omg.CORBA.Object) value); + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioTwo narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioTwo) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioTwo)obj; + else if (!obj._is_a (id ())) + throw new org.omg.CORBA.BAD_PARAM (); + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioTwoStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioTwoStub (); + stub._set_delegate(delegate); + return stub; + } + } + + public static org.apache.tuscany.sca.test.corba.generated.ScenarioTwo unchecked_narrow (org.omg.CORBA.Object obj) + { + if (obj == null) + return null; + else if (obj instanceof org.apache.tuscany.sca.test.corba.generated.ScenarioTwo) + return (org.apache.tuscany.sca.test.corba.generated.ScenarioTwo)obj; + else + { + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate (); + org.apache.tuscany.sca.test.corba.generated._ScenarioTwoStub stub = new org.apache.tuscany.sca.test.corba.generated._ScenarioTwoStub (); + stub._set_delegate(delegate); + return stub; + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java new file mode 100644 index 0000000000..9717629711 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java @@ -0,0 +1,59 @@ +/* + * 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.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioTwoHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +public final class ScenarioTwoHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.ScenarioTwo value = null; + + public ScenarioTwoHolder () + { + } + + public ScenarioTwoHolder (org.apache.tuscany.sca.test.corba.generated.ScenarioTwo initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.ScenarioTwoHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.ScenarioTwoHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.ScenarioTwoHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java new file mode 100644 index 0000000000..1247b4618d --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java @@ -0,0 +1,36 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/ScenarioTwoOperations.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +public interface ScenarioTwoOperations +{ + String stringField (); + void stringField (String newStringField); +} // interface ScenarioTwoOperations diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java new file mode 100644 index 0000000000..f2cc3adad5 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java @@ -0,0 +1,95 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/StringArrayHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +abstract public class StringArrayHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/StringArray:1.0"; + + public static void insert (org.omg.CORBA.Any a, String[][] that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static String[][] extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_string_tc (0); + __typeCode = org.omg.CORBA.ORB.init ().create_array_tc (2, __typeCode ); + __typeCode = org.omg.CORBA.ORB.init ().create_array_tc (2, __typeCode ); + __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.id (), "StringArray", __typeCode); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static String[][] read (org.omg.CORBA.portable.InputStream istream) + { + String value[][] = null; + value = new String[2][]; + for (int _o0 = 0;_o0 < (2); ++_o0) + { + value[_o0] = new String[2]; + for (int _o1 = 0;_o1 < (2); ++_o1) + { + value[_o0][_o1] = istream.read_string (); + } + } + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, String[][] value) + { + if (value.length != (2)) + throw new org.omg.CORBA.MARSHAL (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + for (int _i0 = 0;_i0 < (2); ++_i0) + { + if (value[_i0].length != (2)) + throw new org.omg.CORBA.MARSHAL (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + for (int _i1 = 0;_i1 < (2); ++_i1) + { + ostream.write_string (value[_i0][_i1]); + } + } + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java new file mode 100644 index 0000000000..dbad550222 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java @@ -0,0 +1,58 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/StringArrayHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* sobota, 16 sierpieñ 2008 15:31:35 CEST +*/ + +public final class StringArrayHolder implements org.omg.CORBA.portable.Streamable +{ + public String value[][] = null; + + public StringArrayHolder () + { + } + + public StringArrayHolder (String[][] initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java new file mode 100644 index 0000000000..d29129236c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java @@ -0,0 +1,81 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/StringSequenceHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class StringSequenceHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/StringSequence:1.0"; + + public static void insert (org.omg.CORBA.Any a, String[] that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static String[] extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().create_string_tc (0); + __typeCode = org.omg.CORBA.ORB.init ().create_sequence_tc (0, __typeCode); + __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.id (), "StringSequence", __typeCode); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static String[] read (org.omg.CORBA.portable.InputStream istream) + { + String value[] = null; + int _len0 = istream.read_long (); + value = new String[_len0]; + for (int _o1 = 0;_o1 < value.length; ++_o1) + value[_o1] = istream.read_string (); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, String[] value) + { + ostream.write_long (value.length); + for (int _i0 = 0;_i0 < value.length; ++_i0) + ostream.write_string (value[_i0]); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java new file mode 100644 index 0000000000..837ba04cea --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java @@ -0,0 +1,58 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/StringSequenceHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class StringSequenceHolder implements org.omg.CORBA.portable.Streamable +{ + public String value[] = null; + + public StringSequenceHolder () + { + } + + public StringSequenceHolder (String[] initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.StringSequenceHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java new file mode 100644 index 0000000000..0b24056642 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java @@ -0,0 +1,83 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class TwoDimLongSequenceHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequence:1.0"; + + public static void insert (org.omg.CORBA.Any a, int[][] that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static int[][] extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + __typeCode = org.omg.CORBA.ORB.init ().get_primitive_tc (org.omg.CORBA.TCKind.tk_long); + __typeCode = org.omg.CORBA.ORB.init ().create_sequence_tc (0, __typeCode); + __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.id (), "LongSequence", __typeCode); + __typeCode = org.omg.CORBA.ORB.init ().create_sequence_tc (0, __typeCode); + __typeCode = org.omg.CORBA.ORB.init ().create_alias_tc (org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.id (), "TwoDimLongSequence", __typeCode); + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static int[][] read (org.omg.CORBA.portable.InputStream istream) + { + int value[][] = null; + int _len0 = istream.read_long (); + value = new int[_len0][]; + for (int _o1 = 0;_o1 < value.length; ++_o1) + value[_o1] = org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.read (istream); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, int[][] value) + { + ostream.write_long (value.length); + for (int _i0 = 0;_i0 < value.length; ++_i0) + org.apache.tuscany.sca.test.corba.generated.LongSequenceHelper.write (ostream, value[_i0]); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java new file mode 100644 index 0000000000..e2ed1ab037 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java @@ -0,0 +1,58 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/TwoDimLongSequenceHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class TwoDimLongSequenceHolder implements org.omg.CORBA.portable.Streamable +{ + public int value[][] = null; + + public TwoDimLongSequenceHolder () + { + } + + public TwoDimLongSequenceHolder (int[][] initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.TwoDimLongSequenceHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java new file mode 100644 index 0000000000..46888399ed --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java @@ -0,0 +1,52 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/UnexpectedException.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class UnexpectedException extends org.omg.CORBA.UserException +{ + public String info = null; + + public UnexpectedException () + { + super(UnexpectedExceptionHelper.id()); + } // ctor + + public UnexpectedException (String _info) + { + super(UnexpectedExceptionHelper.id()); + info = _info; + } // ctor + + + public UnexpectedException (String $reason, String _info) + { + super(UnexpectedExceptionHelper.id() + " " + $reason); + info = _info; + } // ctor + +} // class UnexpectedException diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java new file mode 100644 index 0000000000..c276038050 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java @@ -0,0 +1,98 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class UnexpectedExceptionHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/UnexpectedException:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.UnexpectedException that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.UnexpectedException extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + private static boolean __active = false; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + synchronized (org.omg.CORBA.TypeCode.class) + { + if (__typeCode == null) + { + if (__active) + { + return org.omg.CORBA.ORB.init().create_recursive_tc ( _id ); + } + __active = true; + org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [1]; + org.omg.CORBA.TypeCode _tcOf_members0 = null; + _tcOf_members0 = org.omg.CORBA.ORB.init ().create_string_tc (0); + _members0[0] = new org.omg.CORBA.StructMember ( + "info", + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_exception_tc (org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.id (), "UnexpectedException", _members0); + __active = false; + } + } + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.UnexpectedException read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.UnexpectedException value = new org.apache.tuscany.sca.test.corba.generated.UnexpectedException (); + // read and discard the repository ID + istream.read_string (); + value.info = istream.read_string (); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.UnexpectedException value) + { + // write the repository ID + ostream.write_string (id ()); + ostream.write_string (value.info); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java new file mode 100644 index 0000000000..079a56b446 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/UnexpectedExceptionHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class UnexpectedExceptionHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.UnexpectedException value = null; + + public UnexpectedExceptionHolder () + { + } + + public UnexpectedExceptionHolder (org.apache.tuscany.sca.test.corba.generated.UnexpectedException initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColor.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColor.java new file mode 100644 index 0000000000..0407184598 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColor.java @@ -0,0 +1,55 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/WrongColor.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class WrongColor extends org.omg.CORBA.UserException +{ + public org.apache.tuscany.sca.test.corba.generated.Color givenColor = null; + public org.apache.tuscany.sca.test.corba.generated.Color correctColor = null; + + public WrongColor () + { + super(WrongColorHelper.id()); + } // ctor + + public WrongColor (org.apache.tuscany.sca.test.corba.generated.Color _givenColor, org.apache.tuscany.sca.test.corba.generated.Color _correctColor) + { + super(WrongColorHelper.id()); + givenColor = _givenColor; + correctColor = _correctColor; + } // ctor + + + public WrongColor (String $reason, org.apache.tuscany.sca.test.corba.generated.Color _givenColor, org.apache.tuscany.sca.test.corba.generated.Color _correctColor) + { + super(WrongColorHelper.id() + " " + $reason); + givenColor = _givenColor; + correctColor = _correctColor; + } // ctor + +} // class WrongColor diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java new file mode 100644 index 0000000000..16e099cfa3 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java @@ -0,0 +1,105 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/WrongColorHelper.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +abstract public class WrongColorHelper +{ + private static String _id = "IDL:org/apache/tuscany/sca/test/corba/generated/WrongColor:1.0"; + + public static void insert (org.omg.CORBA.Any a, org.apache.tuscany.sca.test.corba.generated.WrongColor that) + { + org.omg.CORBA.portable.OutputStream out = a.create_output_stream (); + a.type (type ()); + write (out, that); + a.read_value (out.create_input_stream (), type ()); + } + + public static org.apache.tuscany.sca.test.corba.generated.WrongColor extract (org.omg.CORBA.Any a) + { + return read (a.create_input_stream ()); + } + + private static org.omg.CORBA.TypeCode __typeCode = null; + private static boolean __active = false; + synchronized public static org.omg.CORBA.TypeCode type () + { + if (__typeCode == null) + { + synchronized (org.omg.CORBA.TypeCode.class) + { + if (__typeCode == null) + { + if (__active) + { + return org.omg.CORBA.ORB.init().create_recursive_tc ( _id ); + } + __active = true; + org.omg.CORBA.StructMember[] _members0 = new org.omg.CORBA.StructMember [2]; + org.omg.CORBA.TypeCode _tcOf_members0 = null; + _tcOf_members0 = org.apache.tuscany.sca.test.corba.generated.ColorHelper.type (); + _members0[0] = new org.omg.CORBA.StructMember ( + "givenColor", + _tcOf_members0, + null); + _tcOf_members0 = org.apache.tuscany.sca.test.corba.generated.ColorHelper.type (); + _members0[1] = new org.omg.CORBA.StructMember ( + "correctColor", + _tcOf_members0, + null); + __typeCode = org.omg.CORBA.ORB.init ().create_exception_tc (org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.id (), "WrongColor", _members0); + __active = false; + } + } + } + return __typeCode; + } + + public static String id () + { + return _id; + } + + public static org.apache.tuscany.sca.test.corba.generated.WrongColor read (org.omg.CORBA.portable.InputStream istream) + { + org.apache.tuscany.sca.test.corba.generated.WrongColor value = new org.apache.tuscany.sca.test.corba.generated.WrongColor (); + // read and discard the repository ID + istream.read_string (); + value.givenColor = org.apache.tuscany.sca.test.corba.generated.ColorHelper.read (istream); + value.correctColor = org.apache.tuscany.sca.test.corba.generated.ColorHelper.read (istream); + return value; + } + + public static void write (org.omg.CORBA.portable.OutputStream ostream, org.apache.tuscany.sca.test.corba.generated.WrongColor value) + { + // write the repository ID + ostream.write_string (id ()); + org.apache.tuscany.sca.test.corba.generated.ColorHelper.write (ostream, value.givenColor); + org.apache.tuscany.sca.test.corba.generated.ColorHelper.write (ostream, value.correctColor); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java new file mode 100644 index 0000000000..b4883cb35c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java @@ -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.tuscany.sca.test.corba.generated; + +/** +* org/apache/tuscany/sca/test/corba/generated/WrongColorHolder.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public final class WrongColorHolder implements org.omg.CORBA.portable.Streamable +{ + public org.apache.tuscany.sca.test.corba.generated.WrongColor value = null; + + public WrongColorHolder () + { + } + + public WrongColorHolder (org.apache.tuscany.sca.test.corba.generated.WrongColor initialValue) + { + value = initialValue; + } + + public void _read (org.omg.CORBA.portable.InputStream i) + { + value = org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.read (i); + } + + public void _write (org.omg.CORBA.portable.OutputStream o) + { + org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.write (o, value); + } + + public org.omg.CORBA.TypeCode _type () + { + return org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.type (); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java new file mode 100644 index 0000000000..c96fb61204 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java @@ -0,0 +1,91 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioOneImplBase.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public abstract class _ScenarioOneImplBase extends org.omg.CORBA.portable.ObjectImpl + implements org.apache.tuscany.sca.test.corba.generated.ScenarioOne, org.omg.CORBA.portable.InvokeHandler +{ + + // Constructors + public _ScenarioOneImplBase () + { + } + + private static java.util.Hashtable _methods = new java.util.Hashtable (); + static + { + _methods.put ("setRichStruct", new java.lang.Integer (0)); + } + + public org.omg.CORBA.portable.OutputStream _invoke (String $method, + org.omg.CORBA.portable.InputStream in, + org.omg.CORBA.portable.ResponseHandler $rh) + { + org.omg.CORBA.portable.OutputStream out = null; + java.lang.Integer __method = (java.lang.Integer)_methods.get ($method); + if (__method == null) + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + + switch (__method.intValue ()) + { + case 0: // org/apache/tuscany/sca/test/corba/generated/ScenarioOne/setRichStruct + { + try { + org.apache.tuscany.sca.test.corba.generated.RichStruct richStruct = org.apache.tuscany.sca.test.corba.generated.RichStructHelper.read (in); + org.apache.tuscany.sca.test.corba.generated.RichStruct $result = null; + $result = this.setRichStruct (richStruct); + out = $rh.createReply(); + org.apache.tuscany.sca.test.corba.generated.RichStructHelper.write (out, $result); + } catch (org.apache.tuscany.sca.test.corba.generated.WrongColor $ex) { + out = $rh.createExceptionReply (); + org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.write (out, $ex); + } catch (org.apache.tuscany.sca.test.corba.generated.UnexpectedException $ex) { + out = $rh.createExceptionReply (); + org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.write (out, $ex); + } + break; + } + + default: + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + } + + return out; + } // _invoke + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioOne:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + +} // class _ScenarioOneImplBase diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java new file mode 100644 index 0000000000..3427c127ec --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java @@ -0,0 +1,84 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioOneStub.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* pi±tek, 27 czerwiec 2008 20:40:03 CEST +*/ + +public class _ScenarioOneStub extends org.omg.CORBA.portable.ObjectImpl implements org.apache.tuscany.sca.test.corba.generated.ScenarioOne +{ + + public org.apache.tuscany.sca.test.corba.generated.RichStruct setRichStruct (org.apache.tuscany.sca.test.corba.generated.RichStruct richStruct) throws org.apache.tuscany.sca.test.corba.generated.WrongColor, org.apache.tuscany.sca.test.corba.generated.UnexpectedException + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("setRichStruct", true); + org.apache.tuscany.sca.test.corba.generated.RichStructHelper.write ($out, richStruct); + $in = _invoke ($out); + org.apache.tuscany.sca.test.corba.generated.RichStruct $result = org.apache.tuscany.sca.test.corba.generated.RichStructHelper.read ($in); + return $result; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + if (_id.equals ("IDL:org/apache/tuscany/sca/test/corba/generated/WrongColor:1.0")) + throw org.apache.tuscany.sca.test.corba.generated.WrongColorHelper.read ($in); + else if (_id.equals ("IDL:org/apache/tuscany/sca/test/corba/generated/UnexpectedException:1.0")) + throw org.apache.tuscany.sca.test.corba.generated.UnexpectedExceptionHelper.read ($in); + else + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + return setRichStruct (richStruct ); + } finally { + _releaseReply ($in); + } + } // setRichStruct + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioOne:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + private void readObject (java.io.ObjectInputStream s) throws java.io.IOException + { + String str = s.readUTF (); + String[] args = null; + java.util.Properties props = null; + org.omg.CORBA.Object obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str); + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)._get_delegate (); + _set_delegate (delegate); + } + + private void writeObject (java.io.ObjectOutputStream s) throws java.io.IOException + { + String[] args = null; + java.util.Properties props = null; + String str = org.omg.CORBA.ORB.init (args, props).object_to_string (this); + s.writeUTF (str); + } +} // class _ScenarioOneStub diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java new file mode 100644 index 0000000000..78464fe40d --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java @@ -0,0 +1,105 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioSixImplBase.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 23:35:36 CEST +*/ + +public abstract class _ScenarioSixImplBase extends org.omg.CORBA.portable.ObjectImpl + implements org.apache.tuscany.sca.test.corba.generated.ScenarioSix, org.omg.CORBA.portable.InvokeHandler +{ + + // Constructors + public _ScenarioSixImplBase () + { + } + + private static java.util.Hashtable _methods = new java.util.Hashtable (); + static + { + _methods.put ("passStringArray", new java.lang.Integer (0)); + _methods.put ("passAnnotatedStruct", new java.lang.Integer (1)); + _methods.put ("passRichUnion", new java.lang.Integer (2)); + } + + public org.omg.CORBA.portable.OutputStream _invoke (String $method, + org.omg.CORBA.portable.InputStream in, + org.omg.CORBA.portable.ResponseHandler $rh) + { + org.omg.CORBA.portable.OutputStream out = null; + java.lang.Integer __method = (java.lang.Integer)_methods.get ($method); + if (__method == null) + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + + switch (__method.intValue ()) + { + case 0: // org/apache/tuscany/sca/test/corba/generated/ScenarioSix/passStringArray + { + String arg[][] = org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.read (in); + String $result[][] = null; + $result = this.passStringArray (arg); + out = $rh.createReply(); + org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.write (out, $result); + break; + } + + case 1: // org/apache/tuscany/sca/test/corba/generated/ScenarioSix/passAnnotatedStruct + { + org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct arg = org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.read (in); + org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct $result = null; + $result = this.passAnnotatedStruct (arg); + out = $rh.createReply(); + org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.write (out, $result); + break; + } + + case 2: // org/apache/tuscany/sca/test/corba/generated/ScenarioSix/passRichUnion + { + org.apache.tuscany.sca.test.corba.generated.RichUnion arg = org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.read (in); + org.apache.tuscany.sca.test.corba.generated.RichUnion $result = null; + $result = this.passRichUnion (arg); + out = $rh.createReply(); + org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.write (out, $result); + break; + } + + default: + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + } + + return out; + } // _invoke + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioSix:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + +} // class _ScenarioSixImplBase diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java new file mode 100644 index 0000000000..faff36c2a4 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java @@ -0,0 +1,119 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioSixStub.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* niedziela, 17 sierpieñ 2008 19:07:14 CEST +*/ + +public class _ScenarioSixStub extends org.omg.CORBA.portable.ObjectImpl implements org.apache.tuscany.sca.test.corba.generated.ScenarioSix +{ + + public String[][] passStringArray (String[][] arg) + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("passStringArray", true); + org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.write ($out, arg); + $in = _invoke ($out); + String $result[][] = org.apache.tuscany.sca.test.corba.generated.StringArrayHelper.read ($in); + return $result; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + return passStringArray (arg ); + } finally { + _releaseReply ($in); + } + } // passStringArray + + public org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct passAnnotatedStruct (org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct arg) + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("passAnnotatedStruct", true); + org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.write ($out, arg); + $in = _invoke ($out); + org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct $result = org.apache.tuscany.sca.test.corba.generated.AnnotatedStructHelper.read ($in); + return $result; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + return passAnnotatedStruct (arg ); + } finally { + _releaseReply ($in); + } + } // passAnnotatedStruct + + public org.apache.tuscany.sca.test.corba.generated.RichUnion passRichUnion (org.apache.tuscany.sca.test.corba.generated.RichUnion arg) + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("passRichUnion", true); + org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.write ($out, arg); + $in = _invoke ($out); + org.apache.tuscany.sca.test.corba.generated.RichUnion $result = org.apache.tuscany.sca.test.corba.generated.RichUnionHelper.read ($in); + return $result; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + return passRichUnion (arg ); + } finally { + _releaseReply ($in); + } + } // passRichUnion + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioSix:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + private void readObject (java.io.ObjectInputStream s) throws java.io.IOException + { + String str = s.readUTF (); + String[] args = null; + java.util.Properties props = null; + org.omg.CORBA.Object obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str); + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)._get_delegate (); + _set_delegate (delegate); + } + + private void writeObject (java.io.ObjectOutputStream s) throws java.io.IOException + { + String[] args = null; + java.util.Properties props = null; + String str = org.omg.CORBA.ORB.init (args, props).object_to_string (this); + s.writeUTF (str); + } +} // class _ScenarioSixStub diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java new file mode 100644 index 0000000000..750006cec6 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java @@ -0,0 +1,93 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoImplBase.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +public abstract class _ScenarioTwoImplBase extends org.omg.CORBA.portable.ObjectImpl + implements org.apache.tuscany.sca.test.corba.generated.ScenarioTwo, org.omg.CORBA.portable.InvokeHandler +{ + + // Constructors + public _ScenarioTwoImplBase () + { + } + + private static java.util.Hashtable _methods = new java.util.Hashtable (); + static + { + _methods.put ("_get_stringField", new java.lang.Integer (0)); + _methods.put ("_set_stringField", new java.lang.Integer (1)); + } + + public org.omg.CORBA.portable.OutputStream _invoke (String $method, + org.omg.CORBA.portable.InputStream in, + org.omg.CORBA.portable.ResponseHandler $rh) + { + org.omg.CORBA.portable.OutputStream out = null; + java.lang.Integer __method = (java.lang.Integer)_methods.get ($method); + if (__method == null) + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + + switch (__method.intValue ()) + { + case 0: // org/apache/tuscany/sca/test/corba/generated/ScenarioTwo/_get_stringField + { + String $result = null; + $result = this.stringField (); + out = $rh.createReply(); + out.write_string ($result); + break; + } + + case 1: // org/apache/tuscany/sca/test/corba/generated/ScenarioTwo/_set_stringField + { + String newStringField = in.read_string (); + this.stringField (newStringField); + out = $rh.createReply(); + break; + } + + default: + throw new org.omg.CORBA.BAD_OPERATION (0, org.omg.CORBA.CompletionStatus.COMPLETED_MAYBE); + } + + return out; + } // _invoke + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioTwo:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + +} // class _ScenarioTwoImplBase diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java new file mode 100644 index 0000000000..ef9f561d1b --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java @@ -0,0 +1,99 @@ +/* + * 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.test.corba.generated; + + +/** +* org/apache/tuscany/sca/test/corba/generated/_ScenarioTwoStub.java . +* Generated by the IDL-to-Java compiler (portable), version "3.2" +* from itest_scenario.idl +* wtorek, 15 lipiec 2008 13:36:31 CEST +*/ + + +// objects for ScenarioTwo +public class _ScenarioTwoStub extends org.omg.CORBA.portable.ObjectImpl implements org.apache.tuscany.sca.test.corba.generated.ScenarioTwo +{ + + public String stringField () + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("_get_stringField", true); + $in = _invoke ($out); + String $result = $in.read_string (); + return $result; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + return stringField ( ); + } finally { + _releaseReply ($in); + } + } // stringField + + public void stringField (String newStringField) + { + org.omg.CORBA.portable.InputStream $in = null; + try { + org.omg.CORBA.portable.OutputStream $out = _request ("_set_stringField", true); + $out.write_string (newStringField); + $in = _invoke ($out); + return; + } catch (org.omg.CORBA.portable.ApplicationException $ex) { + $in = $ex.getInputStream (); + String _id = $ex.getId (); + throw new org.omg.CORBA.MARSHAL (_id); + } catch (org.omg.CORBA.portable.RemarshalException $rm) { + stringField (newStringField ); + } finally { + _releaseReply ($in); + } + } // stringField + + // Type-specific CORBA::Object operations + private static String[] __ids = { + "IDL:org/apache/tuscany/sca/test/corba/generated/ScenarioTwo:1.0"}; + + public String[] _ids () + { + return (String[])__ids.clone (); + } + + private void readObject (java.io.ObjectInputStream s) throws java.io.IOException + { + String str = s.readUTF (); + String[] args = null; + java.util.Properties props = null; + org.omg.CORBA.Object obj = org.omg.CORBA.ORB.init (args, props).string_to_object (str); + org.omg.CORBA.portable.Delegate delegate = ((org.omg.CORBA.portable.ObjectImpl) obj)._get_delegate (); + _set_delegate (delegate); + } + + private void writeObject (java.io.ObjectOutputStream s) throws java.io.IOException + { + String[] args = null; + java.util.Properties props = null; + String str = org.omg.CORBA.ORB.init (args, props).object_to_string (this); + s.writeUTF (str); + } +} // class _ScenarioTwoStub diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFive.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFive.java new file mode 100644 index 0000000000..1bc2156183 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFive.java @@ -0,0 +1,33 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * @version $Rev$ $Date$ + * Operations for scenario five + */ +@Remotable +public interface ScenarioFive { + + void doNothing(); + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveComponent.java new file mode 100644 index 0000000000..a198eaf646 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveComponent.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for obtaining ScenarioFive reference + */ +public class ScenarioFiveComponent { + + private ScenarioFive scenarioFive; + + @Reference + public void setScenarioFive(ScenarioFive scenarioFive) { + this.scenarioFive = scenarioFive; + } + + public ScenarioFive getScenarioFive() { + return scenarioFive; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveImpl.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveImpl.java new file mode 100644 index 0000000000..dc752a2aea --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFiveImpl.java @@ -0,0 +1,32 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Implementation of ScenarioFive service + */ +public class ScenarioFiveImpl implements ScenarioFive { + + public void doNothing() { + // does nothing + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFour.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFour.java new file mode 100644 index 0000000000..aa2f06909b --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFour.java @@ -0,0 +1,38 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.scenariofour.ScenarioFourSdo; +import org.oasisopen.sca.annotation.Remotable; + +/** + * @version $Rev$ $Date$ + * Operations for ScenarioFour + */ +@Remotable +public interface ScenarioFour { + + ScenarioFourStruct setStruct(ScenarioFourStruct struct); + + void exceptionTest() throws ScenarioFourException; + + ScenarioFourSdo passScenarioFourStruct(ScenarioFourSdo scenarioFourSdo); + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourComponent.java new file mode 100644 index 0000000000..c7569720f0 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourComponent.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for obtaining ScenarioFour reference + */ +public class ScenarioFourComponent { + + private ScenarioFour scenarioFour; + + @Reference + public void setScenarioFour(ScenarioFour scenarioFour) { + this.scenarioFour = scenarioFour; + } + + public ScenarioFour getScenarioFour() { + return scenarioFour; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourException.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourException.java new file mode 100644 index 0000000000..bc76373633 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourException.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Exception for ScenarioFour tests + */ +public class ScenarioFourException extends Exception { + + public static final String DEFAULT_CONTENT = "Test"; + + private static final long serialVersionUID = 1L; + private String content; + + public String getContent() { + return content; + } + + public void setContent(String content) { + this.content = content; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourImpl.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourImpl.java new file mode 100644 index 0000000000..2f10177bd0 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourImpl.java @@ -0,0 +1,44 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.scenariofour.ScenarioFourSdo; + +/** + * @version $Rev$ $Date$ + * Implementation of ScenarioFour service + */ +public class ScenarioFourImpl implements ScenarioFour { + + public ScenarioFourStruct setStruct(ScenarioFourStruct struct) { + return struct; + } + + public void exceptionTest() throws ScenarioFourException { + ScenarioFourException exception = new ScenarioFourException(); + exception.setContent(ScenarioFourException.DEFAULT_CONTENT); + throw exception; + } + + public ScenarioFourSdo passScenarioFourStruct(ScenarioFourSdo scenarioFourSdo) { + return scenarioFourSdo; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourStruct.java new file mode 100644 index 0000000000..de8624455f --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioFourStruct.java @@ -0,0 +1,40 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Type for ScenarioFour test + */ +public class ScenarioFourStruct { + + public String field1; + public int field2; + public double[] field3; + + public boolean equals(ScenarioFourStruct arg) { + return (field1 != null && arg.field1 != null + && field1.equals(arg.field1) + && field2 == arg.field2 + && field3 != null + && arg.field3 != null && field3.length == arg.field3.length); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneComponent.java new file mode 100644 index 0000000000..1813de4e67 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneComponent.java @@ -0,0 +1,46 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.RichStruct; +import org.apache.tuscany.sca.test.corba.generated.ScenarioOne; +import org.apache.tuscany.sca.test.corba.generated.ScenarioOneOperations; +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for reference using generated interface. + */ +public class ScenarioOneComponent implements ScenarioOneOperations { + + private ScenarioOne scenarionOne; + + @Reference + public void setScenarioOne(ScenarioOne scenarioOne) { + this.scenarionOne = scenarioOne; + } + + public RichStruct setRichStruct(RichStruct richStruct) throws WrongColor, UnexpectedException { + return scenarionOne.setRichStruct(richStruct); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneServant.java new file mode 100644 index 0000000000..9b49adbfbb --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioOneServant.java @@ -0,0 +1,45 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.Color; +import org.apache.tuscany.sca.test.corba.generated.RichStruct; +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; +import org.apache.tuscany.sca.test.corba.generated._ScenarioOneImplBase; + +/** + * @version $Rev$ $Date$ + * Servant for generated interface. Uses generated classes. + */ +public class ScenarioOneServant extends _ScenarioOneImplBase { + + private static final long serialVersionUID = 1L; + + public RichStruct setRichStruct(RichStruct richStruct) throws WrongColor, UnexpectedException { + if (richStruct.innerStruct.color.value() == Color.red.value()) { + throw new WrongColor(richStruct.innerStruct.color, Color.green); + } else if (richStruct.longField == 0) { + throw new UnexpectedException("Expected richStruct.longField != 0"); + } + return richStruct; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioSixServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioSixServant.java new file mode 100644 index 0000000000..7889a80bf1 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioSixServant.java @@ -0,0 +1,46 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.AnnotatedStruct; +import org.apache.tuscany.sca.test.corba.generated.RichUnion; +import org.apache.tuscany.sca.test.corba.generated._ScenarioSixImplBase; + +/** + * @version $Rev$ $Date$ + * Scenario six servant for generated interface. + */ +public class ScenarioSixServant extends _ScenarioSixImplBase { + + private static final long serialVersionUID = 1L; + + public String[][] passStringArray(String[][] arg) { + return arg; + } + + public AnnotatedStruct passAnnotatedStruct(AnnotatedStruct arg) { + return arg; + } + + public RichUnion passRichUnion(RichUnion arg) { + return arg; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioTwoServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioTwoServant.java new file mode 100644 index 0000000000..cdd49904d3 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/ScenarioTwoServant.java @@ -0,0 +1,42 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated._ScenarioTwoImplBase; + +/** + * @version $Rev$ $Date$ + * Servant for generated interface. + */ +public class ScenarioTwoServant extends _ScenarioTwoImplBase { + + private static final long serialVersionUID = 1L; + + private String stringField = ""; + + public String stringField() { + return stringField; + } + + public void stringField(String newStringField) { + this.stringField = newStringField; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TAnnotatedStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TAnnotatedStruct.java new file mode 100644 index 0000000000..6f0ef584da --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TAnnotatedStruct.java @@ -0,0 +1,40 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaArray; + +/** + * @version $Rev$ $Date$ Scenario six structure used by Tuscany. + */ +public final class TAnnotatedStruct { + + @CorbaArray( {2, 2}) + public String[][] stringArray; + + public TAnnotatedStruct() { + + } + + public TAnnotatedStruct(String[][] stringArray) { + this.stringArray = stringArray; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TColor.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TColor.java new file mode 100644 index 0000000000..71003d008f --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TColor.java @@ -0,0 +1,62 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * User provided enum representation for Color type. + */ +public class TColor { + + private int value; + + public static final int _red = 0; + public static final int _yellow = 1; + public static final int _green = 2; + + public static final TColor red = new TColor(_red); + public static final TColor yellow = new TColor(_yellow); + public static final TColor green = new TColor(_green); + + public int value() { + return value; + } + + public static TColor from_int(int value) { + switch (value) { + case 0: + return red; + case 1: + return yellow; + case 2: + return green; + } + return green; + } + + protected TColor(int value) { + this.value = value; + } + + public TColor() { + + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerStruct.java new file mode 100644 index 0000000000..271f1e669b --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerStruct.java @@ -0,0 +1,42 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * User provided interface representation for InnerStruct type. + */ +public final class TInnerStruct { + + public int[][] twoDimLongSequence; + public String stringField; + public TColor color; + + public TInnerStruct() { + + } + + public TInnerStruct(int[][] a1, String a2, TColor a3) { + twoDimLongSequence = a1; + stringField = a2; + color = a3; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerUnion.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerUnion.java new file mode 100644 index 0000000000..f2baffce9a --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TInnerUnion.java @@ -0,0 +1,59 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaUnionElement; +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaUnionElementType; + +/** + * @version $Rev$ $Date$ + * User provided interface representation for CORBA InnerUnion type. + */ +public final class TInnerUnion { + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 1) + private int x; + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 2) + private float y; + + @CorbaUnionElement(type = CorbaUnionElementType.discriminator) + @SuppressWarnings("unused") + private int discriminator; + + public int getX() { + return x; + } + + public void setX(int x) { + discriminator = 1; + this.x = x; + } + + public float getY() { + return y; + } + + public void setY(float y) { + discriminator = 2; + this.y = y; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichStruct.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichStruct.java new file mode 100644 index 0000000000..1b44da9752 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichStruct.java @@ -0,0 +1,42 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * User provided interface representation for RichStruct type. + */ +public final class TRichStruct { + + public TInnerStruct innerStruct; + public String[] stringSequence; + public int longField; + + public TRichStruct() { + + } + + public TRichStruct(TInnerStruct a1, String[] a2, int a3) { + innerStruct = a1; + stringSequence = a2; + longField = a3; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichUnion.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichUnion.java new file mode 100644 index 0000000000..8270ba1a8c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TRichUnion.java @@ -0,0 +1,95 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaUnionElement; +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaUnionElementType; + +/** + * @version $Rev$ $Date$ + * User provided interface representation for CORBA RichUnion type. + */ +public final class TRichUnion { + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 1) + private int x; + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 2) + private float y; + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 3) + private String z; + + @CorbaUnionElement(type = CorbaUnionElementType.option, optionNumber = 4) + private TInnerUnion iu; + + @CorbaUnionElement(type = CorbaUnionElementType.defaultOption) + private boolean def; + + @CorbaUnionElement(type = CorbaUnionElementType.discriminator) + @SuppressWarnings("unused") + private int discriminator = -1; + + public int getX() { + return x; + } + + public void setX(int x) { + this.discriminator = 1; + this.x = x; + } + + public float getY() { + return y; + } + + public void setY(float y) { + this.discriminator = 2; + this.y = y; + } + + public String getZ() { + return z; + } + + public void setZ(String z) { + this.discriminator = 3; + this.z = z; + } + + public boolean isDef() { + return def; + } + + public void setDef(boolean def) { + this.discriminator = -1; + this.def = def; + } + + public TInnerUnion getIu() { + return iu; + } + + public void setIu(TInnerUnion iu) { + this.discriminator = 4; + this.iu = iu; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOne.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOne.java new file mode 100644 index 0000000000..922759cd8d --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOne.java @@ -0,0 +1,33 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; + +/** + * @version $Rev$ $Date$ + * User provided CORBA service interface. + */ +public interface TScenarioOne { + + TRichStruct setRichStruct(TRichStruct richStruct) throws WrongColor, UnexpectedException; + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneComponent.java new file mode 100644 index 0000000000..ac7b0af175 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneComponent.java @@ -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 org.apache.tuscany.sca.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for reference using user provided interface. + */ +public class TScenarioOneComponent implements TScenarioOne { + + private TScenarioOne scenarionOne; + + @Reference + public void setScenarioOne(TScenarioOne scenarioOne) { + this.scenarionOne = scenarioOne; + } + + public TRichStruct setRichStruct(TRichStruct richStruct) throws WrongColor, UnexpectedException { + return scenarionOne.setRichStruct(richStruct); + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneServant.java new file mode 100644 index 0000000000..47f0775c16 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioOneServant.java @@ -0,0 +1,44 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.test.corba.generated.Color; +import org.apache.tuscany.sca.test.corba.generated.UnexpectedException; +import org.apache.tuscany.sca.test.corba.generated.WrongColor; + +/** + * @version $Rev$ $Date$ + * Servant for user provided interface. Uses T* classes. + */ +public class TScenarioOneServant implements TScenarioOne { + + private static final long serialVersionUID = 1L; + + public TRichStruct setRichStruct(TRichStruct richStruct) throws WrongColor, UnexpectedException { + if (richStruct.innerStruct.color.value() == Color.red.value()) { + Color translatedColor = Color.from_int(richStruct.innerStruct.color.value()); + throw new WrongColor(translatedColor, Color.green); + } else if (richStruct.longField == 0) { + throw new UnexpectedException("Expected richStruct.longField != 0"); + } + return richStruct; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSix.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSix.java new file mode 100644 index 0000000000..0e894cb7ea --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSix.java @@ -0,0 +1,37 @@ +/* + * 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.test.corba.types; + +import org.apache.tuscany.sca.binding.corba.provider.meta.CorbaArray; + +/** + * @version $Rev$ $Date$ + * Operations for scenario six. + */ +public interface TScenarioSix { + + @CorbaArray( {2, 2}) + public String[][] passStringArray(@CorbaArray( {2, 2})String[][] arg); + + public TAnnotatedStruct passAnnotatedStruct(TAnnotatedStruct arg); + + public TRichUnion passRichUnion(TRichUnion arg); + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixComponent.java new file mode 100644 index 0000000000..13bc1d499e --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixComponent.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for obtaining ScenartioSix reference. + */ +public class TScenarioSixComponent { + + private TScenarioSix scenarioSix; + + @Reference + public void setScenarioSix(TScenarioSix scenarioSix) { + this.scenarioSix = scenarioSix; + } + + public TScenarioSix getScenarioSix() { + return scenarioSix; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixServant.java new file mode 100644 index 0000000000..8e76958e31 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioSixServant.java @@ -0,0 +1,42 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Tuscany scenario six servant. + */ +public class TScenarioSixServant implements TScenarioSix { + + private static final long serialVersionUID = 1L; + + public String[][] passStringArray(String[][] arg) { + return arg; + } + + public TAnnotatedStruct passAnnotatedStruct(TAnnotatedStruct arg) { + return arg; + } + + public TRichUnion passRichUnion(TRichUnion arg) { + return arg; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThree.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThree.java new file mode 100644 index 0000000000..1e4264256b --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThree.java @@ -0,0 +1,42 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Operations for ScenarioThree. + */ +public interface TScenarioThree { + + int getIntField(); + + void setIntField(int intField); + + void overloadedName(); + + void overloadedName(String arg1); + + void overloadedName(String arg1, int arg2); + + int caseDifferent(); + + int CaseDifferent(); + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeComponent.java new file mode 100644 index 0000000000..12b0f404ae --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeComponent.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for obtaining ScenartioThree reference. + */ +public class TScenarioThreeComponent { + + private TScenarioThree scenarionThree; + + @Reference + public void setScenarioThree(TScenarioThree scenarioThree) { + this.scenarionThree = scenarioThree; + } + + public TScenarioThree getScenarioThree() { + return scenarionThree; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeServant.java new file mode 100644 index 0000000000..b679214c6c --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioThreeServant.java @@ -0,0 +1,52 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Servant for user provided interface. + */ +public class TScenarioThreeServant implements TScenarioThree { + + public int getIntField() { + return 0; + } + + public void overloadedName() { + } + + public void overloadedName(String arg1) { + } + + public void overloadedName(String arg1, int arg2) { + } + + public void setIntField(int intField) { + } + + public int CaseDifferent() { + return 1; + } + + public int caseDifferent() { + return 0; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwo.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwo.java new file mode 100644 index 0000000000..415634c80f --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwo.java @@ -0,0 +1,32 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Operations for ScenarioTwo. + */ +public interface TScenarioTwo { + + String getStringField(); + + void setStringField(String stringField); + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoComponent.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoComponent.java new file mode 100644 index 0000000000..937d82b33e --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoComponent.java @@ -0,0 +1,41 @@ +/* + * 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.test.corba.types; + +import org.oasisopen.sca.annotation.Reference; + +/** + * @version $Rev$ $Date$ + * Component for obtaining ScenartioTwo reference. + */ +public class TScenarioTwoComponent { + + private TScenarioTwo scenarioTwo; + + @Reference + public void setScenarioTwo(TScenarioTwo scenarioTwo) { + this.scenarioTwo = scenarioTwo; + } + + public TScenarioTwo getScenarioTwo() { + return scenarioTwo; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoServant.java b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoServant.java new file mode 100644 index 0000000000..cb868d18a0 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/java/org/apache/tuscany/sca/test/corba/types/TScenarioTwoServant.java @@ -0,0 +1,38 @@ +/* + * 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.test.corba.types; + +/** + * @version $Rev$ $Date$ + * Servant for user provided interface. + */ +public class TScenarioTwoServant implements TScenarioTwo { + + private static String stringField = ""; + + public String getStringField() { + return stringField; + } + + public void setStringField(String stringField) { + TScenarioTwoServant.stringField = stringField; + } + +} diff --git a/java/sca/contrib/itest/corba/src/test/resources/META-INF/services/org.apache.tuscany.sca.core.ModuleActivator b/java/sca/contrib/itest/corba/src/test/resources/META-INF/services/org.apache.tuscany.sca.core.ModuleActivator new file mode 100644 index 0000000000..3e77527d73 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/META-INF/services/org.apache.tuscany.sca.core.ModuleActivator @@ -0,0 +1,18 @@ +# 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. + +org.apache.tuscany.sca.test.corba.TestCorbaHostModuleActivator diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioFive.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioFive.composite new file mode 100644 index 0000000000..3c73e238a5 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioFive.composite @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioFour.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioFour.composite new file mode 100644 index 0000000000..01d7e2314a --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioFour.composite @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioOne.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioOne.composite new file mode 100644 index 0000000000..c10b383661 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioOne.composite @@ -0,0 +1,111 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioSix.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioSix.composite new file mode 100644 index 0000000000..88238478c1 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioSix.composite @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioThree.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioThree.composite new file mode 100644 index 0000000000..f43e4a3f7a --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioThree.composite @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/ScenarioTwo.composite b/java/sca/contrib/itest/corba/src/test/resources/ScenarioTwo.composite new file mode 100644 index 0000000000..dc5ddc50d3 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/ScenarioTwo.composite @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/corba/src/test/resources/itest_scenario.idl b/java/sca/contrib/itest/corba/src/test/resources/itest_scenario.idl new file mode 100644 index 0000000000..41489a4565 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/itest_scenario.idl @@ -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. + */ + +/* + * compile by + * idlj -fall -oldImplBase itest_scenario.idl + */ + +module org { + module apache { + module tuscany { + module sca { + module test { + module corba { + module generated { + + // objects for ScenarioOne + + enum Color {red, yellow, green}; + + typedef sequence StringSequence; + typedef sequence LongSequence; + typedef sequence TwoDimLongSequence; + + struct InnerStruct { + TwoDimLongSequence twoDimLongSequence; + string stringField; + Color color; + }; + + struct RichStruct { + InnerStruct innerStruct; + StringSequence stringSequence; + long longField; + }; + + exception WrongColor { + Color givenColor; + Color correctColor; + }; + + exception UnexpectedException { + string info; + }; + + interface ScenarioOne { + + RichStruct setRichStruct(in RichStruct richStruct) raises (WrongColor, UnexpectedException); + + }; + + // objects for ScenarioTwo + + interface ScenarioTwo { + + attribute string stringField; + + }; + + typedef string StringArray[2][2]; + + struct AnnotatedStruct { + StringArray stringArray; + }; + + union InnerUnion switch (long) { + case 1: long x; + case 2: float y; + }; + + union RichUnion switch (long) { + case 1: long x; + case 2: float y; + case 3: string z; + case 4: InnerUnion iu; + default: boolean a; + }; + + interface ScenarioSix { + + StringArray passStringArray(in StringArray arg); + + AnnotatedStruct passAnnotatedStruct(in AnnotatedStruct arg); + + RichUnion passRichUnion(in RichUnion arg); + + }; + }; + }; + }; + }; + }; + }; +}; diff --git a/java/sca/contrib/itest/corba/src/test/resources/scenariofour.xsd b/java/sca/contrib/itest/corba/src/test/resources/scenariofour.xsd new file mode 100644 index 0000000000..2669b54be3 --- /dev/null +++ b/java/sca/contrib/itest/corba/src/test/resources/scenariofour.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/pom.xml b/java/sca/contrib/itest/databindings/common/pom.xml new file mode 100644 index 0000000000..661b264a49 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/pom.xml @@ -0,0 +1,126 @@ + + + + + org.apache.tuscany.sca + itest-databindings + 2.0-SNAPSHOT + + + 4.0.0 + + itest-databindings-common + 2.0-SNAPSHOT + jar + Apache Tuscany SCA Databinding Common Integration Tests + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + + + + org.apache.tuscany.sca + tuscany-databinding-sdo + ${pom.version} + compile + + + org.apache.tuscany.sdo + tuscany-sdo-tools + 1.1.1 + compile + + + velocity + velocity + 1.4 + compile + + + + + + + org.codehaus.mojo + build-helper-maven-plugin + 1.0 + + + add-test-source + generate-sources + + add-test-source + + + + target/sdo-source + + + + + + + org.apache.tuscany.sdo + tuscany-sdo-plugin + 1.1.1 + + + generate-sdo + generate-sources + + + + ${basedir}/src/main/resources/generate/generate.xsd + + + true + true + true + + + generate + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/java/org/apache/tuscany/sca/itest/generate/Generate.java b/java/sca/contrib/itest/databindings/common/src/main/java/org/apache/tuscany/sca/itest/generate/Generate.java new file mode 100644 index 0000000000..adb546a1ea --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/java/org/apache/tuscany/sca/itest/generate/Generate.java @@ -0,0 +1,181 @@ +/* + * 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.itest.generate; + +import java.io.File; +import java.io.FileInputStream; +import java.io.FileWriter; +import java.util.List; +import java.util.Properties; + +import org.apache.tuscany.generate.GenerateFactory; +import org.apache.tuscany.generate.GenerateType; +import org.apache.tuscany.generate.InputFileType; +import org.apache.tuscany.generate.TemplateType; +import org.apache.tuscany.sdo.generate.XSD2JavaGenerator; +import org.apache.tuscany.sdo.util.SDOUtil; +import org.apache.velocity.VelocityContext; +import org.apache.velocity.app.Velocity; + +import commonj.sdo.helper.HelperContext; +import commonj.sdo.helper.XMLDocument; + +/** + * Generates test files based on the information in a configuration files (generate.xml) + * and a set of velocity templates. The process is + * + * for each template + * for each xsd file + * generate SDOs + * include the factory into the composite + * for each type + * add client iface method + * add client impl method + * add service iface method + * add service impl method + * add test method + * add wsdl type and method + * + * @version $Rev$ $Date$ + */ +public class Generate { + + /** + * Does all the hard work of running the velocity templates against the + * the list of types to test. Both the list of templates and the list of + * XSD files is held in the configuration file (generate.xsd) which lives in the + * resources/generate directory of the project being generated. + * + * @param projectBuildDir the path to the target dir of the project being generated. + */ + public static void generate(String projectBuildDir) { + System.out.println(">> Building project from dir: " + projectBuildDir); + FileInputStream fis = null; + + try { + // Load the config file into a stream + fis = new FileInputStream(projectBuildDir + "/classes/generate/generate.xml"); + + // Load the stream into SDO + // We are just using SDO as a convenient way to parse the XML config file + HelperContext scope = SDOUtil.createHelperContext(); + GenerateFactory.INSTANCE.register(scope); + XMLDocument xmlDoc = scope.getXMLHelper().load(fis); + GenerateType generateType = (GenerateType)xmlDoc.getRootObject(); + + // Get the file list. This is the list of XSD that is passed into the + // the velocity templates. Each configured file holds a list of types + // that the velocity templates expand into appropriate methods and method calls + List fileList = generateType.getInputFile(); + + //Initialise velocity ready to generate the various files + Properties p = new Properties(); + p.setProperty("file.resource.loader.path", projectBuildDir + "/classes/generate"); + Velocity.init(p); + VelocityContext context = new VelocityContext(); + context.put("fileList", fileList); + + List templateList = generateType.getTemplate(); + + // For each velocity template in the template list pass in the XSD file list + for ( Object item: templateList){ + TemplateType template = (TemplateType)item; + context.put("template", template); + String tmp = template.getTemplateName(); + String filename = projectBuildDir + "/" + template.getTemplateTargetDir() + "/" + tmp.substring(0,tmp.length() - 3); + File f = new File(filename); + // Create folders since the package doesn't exist before the code-gen for the 1st time + f.getParentFile().mkdirs(); + FileWriter fw = new FileWriter(f); + System.out.println(">> Processing " + template.getTemplateName() + " to " + filename); + Velocity.mergeTemplate(template.getTemplateName(), context, fw ); + fw.flush(); + fw.close(); + } + + + } catch (Exception e) { + System.out.println("Exception : " + e.toString()); + e.printStackTrace(); + return; + } + } + + /** + * The SDO generator tool does all of the hard work + * + * @param projectBuildDir the path to the target dir of the project being generated. + */ + public static void generateSDO(String projectBuildDir) { + System.out.println(">> Building SDOs from dir: " + projectBuildDir); + FileInputStream fis = null; + + try { + // Load the config file into a stream + fis = new FileInputStream(projectBuildDir + "/classes/generate/generate.xml"); + + // Load the stream into SDO + // We are just using SDO as a convenient way to parse the XML config file + HelperContext scope = SDOUtil.createHelperContext(); + GenerateFactory.INSTANCE.register(scope); + XMLDocument xmlDoc = scope.getXMLHelper().load(fis); + GenerateType generateType = (GenerateType)xmlDoc.getRootObject(); + + // Get the file list. This is the list of XSD that is passed into the + // the velocity templates. Each configured file holds a list of types + // that the velocity templates expand into appropriate methods and method calls + List fileList = generateType.getInputFile(); + + // for each XSD in the XSD file list generate an SDO. + XSD2JavaGenerator generator = new XSD2JavaGenerator(); + + for ( Object item : fileList){ + InputFileType file = (InputFileType)item; + + XSD2JavaGenerator.generateFromXMLSchema(projectBuildDir + "/classes/xsd/" + file.getFileName(), + file.getNamespace(), + projectBuildDir + "/sdo-source", + file.getJavaPackage(), + null, //file.getPrefix(), + XSD2JavaGenerator.OPTION_NO_CONTAINMENT | XSD2JavaGenerator.OPTION_NO_NOTIFICATION | XSD2JavaGenerator.OPTION_NO_UNSETTABLE); + + } + + } catch (Exception e) { + System.out.println("Exception : " + e.toString()); + e.printStackTrace(); + return; + } + } + + /** + * The mainline + * + * @param args the target directory where project in which files are being generated + */ + public static void main(String[] args) { + + Generate.generate(args[0]); + + if (args.length > 1){ + Generate.generateSDO(args[0]); + } + } + +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/DatabindingTestCase.java.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/DatabindingTestCase.java.vm new file mode 100644 index 0000000000..db24ceab14 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/DatabindingTestCase.java.vm @@ -0,0 +1,112 @@ +/* + * 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 $template.getJavaPackage(); + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.oasisopen.sca.ComponentContext; +import org.oasisopen.sca.ServiceReference; + +import ${template.getJavaPackage()}.GreeterService; + +// Data types +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +import $file.getJavaPackage().$file.getFactory(); +#end +#end + +/** + * Automatically generated test case. Calls the greeter client for a number of + * bindings and a number of data types. + * + * @version $Rev: 511417 $ $Date: 2007-02-25 03:06:42 +0000 (Sun, 25 Feb 2007) $ + */ +public class DatabindingTestCase extends TestCase { + + private SCADomain domain; + private GreeterService greeterClient; + + /** + * Runs before each test method + */ + protected void setUp() throws Exception { + domain = SCADomain.newInstance("greeter.composite"); + super.setUp(); + } + + /** + * Runs after each test method + */ + protected void tearDown() { + domain.close(); + } + + /** + * Finds the SCA component that relates to the protocol being tested. This test + * always connects locally to the client component but the client component will + * connect to the back end component using the appropriate protocol + * + * @param ext the protcol required + */ + private void setUpClient(String ext) throws Exception { + greeterClient = domain.getService(GreeterService.class, ext + "GreeterServiceClient"); + } + + /** + * Invokes the SDO Greet service using web service bindings with SDO payload + */ + public void testWSGreet() throws Exception { + setUpClient("WS"); + greet(); + } + + /** + * Invokes the SDO Greet service using default bindings with SDO payload + */ + public void testDefaultGreet() throws Exception { + setUpClient("Default"); + greet(); + } + + /** + * A generic method which, regarless of which client is connected, sends out a + * series of requrests passing different data types. + */ + public void greet() { +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + // test $typeInstance.getTypeName() + { + $typeInstance.getTypeName() param = null; + $typeInstance.getCreateTypeCode() + $typeInstance.getTypeName() result = greeterClient.greet$typeInstance.getTypeName()(param); + $typeInstance.getResultComparison() + } +#end +#end + } + +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/Greeter.wsdl.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/Greeter.wsdl.vm new file mode 100644 index 0000000000..88616cc997 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/Greeter.wsdl.vm @@ -0,0 +1,103 @@ + + + + + + + +#foreach($file in $fileList) + +#end + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + +#end +#end + + + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + + + +#end +#end + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterService.java.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterService.java.vm new file mode 100644 index 0000000000..2df4a558e6 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterService.java.vm @@ -0,0 +1,53 @@ +/* + * 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 $template.getJavaPackage(); + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +#end +#end + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The automatically generated interface to the service that reflects data objects + * that are sent to it + * + * @version $Rev: 511417 $ $Date: 2007-02-25 03:06:42 +0000 (Sun, 25 Feb 2007) $ + */ +@Remotable +public interface GreeterService { + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + /** + * Take the provided data object, change it slightly and return it + * + * @param param the data object to be changed and returned + * @return the change data object + */ + $typeInstance.getTypeName() greet$typeInstance.getTypeName()($typeInstance.getTypeName() param); +#end +#end + +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClient.java.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClient.java.vm new file mode 100644 index 0000000000..b73173247f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClient.java.vm @@ -0,0 +1,42 @@ +/* + * 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 $template.getJavaPackage(); + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +#end +#end + +import org.oasisopen.sca.annotation.AllowsPassByReference; + +/** + * GreeterServiceClient + */ +@AllowsPassByReference +public interface GreeterServiceClient { +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + $typeInstance.getTypeName() greet$typeInstance.getTypeName()($typeInstance.getTypeName() param); +#end +#end +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClientImpl.java.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClientImpl.java.vm new file mode 100644 index 0000000000..46c74ec819 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceClientImpl.java.vm @@ -0,0 +1,65 @@ +/* + * 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 $template.getJavaPackage(); + +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +#end +#end + +/** + * The automatically generated service that simply forwards data objects on to + * the GreeterService and passes back the responses + * + * @version $Rev: 508831 $ $Date: 2007-02-18 00:12:31 +0000 (Sun, 18 Feb 2007) $ + */ +@Service(GreeterService.class) +public class GreeterServiceClientImpl implements GreeterService { + + /** + * the reference the the GreeterService that will + * change each data object slightly and return it + */ + private GreeterService service; + + @Reference + public void setGreeterService(GreeterService service) { + this.service = service; + } +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + /* + * (non-Javadoc) + * + * @see org.apache.tuscany.sca.itest.sdodatabinding.GreeterService#greet$typeInstance.getTypeName()($typeInstance.getTypeName() param) + */ + public $typeInstance.getTypeName() greet$typeInstance.getTypeName()($typeInstance.getTypeName() param) { + return service.greet$typeInstance.getTypeName()(param); + } +#end +#end +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceImpl.java.vm b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceImpl.java.vm new file mode 100644 index 0000000000..2fd10ef0bf --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/GreeterServiceImpl.java.vm @@ -0,0 +1,55 @@ +/* + * 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 $template.getJavaPackage(); + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +#end +#end + +import org.oasisopen.sca.annotation.Service; + +/** + * The automatically generated service implementation that reflects data objects + * that are sent to it + * + * @version $Rev: 511417 $ $Date: 2007-02-25 03:06:42 +0000 (Sun, 25 Feb 2007) $ + */ +@Service(GreeterService.class) +public class GreeterServiceImpl implements GreeterService { +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + /** + * Take the provided data object, change it slightly and return it + * + * @param param the data object to be changed and returned + * @return the change data object + */ + public $typeInstance.getTypeName() greet$typeInstance.getTypeName()($typeInstance.getTypeName() param) { + $typeInstance.getModifyTypeCode() + return param; + } +#end +#end +} diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/generate/generate.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/generate.xsd new file mode 100644 index 0000000000..1fabedf55f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/generate/generate.xsd @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/wsdl/Dummy.txt b/java/sca/contrib/itest/databindings/common/src/main/resources/wsdl/Dummy.txt new file mode 100644 index 0000000000..8927d725b6 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/wsdl/Dummy.txt @@ -0,0 +1,4 @@ +A dummy file that causes the target/classes/wsdl dir to be created in the generated test project. This is +required because the test generator must run in the process-resource phase, after generate.xml has been copied +into target. The generator needs to write out target/classes/wsdl and will fail the directory isn't there. So +this file just gets unpacked and forces the directory to be created. diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xml new file mode 100644 index 0000000000..f1f4346e58 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xsd new file mode 100644 index 0000000000..1fae43eb09 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Annotation.xsd @@ -0,0 +1,38 @@ + + + + + + SDO 2.0.1 + + A schema that tests the presence of annotations in schema read by SDO + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xml new file mode 100644 index 0000000000..c20c80b658 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xsd new file mode 100644 index 0000000000..bd3db2e030 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Attribute.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xml new file mode 100644 index 0000000000..30e4979dca --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xsd new file mode 100644 index 0000000000..e7738dcff7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeReference.xsd @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xml new file mode 100644 index 0000000000..9552421e2d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xsd new file mode 100644 index 0000000000..c7b9655749 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithDefaultValue.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xml new file mode 100644 index 0000000000..5e5e7fbd55 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xsd new file mode 100644 index 0000000000..5c455c2ab5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithFixedValue.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xml new file mode 100644 index 0000000000..635e851632 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xsd new file mode 100644 index 0000000000..004dab4fbb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOAliasName.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xml new file mode 100644 index 0000000000..136092951b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xsd new file mode 100644 index 0000000000..796f08e1cf --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDODataType.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xml new file mode 100644 index 0000000000..927b94885c --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xsd new file mode 100644 index 0000000000..93f83cd0a1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOName.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xml new file mode 100644 index 0000000000..ea7db70595 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xsd new file mode 100644 index 0000000000..c64323e7e1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertySDOOppositePropertyType.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xml new file mode 100644 index 0000000000..85c7d85fd4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xsd new file mode 100644 index 0000000000..543f276c50 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOPropertyType.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xml new file mode 100644 index 0000000000..fcd281539b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xsd new file mode 100644 index 0000000000..1610c2b861 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/AttributeWithSDOString.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xml new file mode 100644 index 0000000000..36a0760a61 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xml @@ -0,0 +1,24 @@ + + + + anySimpleType + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xsd new file mode 100644 index 0000000000..999b72bb35 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnySimpleType.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xml new file mode 100644 index 0000000000..5849165fe0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xsd new file mode 100644 index 0000000000..71dad561ca --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyType.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xml new file mode 100644 index 0000000000..8acf9376d7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xml @@ -0,0 +1,24 @@ + + + + http://tempuri.org + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xsd new file mode 100644 index 0000000000..a49987c352 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInAnyURI.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xml new file mode 100644 index 0000000000..a35b6e174a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xml @@ -0,0 +1,24 @@ + + + + ABCDEF + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xsd new file mode 100644 index 0000000000..e1995890f9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBase64Binary.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xml new file mode 100644 index 0000000000..91cfce51b8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xml @@ -0,0 +1,27 @@ + + + + true + false + 1 + 0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xsd new file mode 100644 index 0000000000..a2f86ba8c5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInBoolean.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xml new file mode 100644 index 0000000000..907474cd1b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xml @@ -0,0 +1,25 @@ + + + + 127 + -127 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xsd new file mode 100644 index 0000000000..a2f6bcfa77 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInByte.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xml new file mode 100644 index 0000000000..c5820e1a2e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xml @@ -0,0 +1,24 @@ + + + + 2001-01-01 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xsd new file mode 100644 index 0000000000..f4d596bfe3 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDate.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xml new file mode 100644 index 0000000000..0debe2fec5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xml @@ -0,0 +1,24 @@ + + + + 2001-12-31T12:00:00 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xsd new file mode 100644 index 0000000000..b5bcfdcfd4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDateTime.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xml new file mode 100644 index 0000000000..7f001254cc --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xml @@ -0,0 +1,23 @@ + + + + -1.23456789 + 1.23456789 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xsd new file mode 100644 index 0000000000..8d4d106f59 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDecimal.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xml new file mode 100644 index 0000000000..f875b9f94d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xml @@ -0,0 +1,25 @@ + + + + 0.0 + 12.3E-4 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xsd new file mode 100644 index 0000000000..4c8a39b06c --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDouble.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xml new file mode 100644 index 0000000000..7d343d6dda --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xml @@ -0,0 +1,24 @@ + + + + P1D + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xsd new file mode 100644 index 0000000000..bb12bc04a9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInDuration.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xml new file mode 100644 index 0000000000..7a81f3b0dd --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xml @@ -0,0 +1,24 @@ + + + + 0.0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xsd new file mode 100644 index 0000000000..f0e1c21233 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInFloat.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xml new file mode 100644 index 0000000000..d35568b3c9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xml @@ -0,0 +1,24 @@ + + + + ---01 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xsd new file mode 100644 index 0000000000..92bd9a4b66 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGDay.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xml new file mode 100644 index 0000000000..52cdfa8c4e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xml @@ -0,0 +1,24 @@ + + + + --01-- + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xsd new file mode 100644 index 0000000000..78d001a585 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonth.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xml new file mode 100644 index 0000000000..2609a858f7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xml @@ -0,0 +1,24 @@ + + + + --01-01 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xsd new file mode 100644 index 0000000000..38f6c55059 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGMonthDay.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xml new file mode 100644 index 0000000000..7868a47ca3 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xml @@ -0,0 +1,24 @@ + + + + 2001 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xsd new file mode 100644 index 0000000000..0d65b124ff --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYear.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xml new file mode 100644 index 0000000000..3f5080d49f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xml @@ -0,0 +1,24 @@ + + + + 2001-01 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xsd new file mode 100644 index 0000000000..340555dc5f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInGYearMonth.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xml new file mode 100644 index 0000000000..0deb7af980 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xml @@ -0,0 +1,24 @@ + + + + 0F00 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xsd new file mode 100644 index 0000000000..8059fe6da0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInHexBinary.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xml new file mode 100644 index 0000000000..06c92ce19b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xml @@ -0,0 +1,24 @@ + + + + idvalue0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xsd new file mode 100644 index 0000000000..7b1f02d1d4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInID.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xml new file mode 100644 index 0000000000..9bc0cefd0f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xml @@ -0,0 +1,24 @@ + + + + idvalue0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xsd new file mode 100644 index 0000000000..0c207983bc --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREF.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xml new file mode 100644 index 0000000000..f91b602f99 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xml @@ -0,0 +1,24 @@ + + + + idvalue0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xsd new file mode 100644 index 0000000000..b99bf01b73 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInIDREFS.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xml new file mode 100644 index 0000000000..c99698e175 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xml @@ -0,0 +1,25 @@ + + + + -2147483648 + 2147483647 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xsd new file mode 100644 index 0000000000..b5b9b0d1eb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInt.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xml new file mode 100644 index 0000000000..80d22ce057 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xml @@ -0,0 +1,25 @@ + + + + -2147483648 + 2147483647 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xsd new file mode 100644 index 0000000000..4902935db5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInInteger.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xml new file mode 100644 index 0000000000..664bf824b4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xml @@ -0,0 +1,24 @@ + + + + EN + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xsd new file mode 100644 index 0000000000..5d3658d224 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLanguage.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xml new file mode 100644 index 0000000000..c5861fa92a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xml @@ -0,0 +1,25 @@ + + + + -9223372036854775808 + 9223372036854775807 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xsd new file mode 100644 index 0000000000..0aa4710057 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInLong.xsd @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xml new file mode 100644 index 0000000000..1f95950394 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xml @@ -0,0 +1,24 @@ + + + + NCName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xsd new file mode 100644 index 0000000000..6ee9c435db --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNCName.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xml new file mode 100644 index 0000000000..0297f1aeb4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xml @@ -0,0 +1,24 @@ + + + + NMTOKEN + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xsd new file mode 100644 index 0000000000..56d027bdbb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKEN.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xml new file mode 100644 index 0000000000..81ba1069bd --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xml @@ -0,0 +1,24 @@ + + + + NMTOKENS + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xsd new file mode 100644 index 0000000000..866ab73024 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNMTOKENS.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xml new file mode 100644 index 0000000000..8bb3a08b94 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xml @@ -0,0 +1,24 @@ + + + + tns:BuiltInNotationNotation + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xsd new file mode 100644 index 0000000000..c7c62f812b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNOTATION.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xml new file mode 100644 index 0000000000..8235718c5e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xml @@ -0,0 +1,24 @@ + + + + Name + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xsd new file mode 100644 index 0000000000..36caba2f16 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInName.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xml new file mode 100644 index 0000000000..599c428a44 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xml @@ -0,0 +1,24 @@ + + + + -1 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xsd new file mode 100644 index 0000000000..389d5a99f0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNegativeInteger.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xml new file mode 100644 index 0000000000..919c4a20ee --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xml @@ -0,0 +1,24 @@ + + + + 0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xsd new file mode 100644 index 0000000000..59887078b5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonNegativeInteger.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xml new file mode 100644 index 0000000000..79011f26ab --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xml @@ -0,0 +1,24 @@ + + + + -1 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xsd new file mode 100644 index 0000000000..5de7d64d7b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNonPositiveInteger.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xml new file mode 100644 index 0000000000..c40be9e18b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xml @@ -0,0 +1,24 @@ + + + + normalizedString + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xsd new file mode 100644 index 0000000000..d4a78787b8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInNormalizedString.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xml new file mode 100644 index 0000000000..c30434de66 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xml @@ -0,0 +1,24 @@ + + + + 1 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xsd new file mode 100644 index 0000000000..5381590cd1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInPositiveInteger.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xml new file mode 100644 index 0000000000..4cd6ea7e72 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xml @@ -0,0 +1,24 @@ + + + + QName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xsd new file mode 100644 index 0000000000..e8faf6225b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInQName.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xml new file mode 100644 index 0000000000..b4375467c4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xml @@ -0,0 +1,25 @@ + + + + -32768 + 32767 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xsd new file mode 100644 index 0000000000..a4f564d9b7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInShort.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xml new file mode 100644 index 0000000000..d30ab85530 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xml @@ -0,0 +1,24 @@ + + + + string + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xsd new file mode 100644 index 0000000000..8abb34b5a5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInString.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xml new file mode 100644 index 0000000000..7fd9a061ae --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xsd new file mode 100644 index 0000000000..1615976813 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInTime.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xml new file mode 100644 index 0000000000..cd567ba528 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xml @@ -0,0 +1,24 @@ + + + + token + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xsd new file mode 100644 index 0000000000..0beaac571f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInToken.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xml new file mode 100644 index 0000000000..025362defb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xml @@ -0,0 +1,25 @@ + + + + 0 + 255 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xsd new file mode 100644 index 0000000000..d6d951fe5d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedByte.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xml new file mode 100644 index 0000000000..5736a8c121 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xml @@ -0,0 +1,25 @@ + + + + 0 + 4294967295 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xsd new file mode 100644 index 0000000000..242be1d53b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedInt.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xml new file mode 100644 index 0000000000..d728115a77 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xml @@ -0,0 +1,25 @@ + + + + 0 + 18446744073709551615 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xsd new file mode 100644 index 0000000000..108e3a8619 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedLong.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xml new file mode 100644 index 0000000000..d4ffae5e17 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xml @@ -0,0 +1,25 @@ + + + + 0 + 65535 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xsd new file mode 100644 index 0000000000..5ee5e0229e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/BuiltInUnsignedShort.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xml new file mode 100644 index 0000000000..3d5aed5aa8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xsd new file mode 100644 index 0000000000..e7b80ab11c --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeComplexContentRestrictingComplexType.xsd @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xml new file mode 100644 index 0000000000..2b4fe5594e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xml @@ -0,0 +1,27 @@ + + + + + SimpleTypeWithName + SimpleTypeWithNameExtended + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xsd new file mode 100644 index 0000000000..fc4deb63c2 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingComplexType.xsd @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xml new file mode 100644 index 0000000000..03570f41d9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xml @@ -0,0 +1,24 @@ + + + + ComplexTypeExtendingSimpeTypeElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xsd new file mode 100644 index 0000000000..c754502645 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeExtendingSimpleType.xsd @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xml new file mode 100644 index 0000000000..4603793bfc --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xml @@ -0,0 +1,24 @@ + + + + ComplexTypeSimpleContentRestrictingComplexTypeElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xsd new file mode 100644 index 0000000000..4bcd2f8c46 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeSimpleContentRestrictingComplexType.xsd @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xml new file mode 100644 index 0000000000..a6861f803a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xml @@ -0,0 +1,27 @@ + + + + + BaseElement + ExtensionElement + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xsd new file mode 100644 index 0000000000..8bb251cab2 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithAbstract.xsd @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xml new file mode 100644 index 0000000000..467ec007ed --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xml @@ -0,0 +1,30 @@ + + + + + Some + ]]> + Mixed + SimpleType]]>WithName + Content + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xsd new file mode 100644 index 0000000000..8d00646678 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithCDATA.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xml new file mode 100644 index 0000000000..7deafd798a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xsd new file mode 100644 index 0000000000..72ac75fee0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithContent.xsd @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xml new file mode 100644 index 0000000000..f6208f81b3 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xml @@ -0,0 +1,29 @@ + + + + + Some + Mixed + SimpleTypeWithName + Content + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xsd new file mode 100644 index 0000000000..1f26e13673 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithMixed.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xml new file mode 100644 index 0000000000..97de7b98eb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xml @@ -0,0 +1,24 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xsd new file mode 100644 index 0000000000..67716553d8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenAttributes.xsd @@ -0,0 +1,42 @@ + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xml new file mode 100644 index 0000000000..5941348921 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xml @@ -0,0 +1,31 @@ + + + + + + + Some + Mixed + SimpleTypeWithName + Content + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xsd new file mode 100644 index 0000000000..24d5d09054 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOpenContent.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xml new file mode 100644 index 0000000000..f684d06a4d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xml @@ -0,0 +1,30 @@ + + + + + SomeData + + + idvalue2 + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xsd new file mode 100644 index 0000000000..de4a8a666d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithOppositeProperty.xsd @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xml new file mode 100644 index 0000000000..242908bd27 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xsd new file mode 100644 index 0000000000..4c00fbe295 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOAliasName.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xml new file mode 100644 index 0000000000..925e8625d5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xsd new file mode 100644 index 0000000000..b12bec040b --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOName.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xml new file mode 100644 index 0000000000..c73708ce46 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xsd new file mode 100644 index 0000000000..795c3ea7d9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithSDOSequence.xsd @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xml new file mode 100644 index 0000000000..3ebdc89ae0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xml @@ -0,0 +1,24 @@ + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xsd new file mode 100644 index 0000000000..21546d0f67 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutContent.xsd @@ -0,0 +1,33 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xml new file mode 100644 index 0000000000..89657e42ca --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xsd new file mode 100644 index 0000000000..d01b4172e4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ComplexTypeWithoutName.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xml new file mode 100644 index 0000000000..82fd1eedaf --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xml @@ -0,0 +1,23 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xsd new file mode 100644 index 0000000000..e1dcf06194 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/DefaultNamespace.xsd @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xml new file mode 100644 index 0000000000..ebf03c9d5d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xml @@ -0,0 +1,27 @@ + + + + + ElementInAllOne + ElementInAllTwo + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xsd new file mode 100644 index 0000000000..8b9ba5b4b8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInAll.xsd @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xml new file mode 100644 index 0000000000..26466b1b39 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xml @@ -0,0 +1,25 @@ + + + + Element1InChoice + Element2InChoice + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xsd new file mode 100644 index 0000000000..ff418c56ab --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementInChoice.xsd @@ -0,0 +1,48 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xml new file mode 100644 index 0000000000..27bb1ce9cc --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xml @@ -0,0 +1,29 @@ + + + + + + ChangeSummaryText + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xsd new file mode 100644 index 0000000000..2bf1df8c99 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSDOChangeSummaryType.xsd @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xml new file mode 100644 index 0000000000..9b5561ed43 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xml @@ -0,0 +1,24 @@ + + + + ElementOfSimpleTypeWithDefaultDefault + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xsd new file mode 100644 index 0000000000..0b4e7bdf45 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithDefault.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xml new file mode 100644 index 0000000000..f1b7cd264c --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xml @@ -0,0 +1,24 @@ + + + + ElementOfSimpleTypeWithFixedFixed + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xsd new file mode 100644 index 0000000000..a2c8456257 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithFixed.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xml new file mode 100644 index 0000000000..1f60b0423f --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xml @@ -0,0 +1,24 @@ + + + + ElementOfSimpleTypeWithSDODataTypeElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xsd new file mode 100644 index 0000000000..21e55ab8c1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDODataType.xsd @@ -0,0 +1,33 @@ + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xml new file mode 100644 index 0000000000..30762f4912 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xml @@ -0,0 +1,24 @@ + + + + idvalue0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xsd new file mode 100644 index 0000000000..5bf35d0d70 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOOppositePropertyType.xsd @@ -0,0 +1,33 @@ + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xml new file mode 100644 index 0000000000..2dd01e4090 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xml @@ -0,0 +1,24 @@ + + + + idvalue0 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd new file mode 100644 index 0000000000..6920cd8dd0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOPropertyType.xsd @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xml new file mode 100644 index 0000000000..6a526bdc47 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xml @@ -0,0 +1,24 @@ + + + + ElementOfSimpleTypeWithSDOStringElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xsd new file mode 100644 index 0000000000..1117a95eb8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementOfSimpleTypeWithSDOString.xsd @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xml new file mode 100644 index 0000000000..ab91458bff --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xml @@ -0,0 +1,40 @@ + + + + + + ElementInSubstitutionGroupBase + + + + Some Data + + + + ElementInSubstitutionGroupBase + + + ElementInSubstitutionGroupExtends + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xsd new file mode 100644 index 0000000000..3e015843b5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementSubstitutionGroupBase.xsd @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xml new file mode 100644 index 0000000000..b6d68fd08a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xml @@ -0,0 +1,25 @@ + + + + ElementWithMaxOccursElement1 + ElementWithMaxOccursElement2 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xsd new file mode 100644 index 0000000000..d4453a4477 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithMaxOccurs.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xml new file mode 100644 index 0000000000..6de3adc937 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xml @@ -0,0 +1,24 @@ + + + + ElementWithNillableElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xsd new file mode 100644 index 0000000000..786ab226da --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithNillable.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xml new file mode 100644 index 0000000000..64093aa803 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xml @@ -0,0 +1,24 @@ + + + + ElementWithSDOAliasName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xsd new file mode 100644 index 0000000000..01f4c2b1ef --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOAliasName.xsd @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xml new file mode 100644 index 0000000000..774646f682 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xml @@ -0,0 +1,24 @@ + + + + ElementWithSDONameElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xsd new file mode 100644 index 0000000000..34da37564c --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ElementWithSDOName.xsd @@ -0,0 +1,32 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xml new file mode 100644 index 0000000000..a1fb3aa803 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xsd new file mode 100644 index 0000000000..8eb7a4fce4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementComplexType.xsd @@ -0,0 +1,31 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xml new file mode 100644 index 0000000000..f68eb1939d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xml @@ -0,0 +1,24 @@ + + + + GlobalElementSimpleType + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xsd new file mode 100644 index 0000000000..b9f77e6658 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/GlobalElementSimpleType.xsd @@ -0,0 +1,26 @@ + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xml new file mode 100644 index 0000000000..fd28850050 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xml @@ -0,0 +1,30 @@ + + + + + SimpleTypeWithName + + SomeString + SomeString + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xsd new file mode 100644 index 0000000000..eae93fd44a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Import.xsd @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ImportedSchema.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ImportedSchema.xsd new file mode 100644 index 0000000000..a7e568decf --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/ImportedSchema.xsd @@ -0,0 +1,33 @@ + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xml new file mode 100644 index 0000000000..d4b9e24fa6 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xsd new file mode 100644 index 0000000000..34ff314a19 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Include.xsd @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Interop.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Interop.xsd new file mode 100644 index 0000000000..ae22ab2c44 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Interop.xsd @@ -0,0 +1,138 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xml new file mode 100644 index 0000000000..b75ac6500a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xml @@ -0,0 +1,24 @@ + + + +tns:Tuscany + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xsd new file mode 100644 index 0000000000..6ad019cb81 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Notation.xsd @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Person.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Person.xsd new file mode 100644 index 0000000000..5f5021b15e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/Person.xsd @@ -0,0 +1,30 @@ + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xml new file mode 100644 index 0000000000..6c5ad88ff4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xml @@ -0,0 +1,25 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xsd new file mode 100644 index 0000000000..6b7e39b334 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SDOJavaPackage.xsd @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xml new file mode 100644 index 0000000000..f9d4a24a49 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithAbstractExtensionElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xsd new file mode 100644 index 0000000000..f649e2ba83 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithAbstract.xsd @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xml new file mode 100644 index 0000000000..410df4b7e4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithExtendedInstanceClassElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xsd new file mode 100644 index 0000000000..5d27ef5ce1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithExtendedInstanceClass.xsd @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xml new file mode 100644 index 0000000000..7b74867c03 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithInstanceClassElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xsd new file mode 100644 index 0000000000..ec16a678a3 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithInstanceClass.xsd @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xml new file mode 100644 index 0000000000..708d526f44 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xml @@ -0,0 +1,24 @@ + + + + listmember1 listmember2 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xsd new file mode 100644 index 0000000000..ed681009f9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithList.xsd @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xml new file mode 100644 index 0000000000..e404ac86b7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithNameElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xsd new file mode 100644 index 0000000000..af0431f048 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithName.xsd @@ -0,0 +1,36 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xml new file mode 100644 index 0000000000..c86a0f6bcb --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithSDONameElement + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xsd new file mode 100644 index 0000000000..89b00a36cc --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithSDOName.xsd @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xml new file mode 100644 index 0000000000..399b0d8175 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xml @@ -0,0 +1,25 @@ + + + + EN + 01:02:03 + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xsd new file mode 100644 index 0000000000..ea35bec61a --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithUnion.xsd @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xml new file mode 100644 index 0000000000..bc8cf35368 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xml @@ -0,0 +1,26 @@ + + + + + SimpleTypeWithoutName + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xsd new file mode 100644 index 0000000000..57981e3666 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/SimpleTypeWithoutName.xsd @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xml b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xml new file mode 100644 index 0000000000..da2929776e --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xml @@ -0,0 +1,24 @@ + + + + SimpleTypeWithName + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xsd new file mode 100644 index 0000000000..ace5427786 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/TargetNamespace.xsd @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/datagraph.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/datagraph.xsd new file mode 100644 index 0000000000..e6b9697a8d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/datagraph.xsd @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Expected type is emof:Package. + + + + + + + + + + + Expected type is xsd:schema. + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoJava.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoJava.xsd new file mode 100644 index 0000000000..7387568942 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoJava.xsd @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoModel.xsd b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoModel.xsd new file mode 100644 index 0000000000..c5aabc9cc8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/main/resources/xsd/sdoModel.xsd @@ -0,0 +1,221 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/common/src/test/java/org/apache/tuscany/sca/itest/generate/GenerateTestCase.java b/java/sca/contrib/itest/databindings/common/src/test/java/org/apache/tuscany/sca/itest/generate/GenerateTestCase.java new file mode 100644 index 0000000000..fa3f310d4d --- /dev/null +++ b/java/sca/contrib/itest/databindings/common/src/test/java/org/apache/tuscany/sca/itest/generate/GenerateTestCase.java @@ -0,0 +1,49 @@ +/* + * 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.itest.generate; + +import junit.framework.TestCase; + + +/** + * + */ +public class GenerateTestCase extends TestCase { + + //private Generate generator = null; + + @Override + protected void setUp() throws Exception { + //generator = new Generate(); + } + + @Override + protected void tearDown() { + } + + /** + * Invokes the Generate class to generate databinding test classes and resources. + * + * @throws Exception + */ + public void testGenerate() throws Exception { + //generator.generate(); + } +} diff --git a/java/sca/contrib/itest/databindings/config.png b/java/sca/contrib/itest/databindings/config.png new file mode 100644 index 0000000000..7912019e9d Binary files /dev/null and b/java/sca/contrib/itest/databindings/config.png differ diff --git a/java/sca/contrib/itest/databindings/config.svg b/java/sca/contrib/itest/databindings/config.svg new file mode 100644 index 0000000000..aaf027e2df --- /dev/null +++ b/java/sca/contrib/itest/databindings/config.svg @@ -0,0 +1,117 @@ + + + + + + + + + + + image/svg+xml + + + + + + <tns:Generate ...> <Template> <TemplateName>greeter.composite.vm</TemplateName> <TemplateTargetDir>classes</TemplateTargetDir> </Template> ... <InputFile> <FileName>Person.xsd</FileName> <FilePath>xsd</FilePath> <JavaPackage>org.apache.tuscany.sca.itest.databinding.types</JavaPackage> <Factory>TypesFactory</Factory> <Namespace>http://apache.org/tuscany/sca/itest/databinding/types</Namespace> <Prefix>p</Prefix> <Type> <TypeName>PersonType</TypeName> <CreateTypeCode> TypesFactory factory = TypesFactory.INSTANCE; param = factory.createPersonType(); param.setFirstName("George"); param.setLastName("Doors"); </CreateTypeCode> <ModifyTypeCode> param.setGreeting("Hello"); </ModifyTypeCode> <ResultComparison> assertNotSame("greetedPerson.getGreeting() not set", "", result.getGreeting()); </ResultComparison> </Type> </InputFile> ...</tns:Generate> + diff --git a/java/sca/contrib/itest/databindings/databinding.png b/java/sca/contrib/itest/databindings/databinding.png new file mode 100644 index 0000000000..76a9c71b7d Binary files /dev/null and b/java/sca/contrib/itest/databindings/databinding.png differ diff --git a/java/sca/contrib/itest/databindings/databinding.svg b/java/sca/contrib/itest/databindings/databinding.svg new file mode 100644 index 0000000000..d6850ccf7d --- /dev/null +++ b/java/sca/contrib/itest/databindings/databinding.svg @@ -0,0 +1,242 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + GreeterService + + DefaultGreeterServiceClient + + + GreeterServiceComponent + + WSGreeterServiceClient + + + + + WSReference WSService + + + + diff --git a/java/sca/contrib/itest/databindings/interop.png b/java/sca/contrib/itest/databindings/interop.png new file mode 100644 index 0000000000..005e0f24ea Binary files /dev/null and b/java/sca/contrib/itest/databindings/interop.png differ diff --git a/java/sca/contrib/itest/databindings/interop.svg b/java/sca/contrib/itest/databindings/interop.svg new file mode 100644 index 0000000000..03897c6d09 --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop.svg @@ -0,0 +1,352 @@ + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + InteropGreeterService + + SDODefaultGreeterServiceClient + + + SDOGreeterServiceComponent + + SDOWSGreeterServiceClient + + + + WSReference WSService + JAXBDefaultGreeterServiceClient + + + JAXBWSGreeterServiceClient + + + + WSReference WSService + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/interop/pom.xml b/java/sca/contrib/itest/databindings/interop/pom.xml new file mode 100644 index 0000000000..a8f7635183 --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/pom.xml @@ -0,0 +1,223 @@ + + + + + org.apache.tuscany.sca + itest-databindings + 2.0-SNAPSHOT + + + 4.0.0 + + itest-databindings-interop + 2.0-SNAPSHOT + jar + Apache Tuscany SCA DataBinding Interop Integration Tests + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-databinding-jaxb + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-databinding-sdo + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-databinding-axiom + ${pom.version} + compile + + + javax.xml.bind + jaxb-api + 2.1 + compile + + + + com.sun.xml.ws + jaxws-rt + 2.1.3 + + + org.apache.tuscany.sca + itest-databindings-common + ${pom.version} + compile + + + org.apache.tuscany.sca + itest-databindings-sdo + ${pom.version} + compile + + + org.apache.tuscany.sca + itest-databindings-jaxb + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-embedded + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-interface-java-xml + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + test + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + -Djava.endorsed.dirs=target/endorsed + + + + org.apache.maven.plugins + maven-dependency-plugin + + + generate-sources + + unpack + + + + + org.apache.tuscany.sca + itest-databindings-common + ${project.version} + true + ${project.build.directory}/classes + + + + + + copy + generate-sources + + copy + + + + + javax.xml.ws + jaxws-api + 2.1 + jar + + + javax.xml.bind + jaxb-api + 2.1 + jar + + + ${project.build.directory}/endorsed + false + true + + + + + + org.codehaus.mojo + exec-maven-plugin + + + generate-test-source + process-resources + + java + + + + + org.apache.tuscany.sca.itest.generate.Generate + + ${project.build.directory} + + + + + + diff --git a/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/InteropDatabindingTestCase.java.vm b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/InteropDatabindingTestCase.java.vm new file mode 100644 index 0000000000..7bdfc57924 --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/InteropDatabindingTestCase.java.vm @@ -0,0 +1,113 @@ +/* + * 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 $template.getJavaPackage(); + +import junit.framework.TestCase; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import ${template.getJavaPackage()}.GreeterService; + +// Data types +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) +import $file.getJavaPackage().$typeInstance.getTypeName(); +import $file.getJavaPackage().$file.getFactory(); +#end +#end + +/** + * Automatically generated test case. Calls the greeter client for a number of + * bindings and a number of data types. + * + * @version $Rev: 511417 $ $Date: 2007-02-25 03:06:42 +0000 (Sun, 25 Feb 2007) $ + */ +public class InteropDatabindingTestCase extends TestCase { + + private static boolean initalised = false; + private GreeterService greeterClient; + private static SCADomain domain; + + /** + * Runs before each test method + */ + protected void setUp() throws Exception { + if (!initalised) { + domain = SCADomain.newInstance("interopgreeter.composite"); + super.setUp(); + initalised = true; + } + } + + /** + * Runs after each test method + */ + protected void tearDown() { + + } + + /** + * Finds the SCA component that relates to the protocol being tested. This test + * always connects locally to the client component but the client component will + * connect to the back end component using the appropriate protocol + * + * @param ext the protcol required + */ + private void setUpClient(String ext) throws Exception { + greeterClient = domain.getService(GreeterService.class, "SDO" + ext + "GreeterServiceClient"); + } + + /** + * Invokes the SDO Greet service using web service bindings with SDO payload + */ + public void testWSGreet() throws Exception { + setUpClient("WS"); + greet(); + } + + /** + * Invokes the SDO Greet service using default bindings with SDO payload + */ + public void testDefaultGreet() throws Exception { + setUpClient("Default"); + greet(); + } + + /** + * A generic method which, regarless of which client is connected, sends out a + * series of requrests passing different data types. + */ + public void greet() { +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + // test $typeInstance.getTypeName() + { + $typeInstance.getTypeName() param = null; + $typeInstance.getCreateTypeCode() + $typeInstance.getTypeName() result = greeterClient.greet$typeInstance.getTypeName()(param); + $typeInstance.getResultComparison() + } +#end +#end + } + +} diff --git a/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/JAXBGreeter.wsdl.vm b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/JAXBGreeter.wsdl.vm new file mode 100644 index 0000000000..38bfccce0c --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/JAXBGreeter.wsdl.vm @@ -0,0 +1,103 @@ + + + + + + + +#foreach($file in $fileList) + +#end + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + +#end +#end + + + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + + + +#end +#end + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/SDOGreeter.wsdl.vm b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/SDOGreeter.wsdl.vm new file mode 100644 index 0000000000..6f02af4c9d --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/SDOGreeter.wsdl.vm @@ -0,0 +1,103 @@ + + + + + + + +#foreach($file in $fileList) + +#end + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + +#end +#end + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + +#end +#end + + + + +#foreach($file in $fileList) +#set($typeList = $file.getType_()) +#foreach($typeInstance in $typeList) + + + + + + + + + +#end +#end + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/generate.xml b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/generate.xml new file mode 100644 index 0000000000..8453dd56b4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/generate.xml @@ -0,0 +1,159 @@ + + + + + + + + + + Person.xsd + xsd + org.apache.tuscany.sca.itest.databinding.types + TypesFactory + http://apache.org/tuscany/sca/itest/databinding/types + p + + PersonType + + TypesFactory factory = TypesFactory.INSTANCE; + param = factory.createPersonType(); + param.setFirstName("George"); + param.setLastName("Doors"); + + + param.setGreeting("Hello"); + + + assertNotSame("greetedPerson.getGreeting() not set", "", result.getGreeting()); + + + + + Interop.xsd + xsd + org.apache.tuscany.interop + InteropFactory + http://www.apache.org/tuscany/interop + i + + + AttributeComplexType + + InteropFactory factory = InteropFactory.INSTANCE; + org.apache.tuscany.interop.AttributeType attrib = factory.createAttributeType(); + attrib.setAttribute("SomeText"); + param = factory.createAttributeComplexType(); + param.setAttributeElement(attrib); + + + param.getAttributeElement().setAttribute("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getAttributeElement().getAttribute()); + + + + AttributeReferenceComplexType + + InteropFactory factory = InteropFactory.INSTANCE; + param = factory.createAttributeReferenceComplexType(); + + param.setReferencedAttribute("SomeText"); + + + param.setReferencedAttribute("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getReferencedAttribute()); + + + + SimpleTypeWithAbstractComplexType + + InteropFactory factory = InteropFactory.INSTANCE; + param = factory.createSimpleTypeWithAbstractComplexType(); + param.setSimpleTypeWithAbstractExtensionElement("SomeText"); + + + param.setSimpleTypeWithAbstractExtensionElement("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithAbstractExtensionElement()); + + + + SimpleTypeWithNameComplexType + + InteropFactory factory = InteropFactory.INSTANCE; + param = factory.createSimpleTypeWithNameComplexType(); + param.setSimpleTypeWithNameElement("SomeText"); + + + param.setSimpleTypeWithNameElement("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithNameElement()); + + + + ComplexTypeWithContentType + + InteropFactory factory = InteropFactory.INSTANCE; + param = factory.createComplexTypeWithContentType(); + param.setSimpleTypeWithName("SomeText"); + + + param.setSimpleTypeWithName("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithName()); + + + + diff --git a/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/interopgreeter.composite.vm b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/interopgreeter.composite.vm new file mode 100644 index 0000000000..36797fde57 --- /dev/null +++ b/java/sca/contrib/itest/databindings/interop/src/main/resources/generate/interopgreeter.composite.vm @@ -0,0 +1,78 @@ + + + + + + #foreach( $file in $fileList ) + + #end + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/pom.xml b/java/sca/contrib/itest/databindings/jaxb-bottom-up/pom.xml new file mode 100644 index 0000000000..45e5720602 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/pom.xml @@ -0,0 +1,239 @@ + + + + + org.apache.tuscany.sca + itest-databindings + 2.0-SNAPSHOT + + + 4.0.0 + + itest-databindings-jaxb-bottom-up + 2.0-SNAPSHOT + jar + Apache Tuscany SCA Databinding Integration Tests - JAXB Bottom Up + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + ${pom.version} + runtime + + + org.apache.tuscany.sca + tuscany-databinding-jaxb + ${pom.version} + runtime + + + org.apache.tuscany.sca + tuscany-databinding-sdo + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-databinding-axiom + ${pom.version} + compile + + + org.apache.tuscany.sca + itest-databindings-common + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-embedded + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-interface-java-xml + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + javax.xml.bind + jaxb-api + 2.1 + compile + + + + com.sun.xml.ws + jaxws-rt + 2.1.3 + + + + commons-collections + commons-collections + 3.1 + + + log4j + log4j + 1.2.12 + provided + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + -Djava.endorsed.dirs=target/endorsed + + + + org.apache.maven.plugins + maven-dependency-plugin + + + copy + generate-sources + + copy + + + + + javax.xml.ws + jaxws-api + 2.1 + jar + + + javax.xml.bind + jaxb-api + 2.1 + jar + + + ${project.build.directory}/endorsed + false + true + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AClientService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AClientService.java new file mode 100644 index 0000000000..5d389643cc --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AClientService.java @@ -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.tuscany.sca.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for AClientService. + */ +@Remotable +public interface AClientService { + public String getGreetingsForward(String name); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AService.java new file mode 100644 index 0000000000..52f1c01fd8 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/AService.java @@ -0,0 +1,32 @@ +/* + * 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.itest.databindings.jaxb; + +import javax.jws.soap.SOAPBinding; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for AService. + */ +@Remotable +@SOAPBinding(parameterStyle = SOAPBinding.ParameterStyle.BARE) +public interface AService { + public String getGreetings(String name); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean1.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean1.java new file mode 100644 index 0000000000..7529c2b841 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean1.java @@ -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 org.apache.tuscany.sca.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean1 { + private T item; + + public Bean1() { + } + + public Bean1(T item) { + this.item = item; + } + + public void setItem(T item) { + this.item = item; + } + + public T getItem() { + return item; + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } + if(that.getClass() != this.getClass()) { + return false; + } + + Bean1 that1 = (Bean1)that; + if(this == that1) { + return true; + } else if(this.item != null) { + return this.item.equals(that1.item); + } else { + return that1.item == null; + } + } + + public String toString() { + return this.getClass().getSimpleName()+"[item = "+item+"]"; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean10.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean10.java new file mode 100644 index 0000000000..4a4419a42b --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean10.java @@ -0,0 +1,25 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean10 extends Bean1 { +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean11.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean11.java new file mode 100644 index 0000000000..65f019ec48 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean11.java @@ -0,0 +1,25 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean11 extends Bean1 { +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean2.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean2.java new file mode 100644 index 0000000000..844e28863a --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean2.java @@ -0,0 +1,56 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean2 { + private String name; + + public void setName(String name) { + this.name = name; + } + + public String getName() { + return name; + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } + + if(this.getClass() != that.getClass()) { + return false; + } + + if(this == that) { + return true; + } else if(this.name != null) { + return this.name.equals(((Bean2)that).name); + } else { + return ((Bean2)that).name == null; + } + } + + public String toString() { + return this.getClass().getSimpleName()+"[name = "+name+"]"; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean3.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean3.java new file mode 100644 index 0000000000..4e0bd38b2b --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean3.java @@ -0,0 +1,56 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean3 extends Bean2 { + private String address; + + public void setAddress(String address) { + this.address = address; + } + + public String getAddress() { + return address; + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } + + if(this.getClass() != that.getClass()) { + return false; + } + + if(this == that) { + return true; + } else if(this.address != null) { + return this.address.equals(((Bean3)that).address) && super.equals(that); + } else { + return ((Bean3)that).address == null && super.equals(that); + } + } + + public String toString() { + return this.getClass().getSimpleName()+"[name = "+super.getName()+", address = "+address+"]"; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean31.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean31.java new file mode 100644 index 0000000000..40aff31297 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/Bean31.java @@ -0,0 +1,56 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * @version $Rev$ $Date$ + */ +public class Bean31 extends Bean2 { + private String address; + + public void setAddress(String address) { + this.address = address; + } + + public String getAddress() { + return address; + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } + + if(this.getClass() != that.getClass()) { + return false; + } + + if(this == that) { + return true; + } else if(this.address != null) { + return this.address.equals(((Bean31)that).address) && super.equals(that); + } else { + return ((Bean31)that).address == null && super.equals(that); + } + } + + public String toString() { + return this.getClass().getSimpleName()+"[name = "+super.getName()+", address = "+address+"]"; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsLocalService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsLocalService.java new file mode 100644 index 0000000000..ca012b967d --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsLocalService.java @@ -0,0 +1,42 @@ +/* + * 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.itest.databindings.jaxb; + +/** + * The interface for GenericsLocalService. + * + * @version $Rev$ $Date$ + */ +public interface GenericsLocalService { + Bean1 getTypeExplicit(Bean1 arg); + + Bean1 getTypeUnbound(T[] anArray); + + Bean1 getTypeExtends(T[] anArray); + + > Bean1 getRecursiveTypeBound(T[] anArray); + + Bean1 getWildcardUnbound(Bean1 arg); + + Bean1 getWildcardSuper(Bean1 arg); + + Bean1 getWildcardExtends(Bean1 arg); + + Bean2 getPolymorphic(Bean2 arg); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsService.java new file mode 100644 index 0000000000..be446c9759 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsService.java @@ -0,0 +1,30 @@ +/* + * 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.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for GenericsService. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface GenericsService extends GenericsLocalService{ +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsServiceClient.java new file mode 100644 index 0000000000..3bae554dc7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsServiceClient.java @@ -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 org.apache.tuscany.sca.itest.databindings.jaxb; + +/** + * The interface for GenericsServiceClient. + * + * @version $Rev$ $Date$ + */ +public interface GenericsServiceClient { + Bean1 getTypeExplicitForward(Bean1 arg); + + Bean1 getTypeUnboundForward(T[] anArray); + + Bean1 getTypeExtendsForward(T[] anArray); + + > Bean1 getRecursiveTypeBoundForward(T[] anArray); + + Bean1 getWildcardUnboundForward(Bean1 arg); + + Bean1 getWildcardSuperForward(Bean1 arg); + + Bean1 getWildcardExtendsForward(Bean1 arg); + + Bean2 getPolymorphicForward(Bean2 arg); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloLocalServiceSimple.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloLocalServiceSimple.java new file mode 100644 index 0000000000..a31cc3d45a --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloLocalServiceSimple.java @@ -0,0 +1,37 @@ +/* + * 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.itest.databindings.jaxb; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * The interface for HelloLocalServiceSimple. + */ +public interface HelloLocalServiceSimple { + String getGreetings(String name); + String[] getGreetingsArray(String[] names); + List getGreetingsList(List names); + ArrayList getGreetingsArrayList(ArrayList names); + Map getGreetingsMap(Map namesMap); + HashMap getGreetingsHashMap(HashMap namesMap); + String getGreetingsVarArgs(String... names); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimple.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimple.java new file mode 100644 index 0000000000..df9e6e53ec --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimple.java @@ -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.tuscany.sca.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for HelloServiceSimple. + */ +@Remotable +public interface HelloServiceSimple extends HelloLocalServiceSimple { + // Add any methods to the local interface. +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimpleClient.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimpleClient.java new file mode 100644 index 0000000000..23ed57dec9 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceSimpleClient.java @@ -0,0 +1,38 @@ +/* + * 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.itest.databindings.jaxb; + +import java.util.ArrayList; +import java.util.List; +import java.util.HashMap; +import java.util.Map; + +/** + * The interface for HelloServiceSimpleClient. + */ +public interface HelloServiceSimpleClient { + String getGreetingsForward(String name); + String[] getGreetingsArrayForward(String[] names); + List getGreetingsListForward(List names); + ArrayList getGreetingsArrayListForward(ArrayList names); + Map getGreetingsMapForward(Map namesMap); + HashMap getGreetingsHashMapForward(HashMap namesMap); + String getGreetingsVarArgsForward(String... names); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesLocalService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesLocalService.java new file mode 100644 index 0000000000..6239c0f5f1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesLocalService.java @@ -0,0 +1,47 @@ +/* + * 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.itest.databindings.jaxb; + + +/** + * The interface for PrimitivesLocalService. + */ +public interface PrimitivesLocalService { + boolean negateBoolean(boolean flag); + boolean[] negateBooleanArray(boolean[] flags); + boolean[] identityBooleanArray(boolean[] flags); + byte negateByte(byte b); + byte[] negateByteArray(byte[] ba); + byte[] identityByteArray(byte[] ba); + short negateShort(short s); + short[] negateShortArray(short[] s); + short[] identityShortArray(short[] sa); + int negateInt(int s); + int[] negateIntArray(int[] s); + int[] identityIntArray(int[] ia); + long negateLong(long l); + long[] negateLongArray(long[] la); + long[] identityLongArray(long[] la); + float negateFloat(float f); + float[] negateFloatArray(float[] fa); + float[] identityFloatArray(float[] fa); + double negateDouble(double d); + double[] negateDoubleArray(double[] da); + double[] identityDoubleArray(double[] da); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java new file mode 100644 index 0000000000..690a2adb3d --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java @@ -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.tuscany.sca.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for PrimitivesService. + */ +@Remotable +public interface PrimitivesService extends PrimitivesLocalService { + // Add any methods to the local interface. +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java new file mode 100644 index 0000000000..3bdf886dfa --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java @@ -0,0 +1,48 @@ +/* + * 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.itest.databindings.jaxb; + + +/** + * The interface for PrimitivesServiceClient. + */ +public interface PrimitivesServiceClient { + boolean negateBooleanForward(boolean flag); + boolean[] negateBooleanArrayForward(boolean[] flags); + boolean passByValueBooleanArray(); + byte negateByteForward(byte b); + byte[] negateByteArrayForward(byte[] ba); + boolean passByValueByteArray(); + short negateShortForward(short s); + short[] negateShortArrayForward(short[] sa); + boolean passByValueShortArray(); + int negateIntForward(int i); + int[] negateIntArrayForward(int[] ia); + boolean passByValueIntArray(); + long negateLongForward(long l); + long[] negateLongArrayForward(long[] la); + boolean passByValueLongArray(); + float negateFloatForward(float f); + float[] negateFloatArrayForward(float[] fa); + boolean passByValueFloatArray(); + double negateDoubleForward(double d); + double[] negateDoubleArrayForward(double[] da); + boolean passByValueDoubleArray(); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesLocalService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesLocalService.java new file mode 100644 index 0000000000..0fdf69459f --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesLocalService.java @@ -0,0 +1,78 @@ +/* + * 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.itest.databindings.jaxb; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + + +/** + * The interface for StandardTypesLocalService. + */ +public interface StandardTypesLocalService { + BigInteger getNewBigInteger(BigInteger bi); + BigInteger[] getNewBigIntegerArray(BigInteger[] bia); + + BigDecimal getNewBigDecimal(BigDecimal bd); + BigDecimal[] getNewBigDecimalArray(BigDecimal[] bda); + + Calendar getNewCalendar(Calendar c); + Calendar[] getNewCalendarArray(Calendar[] ca); + + Date getNewDate(Date d); + Date[] getNewDateArray(Date[] da); + + QName getNewQName(QName qname); + QName[] getNewQNameArray(QName[] qnames); + + URI getNewURI(URI uri); + URI[] getNewURIArray(URI[] uris); + + XMLGregorianCalendar getNewXMLGregorianCalendar(XMLGregorianCalendar xgcal); + XMLGregorianCalendar[] getNewXMLGregorianCalendarArray(XMLGregorianCalendar[] xgcal); + + Duration getNewDuration(Duration d); + Duration[] getNewDurationArray(Duration[] da); + + Object getNewObject(Object obj); + Object[] getNewObjectArray(Object[] objs); + + Image getNewImage(Image img); + Image[] getNewImageArray(Image[] imgs); + + DataHandler getNewDataHandler(DataHandler dh); + DataHandler[] getNewDataHandlerArray(DataHandler[] dha); + + Source getNewSource(Source src); + Source[] getNewSourceArray(Source[] srcs); + + UUID getNewUUID(UUID uuid); + UUID[] getNewUUIDArray(UUID[] uuids); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java new file mode 100644 index 0000000000..3b9690b7d2 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java @@ -0,0 +1,30 @@ +/* + * 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.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + + + +/** + * The interface for StandardTypesService. + */ +@Remotable +public interface StandardTypesService extends StandardTypesLocalService{ +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java new file mode 100644 index 0000000000..351d9df0cb --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java @@ -0,0 +1,79 @@ +/* + * 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.itest.databindings.jaxb; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + + +/** + * The interface for StandardTypesServiceClient. + */ +public interface StandardTypesServiceClient { + BigInteger getNewBigIntegerForward(BigInteger bi); + BigInteger[] getNewBigIntegerArrayForward(BigInteger[] bia); + + BigDecimal getNewBigDecimalForward(BigDecimal bd); + BigDecimal[] getNewBigDecimalArrayForward(BigDecimal[] bda); + + Calendar getNewCalendarForward(Calendar c); + Calendar[] getNewCalendarArrayForward(Calendar[] ca); + + Date getNewDateForward(Date d); + Date[] getNewDateArrayForward(Date[] da); + + QName getNewQNameForward(QName qname); + QName[] getNewQNameArrayForward(QName[] qnames); + + URI getNewURIForward(URI uri); + URI[] getNewURIArrayForward(URI[] uris); + + XMLGregorianCalendar getNewXMLGregorianCalendarForward(XMLGregorianCalendar xgcal); + XMLGregorianCalendar[] getNewXMLGregorianCalendarArrayForward(XMLGregorianCalendar[] xgcals); + + Duration getNewDurationForward(Duration d); + Duration[] getNewDurationArrayForward(Duration[] da); + + Object getNewObjectForward(Object obj); + Object[] getNewObjectArrayForward(Object[] objs); + + Image getNewImageForward(Image img); + Image[] getNewImageArrayForward(Image[] imgs); + + DataHandler getNewDataHandlerForward(DataHandler dh); + DataHandler[] getNewDataHandlerArrayForward(DataHandler[] dha); + + Source getNewSourceForward(Source src); + Source[] getNewSourceArrayForward(Source[] srcs); + + UUID getNewUUIDForward(UUID uuid); + UUID[] getNewUUIDArrayForward(UUID[] uuids); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AClientServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AClientServiceImpl.java new file mode 100644 index 0000000000..2f3bd3f2cb --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AClientServiceImpl.java @@ -0,0 +1,38 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.AClientService; +import org.apache.tuscany.sca.itest.databindings.jaxb.AService; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements AService. + */ +@Service(AClientService.class) +public class AClientServiceImpl implements AClientService { + + @Reference + protected AService aService; + + public String getGreetingsForward(String name) { + return aService.getGreetings(name); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AServiceImpl.java new file mode 100644 index 0000000000..078be8896e --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/AServiceImpl.java @@ -0,0 +1,33 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.AService; +import org.oasisopen.sca.annotation.Service; + +/** + * This class implements AService. + */ +@Service(AService.class) +public class AServiceImpl implements AService { + + public String getGreetings(String name) { + return "Hello " + name; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsLocalServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsLocalServiceClientImpl.java new file mode 100644 index 0000000000..4d451e6d32 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsLocalServiceClientImpl.java @@ -0,0 +1,77 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean1; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean2; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean3; +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of GenericsLocalServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + * + * @version $Rev$ $Date$ + */ +@Service(GenericsServiceClient.class) +public class GenericsLocalServiceClientImpl implements GenericsServiceClient { + + private GenericsLocalService service; + + @Reference(required=false) + protected void setGenericsLocalService(GenericsLocalService service) { + this.service = service; + } + + public Bean1 getTypeExplicitForward(Bean1 arg) { + return service.getTypeExplicit(arg); + } + + public Bean1 getTypeUnboundForward(T[] anArray) { + return service.getTypeUnbound(anArray); + } + + public Bean1 getTypeExtendsForward(T[] anArray) { + return service.getTypeExtends(anArray); + } + + public > Bean1 getRecursiveTypeBoundForward(T[] anArray) { + return service.getRecursiveTypeBound(anArray); + } + + public Bean1 getWildcardUnboundForward(Bean1 arg) { + return service.getWildcardUnbound(arg); + } + + public Bean1 getWildcardSuperForward(Bean1 arg) { + return service.getWildcardSuper(arg); + } + + public Bean1 getWildcardExtendsForward(Bean1 arg) { + return service.getWildcardExtends(arg); + } + + public Bean2 getPolymorphicForward(Bean2 arg) { + return service.getPolymorphic(arg); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceClientImpl.java new file mode 100644 index 0000000000..d520e64881 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceClientImpl.java @@ -0,0 +1,40 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsService; +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of GenericsServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + * + * @version $Rev$ $Date$ + */ +@Service(GenericsServiceClient.class) +public class GenericsServiceClientImpl extends GenericsLocalServiceClientImpl { + + @Reference + public void setGenericsService(GenericsService service) { + super.setGenericsLocalService(service); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceImpl.java new file mode 100644 index 0000000000..27dc25289e --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsServiceImpl.java @@ -0,0 +1,69 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean1; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean2; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean3; +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.GenericsService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of GenericsService. + * This implementation provides both a local and a remotable service. + * + * @version $Rev$ $Date$ + */ +@Service(interfaces={GenericsService.class, GenericsLocalService.class}) +public class GenericsServiceImpl implements GenericsService, GenericsLocalService { + + public Bean1 getTypeExplicit(Bean1 arg) { + return GenericsTransformer.getTypeExplicit(arg); + } + + public Bean1 getTypeUnbound(T[] anArray) { + return GenericsTransformer.getTypeUnbound(anArray); + } + + public Bean1 getTypeExtends(T[] anArray) { + return GenericsTransformer.getTypeExtends(anArray); + } + + public > Bean1 getRecursiveTypeBound(T[] anArray) { + return GenericsTransformer.getRecursiveTypeBound(anArray); + } + + public Bean1 getWildcardUnbound(Bean1 arg) { + return GenericsTransformer.getWildcardUnbound(arg); + } + + public Bean1 getWildcardSuper(Bean1 arg) { + return GenericsTransformer.getWildcardSuper(arg); + } + + public Bean1 getWildcardExtends(Bean1 arg) { + return GenericsTransformer.getWildcardExtends(arg); + } + + public Bean2 getPolymorphic(Bean2 arg) { + return GenericsTransformer.getPolymorphic(arg); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsTransformer.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsTransformer.java new file mode 100644 index 0000000000..858b8da59a --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/GenericsTransformer.java @@ -0,0 +1,125 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean1; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean10; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean11; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean2; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean3; +import org.apache.tuscany.sca.itest.databindings.jaxb.Bean31; + + +/** + * GenericsTransformer class that provide for transforming input provided to GenericsService methods. + * + * @version $Rev$ $Date$ + */ +public class GenericsTransformer { + + public static Bean1 getTypeExplicit(Bean1 arg) { + return new Bean1(arg.getItem() == null ? null : arg.getItem()+" AA"); + } + + public static Bean1 getTypeUnbound(T[] arg) { + if(arg instanceof String[]) { + return new Bean1(arg[0]); + } else if(arg instanceof Integer[]){ + return new Bean1(arg[1]); + } else { + return new Bean1(arg[2]); + } + } + + public static Bean1 getTypeExtends(T[] arg) { + if(arg instanceof Bean3[]) { + return new Bean1(arg[0]); + } else if(arg instanceof Bean31[]) { + return new Bean1(arg[1]); + } else { + return new Bean1(arg[2]); + } + } + + public static > Bean1 getRecursiveTypeBound(T[] arg) { + if(arg instanceof Bean10[]) { + return new Bean1(arg[0]); + } else if(arg instanceof Bean11[]) { + return new Bean1(arg[1]); + } else { + return new Bean1(arg[2]); + } + } + + public static Bean1 getWildcardUnbound(Bean1 arg) { + if(arg.getItem() instanceof String) { + Bean1 temp = new Bean1(); + temp.setItem("Hello "+arg.getItem()); + return temp; + } else if(arg.getItem() instanceof Integer) { + Bean1 temp = new Bean1(); + temp.setItem(10+(Integer)arg.getItem()); + return temp; + } else { + return new Bean1(arg.toString()); + } + } + + public static Bean1 getWildcardSuper(Bean1 arg) { + Object item = arg.getItem(); + if(item instanceof Bean3) { + Bean3 temp = new Bean3(); + temp.setName("Hello " + ((Bean3)item).getName()); + temp.setAddress("New "+((Bean3)item).getAddress()); + return new Bean1(temp); + } else if(item instanceof Bean2) { + Bean2 temp = new Bean2(); + temp.setName("Hello " + ((Bean3)item).getName()); + return new Bean1(temp); + } else { + Bean2 temp = new Bean2(); + temp.setName(item.toString()); + return new Bean1(temp); + } + } + + public static Bean1 getWildcardExtends(Bean1 arg) { + Bean2 item = arg.getItem(); + if(item instanceof Bean3) { + Bean3 temp = new Bean3(); + temp.setName("Hello "+item.getName()); + temp.setAddress("New "+((Bean3)item).getAddress()); + return new Bean1(temp); + } else if(item instanceof Bean31) { + Bean31 temp = new Bean31(); + temp.setName("Hello "+item.getName()); + temp.setAddress("New "+((Bean31)item).getAddress()); + return new Bean1(temp); + } else { + Bean2 temp = new Bean2(); + temp.setName("Hello "+item.getName()); + return new Bean1(temp); + } + } + + public static Bean2 getPolymorphic(Bean2 arg) { + return arg; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloLocalServiceSimpleClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloLocalServiceSimpleClientImpl.java new file mode 100644 index 0000000000..37b3f1b680 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloLocalServiceSimpleClientImpl.java @@ -0,0 +1,73 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.util.ArrayList; +import java.util.List; +import java.util.HashMap; +import java.util.Map; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloLocalServiceSimple; +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceSimpleClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of HelloServiceSimpleClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(HelloServiceSimpleClient.class) +public class HelloLocalServiceSimpleClientImpl implements HelloServiceSimpleClient { + + private HelloLocalServiceSimple service; + + @Reference(required=false) + protected void setHelloLocalServiceSimple(HelloLocalServiceSimple service) { + this.service = service; + } + + public String getGreetingsForward(String name) { + return service.getGreetings(name); + } + + public String[] getGreetingsArrayForward(String[] names) { + return service.getGreetingsArray(names); + } + + public List getGreetingsListForward(List names) { + return service.getGreetingsList(names); + } + + public Map getGreetingsMapForward(Map namesMap) { + return service.getGreetingsMap(namesMap); + } + + public ArrayList getGreetingsArrayListForward(ArrayList names) { + return service.getGreetingsArrayList(names); + } + + public HashMap getGreetingsHashMapForward(HashMap namesMap) { + return service.getGreetingsHashMap(namesMap); + } + + public String getGreetingsVarArgsForward(String... names) { + return service.getGreetingsVarArgs(names[0], names[1], names[2]); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleClientImpl.java new file mode 100644 index 0000000000..44b6e9d906 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleClientImpl.java @@ -0,0 +1,38 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceSimple; +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceSimpleClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of HelloServiceSimpleClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(HelloServiceSimpleClient.class) +public class HelloServiceSimpleClientImpl extends HelloLocalServiceSimpleClientImpl { + + @Reference + public void setHelloServiceSimple(HelloServiceSimple service) { + super.setHelloLocalServiceSimple(service); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleImpl.java new file mode 100644 index 0000000000..5c389bf67f --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceSimpleImpl.java @@ -0,0 +1,86 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloLocalServiceSimple; +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceSimple; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of HelloServiceSimple. + * The implementation provides both a local and a remotable service. + */ +@Service(interfaces = {HelloServiceSimple.class, HelloLocalServiceSimple.class}) +public class HelloServiceSimpleImpl implements HelloServiceSimple { + public String getGreetings(String name) { + return "Hello " + name; + } + + public String[] getGreetingsArray(String[] names) { + String[] resps = new String[names.length]; + for (int i = 0; i < names.length; ++i) { + resps[i] = "Hello " + names[i]; + } + return resps; + } + + public List getGreetingsList(List names) { + List resps = new ArrayList(); + for (int i = 0; i < names.size(); ++i) { + resps.add("Hello " + names.get(i)); + } + return resps; + } + + public ArrayList getGreetingsArrayList(ArrayList names) { + ArrayList resps = new ArrayList(); + for (int i = 0; i < names.size(); ++i) { + resps.add("Hello " + names.get(i)); + } + return resps; + } + + public Map getGreetingsMap(Map namesMap) { + for (Map.Entry entry : namesMap.entrySet()) { + entry.setValue("Hello " + entry.getKey()); + } + return namesMap; + } + + public HashMap getGreetingsHashMap(HashMap namesMap) { + for (Map.Entry entry : namesMap.entrySet()) { + entry.setValue("Hello " + entry.getKey()); + } + return namesMap; + } + + public String getGreetingsVarArgs(String... names) { + String resp = "Hello"; + for(int i = 0; i < names.length; ++i) { + resp += (" "+names[i]); + } + return resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesLocalServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesLocalServiceClientImpl.java new file mode 100644 index 0000000000..eea19521c4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesLocalServiceClientImpl.java @@ -0,0 +1,138 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of PrimitivesLocalServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(PrimitivesServiceClient.class) +public class PrimitivesLocalServiceClientImpl implements PrimitivesServiceClient { + + private PrimitivesLocalService service; + + @Reference(required=false) + protected void setPrimitivesLocalService(PrimitivesLocalService service) { + this.service = service; + } + + public boolean negateBooleanForward(boolean flag) { + return service.negateBoolean(flag); + } + + public boolean[] negateBooleanArrayForward(boolean[] flags) { + return service.negateBooleanArray(flags); + } + + public boolean passByValueBooleanArray() { + boolean[] req = new boolean[2]; + boolean[] resp = service.identityBooleanArray(req); + return req != resp; + } + + public byte negateByteForward(byte b) { + return service.negateByte(b); + } + + public byte[] negateByteArrayForward(byte[] ba) { + return service.negateByteArray(ba); + } + + public boolean passByValueByteArray() { + byte[] req = new byte[2]; + byte[] resp = service.identityByteArray(req); + return req != resp; + } + + public short negateShortForward(short s) { + return service.negateShort(s); + } + + public short[] negateShortArrayForward(short[] s) { + return service.negateShortArray(s); + } + + public boolean passByValueShortArray() { + short[] req = new short[2]; + short[] resp = service.identityShortArray(req); + return req != resp; + } + + public int negateIntForward(int i) { + return service.negateInt(i); + } + + public int[] negateIntArrayForward(int[] ia) { + return service.negateIntArray(ia); + } + + public boolean passByValueIntArray() { + int[] req = new int[2]; + int[] resp = service.identityIntArray(req); + return req != resp; + } + + public long negateLongForward(long l) { + return service.negateLong(l); + } + + public long[] negateLongArrayForward(long[] la) { + return service.negateLongArray(la); + } + + public boolean passByValueLongArray() { + long[] req = new long[2]; + long[] resp = service.identityLongArray(req); + return req != resp; + } + + public float negateFloatForward(float f) { + return service.negateFloat(f); + } + + public float[] negateFloatArrayForward(float[] fa) { + return service.negateFloatArray(fa); + } + + public boolean passByValueFloatArray() { + float[] req = new float[2]; + float[] resp = service.identityFloatArray(req); + return req != resp; + } + + public double negateDoubleForward(double d) { + return service.negateDouble(d); + } + + public double[] negateDoubleArrayForward(double[] da) { + return service.negateDoubleArray(da); + } + + public boolean passByValueDoubleArray() { + double[] req = new double[2]; + double[] resp = service.identityDoubleArray(req); + return req != resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java new file mode 100644 index 0000000000..263d1212ca --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java @@ -0,0 +1,38 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesService; +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of PrimitivesServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(PrimitivesServiceClient.class) +public class PrimitivesServiceClientImpl extends PrimitivesLocalServiceClientImpl { + + @Reference + public void setPrimitivesService(PrimitivesService service) { + super.setPrimitivesLocalService(service); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java new file mode 100644 index 0000000000..9e14140752 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java @@ -0,0 +1,151 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of PrimitivesService. + * This implementation provides both a local and a remotable service. + */ +@Service(interfaces={PrimitivesService.class, PrimitivesLocalService.class}) +public class PrimitivesServiceImpl implements PrimitivesService, PrimitivesLocalService { + + public boolean negateBoolean(boolean flag) { + return !flag; + } + + public boolean[] negateBooleanArray(boolean[] flags) { + boolean[] resp = new boolean[flags.length]; + + for(int i = 0; i < flags.length; ++i) { + resp[i] = !flags[i]; + } + return resp; + } + + public boolean[] identityBooleanArray(boolean[] flags) { + return flags; + } + + public byte negateByte(byte b) { + return (byte)-b; + } + + public byte[] negateByteArray(byte[] ba) { + byte[] resp = new byte[ba.length]; + + for(int i = 0; i < ba.length; ++i) { + resp[i] = (byte)-ba[i]; + } + return resp; + } + + public byte[] identityByteArray(byte[] ba) { + return ba; + } + + public short negateShort(short s) { + return (short)-s; + } + + public short[] negateShortArray(short[] s) { + short[] resp = new short[s.length]; + + for(int i = 0; i < s.length; ++i) { + resp[i] = (short)-s[i]; + } + return resp; + } + + public short[] identityShortArray(short[] sa) { + return sa; + } + + public int negateInt(int i) { + return -i; + } + + public int[] negateIntArray(int[] ia) { + int[] resp = new int[ia.length]; + + for(int i = 0; i < ia.length; ++i) { + resp[i] = -ia[i]; + } + return resp; + } + + public int[] identityIntArray(int[] ia) { + return ia; + } + + public long negateLong(long l) { + return -l; + } + + public long[] negateLongArray(long[] la) { + long[] resp = new long[la.length]; + + for(int i = 0; i < la.length; ++i) { + resp[i] = -la[i]; + } + return resp; + } + + public long[] identityLongArray(long[] la) { + return la; + } + + public float negateFloat(float f) { + return -f; + } + + public float[] negateFloatArray(float[] fa) { + float[] resp = new float[fa.length]; + + for(int i = 0; i < fa.length; ++i) { + resp[i] = -fa[i]; + } + return resp; + } + + public float[] identityFloatArray(float[] fa) { + return fa; + } + + public double negateDouble(double d) { + return -d; + } + + public double[] negateDoubleArray(double[] da) { + double[] resp = new double[da.length]; + + for(int i = 0; i < da.length; ++i) { + resp[i] = -da[i]; + } + return resp; + } + + public double[] identityDoubleArray(double[] da) { + return da; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesLocalServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesLocalServiceClientImpl.java new file mode 100644 index 0000000000..3ceee3c4b1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesLocalServiceClientImpl.java @@ -0,0 +1,157 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of StandardTypesLocalServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(StandardTypesServiceClient.class) +public class StandardTypesLocalServiceClientImpl implements StandardTypesServiceClient { + + private StandardTypesLocalService service; + + @Reference(required=false) + protected void setStandardTypesLocalService(StandardTypesLocalService service) { + this.service = service; + } + + public BigInteger getNewBigIntegerForward(BigInteger bi) { + return service.getNewBigInteger(bi); + } + + public BigInteger[] getNewBigIntegerArrayForward(BigInteger[] bia) { + return service.getNewBigIntegerArray(bia); + } + + public BigDecimal getNewBigDecimalForward(BigDecimal bd) { + return service.getNewBigDecimal(bd); + } + + public BigDecimal[] getNewBigDecimalArrayForward(BigDecimal[] bda) { + return service.getNewBigDecimalArray(bda); + } + public Calendar getNewCalendarForward(Calendar c) { + return service.getNewCalendar(c); + } + public Calendar[] getNewCalendarArrayForward(Calendar[] ca) { + return service.getNewCalendarArray(ca); + } + + public Date getNewDateForward(Date d) { + return service.getNewDate(d); + } + + public Date[] getNewDateArrayForward(Date[] da) { + return service.getNewDateArray(da); + } + + public QName getNewQNameForward(QName qname) { + return service.getNewQName(qname); + } + + public QName[] getNewQNameArrayForward(QName[] qnames) { + return service.getNewQNameArray(qnames); + } + + public URI getNewURIForward(URI uri) { + return service.getNewURI(uri); + } + + public URI[] getNewURIArrayForward(URI[] uris) { + return service.getNewURIArray(uris); + } + + public XMLGregorianCalendar getNewXMLGregorianCalendarForward(XMLGregorianCalendar xgcal) { + return service.getNewXMLGregorianCalendar(xgcal); + } + + public XMLGregorianCalendar[] getNewXMLGregorianCalendarArrayForward(XMLGregorianCalendar[] xgcals) { + return service.getNewXMLGregorianCalendarArray(xgcals); + } + + public Duration getNewDurationForward(Duration d) { + return service.getNewDuration(d); + } + + public Duration[] getNewDurationArrayForward(Duration[] da) { + return service.getNewDurationArray(da); + } + + public Object getNewObjectForward(Object obj) { + return service.getNewObject(obj); + } + + public Object[] getNewObjectArrayForward(Object[] objs) { + return service.getNewObjectArray(objs); + } + + public Image getNewImageForward(Image img) { + return service.getNewImage(img); + } + + public Image[] getNewImageArrayForward(Image[] imgs) { + return service.getNewImageArray(imgs); + } + + public DataHandler getNewDataHandlerForward(DataHandler dh) { + return service.getNewDataHandler(dh); + } + + public DataHandler[] getNewDataHandlerArrayForward(DataHandler[] dha) { + return service.getNewDataHandlerArray(dha); + } + + + public Source getNewSourceForward(Source src) { + return service.getNewSource(src); + } + + public Source[] getNewSourceArrayForward(Source[] srcs) { + return service.getNewSourceArray(srcs); + } + + public UUID getNewUUIDForward(UUID uuid) { + return service.getNewUUID(uuid); + } + + public UUID[] getNewUUIDArrayForward(UUID[] uuids) { + return service.getNewUUIDArray(uuids); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java new file mode 100644 index 0000000000..6aefb05c83 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java @@ -0,0 +1,38 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesService; +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of StandardTypesServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(StandardTypesServiceClient.class) +public class StandardTypesServiceClientImpl extends StandardTypesLocalServiceClientImpl { + + @Reference + public void setStandardTypesService(StandardTypesService service) { + super.setStandardTypesLocalService(service); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java new file mode 100644 index 0000000000..42fb9cbac2 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java @@ -0,0 +1,208 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesLocalService; +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of StandardTypesService. + * This implementation provides both a local and a remotable service. + */ +@Service(interfaces={StandardTypesService.class, StandardTypesLocalService.class}) +public class StandardTypesServiceImpl implements StandardTypesService, StandardTypesLocalService { + + public BigInteger getNewBigInteger(BigInteger bi) { + return bi.negate(); + } + + public BigInteger[] getNewBigIntegerArray(BigInteger[] bia) { + BigInteger[] resp = new BigInteger[bia.length]; + for(int i = 0; i < bia.length; ++i) { + resp[i] = bia[i].negate(); + } + return resp; + } + + public BigDecimal getNewBigDecimal(BigDecimal bd) { + return bd.negate(); + } + + public BigDecimal[] getNewBigDecimalArray(BigDecimal[] bda) { + BigDecimal[] resp = new BigDecimal[bda.length]; + for(int i = 0; i < bda.length; ++i) { + resp[i] = bda[i].negate(); + } + return resp; + } + + public Calendar getNewCalendar(Calendar c) { + Calendar resp = (Calendar)c.clone(); + resp.add(Calendar.DAY_OF_MONTH, 5); + return resp; + } + + public Calendar[] getNewCalendarArray(Calendar[] ca) { + Calendar[] resp = new Calendar[ca.length]; + for(int i = 0; i < ca.length; ++i) { + resp[i] = getNewCalendar(ca[i]); + } + return resp; + } + + public Date getNewDate(Date d) { + return new Date(d.getTime() + 5*24*60*60*1000); + } + + public Date[] getNewDateArray(Date[] da) { + Date[] resp = new Date[da.length]; + for(int i = 0; i < da.length; ++i) { + resp[i] = getNewDate(da[i]); + } + return resp; + } + + public QName getNewQName(QName qname) { + return new QName(qname.getNamespaceURI()+"q", qname.getLocalPart()+"q", qname.getPrefix()+"q"); + + } + + public QName[] getNewQNameArray(QName[] qnames) { + QName[] resp = new QName[qnames.length]; + for(int i = 0; i < qnames.length; ++i) { + resp[i] = getNewQName(qnames[i]); + } + return resp; + } + + public URI getNewURI(URI uri) { + return uri.resolve("uri"); + } + + public URI[] getNewURIArray(URI[] uris) { + URI[] resp = new URI[uris.length]; + for(int i = 0; i < uris.length; ++i) { + resp[i] = getNewURI(uris[i]); + } + return resp; + } + + public XMLGregorianCalendar getNewXMLGregorianCalendar(XMLGregorianCalendar xgcal) { + xgcal = (XMLGregorianCalendar)xgcal.clone(); + xgcal.setDay(xgcal.getDay()+5); + return xgcal; + } + + public XMLGregorianCalendar[] getNewXMLGregorianCalendarArray(XMLGregorianCalendar[] xgcals) { + XMLGregorianCalendar[] resp = new XMLGregorianCalendar[xgcals.length]; + for(int i = 0; i < xgcals.length; ++i) { + resp[i] = getNewXMLGregorianCalendar(xgcals[i]); + } + return resp; + } + + public Duration getNewDuration(Duration d) { + return d.negate(); + } + + public Duration[] getNewDurationArray(Duration[] da) { + Duration[] resp = new Duration[da.length]; + for(int i = 0; i < da.length; ++i) { + resp[i] = da[i].negate(); + } + return resp; + } + + public Object getNewObject(Object obj) { + return StandardTypesTransformer.getNewObject(obj); + } + + public Object[] getNewObjectArray(Object[] objs) { + Object[] resp = new Object[objs.length]; + for(int i = 0; i < objs.length; ++i) { + resp[i] = getNewObject(objs[i]); + } + return resp; + } + + public Image getNewImage(Image img) { + return StandardTypesTransformer.getNewImage(img); + } + + public Image[] getNewImageArray(Image[] imgs) { + Image[] resp = new Image[imgs.length]; + for(int i = 0; i < imgs.length; ++i) { + resp[i] = getNewImage(imgs[i]); + } + return resp; + } + + public DataHandler getNewDataHandler(DataHandler dh) { + // FIXME: transform the input + return dh; + } + + public DataHandler[] getNewDataHandlerArray(DataHandler[] dha) { + DataHandler[] resp = new DataHandler[dha.length]; + for(int i = 0; i < dha.length; ++i) { + resp[i] = dha[i]; + } + return resp; + } + + public Source getNewSource(Source src) { + return StandardTypesTransformer.getNewSource(src); + } + + public Source[] getNewSourceArray(Source[] srcs) { + Source[] resp = new Source[srcs.length]; + for(int i = 0; i < srcs.length; ++i) { + resp[i] = getNewSource(srcs[i]); + } + return resp; + } + + public UUID getNewUUID(UUID uuid) { + return UUID.fromString(uuid.toString()+"AAA"); + } + + public UUID[] getNewUUIDArray(UUID[] uuids) { + UUID[] resp = new UUID[uuids.length]; + for(int i = 0; i < uuids.length; ++i) { + resp[i] = getNewUUID(uuids[i]); + } + return resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java new file mode 100644 index 0000000000..68510b4b03 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java @@ -0,0 +1,144 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.CharArrayReader; +import java.io.CharArrayWriter; +import java.io.IOException; +import java.io.InputStream; +import java.io.Reader; + +import javax.xml.transform.Source; +import javax.xml.transform.dom.DOMSource; +import javax.xml.transform.sax.SAXSource; +import javax.xml.transform.stream.StreamSource; + +import org.xml.sax.InputSource; + + + +/** + * StandardTypesTransformer class that provide for transforming input provided to StandardTypesService methods. + * + * @version $Rev$ $Date$ + */ +public class StandardTypesTransformer { + + public static Object getNewObject(Object obj) { + if(obj instanceof String) { + return "Hello "+obj; + } else if(obj instanceof Integer) { + return new Integer(-((Integer)obj).intValue()); + } else if(obj instanceof Double) { + return new Double(-((Double)obj).doubleValue()); + } + + return obj; + } + + /** + * Returns a copy of the source object if the input is DOMSource, SAXSource or StreamSource. + * Returns the input object as is for other types. + */ + public static Source getNewSource(Source src) { + Source ret = null; + if(src instanceof DOMSource) { + DOMSource dsrc = (DOMSource)src; + ret = new DOMSource(dsrc.getNode() != null ? dsrc.getNode().cloneNode(true) : null); + } else if(src instanceof SAXSource) { + SAXSource ssrc = (SAXSource)src; + if(ssrc.getInputSource().getByteStream() != null) { + InputStream inp = ssrc.getInputSource().getByteStream(); + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + int b; + try { + while((b = inp.read()) != -1) { + bout.write(b); + } + } catch (IOException ignored) { + } + try { bout.close();} catch (IOException ignored) {} + try { inp.reset();} catch (IOException ignored) {} + ret = new SAXSource(new InputSource(new ByteArrayInputStream(bout.toByteArray()))); + } else if(ssrc.getInputSource().getCharacterStream() != null) { + Reader rdr = ssrc.getInputSource().getCharacterStream(); + CharArrayWriter caw = new CharArrayWriter(); + try { + int c; + while((c = rdr.read()) != -1) { + caw.append((char)c); + } + } catch (IOException ignored) { + } + caw.close(); + try{ rdr.reset();} catch(IOException ignored) {} + ret = new SAXSource(new InputSource(new CharArrayReader(caw.toCharArray()))); + } else { + ret = new SAXSource(); + } + } else if(src instanceof StreamSource) { + StreamSource ssrc = (StreamSource)src; + if(ssrc.getInputStream() != null) { + InputStream inp = ssrc.getInputStream(); + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + int b; + try { + while((b = inp.read()) != -1) { + bout.write(b); + } + } catch (IOException ignored) { + } + try { bout.close();} catch (IOException ignored) {} + try { inp.reset();} catch (IOException ignored) {} + ret = new StreamSource(new ByteArrayInputStream(bout.toByteArray())); + } else if(ssrc.getReader() != null) { + Reader rdr = ssrc.getReader(); + CharArrayWriter caw = new CharArrayWriter(); + try { + int c; + while((c = rdr.read()) != -1) { + caw.append((char)c); + } + } catch (IOException ignored) { + } + caw.close(); + try{ rdr.reset();} catch(IOException ignored) {} + ret = new StreamSource(new CharArrayReader(caw.toCharArray())); + } else { + ret = new StreamSource(); + } + } + + if(ret != null) { + ret.setSystemId(src.getSystemId()); + } else { + ret = src; + } + return ret; + } + + public static Image getNewImage(Image arg) { + arg.getGraphics().drawOval(2, 2, 7, 7); + return arg; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/aservice.wsdl b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/aservice.wsdl new file mode 100644 index 0000000000..10a242be4d --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/aservice.wsdl @@ -0,0 +1,127 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/doclitbarewsdl.composite b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/doclitbarewsdl.composite new file mode 100644 index 0000000000..5ecbb9edee --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/doclitbarewsdl.composite @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/generics-service.composite b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/generics-service.composite new file mode 100644 index 0000000000..2d47ba7b14 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/generics-service.composite @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/helloservice.composite b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/helloservice.composite new file mode 100644 index 0000000000..c39cf21002 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/helloservice.composite @@ -0,0 +1,65 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/primitivesservice.composite b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/primitivesservice.composite new file mode 100644 index 0000000000..4b0a6e215d --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/primitivesservice.composite @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/standard-types-service.composite b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/standard-types-service.composite new file mode 100644 index 0000000000..13ef73c082 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/main/resources/standard-types-service.composite @@ -0,0 +1,66 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DatabindingTestCase.java new file mode 100644 index 0000000000..4967b896a5 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DatabindingTestCase.java @@ -0,0 +1,339 @@ +/* + * 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.itest.databindings.jaxb; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + */ +public class DatabindingTestCase { + + private static SCADomain domain; + + /** + * Runs once before running the tests + */ + @BeforeClass + public static void setUp() throws Exception { + try { + domain = SCADomain.newInstance("helloservice.composite"); + } catch(Throwable e) { + e.printStackTrace(); + } + } + + /** + * Runs once after running the tests + */ + @AfterClass + public static void tearDown() { + domain.close(); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetings. + */ + @Test + public void testSCA() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTest(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testSCAArray() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestArray(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testSCAList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testSCAArrayList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestArrayList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testSCAMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testSCAHashMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestHashMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using SCA binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testSCAVarArgs() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientSCAComponent"); + performTestVarArgs(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetings. + */ + @Test + public void testWS() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTest(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testWSArray() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestArray(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testWSList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testWSArrayList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestArrayList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testWSMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testWSHashMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestHashMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloServiceSimple service using WS binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testWSVarArgs() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloServiceSimpleClientWSComponent"); + performTestVarArgs(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetings. + */ + @Test + public void testSCALocal() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTest(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testSCALocalArray() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestArray(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testSCALocalList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testSCALocalArrayList() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestArrayList(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testSCALocalMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testSCALocalHashMap() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestHashMap(helloServiceSimpleClient); + } + + /** + * Invokes the HelloLocalServiceSimple service using SCA binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testSCALocalVarArgs() throws Exception { + HelloServiceSimpleClient helloServiceSimpleClient = domain.getService(HelloServiceSimpleClient.class, "HelloLocalServiceSimpleClientSCAComponent"); + performTestVarArgs(helloServiceSimpleClient); + } + + private void performTest(HelloServiceSimpleClient helloServiceSimpleClient) { + String name = "Pandu"; + String resp = helloServiceSimpleClient.getGreetingsForward(name); + Assert.assertEquals("Hello "+name, resp); + } + + private void performTestArray(HelloServiceSimpleClient helloServiceSimpleClient) { + String[] names = {"Me", "Pandu"}; + String[] resps = helloServiceSimpleClient.getGreetingsArrayForward(names); + for(int i = 0; i < names.length; ++i) { + Assert.assertEquals("Hello "+names[i], resps[i]); + } + } + + private void performTestList(HelloServiceSimpleClient helloServiceSimpleClient) { + List namesList = new ArrayList(); + namesList.add("Me"); + namesList.add("Pandu"); + namesList.add("Chinnipandu"); + List respList = helloServiceSimpleClient.getGreetingsListForward(namesList); + Assert.assertEquals(namesList.size(), respList.size()); + for(int i = 0; i < namesList.size(); ++i) { + Assert.assertEquals("Hello "+namesList.get(i), respList.get(i)); + } + } + + private void performTestArrayList(HelloServiceSimpleClient helloServiceSimpleClient) { + ArrayList namesList = new ArrayList(); + namesList.add("Me"); + namesList.add("Pandu"); + namesList.add("Chinnipandu"); + ArrayList respList = helloServiceSimpleClient.getGreetingsArrayListForward(namesList); + Assert.assertEquals(namesList.size(), respList.size()); + for(int i = 0; i < namesList.size(); ++i) { + Assert.assertEquals("Hello "+namesList.get(i), respList.get(i)); + } + } + + private void performTestMap(HelloServiceSimpleClient helloServiceSimpleClient) { + Map namesMap = new HashMap(); + namesMap.put("Me", null); + namesMap.put("Pandu", null); + namesMap.put("Chinnipandu", null); + Map respMap = helloServiceSimpleClient.getGreetingsMapForward(namesMap); + Assert.assertEquals(namesMap.keySet().size(), respMap.keySet().size()); + for(Map.Entry entry: namesMap.entrySet()) { + Assert.assertEquals("Hello "+entry.getKey(), respMap.get(entry.getKey())); + } + } + + private void performTestHashMap(HelloServiceSimpleClient helloServiceSimpleClient) { + HashMap namesMap = new HashMap(); + namesMap.put("Me", null); + namesMap.put("Pandu", null); + namesMap.put("Chinnipandu", null); + Map respMap = helloServiceSimpleClient.getGreetingsHashMapForward(namesMap); + Assert.assertEquals(namesMap.keySet().size(), respMap.keySet().size()); + for(Map.Entry entry: namesMap.entrySet()) { + Assert.assertEquals("Hello "+entry.getKey(), respMap.get(entry.getKey())); + } + } + + private void performTestVarArgs(HelloServiceSimpleClient helloServiceSimpleClient) { + String[] names = { "Me", "You", "Pandu" }; // Do not change the array size from 3. + String expected = "Hello Me You Pandu"; + String actual = helloServiceSimpleClient.getGreetingsVarArgsForward(names[0], names[1], names[2]); + Assert.assertEquals(expected, actual); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DocLitBareWsdlTestCase.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DocLitBareWsdlTestCase.java new file mode 100644 index 0000000000..744bf20494 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/DocLitBareWsdlTestCase.java @@ -0,0 +1,67 @@ +/* + * 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.itest.databindings.jaxb; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + */ +public class DocLitBareWsdlTestCase { + + private static SCADomain domain; + + /** + * Runs once before running the tests + */ + @BeforeClass + public static void setUp() throws Exception { + try { + domain = SCADomain.newInstance("doclitbarewsdl.composite"); + } catch (Throwable e) { + // @Ignore("TUSCANY-2398") + e.printStackTrace(); + } + } + + /** + * Runs once after running the tests + */ + @AfterClass + public static void tearDown() { + if (domain != null) { + domain.close(); + } + } + + // @Ignore("TUSCANY-2398") + @Test + public void testDocLitBareWsdl() throws Exception { + AClientService client = domain.getService(AClientService.class, "AClientComponent"); + String name = "Pandu"; + String resp = client.getGreetingsForward(name); + Assert.assertEquals("Hello " + name, resp); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsDatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsDatabindingTestCase.java new file mode 100644 index 0000000000..c22d00140e --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/GenericsDatabindingTestCase.java @@ -0,0 +1,484 @@ +/* + * 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.itest.databindings.jaxb; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.itest.databindings.jaxb.impl.GenericsTransformer; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * Databinding tests for generics, parameterized and polymorphic types. + * + * @version $Rev$ $Date$ + */ +public class GenericsDatabindingTestCase { + private static SCADomain domain; + + /** + * Runs before each test method + */ + @BeforeClass + public static void setUp() throws Exception { + try { + domain = SCADomain.newInstance("generics-service.composite"); + } catch(Throwable e) { + e.printStackTrace(); + } + } + + /** + * Runs after each test method + */ + @AfterClass + public static void tearDown() { + domain.close(); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getTypeExplicit. + */ + @Test + public void testSCATypeExplicit() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestTypeExplicit(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getTypeUnbound. + */ + @Test + public void testSCATypeUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestTypeUnbound(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getTypeExtends. + */ + @Test + public void testSCATypeExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestTypeExtends(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getRecursiveTypeBound. + */ + @Test + public void testSCARecursiveTypeBound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestRecursiveTypeBound(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getWildcardUnbound. + */ + @Test + public void testSCAWildcardUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestWildcardUnbound(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getWildcardSuper. + */ + @Test + public void testSCAWildcardSuper() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestWildcardSuper(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getWildcardExtends. + */ + @Test + public void testSCAWildcardExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestWildcardExtends(serviceClient); + } + + /** + * Invokes the GenericsService service using SCA binding. + * Service method invoked is getPolymorphic. + */ + @Test + public void testSCAPolymorphic() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientSCAComponent"); + performTestPolymorphic(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getTypeExplicit. + */ + @Test + public void testWSTypeExplicit() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestTypeExplicit(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getTypeUnbound. + */ + @Test + public void testWSTypeUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestTypeUnbound(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getTypeExtends. + */ + @Test + public void testWSTypeExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestTypeExtends(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getRecursiveTypeBound. + */ + @Test + public void testWSRecursiveTypeBound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestRecursiveTypeBound(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getWildcardUnbound. + */ + @Test + public void testWSWildcardUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestWildcardUnbound(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getWildcardSuper. + */ + @Test + public void testWSWildcardSuper() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestWildcardSuper(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getWildcardExtends. + */ + @Test + public void testWSWildcardExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestWildcardExtends(serviceClient); + } + + /** + * Invokes the GenericsService service using WS binding. + * Service method invoked is getPolymorphic. + */ + @Test + public void testWSPolymorphic() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsServiceClientWSComponent"); + performTestPolymorphic(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getTypeExplicit. + */ + @Test + public void testSCALocalTypeExplicit() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestTypeExplicit(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getTypeUnbound. + */ + @Test + public void testSCALocalTypeUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestTypeUnbound(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getTypeExtends. + */ + @Test + public void testSCALocalTypeExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestTypeExtends(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getRecursiveTypeBound. + */ + @Test + public void testSCALocalRecursiveTypeBound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestRecursiveTypeBound(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getWildcardUnbound. + */ + @Test + public void testSCALocalWildcardUnbound() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestWildcardUnbound(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getWildcardSuper. + */ + @Test + public void testSCALocalWildcardSuper() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestWildcardSuper(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getWildcardExtends. + */ + @Test + public void testSCALocalWildcardExtends() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestWildcardExtends(serviceClient); + } + + /** + * Invokes the GenericsLocalService service using SCA binding. + * Service method invoked is getPolymorphic. + */ + @Test + public void testSCALocalPolymorphic() throws Exception { + GenericsServiceClient serviceClient = domain.getService(GenericsServiceClient.class, "GenericsLocalServiceClientSCAComponent"); + performTestPolymorphic(serviceClient); + } + + private void performTestTypeExplicit(GenericsServiceClient serviceClient) { + Bean1 args[] = new Bean1[2]; + args[0] = new Bean1("Me"); + args[1] = new Bean1(); + for(int i = 0; i < args.length; ++i) { + Bean1 arg = args[i]; + Bean1 expected = GenericsTransformer.getTypeExplicit(arg); + Bean1 actual = serviceClient.getTypeExplicitForward(arg); + Assert.assertEquals(expected, actual); + } + } + + private void performTestTypeUnbound(GenericsServiceClient serviceClient) { + { // String + String[] args = { "Me", "You", "Him" }; + Bean1 expected = GenericsTransformer.getTypeUnbound(args); + Bean1 actual = serviceClient.getTypeUnboundForward(args); + // Assert.assertEquals(expected, actual); + } + { // Integer + Integer[] args = new Integer[3]; + args[0] = -10; + args[1] = 0; + args[2] = 10; + Bean1 expected = GenericsTransformer.getTypeUnbound(args); + Bean1 actual = serviceClient.getTypeUnboundForward(args); + // Assert.assertEquals(expected, actual); + } + { // Object + Object[] args = new Object[3]; + args[0] = "Me"; + args[1] = 10; + args[2] = "Him"; + Bean1 expected = GenericsTransformer.getTypeUnbound(args); + Bean1 actual = serviceClient.getTypeUnboundForward(args); + Assert.assertEquals(expected, actual); + } + } + + private void performTestTypeExtends(GenericsServiceClient serviceClient) { + { // Bean2 + Bean2[] args = new Bean2[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean2(); + args[i].setName("Name"+i); + } + + Bean1 expected = GenericsTransformer.getTypeExtends(args); + Bean1 actual = serviceClient.getTypeExtendsForward(args); + Assert.assertEquals(expected, actual); + } + { // Bean3 extends Bean2 + Bean3[] args = new Bean3[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean3(); + args[i].setName("Name"+i); + args[i].setAddress("Address"+i); + } + + Bean1 expected = GenericsTransformer.getTypeExtends(args); + Bean1 actual = serviceClient.getTypeExtendsForward(args); + // Assert.assertEquals(expected, actual); + } + { //Bean31 extends Bean2 + Bean31[] args = new Bean31[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean31(); + args[i].setName("Name"+i); + args[i].setAddress("Address"+i); + } + + Bean1 expected = GenericsTransformer.getTypeExtends(args); + Bean1 actual = serviceClient.getTypeExtendsForward(args); + // Assert.assertEquals(expected, actual); + } + } + + private void performTestRecursiveTypeBound(GenericsServiceClient serviceClient) { + { // Bean1 + Bean1[] args = new Bean1[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean1(); + args[i].setItem("Bean."+i); + } + Bean1> expected = GenericsTransformer.getRecursiveTypeBound(args); + Bean1> actual = serviceClient.getRecursiveTypeBoundForward(args); + Assert.assertEquals(expected, actual); + } + { // Bean10 extends Bean1 + Bean10[] args = new Bean10[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean10(); + args[i].setItem("Bean10."+i); + } + Bean1 expected = GenericsTransformer.getRecursiveTypeBound(args); + Bean1 actual = serviceClient.getRecursiveTypeBoundForward(args); + // Assert.assertEquals(expected, actual); + } + { // Bean11 extends Bean1 + Bean11[] args = new Bean11[3]; + for(int i = 0; i < args.length; ++i) { + args[i] = new Bean11(); + args[i].setItem("Bean11."+i); + } + Bean1 expected = GenericsTransformer.getRecursiveTypeBound(args); + Bean1 actual = serviceClient.getRecursiveTypeBoundForward(args); + // Assert.assertEquals(expected, actual); + } + } + + private void performTestWildcardUnbound(GenericsServiceClient serviceClient) { + { + Bean1 arg = new Bean1("Me"); + Bean1 expected = GenericsTransformer.getWildcardUnbound(arg); + Bean1 actual = serviceClient.getWildcardUnboundForward(arg); + Assert.assertEquals(expected, actual); + } + { + Bean1 arg = new Bean1(1); + Bean1 expected = GenericsTransformer.getWildcardUnbound(arg); + Bean1 actual = serviceClient.getWildcardUnboundForward(arg); + Assert.assertEquals(expected, actual); + } + } + + private void performTestWildcardSuper(GenericsServiceClient serviceClient) { + Bean1 arg = new Bean1(); + Bean3 item = new Bean3(); + item.setName("Name"); + item.setAddress("Address"); + arg.setItem(item); + Bean1 expected = GenericsTransformer.getWildcardSuper(arg); + Bean1 actual = serviceClient.getWildcardSuperForward(arg); + Assert.assertEquals(expected, actual); + } + + private void performTestWildcardExtends(GenericsServiceClient serviceClient) { + { // Bean2 + Bean2 temp = new Bean2(); + temp.setName("Me"); + Bean1 arg = new Bean1(temp); + Bean1 expected = GenericsTransformer.getWildcardExtends(arg); + Bean1 actual = serviceClient.getWildcardExtendsForward(arg); + Assert.assertEquals(expected, actual); + } + { // Bean3 extends Bean2 + Bean3 temp = new Bean3(); + temp.setName("Me"); + temp.setAddress("My address"); + Bean1 arg = new Bean1(temp); + Bean1 expected = GenericsTransformer.getWildcardExtends(arg); + Bean1 actual = serviceClient.getWildcardExtendsForward(arg); + // The Bean3 will be unmarshalled into Bean2 + // Assert.assertEquals(expected, actual); + Assert.assertTrue(actual.getItem() instanceof Bean2); + } + { // Bean31 extends Bean2 + Bean31 temp = new Bean31(); + temp.setName("Me1"); + temp.setAddress("My address1"); + Bean1 arg = new Bean1(temp); + Bean1 expected = GenericsTransformer.getWildcardExtends(arg); + Bean1 actual = serviceClient.getWildcardExtendsForward(arg); + // The Bean31 will be unmarshalled into Bean2 + // Assert.assertEquals(expected, actual); + Assert.assertTrue(actual.getItem() instanceof Bean2); + } + } + + private void performTestPolymorphic(GenericsServiceClient serviceClient) { + { // Bean2 + Bean2 arg = new Bean2(); + arg.setName("Me"); + Bean2 expected = GenericsTransformer.getPolymorphic(arg); + Bean2 actual = serviceClient.getPolymorphicForward(arg); + Assert.assertEquals(expected, actual); + } + { // Bean3 extends Bean2 + Bean3 arg = new Bean3(); + arg.setName("Me"); + arg.setAddress("My address"); + Bean2 expected = GenericsTransformer.getPolymorphic(arg); + Bean2 actual = serviceClient.getPolymorphicForward(arg); + Assert.assertEquals(expected.getName(), actual.getName()); + } + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesDatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesDatabindingTestCase.java new file mode 100644 index 0000000000..f8aaad3dac --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesDatabindingTestCase.java @@ -0,0 +1,776 @@ +/* + * 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.itest.databindings.jaxb; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + */ +public class PrimitivesDatabindingTestCase { + + private static SCADomain domain; + + /** + * Runs before each test method + */ + @BeforeClass + public static void setUp() throws Exception { + try { + domain = SCADomain.newInstance("primitivesservice.composite"); + } catch(Throwable e) { + e.printStackTrace(); + Assert.fail(); + } + } + + /** + * Runs after each test method + */ + @AfterClass + public static void tearDown() { + domain.close(); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testSCANegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testSCANegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for boolean array. + */ + @Test + public void testSCAPassByValueBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueBooleanArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateByte. + */ + @Test + public void testSCANegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testSCANegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for byte array. + */ + @Test + public void testSCAPassByValueByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueByteArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateShort. + */ + @Test + public void testSCANegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testSCANegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for short array. + */ + @Test + public void testSCAPassByValueShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueShortArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateInt. + */ + @Test + public void testSCANegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testSCANegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for int array. + */ + @Test + public void testSCAPassByValueIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueIntArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateLong. + */ + @Test + public void testSCANegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testSCANegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for long array. + */ + @Test + public void testSCAPassByValueLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueLongArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateFloat. + */ + @Test + public void testSCANegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testSCANegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for float array. + */ + @Test + public void testSCAPassByValueFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueFloatArray()); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateDouble. + */ + @Test + public void testSCANegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testSCANegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with SCA binding. + * Test for double array. + */ + @Test + public void testSCAPassByValueDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientSCAComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueDoubleArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testWSNegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testWSNegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for boolean array. + */ + @Test + public void testWSPassByValueBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueBooleanArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByte. + */ + @Test + public void testWSNegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testWSNegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for byte array. + */ + @Test + public void testWSPassByValueByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueByteArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShort. + */ + @Test + public void testWSNegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testWSNegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for short array. + */ + @Test + public void testWSPassByValueShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueShortArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateInt. + */ + @Test + public void testWSNegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testWSNegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for int array. + */ + @Test + public void testWSPassByValueIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueIntArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLong. + */ + @Test + public void testWSNegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testWSNegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for long array. + */ + @Test + public void testWSPassByValueLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueLongArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloat. + */ + @Test + public void testWSNegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testWSNegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for float array. + */ + @Test + public void testWSPassByValueFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueFloatArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDouble. + */ + @Test + public void testWSNegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testWSNegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for double array. + */ + @Test + public void testWSPassByValueDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientWSComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueDoubleArray()); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testSCALocalNegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testSCALocalNegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateByte. + */ + @Test + public void testSCALocalNegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testSCALocalNegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateShort. + */ + @Test + public void testSCALocalNegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testSCALocalNegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateInt. + */ + @Test + public void testSCALocalNegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testSCALocalNegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateLong. + */ + @Test + public void testSCALocalNegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testSCALocalNegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateFloat. + */ + @Test + public void testSCALocalNegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using SCA binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testSCALocalNegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateDouble. + */ + @Test + public void testSCALocalNegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesLocalService service using SCA binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testSCALocalNegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesLocalServiceClientSCAComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + private void performTestNegateBoolean(PrimitivesServiceClient primitivesServiceClient) { + Assert.assertTrue(primitivesServiceClient.negateBooleanForward(false)); + Assert.assertFalse(primitivesServiceClient.negateBooleanForward(true)); + } + + private void performTestNegateBooleanArray(PrimitivesServiceClient primitivesServiceClient) { + boolean flags[] = new boolean[2]; + flags[0] = false; + flags[1] = true; + boolean[] respFlags = primitivesServiceClient.negateBooleanArrayForward(flags); + Assert.assertEquals(flags.length, respFlags.length); + for(int i = 0; i < flags.length; ++i) { + Assert.assertEquals(!flags[i], respFlags[i]); + } + } + + private void performTestNegateByte(PrimitivesServiceClient primitivesServiceClient) { + byte[] ba = new byte[3]; + ba[0] = -1; + ba[1] = 0; + ba[2] = 1; + + for(int i = 0; i < ba.length; ++i) { + Assert.assertEquals((byte)-ba[i], primitivesServiceClient.negateByteForward(ba[i])); + } + } + + private void performTestNegateByteArray(PrimitivesServiceClient primitivesServiceClient) { + byte[] ba = new byte[3]; + ba[0] = -1; + ba[1] = 0; + ba[2] = 1; + + byte[] r = primitivesServiceClient.negateByteArrayForward(ba); + Assert.assertEquals(ba.length, r.length); + for(int i = 0; i < ba.length; ++i) { + Assert.assertEquals((byte)-ba[i], r[i]); + } + } + + private void performTestNegateShort(PrimitivesServiceClient primitivesServiceClient) { + short[] s = new short[3]; + s[0] = -1; + s[1] = 0; + s[2] = 1; + + for(int i = 0; i < s.length; ++i) { + Assert.assertEquals((short)-s[i], primitivesServiceClient.negateShortForward(s[i])); + } + } + + private void performTestNegateShortArray(PrimitivesServiceClient primitivesServiceClient) { + short[] s = new short[3]; + s[0] = -1; + s[1] = 0; + s[2] = 1; + + short[] r = primitivesServiceClient.negateShortArrayForward(s); + Assert.assertEquals(s.length, r.length); + for(int i = 0; i < s.length; ++i) { + Assert.assertEquals((short)-s[i], r[i]); + } + } + + private void performTestNegateInt(PrimitivesServiceClient primitivesServiceClient) { + int[] ia = new int[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], primitivesServiceClient.negateIntForward(ia[i])); + } + } + + private void performTestNegateIntArray(PrimitivesServiceClient primitivesServiceClient) { + int[] ia = new int[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + int[] r = primitivesServiceClient.negateIntArrayForward(ia); + Assert.assertEquals(ia.length, r.length); + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], r[i]); + } + } + + private void performTestNegateLong(PrimitivesServiceClient primitivesServiceClient) { + long[] la = new long[3]; + la[0] = -1; + la[1] = 0; + la[2] = 1; + + for(int i = 0; i < la.length; ++i) { + Assert.assertEquals(-la[i], primitivesServiceClient.negateLongForward(la[i])); + } + } + + private void performTestNegateLongArray(PrimitivesServiceClient primitivesServiceClient) { + long[] la = new long[3]; + la[0] = -1; + la[1] = 0; + la[2] = 1; + + long[] r = primitivesServiceClient.negateLongArrayForward(la); + Assert.assertEquals(la.length, r.length); + for(int i = 0; i < la.length; ++i) { + Assert.assertEquals(-la[i], r[i]); + } + } + + private void performTestNegateFloat(PrimitivesServiceClient primitivesServiceClient) { + float[] fa = new float[3]; + fa[0] = -1; + fa[1] = 0; + fa[2] = 1; + + for(int i = 0; i < fa.length; ++i) { + Assert.assertEquals(-fa[i], primitivesServiceClient.negateFloatForward(fa[i])); + } + } + + private void performTestNegateFloatArray(PrimitivesServiceClient primitivesServiceClient) { + float[] ia = new float[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + float[] r = primitivesServiceClient.negateFloatArrayForward(ia); + Assert.assertEquals(ia.length, r.length); + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], r[i]); + } + } + + private void performTestNegateDouble(PrimitivesServiceClient primitivesServiceClient) { + double[] da = new double[3]; + da[0] = -1; + da[1] = 0; + da[2] = 1; + + for(int i = 0; i < da.length; ++i) { + Assert.assertEquals(-da[i], primitivesServiceClient.negateDoubleForward(da[i])); + } + } + + private void performTestNegateDoubleArray(PrimitivesServiceClient primitivesServiceClient) { + double[] da = new double[3]; + da[0] = -1; + da[1] = 0; + da[2] = 1; + + double[] r = primitivesServiceClient.negateDoubleArrayForward(da); + Assert.assertEquals(da.length, r.length); + for(int i = 0; i < da.length; ++i) { + Assert.assertEquals(-da[i], r[i]); + } + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesDatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesDatabindingTestCase.java new file mode 100644 index 0000000000..2d023ab448 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-bottom-up/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesDatabindingTestCase.java @@ -0,0 +1,1438 @@ +/* + * 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.itest.databindings.jaxb; + +import java.awt.Image; +import java.awt.image.BufferedImage; +import java.awt.image.PixelGrabber; +import java.io.IOException; +import java.io.InputStream; +import java.io.StringReader; +import java.io.StringWriter; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.GregorianCalendar; +import java.util.TimeZone; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.TransformerFactory; +import javax.xml.transform.dom.DOMSource; +import javax.xml.transform.sax.SAXSource; +import javax.xml.transform.stream.StreamResult; +import javax.xml.transform.stream.StreamSource; + +import junit.framework.Assert; + +import org.apache.axiom.attachments.ByteArrayDataSource; +import org.apache.tuscany.sca.databinding.xml.String2Node; +import org.apache.tuscany.sca.host.embedded.SCADomain; +import org.apache.tuscany.sca.itest.databindings.jaxb.impl.StandardTypesTransformer; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Ignore; +import org.junit.Test; +import org.xml.sax.InputSource; + +/** + * @version $Rev$ $Date$ + */ +public class StandardTypesDatabindingTestCase { + + private static SCADomain domain; + + /** + * Runs before each test method + */ + @BeforeClass + public static void setUp() throws Exception { + try { + domain = SCADomain.newInstance("standard-types-service.composite"); + } catch (Throwable e) { + e.printStackTrace(); + } + } + + /** + * Runs after each test method + */ + @AfterClass + public static void tearDown() { + domain.close(); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testSCANewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testSCANewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testSCANewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testSCANewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testSCANewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testSCANewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDate. + */ + @Test + public void testSCANewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testSCANewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewQName. + */ + @Test + public void testSCANewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testSCANewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewURI. + */ + @Test + public void testSCANewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testSCANewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testSCANewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testSCANewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testSCANewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testSCANewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewObject. + */ + @Test + public void testSCANewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testSCANewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewImage. + */ + @Test + public void testSCANewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testSCANewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDataHandler. + */ + @Test + public void testSCANewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + public void testSCANewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewSource. + */ + @Test + public void testSCANewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewSourceArray. + */ + @Test + @Ignore("TUSCANY-2387") + public void testSCANewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testSCANewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesService service using SCA binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testSCANewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientSCAComponent"); + performTestNewUUIDArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testWSNewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testWSNewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testWSNewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testWSNewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testWSNewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testWSNewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDate. + */ + @Test + public void testWSNewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testWSNewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQName. + */ + @Test + public void testWSNewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testWSNewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURI. + */ + @Test + public void testWSNewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testWSNewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testWSNewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testWSNewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testWSNewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testWSNewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObject. + */ + @Test + public void testWSNewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testWSNewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImage. + */ + @Test + public void testWSNewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testWSNewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandler. + */ + @Test + public void testWSNewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + public void testWSNewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSource. + */ + @Test + // @Ignore("junit.framework.ComparisonFailure: null expected:<... encoding=\"UTF-8\"?><[a>A> but was:<... encoding=\"UTF-8\"?><[return xmlns=\"http://jaxb.databindings.itest.sca.tuscany.apache.org/\">A>") + public void testWSNewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSourceArray. + */ + @Test + @Ignore("TUSCANY-2386") + public void testWSNewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testWSNewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testWSNewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientWSComponent"); + performTestNewUUIDArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testSCALocalNewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testSCALocalNewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testSCALocalNewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testSCALocalNewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testSCALocalNewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testSCALocalNewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewDate. + */ + @Test + public void testSCALocalNewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testSCALocalNewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewQName. + */ + @Test + public void testSCALocalNewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testSCALocalNewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewURI. + */ + @Test + public void testSCALocalNewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testSCALocalNewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testSCALocalNewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testSCALocalNewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testSCALocalNewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testSCALocalNewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewObject. + */ + @Test + public void testSCALocalNewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testSCALocalNewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewImage. + */ + @Test + public void testSCALocalNewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testSCALocalNewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalLocalService service using SCA binding. + * Service method invoked is getNewDataHandler. + */ + @Test + public void testSCALocalNewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + public void testSCALocalNewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewSource. + */ + @Test + public void testSCALocalNewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewSourceArray. + */ + @Test + public void testSCALocalNewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testSCALocalNewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesLocalService service using SCA binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testSCALocalNewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesLocalServiceClientSCAComponent"); + performTestNewUUIDArray(serviceClient); + } + + private void performTestNewBigInteger(StandardTypesServiceClient serviceClient) { + BigInteger bi = new BigInteger("1234567890123456789012345678901234"); + BigInteger expected = bi.negate(); + BigInteger actual = serviceClient.getNewBigIntegerForward(bi); + Assert.assertEquals(expected, actual); + } + + private void performTestNewBigIntegerArray(StandardTypesServiceClient serviceClient) { + BigInteger[] bia = new BigInteger[2]; + bia[0] = new BigInteger("1234567890123456789012345678901234"); + bia[1] = new BigInteger("-98765432109876543210987654321"); + BigInteger[] actual = serviceClient.getNewBigIntegerArrayForward(bia); + Assert.assertEquals(bia.length, actual.length); + for (int i = 0; i < bia.length; ++i) { + Assert.assertEquals(bia[i].negate(), actual[i]); + } + } + + private void performTestNewBigDecimal(StandardTypesServiceClient serviceClient) { + BigDecimal bd = new BigDecimal("12345678901234567890.12345678901234"); + BigDecimal expected = bd.negate(); + BigDecimal actual = serviceClient.getNewBigDecimalForward(bd); + Assert.assertEquals(expected, actual); + } + + private void performTestNewBigDecimalArray(StandardTypesServiceClient serviceClient) { + BigDecimal[] bda = new BigDecimal[2]; + bda[0] = new BigDecimal("1234567890123456.789012345678901234"); + bda[1] = new BigDecimal("-987654321098765.43210987654321"); + BigDecimal[] actual = serviceClient.getNewBigDecimalArrayForward(bda); + Assert.assertEquals(bda.length, actual.length); + for (int i = 0; i < bda.length; ++i) { + Assert.assertEquals(bda[i].negate(), actual[i]); + } + } + + private void performTestNewCalendar(StandardTypesServiceClient serviceClient) { + Calendar[] ca = new Calendar[3]; + String[] tz = {"GMT+05:30", "GMT+00:00", "GMT-05:00"}; + for (int i = 0; i < ca.length; ++i) { + ca[i] = Calendar.getInstance(TimeZone.getTimeZone(tz[i])); + ca[i].set(Calendar.DAY_OF_MONTH, i + 1); + } + for (int i = 0; i < ca.length; ++i) { + Calendar actual = serviceClient.getNewCalendarForward(ca[i]); + ca[i].add(Calendar.DAY_OF_MONTH, 5); + if (actual instanceof GregorianCalendar && ca[i] instanceof GregorianCalendar) { + // FIXME: Is this a problem? + // The instance returned by service method invoked over binding.ws seems to have a gregorianCutover + // different from the instance passed. Adjust the gregorianCutover as per the input instance. + ((GregorianCalendar)actual).setGregorianChange(((GregorianCalendar)ca[i]).getGregorianChange()); + } + Assert.assertEquals(ca[i], actual); + } + } + + private void performTestNewCalendarArray(StandardTypesServiceClient serviceClient) { + Calendar[] ca = new Calendar[3]; + String[] tz = {"GMT+05:30", "GMT+00:00", "GMT-05:00"}; + for (int i = 0; i < ca.length; ++i) { + ca[i] = Calendar.getInstance(TimeZone.getTimeZone(tz[i])); + ca[i].set(Calendar.DAY_OF_MONTH, i + 1); + } + Calendar[] actual = serviceClient.getNewCalendarArrayForward(ca); + Assert.assertEquals(ca.length, actual.length); + for (int i = 0; i < ca.length; ++i) { + ca[i].add(Calendar.DAY_OF_MONTH, 5); + if (actual[i] instanceof GregorianCalendar && ca[i] instanceof GregorianCalendar) { + // FIXME: Is this a problem? + // The instance returned by service method invoked over binding.ws seems to have a gregorianCutover + // different from the instance passed. Adjust the gregorianCutover as per the input instance. + ((GregorianCalendar)actual[i]).setGregorianChange(((GregorianCalendar)ca[i]).getGregorianChange()); + } + Assert.assertEquals(ca[i], actual[i]); + } + } + + private void performTestNewDate(StandardTypesServiceClient serviceClient) { + Date d = new Date(); + Date expected = new Date(d.getTime() + 5 * 24 * 60 * 60 * 1000); + Date actual = serviceClient.getNewDateForward(d); + Assert.assertEquals(expected, actual); + } + + private void performTestNewDateArray(StandardTypesServiceClient serviceClient) { + Date[] d = new Date[2]; + Date[] expected = new Date[d.length]; + for (int i = 0; i < d.length; ++i) { + d[i] = new Date(); + d[i].setTime(d[i].getTime() + i * 24 * 60 * 60 * 1000); + expected[i] = new Date(d[i].getTime() + 5 * 24 * 60 * 60 * 1000); + } + Date[] actual = serviceClient.getNewDateArrayForward(d); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < expected.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewQName(StandardTypesServiceClient serviceClient) { + QName[] qnames = new QName[3]; + qnames[0] = new QName("localPart"); + qnames[1] = new QName("namespaceUri", "localPart"); + qnames[2] = new QName("namespaceUri", "localPart", "prefix"); + QName[] expected = new QName[qnames.length]; + for (int i = 0; i < qnames.length; ++i) { + expected[i] = + new QName(qnames[i].getNamespaceURI() + "q", qnames[i].getLocalPart() + "q", + qnames[i].getPrefix() + "q"); + } + for (int i = 0; i < qnames.length; ++i) { + QName actual = serviceClient.getNewQNameForward(qnames[i]); + Assert.assertEquals(expected[i], actual); + } + } + + private void performTestNewQNameArray(StandardTypesServiceClient serviceClient) { + QName[] qnames = new QName[4]; + qnames[0] = new QName("localPart"); + qnames[1] = new QName("namespaceUri", "localPart"); + qnames[2] = new QName("namespaceUri", "localPart", "prefix"); + qnames[3] = new QName("localPart2"); + QName[] expected = new QName[qnames.length]; + for (int i = 0; i < qnames.length; ++i) { + expected[i] = + new QName(qnames[i].getNamespaceURI() + "q", qnames[i].getLocalPart() + "q", + qnames[i].getPrefix() + "q"); + } + QName[] actual = serviceClient.getNewQNameArrayForward(qnames); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < qnames.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewURI(StandardTypesServiceClient serviceClient) { + URI[] uris = new URI[4]; + uris[0] = URI.create("a/b/c"); + uris[1] = URI.create("http://abc/"); + uris[2] = URI.create("ftp://a/b"); + uris[3] = URI.create("http://abc/").resolve("xyz"); + + for (int i = 0; i < uris.length; ++i) { + URI expected = uris[i].resolve("uri"); + URI actual = serviceClient.getNewURIForward(uris[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewURIArray(StandardTypesServiceClient serviceClient) { + URI[] uris = new URI[4]; + uris[0] = URI.create("a/b/c"); + // [rfeng] We need to have a trialign / to avoid the resolving problem + // FIXME: [vamsi] This is actually a data transformation problem. The array being returned from the service method is + // not making to the caller intact. + uris[1] = URI.create("http://abc/"); + uris[2] = URI.create("ftp://a/b"); + uris[3] = URI.create("http://abc/").resolve("xyz"); + + URI[] expected = new URI[uris.length]; + for (int i = 0; i < uris.length; ++i) { + expected[i] = uris[i].resolve("uri"); + } + + URI[] actual = serviceClient.getNewURIArrayForward(uris); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < uris.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewXMLGregorianCalendar(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + XMLGregorianCalendar[] xgcals = new XMLGregorianCalendar[3]; + xgcals[0] = df.newXMLGregorianCalendar(new GregorianCalendar(1974, GregorianCalendar.APRIL, 19)); + xgcals[1] = df.newXMLGregorianCalendar(new GregorianCalendar(1978, GregorianCalendar.OCTOBER, 13)); + xgcals[2] = df.newXMLGregorianCalendar(new GregorianCalendar(2006, GregorianCalendar.JUNE, 16)); + + for (int i = 0; i < xgcals.length; ++i) { + XMLGregorianCalendar actual = serviceClient.getNewXMLGregorianCalendarForward(xgcals[i]); + xgcals[i].setDay(xgcals[i].getDay() + 5); + Assert.assertEquals(xgcals[i], actual); + } + } + + private void performTestNewXMLGregorianCalendarArray(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + XMLGregorianCalendar[] xgcals = new XMLGregorianCalendar[3]; + xgcals[0] = df.newXMLGregorianCalendar(new GregorianCalendar(1974, GregorianCalendar.APRIL, 19)); + xgcals[1] = df.newXMLGregorianCalendar(new GregorianCalendar(1978, GregorianCalendar.OCTOBER, 13)); + xgcals[2] = df.newXMLGregorianCalendar(new GregorianCalendar(2006, GregorianCalendar.JUNE, 16)); + + XMLGregorianCalendar[] actual = serviceClient.getNewXMLGregorianCalendarArrayForward(xgcals); + Assert.assertEquals(xgcals.length, actual.length); + for (int i = 0; i < xgcals.length; ++i) { + xgcals[i].setDay(xgcals[i].getDay() + 5); + Assert.assertEquals(xgcals[i], actual[i]); + } + } + + private void performTestNewDuration(StandardTypesServiceClient serviceClient) throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + Duration[] da = new Duration[3]; + da[0] = df.newDuration(1000000000000L); + da[1] = df.newDurationDayTime(1000000000000L); + da[2] = df.newDurationYearMonth(true, 1, 3); + + for (int i = 0; i < da.length; ++i) { + Assert.assertEquals(da[i].negate(), serviceClient.getNewDurationForward(da[i])); + } + } + + private void performTestNewObject(StandardTypesServiceClient serviceClient) { + Object[] objs = new Object[5]; + objs[0] = "Hello"; + objs[1] = 10; + objs[2] = null; + objs[3] = -1.0; + objs[4] = null; + + for (int i = 0; i < objs.length; ++i) { + Object expected = StandardTypesTransformer.getNewObject(objs[i]); + Object actual = serviceClient.getNewObjectForward(objs[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewObjectArray(StandardTypesServiceClient serviceClient) { + Object[] objs = new Object[5]; + objs[0] = "Hello"; + objs[1] = 10; + objs[2] = null; + objs[3] = -1.0; + objs[4] = null; + + Object[] actual = serviceClient.getNewObjectArrayForward(objs); + Assert.assertEquals(objs.length, actual.length); + for (int i = 0; i < objs.length; ++i) { + Object expected = StandardTypesTransformer.getNewObject(objs[i]); + Assert.assertEquals(expected, actual[i]); + } + } + + private void performTestNewImage(StandardTypesServiceClient serviceClient) throws InterruptedException { + // Create some images to test with. + Image[] imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + Image[] copy = imgs; + // Create the same images once again as the StandardTypesTransformer may manipulate the image passed. + imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + // Make sure the images and copies are equal using ImageInfo + for(int i = 0; i < imgs.length; ++i) { + Assert.assertEquals(new ImageInfo(imgs[i]), new ImageInfo(copy[i])); + } + + for (int i = 0; i < imgs.length; ++i) { + Image actual = serviceClient.getNewImageForward(imgs[i]); + Image expected = StandardTypesTransformer.getNewImage(copy[i]); + // Compare using ImageInfo + Assert.assertEquals(new ImageInfo(expected), new ImageInfo(actual)); + } + } + + private void performTestNewImageArray(StandardTypesServiceClient serviceClient) throws InterruptedException { + // Create some images to test with. + Image[] imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + Image[] copy = imgs; + // Create the same images once again as the StandardTypesTransformer may manipulate the image passed. + imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + // Make sure the images and copies are equal using ImageInfo + for(int i = 0; i < imgs.length; ++i) { + Assert.assertEquals(new ImageInfo(imgs[i]), new ImageInfo(copy[i])); + } + + Image[] actual = serviceClient.getNewImageArrayForward(imgs); + Assert.assertEquals(imgs.length, actual.length); + for (int i = 0; i < imgs.length; ++i) { + Image expected = StandardTypesTransformer.getNewImage(copy[i]); + // Compare using ImageInfo + Assert.assertEquals(new ImageInfo(expected), new ImageInfo(actual[i])); + } + } + + private void performTestNewDurationArray(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + Duration[] da = new Duration[3]; + da[0] = df.newDuration(1000000000000L); + da[1] = df.newDurationDayTime(1000000000000L); + da[2] = df.newDurationYearMonth(true, 1, 3); + + Duration[] actual = serviceClient.getNewDurationArrayForward(da); + Assert.assertEquals(da.length, actual.length); + for (int i = 0; i < da.length; ++i) { + Assert.assertEquals(da[i].negate(), actual[i]); + } + } + + private void performTestNewDataHandler(StandardTypesServiceClient serviceClient) throws IOException { + DataHandler[] dha = new DataHandler[3]; + dha[0] = new DataHandler("Some data", "text/plain"); + dha[1] = new DataHandler(this.getClass().getClassLoader().getResource("standard-types-service.composite")); + dha[2] = new DataHandler(new ByteArrayDataSource("Some data2".getBytes())); + + for (int i = 0; i < dha.length; ++i) { + DataHandler actual = serviceClient.getNewDataHandlerForward(dha[i]); + // Note: The DataHandler returned may use a different type of DataSource. + // Compare the data content instead of using equals(). + Assert.assertTrue(compare(dha[i], actual)); + } + } + + private void performTestNewDataHandlerArray(StandardTypesServiceClient serviceClient) throws IOException { + DataHandler[] dha = new DataHandler[3]; + dha[0] = new DataHandler("Some data", "text/plain"); + dha[1] = new DataHandler(this.getClass().getClassLoader().getResource("standard-types-service.composite")); + dha[2] = new DataHandler(new ByteArrayDataSource("Some data2".getBytes())); + + DataHandler[] actual = serviceClient.getNewDataHandlerArrayForward(dha); + Assert.assertEquals(dha.length, actual.length); + for (int i = 0; i < dha.length; ++i) { + // Note: The DataHandler returned may use a different type of DataSource. + // Compare the data content instead of using equals(). + Assert.assertTrue(compare(dha[i], actual[i])); + } + } + + private void performTestNewSource(StandardTypesServiceClient serviceClient) throws Exception { + String xml = "ABC"; + Source[] srcs = new Source[3]; + srcs[0] = new DOMSource(new String2Node().transform(xml, null)); + srcs[1] = new SAXSource(new InputSource(new StringReader(xml))); + srcs[2] = new StreamSource(new StringReader(xml)); + + for (int i = 0; i < srcs.length; ++i) { + Source expected = StandardTypesTransformer.getNewSource(srcs[i]); + Source actual = serviceClient.getNewSourceForward(srcs[i]); + // [rfeng] The data may come back as a different source + Assert.assertEquals(sourceToString(expected), sourceToString(actual)); + } + } + + private void performTestNewSourceArray(StandardTypesServiceClient serviceClient) throws Exception { + String xml = "ABC"; + Source[] srcs = new Source[3]; + srcs[0] = new DOMSource(new String2Node().transform(xml, null)); + srcs[1] = new SAXSource(new InputSource(new StringReader(xml))); + srcs[2] = new StreamSource(new StringReader(xml)); + + Source[] actual = serviceClient.getNewSourceArrayForward(srcs); + Source[] expected = new Source[srcs.length]; + for(int i = 0; i < srcs.length; ++i) { + expected[i] = StandardTypesTransformer.getNewSource(srcs[i]); + } + Assert.assertEquals(srcs.length, actual.length); + for (int i = 0; i < srcs.length; ++i) { + // [rfeng] The data may come back as a different source + Assert.assertEquals(sourceToString(expected[i]), sourceToString(actual[i])); + } + + } + + private void performTestNewUUID(StandardTypesServiceClient serviceClient) { + UUID[] uuids = new UUID[3]; + uuids[0] = UUID.nameUUIDFromBytes("ABCDEFGHJKLMNOPQRSTUVWXYZ".getBytes()); + uuids[1] = UUID.nameUUIDFromBytes("abcdefghjklmnopqrstuvwxyz".getBytes()); + uuids[2] = UUID.randomUUID(); + + for (int i = 0; i < uuids.length; ++i) { + UUID expected = UUID.fromString(uuids[i].toString() + "AAA"); + UUID actual = serviceClient.getNewUUIDForward(uuids[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewUUIDArray(StandardTypesServiceClient serviceClient) { + UUID[] uuids = new UUID[3]; + uuids[0] = UUID.nameUUIDFromBytes("ABCDEFGHJKLMNOPQRSTUVWXYZ".getBytes()); + uuids[1] = UUID.nameUUIDFromBytes("abcdefghjklmnopqrstuvwxyz".getBytes()); + uuids[2] = UUID.randomUUID(); + + UUID[] actual = serviceClient.getNewUUIDArrayForward(uuids); + for (int i = 0; i < uuids.length; ++i) { + UUID expected = UUID.fromString(uuids[i].toString() + "AAA"); + Assert.assertEquals(expected, actual[i]); + } + } + + /** + * This method compares two DataHandlers. + * @return true if the data in the two handlers is the same. + */ + private boolean compare(DataHandler dh1, DataHandler dh2) throws IOException { + InputStream inp1 = dh1.getInputStream(); + InputStream inp2 = dh2.getInputStream(); + for(;;) { + int i1 = inp1.read(); + int i2 = inp2.read(); + if(i1 == -1 && i2 == -1) { + return true; + } else if(i1 != -1 && i2 != -1) { + if(i1 != i2) { + return false; + } + } else { + return false; + } + } + } + + /** + * This method returns the content of a source object as String. + */ + private String sourceToString(Source s) throws Exception { + StringWriter sw = new StringWriter(); + Result r = new StreamResult(sw); + TransformerFactory.newInstance().newTransformer().transform(s, r); + sw.close(); + return sw.toString(); + } + + /** + * This class initializes with the width, height and pixel data of a java.awt.Image object. + */ + private static class ImageInfo { + private int h, w, pixels[]; + public ImageInfo(Image img) throws InterruptedException { + w = img.getWidth(null); + h = img.getHeight(null); + pixels = new int[w*h]; + PixelGrabber pg = new PixelGrabber(img, 0, 0, w, h, pixels, 0, w); + pg.grabPixels(); + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } else if(!(that instanceof ImageInfo)) { + return false; + } + + ImageInfo that1 = (ImageInfo)that; + if(w != that1.w || h != that1.h || pixels == null || that1.pixels == null || pixels.length != that1.pixels.length) { + return false; + } + for(int i = 0; i < pixels.length; ++i) { + if(pixels[i] != that1.pixels[i]) { + return false; + } + } + return true; + } + + public String toString() { + return this.getClass().getSimpleName()+"[w = "+w+", h = "+h+", pixels = "+pixels+"]"; + } + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/pom.xml b/java/sca/contrib/itest/databindings/jaxb-top-down/pom.xml new file mode 100644 index 0000000000..4e3fcfbe5c --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/pom.xml @@ -0,0 +1,194 @@ + + + + + + + + org.apache.tuscany.sca + itest-databindings + 2.0-SNAPSHOT + + + 4.0.0 + + itest-databindings-jaxb-top-down + 2.0-SNAPSHOT + jar + Apache Tuscany SCA Databinding Integration Tests - JAXB Top Down + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + org.apache.tuscany.sca + tuscany-node-impl + 2.0-SNAPSHOT + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + 2.0-SNAPSHOT + runtime + + + org.apache.tuscany.sca + tuscany-databinding-jaxb + 2.0-SNAPSHOT + runtime + + + org.apache.tuscany.sca + tuscany-databinding-sdo + 2.0-SNAPSHOT + compile + + + org.apache.tuscany.sca + tuscany-databinding-axiom + 2.0-SNAPSHOT + compile + + + org.apache.tuscany.sca + itest-databindings-common + 2.0-SNAPSHOT + compile + + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + 2.0-SNAPSHOT + runtime + + + org.apache.tuscany.sca + tuscany-interface-java-xml + 2.0-SNAPSHOT + compile + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + javax.xml.bind + jaxb-api + 2.1 + compile + + + + com.sun.xml.ws + jaxws-rt + 2.1.3 + + + + commons-collections + commons-collections + 3.1 + + + log4j + log4j + 1.2.12 + provided + + + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + -Djava.endorsed.dirs=target/endorsed + + + + org.apache.maven.plugins + maven-dependency-plugin + + + copy + generate-sources + + copy + + + + + javax.xml.ws + jaxws-api + 2.1 + jar + + + javax.xml.bind + jaxb-api + 2.1 + jar + + + ${project.build.directory}/endorsed + false + true + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloService.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloService.java new file mode 100644 index 0000000000..ab2d9630eb --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloService.java @@ -0,0 +1,42 @@ +/* + * 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.itest.databindings.jaxb; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for HelloService. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface HelloService { + String getGreetings(String name); + String[] getGreetingsArray(String[] names); + List getGreetingsList(List names); + ArrayList getGreetingsArrayList(ArrayList names); + Map getGreetingsMap(Map namesMap); + HashMap getGreetingsHashMap(HashMap namesMap); + String getGreetingsVarArgs(String... names); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceClient.java new file mode 100644 index 0000000000..7bd95cec95 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/HelloServiceClient.java @@ -0,0 +1,41 @@ +/* + * 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.itest.databindings.jaxb; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + + +/** + * The interface for HelloServiceClient. + * + * @version $Rev$ $Date$ + */ +public interface HelloServiceClient { + String getGreetingsForward(String name); + String[] getGreetingsArrayForward(String[] names); + List getGreetingsListForward(List names); + ArrayList getGreetingsArrayListForward(ArrayList names); + Map getGreetingsMapForward(Map namesMap); + HashMap getGreetingsHashMapForward(HashMap namesMap); + String getGreetingsVarArgsForward(String... names); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java new file mode 100644 index 0000000000..ac6c8d5a60 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesService.java @@ -0,0 +1,51 @@ +/* + * 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.itest.databindings.jaxb; + +import org.oasisopen.sca.annotation.Remotable; + +/** + * The interface for PrimitivesService. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface PrimitivesService { + boolean negateBoolean(boolean flag); + boolean[] negateBooleanArray(boolean[] flags); + boolean[] identityBooleanArray(boolean[] flags); + byte negateByte(byte b); + byte[] negateByteArray(byte[] ba); + byte[] identityByteArray(byte[] ba); + short negateShort(short s); + short[] negateShortArray(short[] s); + short[] identityShortArray(short[] sa); + int negateInt(int s); + int[] negateIntArray(int[] s); + int[] identityIntArray(int[] ia); + long negateLong(long l); + long[] negateLongArray(long[] la); + long[] identityLongArray(long[] la); + float negateFloat(float f); + float[] negateFloatArray(float[] fa); + float[] identityFloatArray(float[] fa); + double negateDouble(double d); + double[] negateDoubleArray(double[] da); + double[] identityDoubleArray(double[] da); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java new file mode 100644 index 0000000000..3a5a81bae4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/PrimitivesServiceClient.java @@ -0,0 +1,50 @@ +/* + * 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.itest.databindings.jaxb; + + +/** + * The interface for PrimitivesServiceClient. + * + * @version $Rev$ $Date$ + */ +public interface PrimitivesServiceClient { + boolean negateBooleanForward(boolean flag); + boolean[] negateBooleanArrayForward(boolean[] flags); + boolean passByValueBooleanArray(); + byte negateByteForward(byte b); + byte[] negateByteArrayForward(byte[] ba); + boolean passByValueByteArray(); + short negateShortForward(short s); + short[] negateShortArrayForward(short[] sa); + boolean passByValueShortArray(); + int negateIntForward(int i); + int[] negateIntArrayForward(int[] ia); + boolean passByValueIntArray(); + long negateLongForward(long l); + long[] negateLongArrayForward(long[] la); + boolean passByValueLongArray(); + float negateFloatForward(float f); + float[] negateFloatArrayForward(float[] fa); + boolean passByValueFloatArray(); + double negateDoubleForward(double d); + double[] negateDoubleArrayForward(double[] da); + boolean passByValueDoubleArray(); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java new file mode 100644 index 0000000000..1f3b7ec633 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesService.java @@ -0,0 +1,84 @@ +/* + * 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.itest.databindings.jaxb; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + +import org.oasisopen.sca.annotation.Remotable; + + + +/** + * The interface for StandardTypesService. + * + * @version $Rev$ $Date$ + */ +@Remotable +public interface StandardTypesService { + BigInteger getNewBigInteger(BigInteger bi); + BigInteger[] getNewBigIntegerArray(BigInteger[] bia); + + BigDecimal getNewBigDecimal(BigDecimal bd); + BigDecimal[] getNewBigDecimalArray(BigDecimal[] bda); + + Calendar getNewCalendar(Calendar c); + Calendar[] getNewCalendarArray(Calendar[] ca); + + Date getNewDate(Date d); + Date[] getNewDateArray(Date[] da); + + QName getNewQName(QName qname); + QName[] getNewQNameArray(QName[] qnames); + + URI getNewURI(URI uri); + URI[] getNewURIArray(URI[] uris); + + XMLGregorianCalendar getNewXMLGregorianCalendar(XMLGregorianCalendar xgcal); + XMLGregorianCalendar[] getNewXMLGregorianCalendarArray(XMLGregorianCalendar[] xgcal); + + Duration getNewDuration(Duration d); + Duration[] getNewDurationArray(Duration[] da); + + Object getNewObject(Object obj); + Object[] getNewObjectArray(Object[] objs); + + Image getNewImage(Image img); + Image[] getNewImageArray(Image[] imgs); + + DataHandler getNewDataHandler(DataHandler dh); + DataHandler[] getNewDataHandlerArray(DataHandler[] dha); + + Source getNewSource(Source src); + Source[] getNewSourceArray(Source[] srcs); + + UUID getNewUUID(UUID uuid); + UUID[] getNewUUIDArray(UUID[] uuids); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java new file mode 100644 index 0000000000..0c073cd054 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/StandardTypesServiceClient.java @@ -0,0 +1,81 @@ +/* + * 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.itest.databindings.jaxb; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + + +/** + * The interface for StandardTypesServiceClient. + * + * @version $Rev$ $Date$ + */ +public interface StandardTypesServiceClient { + BigInteger getNewBigIntegerForward(BigInteger bi); + BigInteger[] getNewBigIntegerArrayForward(BigInteger[] bia); + + BigDecimal getNewBigDecimalForward(BigDecimal bd); + BigDecimal[] getNewBigDecimalArrayForward(BigDecimal[] bda); + + Calendar getNewCalendarForward(Calendar c); + Calendar[] getNewCalendarArrayForward(Calendar[] ca); + + Date getNewDateForward(Date d); + Date[] getNewDateArrayForward(Date[] da); + + QName getNewQNameForward(QName qname); + QName[] getNewQNameArrayForward(QName[] qnames); + + URI getNewURIForward(URI uri); + URI[] getNewURIArrayForward(URI[] uris); + + XMLGregorianCalendar getNewXMLGregorianCalendarForward(XMLGregorianCalendar xgcal); + XMLGregorianCalendar[] getNewXMLGregorianCalendarArrayForward(XMLGregorianCalendar[] xgcals); + + Duration getNewDurationForward(Duration d); + Duration[] getNewDurationArrayForward(Duration[] da); + + Object getNewObjectForward(Object obj); + Object[] getNewObjectArrayForward(Object[] objs); + + Image getNewImageForward(Image img); + Image[] getNewImageArrayForward(Image[] imgs); + + DataHandler getNewDataHandlerForward(DataHandler dh); + DataHandler[] getNewDataHandlerArrayForward(DataHandler[] dha); + + Source getNewSourceForward(Source src); + Source[] getNewSourceArrayForward(Source[] srcs); + + UUID getNewUUIDForward(UUID uuid); + UUID[] getNewUUIDArrayForward(UUID[] uuids); +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceClientImpl.java new file mode 100644 index 0000000000..61449c8981 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceClientImpl.java @@ -0,0 +1,73 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloService; +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of HelloServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + */ +@Service(HelloServiceClient.class) +public class HelloServiceClientImpl { + + private HelloService service; + + @Reference + public void setHelloService(HelloService service) { + this.service = service; + } + + public String getGreetingsForward(String name) { + return service.getGreetings(name); + } + + public String[] getGreetingsArrayForward(String[] names) { + return service.getGreetingsArray(names); + } + + public List getGreetingsListForward(List names) { + return service.getGreetingsList(names); + } + + public Map getGreetingsMapForward(Map namesMap) { + return service.getGreetingsMap(namesMap); + } + + public ArrayList getGreetingsArrayListForward(ArrayList names) { + return service.getGreetingsArrayList(names); + } + + public HashMap getGreetingsHashMapForward(HashMap namesMap) { + return service.getGreetingsHashMap(namesMap); + } + + public String getGreetingsVarArgsForward(String... names) { + return service.getGreetingsVarArgs(names[0], names[1], names[2]); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceImpl.java new file mode 100644 index 0000000000..c0868f0146 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/HelloServiceImpl.java @@ -0,0 +1,86 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of HelloService. + * + * @version $Rev$ $Date$ + */ +@Service(interfaces = {HelloService.class}) +public class HelloServiceImpl implements HelloService { + public String getGreetings(String name) { + return "Hello " + name; + } + + public String[] getGreetingsArray(String[] names) { + String[] resps = new String[names.length]; + for (int i = 0; i < names.length; ++i) { + resps[i] = "Hello " + names[i]; + } + return resps; + } + + public List getGreetingsList(List names) { + List resps = new ArrayList(); + for (int i = 0; i < names.size(); ++i) { + resps.add("Hello " + names.get(i)); + } + return resps; + } + + public ArrayList getGreetingsArrayList(ArrayList names) { + ArrayList resps = new ArrayList(); + for (int i = 0; i < names.size(); ++i) { + resps.add("Hello " + names.get(i)); + } + return resps; + } + + public Map getGreetingsMap(Map namesMap) { + for (Map.Entry entry : namesMap.entrySet()) { + entry.setValue("Hello " + entry.getKey()); + } + return namesMap; + } + + public HashMap getGreetingsHashMap(HashMap namesMap) { + for (Map.Entry entry : namesMap.entrySet()) { + entry.setValue("Hello " + entry.getKey()); + } + return namesMap; + } + + public String getGreetingsVarArgs(String... names) { + String resp = "Hello"; + for(int i = 0; i < names.length; ++i) { + resp += (" "+names[i]); + } + return resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java new file mode 100644 index 0000000000..e55d2527f4 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceClientImpl.java @@ -0,0 +1,139 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesService; +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of PrimitivesServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + * + * @version $Rev$ $Date$ + */ +@Service(PrimitivesServiceClient.class) +public class PrimitivesServiceClientImpl { + + private PrimitivesService service; + + @Reference + public void setPrimitivesService(PrimitivesService service) { + this.service = service; + } + public boolean negateBooleanForward(boolean flag) { + return service.negateBoolean(flag); + } + + public boolean[] negateBooleanArrayForward(boolean[] flags) { + return service.negateBooleanArray(flags); + } + + public boolean passByValueBooleanArray() { + boolean[] req = new boolean[2]; + boolean[] resp = service.identityBooleanArray(req); + return req != resp; + } + + public byte negateByteForward(byte b) { + return service.negateByte(b); + } + + public byte[] negateByteArrayForward(byte[] ba) { + return service.negateByteArray(ba); + } + + public boolean passByValueByteArray() { + byte[] req = new byte[2]; + byte[] resp = service.identityByteArray(req); + return req != resp; + } + + public short negateShortForward(short s) { + return service.negateShort(s); + } + + public short[] negateShortArrayForward(short[] s) { + return service.negateShortArray(s); + } + + public boolean passByValueShortArray() { + short[] req = new short[2]; + short[] resp = service.identityShortArray(req); + return req != resp; + } + + public int negateIntForward(int i) { + return service.negateInt(i); + } + + public int[] negateIntArrayForward(int[] ia) { + return service.negateIntArray(ia); + } + + public boolean passByValueIntArray() { + int[] req = new int[2]; + int[] resp = service.identityIntArray(req); + return req != resp; + } + + public long negateLongForward(long l) { + return service.negateLong(l); + } + + public long[] negateLongArrayForward(long[] la) { + return service.negateLongArray(la); + } + + public boolean passByValueLongArray() { + long[] req = new long[2]; + long[] resp = service.identityLongArray(req); + return req != resp; + } + + public float negateFloatForward(float f) { + return service.negateFloat(f); + } + + public float[] negateFloatArrayForward(float[] fa) { + return service.negateFloatArray(fa); + } + + public boolean passByValueFloatArray() { + float[] req = new float[2]; + float[] resp = service.identityFloatArray(req); + return req != resp; + } + + public double negateDoubleForward(double d) { + return service.negateDouble(d); + } + + public double[] negateDoubleArrayForward(double[] da) { + return service.negateDoubleArray(da); + } + + public boolean passByValueDoubleArray() { + double[] req = new double[2]; + double[] resp = service.identityDoubleArray(req); + return req != resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java new file mode 100644 index 0000000000..72ff27b85e --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/PrimitivesServiceImpl.java @@ -0,0 +1,151 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of PrimitivesService. + * + * @version $Rev$ $Date$ + */ +@Service(interfaces={PrimitivesService.class}) +public class PrimitivesServiceImpl implements PrimitivesService { + + public boolean negateBoolean(boolean flag) { + return !flag; + } + + public boolean[] negateBooleanArray(boolean[] flags) { + boolean[] resp = new boolean[flags.length]; + + for(int i = 0; i < flags.length; ++i) { + resp[i] = !flags[i]; + } + return resp; + } + + public boolean[] identityBooleanArray(boolean[] flags) { + return flags; + } + + public byte negateByte(byte b) { + return (byte)-b; + } + + public byte[] negateByteArray(byte[] ba) { + byte[] resp = new byte[ba.length]; + + for(int i = 0; i < ba.length; ++i) { + resp[i] = (byte)-ba[i]; + } + return resp; + } + + public byte[] identityByteArray(byte[] ba) { + return ba; + } + + public short negateShort(short s) { + return (short)-s; + } + + public short[] negateShortArray(short[] s) { + short[] resp = new short[s.length]; + + for(int i = 0; i < s.length; ++i) { + resp[i] = (short)-s[i]; + } + return resp; + } + + public short[] identityShortArray(short[] sa) { + return sa; + } + + public int negateInt(int i) { + return -i; + } + + public int[] negateIntArray(int[] ia) { + int[] resp = new int[ia.length]; + + for(int i = 0; i < ia.length; ++i) { + resp[i] = -ia[i]; + } + return resp; + } + + public int[] identityIntArray(int[] ia) { + return ia; + } + + public long negateLong(long l) { + return -l; + } + + public long[] negateLongArray(long[] la) { + long[] resp = new long[la.length]; + + for(int i = 0; i < la.length; ++i) { + resp[i] = -la[i]; + } + return resp; + } + + public long[] identityLongArray(long[] la) { + return la; + } + + public float negateFloat(float f) { + return -f; + } + + public float[] negateFloatArray(float[] fa) { + float[] resp = new float[fa.length]; + + for(int i = 0; i < fa.length; ++i) { + resp[i] = -fa[i]; + } + return resp; + } + + public float[] identityFloatArray(float[] fa) { + return fa; + } + + public double negateDouble(double d) { + return -d; + } + + public double[] negateDoubleArray(double[] da) { + double[] resp = new double[da.length]; + + for(int i = 0; i < da.length; ++i) { + resp[i] = -da[i]; + } + return resp; + } + + public double[] identityDoubleArray(double[] da) { + return da; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java new file mode 100644 index 0000000000..b3d3c3eb3a --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceClientImpl.java @@ -0,0 +1,159 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesService; +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesServiceClient; +import org.oasisopen.sca.annotation.Reference; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of StandardTypesServiceClient. + * The client forwards the request to the service component and returns the response from the service component. + * + * @version $Rev$ $Date$ + */ +@Service(StandardTypesServiceClient.class) +public class StandardTypesServiceClientImpl implements StandardTypesServiceClient{ + + private StandardTypesService service; + + @Reference + public void setStandardTypesService(StandardTypesService service) { + this.service = service; + } + + public BigInteger getNewBigIntegerForward(BigInteger bi) { + return service.getNewBigInteger(bi); + } + + public BigInteger[] getNewBigIntegerArrayForward(BigInteger[] bia) { + return service.getNewBigIntegerArray(bia); + } + + public BigDecimal getNewBigDecimalForward(BigDecimal bd) { + return service.getNewBigDecimal(bd); + } + + public BigDecimal[] getNewBigDecimalArrayForward(BigDecimal[] bda) { + return service.getNewBigDecimalArray(bda); + } + public Calendar getNewCalendarForward(Calendar c) { + return service.getNewCalendar(c); + } + public Calendar[] getNewCalendarArrayForward(Calendar[] ca) { + return service.getNewCalendarArray(ca); + } + + public Date getNewDateForward(Date d) { + return service.getNewDate(d); + } + + public Date[] getNewDateArrayForward(Date[] da) { + return service.getNewDateArray(da); + } + + public QName getNewQNameForward(QName qname) { + return service.getNewQName(qname); + } + + public QName[] getNewQNameArrayForward(QName[] qnames) { + return service.getNewQNameArray(qnames); + } + + public URI getNewURIForward(URI uri) { + return service.getNewURI(uri); + } + + public URI[] getNewURIArrayForward(URI[] uris) { + return service.getNewURIArray(uris); + } + + public XMLGregorianCalendar getNewXMLGregorianCalendarForward(XMLGregorianCalendar xgcal) { + return service.getNewXMLGregorianCalendar(xgcal); + } + + public XMLGregorianCalendar[] getNewXMLGregorianCalendarArrayForward(XMLGregorianCalendar[] xgcals) { + return service.getNewXMLGregorianCalendarArray(xgcals); + } + + public Duration getNewDurationForward(Duration d) { + return service.getNewDuration(d); + } + + public Duration[] getNewDurationArrayForward(Duration[] da) { + return service.getNewDurationArray(da); + } + + public Object getNewObjectForward(Object obj) { + return service.getNewObject(obj); + } + + public Object[] getNewObjectArrayForward(Object[] objs) { + return service.getNewObjectArray(objs); + } + + public Image getNewImageForward(Image img) { + return service.getNewImage(img); + } + + public Image[] getNewImageArrayForward(Image[] imgs) { + return service.getNewImageArray(imgs); + } + + public DataHandler getNewDataHandlerForward(DataHandler dh) { + return service.getNewDataHandler(dh); + } + + public DataHandler[] getNewDataHandlerArrayForward(DataHandler[] dha) { + return service.getNewDataHandlerArray(dha); + } + + + public Source getNewSourceForward(Source src) { + return service.getNewSource(src); + } + + public Source[] getNewSourceArrayForward(Source[] srcs) { + return service.getNewSourceArray(srcs); + } + + public UUID getNewUUIDForward(UUID uuid) { + return service.getNewUUID(uuid); + } + + public UUID[] getNewUUIDArrayForward(UUID[] uuids) { + return service.getNewUUIDArray(uuids); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java new file mode 100644 index 0000000000..b58d04a04c --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesServiceImpl.java @@ -0,0 +1,207 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Source; + +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesService; +import org.oasisopen.sca.annotation.Service; + +/** + * An implementation of StandardTypesService. + * + * @version $Rev$ $Date$ + */ +@Service(interfaces={StandardTypesService.class}) +public class StandardTypesServiceImpl implements StandardTypesService { + public BigInteger getNewBigInteger(BigInteger bi) { + return bi.negate(); + } + + public BigInteger[] getNewBigIntegerArray(BigInteger[] bia) { + BigInteger[] resp = new BigInteger[bia.length]; + for(int i = 0; i < bia.length; ++i) { + resp[i] = bia[i].negate(); + } + return resp; + } + + public BigDecimal getNewBigDecimal(BigDecimal bd) { + return bd.negate(); + } + + public BigDecimal[] getNewBigDecimalArray(BigDecimal[] bda) { + BigDecimal[] resp = new BigDecimal[bda.length]; + for(int i = 0; i < bda.length; ++i) { + resp[i] = bda[i].negate(); + } + return resp; + } + + public Calendar getNewCalendar(Calendar c) { + Calendar resp = (Calendar)c.clone(); + resp.add(Calendar.DAY_OF_MONTH, 5); + return resp; + } + + public Calendar[] getNewCalendarArray(Calendar[] ca) { + Calendar[] resp = new Calendar[ca.length]; + for(int i = 0; i < ca.length; ++i) { + resp[i] = getNewCalendar(ca[i]); + } + return resp; + } + + public Date getNewDate(Date d) { + return new Date(d.getTime() + 5*24*60*60*1000); + } + + public Date[] getNewDateArray(Date[] da) { + Date[] resp = new Date[da.length]; + for(int i = 0; i < da.length; ++i) { + resp[i] = getNewDate(da[i]); + } + return resp; + } + + public QName getNewQName(QName qname) { + return new QName(qname.getNamespaceURI()+"q", qname.getLocalPart()+"q", qname.getPrefix()+"q"); + + } + + public QName[] getNewQNameArray(QName[] qnames) { + QName[] resp = new QName[qnames.length]; + for(int i = 0; i < qnames.length; ++i) { + resp[i] = getNewQName(qnames[i]); + } + return resp; + } + + public URI getNewURI(URI uri) { + return uri.resolve("uri"); + } + + public URI[] getNewURIArray(URI[] uris) { + URI[] resp = new URI[uris.length]; + for(int i = 0; i < uris.length; ++i) { + resp[i] = getNewURI(uris[i]); + } + return resp; + } + + public XMLGregorianCalendar getNewXMLGregorianCalendar(XMLGregorianCalendar xgcal) { + xgcal = (XMLGregorianCalendar)xgcal.clone(); + xgcal.setDay(xgcal.getDay()+5); + return xgcal; + } + + public XMLGregorianCalendar[] getNewXMLGregorianCalendarArray(XMLGregorianCalendar[] xgcals) { + XMLGregorianCalendar[] resp = new XMLGregorianCalendar[xgcals.length]; + for(int i = 0; i < xgcals.length; ++i) { + resp[i] = getNewXMLGregorianCalendar(xgcals[i]); + } + return resp; + } + + public Duration getNewDuration(Duration d) { + return d.negate(); + } + + public Duration[] getNewDurationArray(Duration[] da) { + Duration[] resp = new Duration[da.length]; + for(int i = 0; i < da.length; ++i) { + resp[i] = da[i].negate(); + } + return resp; + } + + public Object getNewObject(Object obj) { + return StandardTypesTransformer.getNewObject(obj); + } + + public Object[] getNewObjectArray(Object[] objs) { + Object[] resp = new Object[objs.length]; + for(int i = 0; i < objs.length; ++i) { + resp[i] = getNewObject(objs[i]); + } + return resp; + } + + public Image getNewImage(Image img) { + return StandardTypesTransformer.getNewImage(img); + } + + public Image[] getNewImageArray(Image[] imgs) { + Image[] resp = new Image[imgs.length]; + for(int i = 0; i < imgs.length; ++i) { + resp[i] = getNewImage(imgs[i]); + } + return resp; + } + + public DataHandler getNewDataHandler(DataHandler dh) { + // FIXME: transform the input + return dh; + } + + public DataHandler[] getNewDataHandlerArray(DataHandler[] dha) { + DataHandler[] resp = new DataHandler[dha.length]; + for(int i = 0; i < dha.length; ++i) { + resp[i] = dha[i]; + } + return resp; + } + + public Source getNewSource(Source src) { + return StandardTypesTransformer.getNewSource(src); + } + + public Source[] getNewSourceArray(Source[] srcs) { + Source[] resp = new Source[srcs.length]; + for(int i = 0; i < srcs.length; ++i) { + resp[i] = getNewSource(srcs[i]); + } + return resp; + } + + public UUID getNewUUID(UUID uuid) { + return UUID.fromString(uuid.toString()+"AAA"); + } + + public UUID[] getNewUUIDArray(UUID[] uuids) { + UUID[] resp = new UUID[uuids.length]; + for(int i = 0; i < uuids.length; ++i) { + resp[i] = getNewUUID(uuids[i]); + } + return resp; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java new file mode 100644 index 0000000000..9d851455da --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/java/org/apache/tuscany/sca/itest/databindings/jaxb/impl/StandardTypesTransformer.java @@ -0,0 +1,142 @@ +/* + * 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.itest.databindings.jaxb.impl; + +import java.awt.Image; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.CharArrayReader; +import java.io.CharArrayWriter; +import java.io.IOException; +import java.io.InputStream; +import java.io.Reader; + +import javax.xml.transform.Source; +import javax.xml.transform.dom.DOMSource; +import javax.xml.transform.sax.SAXSource; +import javax.xml.transform.stream.StreamSource; + +import org.xml.sax.InputSource; + +/** + * StandardTypesTransformer class that provide for transforming input provided to StandardTypesService methods. + * + * @version $Rev$ $Date$ + */ +public class StandardTypesTransformer { + + public static Object getNewObject(Object obj) { + if(obj instanceof String) { + return "Hello "+obj; + } else if(obj instanceof Integer) { + return new Integer(-((Integer)obj).intValue()); + } else if(obj instanceof Double) { + return new Double(-((Double)obj).doubleValue()); + } + + return obj; + } + + /** + * Returns a copy of the source object if the input is DOMSource, SAXSource or StreamSource. + * Returns the input object as is for other types. + */ + public static Source getNewSource(Source src) { + Source ret = null; + if(src instanceof DOMSource) { + DOMSource dsrc = (DOMSource)src; + ret = new DOMSource(dsrc.getNode() != null ? dsrc.getNode().cloneNode(true) : null); + } else if(src instanceof SAXSource) { + SAXSource ssrc = (SAXSource)src; + if(ssrc.getInputSource().getByteStream() != null) { + InputStream inp = ssrc.getInputSource().getByteStream(); + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + int b; + try { + while((b = inp.read()) != -1) { + bout.write(b); + } + } catch (IOException ignored) { + } + try { bout.close();} catch (IOException ignored) {} + try { inp.reset();} catch (IOException ignored) {} + ret = new SAXSource(new InputSource(new ByteArrayInputStream(bout.toByteArray()))); + } else if(ssrc.getInputSource().getCharacterStream() != null) { + Reader rdr = ssrc.getInputSource().getCharacterStream(); + CharArrayWriter caw = new CharArrayWriter(); + try { + int c; + while((c = rdr.read()) != -1) { + caw.append((char)c); + } + } catch (IOException ignored) { + } + caw.close(); + try{ rdr.reset();} catch(IOException ignored) {} + ret = new SAXSource(new InputSource(new CharArrayReader(caw.toCharArray()))); + } else { + ret = new SAXSource(); + } + } else if(src instanceof StreamSource) { + StreamSource ssrc = (StreamSource)src; + if(ssrc.getInputStream() != null) { + InputStream inp = ssrc.getInputStream(); + ByteArrayOutputStream bout = new ByteArrayOutputStream(); + int b; + try { + while((b = inp.read()) != -1) { + bout.write(b); + } + } catch (IOException ignored) { + } + try { bout.close();} catch (IOException ignored) {} + try { inp.reset();} catch (IOException ignored) {} + ret = new StreamSource(new ByteArrayInputStream(bout.toByteArray())); + } else if(ssrc.getReader() != null) { + Reader rdr = ssrc.getReader(); + CharArrayWriter caw = new CharArrayWriter(); + try { + int c; + while((c = rdr.read()) != -1) { + caw.append((char)c); + } + } catch (IOException ignored) { + } + caw.close(); + try{ rdr.reset();} catch(IOException ignored) {} + ret = new StreamSource(new CharArrayReader(caw.toCharArray())); + } else { + ret = new StreamSource(); + } + } + + if(ret != null) { + ret.setSystemId(src.getSystemId()); + } else { + ret = src; + } + return ret; + } + + public static Image getNewImage(Image arg) { + arg.getGraphics().drawOval(2, 2, 7, 7); + return arg; + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/hello-service.wsdl b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/hello-service.wsdl new file mode 100644 index 0000000000..926e4154aa --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/hello-service.wsdl @@ -0,0 +1,371 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/helloservice.composite b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/helloservice.composite new file mode 100644 index 0000000000..63151f6a2d --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/helloservice.composite @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitives-service.wsdl b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitives-service.wsdl new file mode 100644 index 0000000000..f366783e5e --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitives-service.wsdl @@ -0,0 +1,927 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitivesservice.composite b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitivesservice.composite new file mode 100644 index 0000000000..85ca6d0789 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/primitivesservice.composite @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.composite b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.composite new file mode 100644 index 0000000000..4788df78e0 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.composite @@ -0,0 +1,80 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.wsdl b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.wsdl new file mode 100644 index 0000000000..5bfd1ea277 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/main/resources/wsdl/wrapped/standard-types-service.wsdl @@ -0,0 +1,1155 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java new file mode 100644 index 0000000000..35f69608e7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/DatabindingTestCase.java @@ -0,0 +1,349 @@ +/* + * 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.itest.databindings.jaxb.topdown; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.databindings.jaxb.HelloServiceClient; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + */ +public class DatabindingTestCase { + + private static Client client; + private static Node node; + + /** + * Runs once before running the tests + */ + @BeforeClass + public static void setUp() throws Exception { + try { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/helloservice.composite", null); + node.start(); + client = (Client)node; + }catch(Throwable e) { + e.printStackTrace(); + } + }catch(Throwable e) { + e.printStackTrace(); + } + } + + /** + * Runs once after running the tests + */ + @AfterClass + public static void tearDown() { + node.stop(); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetings. + */ + @Test + public void testW2W() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTest(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testW2WArray() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestArray(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testW2WList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testW2WArrayList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestArrayList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testW2WMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testW2WHashMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestHashMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testW2WVarArgs() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2WComponent"); + performTestVarArgs(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetings. + */ + @Test + public void testJ2W() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTest(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testJ2WArray() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestArray(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testJ2WList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testJ2WArrayList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestArrayList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testJ2WMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testJ2WHashMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestHashMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testJ2WVarArgs() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientJ2WComponent"); + performTestVarArgs(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetings. + */ + @Test + public void testW2J() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTest(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArray. + */ + @Test + public void testW2JArray() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestArray(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsList. + */ + @Test + public void testW2JList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsArrayList. + */ + @Test + public void testW2JArrayList() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestArrayList(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsMap. + */ + @Test + public void testW2JMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsHashMap. + */ + @Test + public void testW2JHashMap() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestHashMap(helloServiceClient); + } + + /** + * Invokes the HelloService service using WS binding. + * Service method invoked is getGreetingsVarArgs. + */ + @Test + public void testW2JVarArgs() throws Exception { + HelloServiceClient helloServiceClient = client.getService(HelloServiceClient.class, "HelloServiceClientW2JComponent"); + performTestVarArgs(helloServiceClient); + } + + private void performTest(HelloServiceClient helloServiceClient) { + String name = "Pandu"; + String resp = helloServiceClient.getGreetingsForward(name); + Assert.assertEquals("Hello "+name, resp); + } + + private void performTestArray(HelloServiceClient helloServiceClient) { + String[] names = {"Me", "Pandu"}; + String[] resps = helloServiceClient.getGreetingsArrayForward(names); + for(int i = 0; i < names.length; ++i) { + Assert.assertEquals("Hello "+names[i], resps[i]); + } + } + + private void performTestList(HelloServiceClient helloServiceClient) { + List namesList = new ArrayList(); + namesList.add("Me"); + namesList.add("Pandu"); + namesList.add("Chinnipandu"); + List respList = helloServiceClient.getGreetingsListForward(namesList); + Assert.assertEquals(namesList.size(), respList.size()); + for(int i = 0; i < namesList.size(); ++i) { + Assert.assertEquals("Hello "+namesList.get(i), respList.get(i)); + } + } + + private void performTestArrayList(HelloServiceClient helloServiceClient) { + ArrayList namesList = new ArrayList(); + namesList.add("Me"); + namesList.add("Pandu"); + namesList.add("Chinnipandu"); + ArrayList respList = helloServiceClient.getGreetingsArrayListForward(namesList); + Assert.assertEquals(namesList.size(), respList.size()); + for(int i = 0; i < namesList.size(); ++i) { + Assert.assertEquals("Hello "+namesList.get(i), respList.get(i)); + } + } + + private void performTestMap(HelloServiceClient helloServiceClient) { + Map namesMap = new HashMap(); + namesMap.put("Me", null); + namesMap.put("Pandu", null); + namesMap.put("Chinnipandu", null); + Map respMap = helloServiceClient.getGreetingsMapForward(namesMap); + Assert.assertEquals(namesMap.keySet().size(), respMap.keySet().size()); + for(Map.Entry entry: namesMap.entrySet()) { + Assert.assertEquals("Hello "+entry.getKey(), respMap.get(entry.getKey())); + } + } + + private void performTestHashMap(HelloServiceClient helloServiceClient) { + HashMap namesMap = new HashMap(); + namesMap.put("Me", null); + namesMap.put("Pandu", null); + namesMap.put("Chinnipandu", null); + Map respMap = helloServiceClient.getGreetingsHashMapForward(namesMap); + Assert.assertEquals(namesMap.keySet().size(), respMap.keySet().size()); + for(Map.Entry entry: namesMap.entrySet()) { + Assert.assertEquals("Hello "+entry.getKey(), respMap.get(entry.getKey())); + } + } + + private void performTestVarArgs(HelloServiceClient helloServiceClient) { + String[] names = { "Me", "You", "Pandu" }; // Do not change the array size from 3. + String expected = "Hello Me You Pandu"; + String actual = helloServiceClient.getGreetingsVarArgsForward(names[0], names[1], names[2]); + Assert.assertEquals(expected, actual); + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java new file mode 100644 index 0000000000..4a292a8b7a --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/PrimitivesDatabindingTestCase.java @@ -0,0 +1,848 @@ +/* + * 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.itest.databindings.jaxb.topdown; + +import junit.framework.Assert; + +import org.apache.tuscany.sca.itest.databindings.jaxb.PrimitivesServiceClient; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Test; + +/** + * @version $Rev$ $Date$ + */ +public class PrimitivesDatabindingTestCase { + + private static Client domain; + private static Node node; + + /** + * Runs before each test method + */ + @BeforeClass + public static void setUp() throws Exception { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/primitivesservice.composite", null); + node.start(); + domain = (Client)node; + } + + /** + * Runs after each test method + */ + @AfterClass + public static void tearDown() { + node.stop(); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testW2WNegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testW2WNegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for boolean array. + */ + @Test + public void testW2WPassByValueBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueBooleanArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByte. + */ + @Test + public void testW2WNegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testW2WNegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for byte array. + */ + @Test + public void testW2WPassByValueByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueByteArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShort. + */ + @Test + public void testW2WNegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testW2WNegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for short array. + */ + @Test + public void testW2WPassByValueShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueShortArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateInt. + */ + @Test + public void testW2WNegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testW2WNegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for int array. + */ + @Test + public void testW2WPassByValueIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueIntArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLong. + */ + @Test + public void testW2WNegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testW2WNegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for long array. + */ + @Test + public void testW2WPassByValueLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueLongArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloat. + */ + @Test + public void testW2WNegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testW2WNegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for float array. + */ + @Test + public void testW2WPassByValueFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueFloatArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDouble. + */ + @Test + public void testW2WNegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testW2WNegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for double array. + */ + @Test + public void testW2WPassByValueDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueDoubleArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testJ2WNegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testJ2WNegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for boolean array. + */ + @Test + public void testJ2WPassByValueBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueBooleanArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByte. + */ + @Test + public void testJ2WNegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testJ2WNegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for byte array. + */ + @Test + public void testJ2WPassByValueByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueByteArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShort. + */ + @Test + public void testJ2WNegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testJ2WNegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for short array. + */ + @Test + public void testJ2WPassByValueShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueShortArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateInt. + */ + @Test + public void testJ2WNegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testJ2WNegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for int array. + */ + @Test + public void testJ2WPassByValueIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueIntArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLong. + */ + @Test + public void testJ2WNegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testJ2WNegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for long array. + */ + @Test + public void testJ2WPassByValueLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueLongArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloat. + */ + @Test + public void testJ2WNegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testJ2WNegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for float array. + */ + @Test + public void testJ2WPassByValueFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueFloatArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDouble. + */ + @Test + public void testJ2WNegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testJ2WNegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for double array. + */ + @Test + public void testJ2WPassByValueDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientJ2WComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueDoubleArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBoolean. + */ + @Test + public void testW2JNegateBoolean() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateBoolean(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateBooleanArray. + */ + @Test + public void testW2JNegateBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateBooleanArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for boolean array. + */ + @Test + public void testW2JPassByValueBooleanArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueBooleanArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByte. + */ + @Test + public void testW2JNegateByte() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateByte(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateByteArray. + */ + @Test + public void testW2JNegateByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateByteArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for byte array. + */ + @Test + public void testW2JPassByValueByteArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueByteArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShort. + */ + @Test + public void testW2JNegateShort() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateShort(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateShortArray. + */ + @Test + public void testW2JNegateShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateShortArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for short array. + */ + @Test + public void testW2JPassByValueShortArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueShortArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateInt. + */ + @Test + public void testW2JNegateInt() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateInt(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateIntArray. + */ + @Test + public void testW2JNegateIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateIntArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for int array. + */ + @Test + public void testW2JPassByValueIntArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueIntArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLong. + */ + @Test + public void testW2JNegateLong() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateLong(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateLongArray. + */ + @Test + public void testW2JNegateLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateLongArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for long array. + */ + @Test + public void testW2JPassByValueLongArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueLongArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloat. + */ + @Test + public void testW2JNegateFloat() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateFloat(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateFloatArray. + */ + @Test + public void testW2JNegateFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateFloatArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for float array. + */ + @Test + public void testW2JPassByValueFloatArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueFloatArray()); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDouble. + */ + @Test + public void testW2JNegateDouble() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateDouble(primitivesServiceClient); + } + + /** + * Invokes the PrimitivesService service using WS binding. + * Service method invoked is negateDoubleArray. + */ + @Test + public void testW2JNegateDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + performTestNegateDoubleArray(primitivesServiceClient); + } + + /** + * Test the pass-by-value semantics of a remotable service with WS binding. + * Test for double array. + */ + @Test + public void testW2JPassByValueDoubleArray() throws Exception { + PrimitivesServiceClient primitivesServiceClient = domain.getService(PrimitivesServiceClient.class, "PrimitivesServiceClientW2JComponent"); + Assert.assertTrue(primitivesServiceClient.passByValueDoubleArray()); + } + + private void performTestNegateBoolean(PrimitivesServiceClient primitivesServiceClient) { + Assert.assertTrue(primitivesServiceClient.negateBooleanForward(false)); + Assert.assertFalse(primitivesServiceClient.negateBooleanForward(true)); + } + + private void performTestNegateBooleanArray(PrimitivesServiceClient primitivesServiceClient) { + boolean flags[] = new boolean[2]; + flags[0] = false; + flags[1] = true; + boolean[] respFlags = primitivesServiceClient.negateBooleanArrayForward(flags); + Assert.assertEquals(flags.length, respFlags.length); + for(int i = 0; i < flags.length; ++i) { + Assert.assertEquals(!flags[i], respFlags[i]); + } + } + + private void performTestNegateByte(PrimitivesServiceClient primitivesServiceClient) { + byte[] ba = new byte[3]; + ba[0] = -1; + ba[1] = 0; + ba[2] = 1; + + for(int i = 0; i < ba.length; ++i) { + Assert.assertEquals((byte)-ba[i], primitivesServiceClient.negateByteForward(ba[i])); + } + } + + private void performTestNegateByteArray(PrimitivesServiceClient primitivesServiceClient) { + byte[] ba = new byte[3]; + ba[0] = -1; + ba[1] = 0; + ba[2] = 1; + + byte[] r = primitivesServiceClient.negateByteArrayForward(ba); + Assert.assertEquals(ba.length, r.length); + for(int i = 0; i < ba.length; ++i) { + Assert.assertEquals((byte)-ba[i], r[i]); + } + } + + private void performTestNegateShort(PrimitivesServiceClient primitivesServiceClient) { + short[] s = new short[3]; + s[0] = -1; + s[1] = 0; + s[2] = 1; + + for(int i = 0; i < s.length; ++i) { + Assert.assertEquals((short)-s[i], primitivesServiceClient.negateShortForward(s[i])); + } + } + + private void performTestNegateShortArray(PrimitivesServiceClient primitivesServiceClient) { + short[] s = new short[3]; + s[0] = -1; + s[1] = 0; + s[2] = 1; + + short[] r = primitivesServiceClient.negateShortArrayForward(s); + Assert.assertEquals(s.length, r.length); + for(int i = 0; i < s.length; ++i) { + Assert.assertEquals((short)-s[i], r[i]); + } + } + + private void performTestNegateInt(PrimitivesServiceClient primitivesServiceClient) { + int[] ia = new int[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], primitivesServiceClient.negateIntForward(ia[i])); + } + } + + private void performTestNegateIntArray(PrimitivesServiceClient primitivesServiceClient) { + int[] ia = new int[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + int[] r = primitivesServiceClient.negateIntArrayForward(ia); + Assert.assertEquals(ia.length, r.length); + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], r[i]); + } + } + + private void performTestNegateLong(PrimitivesServiceClient primitivesServiceClient) { + long[] la = new long[3]; + la[0] = -1; + la[1] = 0; + la[2] = 1; + + for(int i = 0; i < la.length; ++i) { + Assert.assertEquals(-la[i], primitivesServiceClient.negateLongForward(la[i])); + } + } + + private void performTestNegateLongArray(PrimitivesServiceClient primitivesServiceClient) { + long[] la = new long[3]; + la[0] = -1; + la[1] = 0; + la[2] = 1; + + long[] r = primitivesServiceClient.negateLongArrayForward(la); + Assert.assertEquals(la.length, r.length); + for(int i = 0; i < la.length; ++i) { + Assert.assertEquals(-la[i], r[i]); + } + } + + private void performTestNegateFloat(PrimitivesServiceClient primitivesServiceClient) { + float[] fa = new float[3]; + fa[0] = -1; + fa[1] = 0; + fa[2] = 1; + + for(int i = 0; i < fa.length; ++i) { + Assert.assertEquals(-fa[i], primitivesServiceClient.negateFloatForward(fa[i])); + } + } + + private void performTestNegateFloatArray(PrimitivesServiceClient primitivesServiceClient) { + float[] ia = new float[3]; + ia[0] = -1; + ia[1] = 0; + ia[2] = 1; + + float[] r = primitivesServiceClient.negateFloatArrayForward(ia); + Assert.assertEquals(ia.length, r.length); + for(int i = 0; i < ia.length; ++i) { + Assert.assertEquals(-ia[i], r[i]); + } + } + + private void performTestNegateDouble(PrimitivesServiceClient primitivesServiceClient) { + double[] da = new double[3]; + da[0] = -1; + da[1] = 0; + da[2] = 1; + + for(int i = 0; i < da.length; ++i) { + Assert.assertEquals(-da[i], primitivesServiceClient.negateDoubleForward(da[i])); + } + } + + private void performTestNegateDoubleArray(PrimitivesServiceClient primitivesServiceClient) { + double[] da = new double[3]; + da[0] = -1; + da[1] = 0; + da[2] = 1; + + double[] r = primitivesServiceClient.negateDoubleArrayForward(da); + Assert.assertEquals(da.length, r.length); + for(int i = 0; i < da.length; ++i) { + Assert.assertEquals(-da[i], r[i]); + } + } +} diff --git a/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java new file mode 100644 index 0000000000..263b2f81eb --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxb-top-down/src/test/java/org/apache/tuscany/sca/itest/databindings/jaxb/topdown/StandardTypesDatabindingTestCase.java @@ -0,0 +1,1450 @@ +/* + * 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.itest.databindings.jaxb.topdown; + +import java.awt.Image; +import java.awt.image.BufferedImage; +import java.awt.image.PixelGrabber; +import java.io.IOException; +import java.io.InputStream; +import java.io.StringReader; +import java.io.StringWriter; +import java.math.BigDecimal; +import java.math.BigInteger; +import java.net.URI; +import java.util.Calendar; +import java.util.Date; +import java.util.GregorianCalendar; +import java.util.TimeZone; +import java.util.UUID; + +import javax.activation.DataHandler; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; +import javax.xml.namespace.QName; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.TransformerFactory; +import javax.xml.transform.dom.DOMSource; +import javax.xml.transform.sax.SAXSource; +import javax.xml.transform.stream.StreamResult; +import javax.xml.transform.stream.StreamSource; + +import junit.framework.Assert; + +import org.apache.axiom.attachments.ByteArrayDataSource; +import org.apache.tuscany.sca.databinding.xml.String2Node; +import org.apache.tuscany.sca.itest.databindings.jaxb.StandardTypesServiceClient; +import org.apache.tuscany.sca.itest.databindings.jaxb.impl.StandardTypesTransformer; +import org.apache.tuscany.sca.node.Client; +import org.apache.tuscany.sca.node.Node; +import org.apache.tuscany.sca.node.NodeFactory; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.Ignore; +import org.junit.Test; +import org.xml.sax.InputSource; + +/** + * @version $Rev$ $Date$ + */ +public class StandardTypesDatabindingTestCase { + + private static Client domain; + private static Node node; + + /** + * Runs once before the tests + */ + @BeforeClass + public static void setUp() throws Exception { + NodeFactory nodeFactory = NodeFactory.newInstance(); + node = nodeFactory.createSCANodeFromClassLoader("wsdl/wrapped/standard-types-service.composite", null); + node.start(); + domain = (Client)node; + } + + /** + * Runs once after the tests + */ + @AfterClass + public static void tearDown() { + node.stop(); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testW2WNewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testW2WNewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testW2WNewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testW2WNewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testW2WNewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testW2WNewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDate. + */ + @Test + public void testW2WNewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testW2WNewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQName. + */ + @Test + public void testW2WNewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testW2WNewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURI. + */ + @Test + public void testW2WNewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testW2WNewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testW2WNewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testW2WNewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testW2WNewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testW2WNewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObject. + */ + @Test + public void testW2WNewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testW2WNewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImage. + */ + @Test + public void testW2WNewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testW2WNewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandler. + */ + @Test + @Ignore("TUSCANY-2451") + public void testW2WNewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + @Ignore("TUSCANY-2451") + public void testW2WNewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSource. + */ + @Test + //@Ignore("junit.framework.ComparisonFailure: null expected:<... encoding=\"UTF-8\"?><[a>A> but was:<... encoding=\"UTF-8\"?><[return xmlns=\"http://jaxb.databindings.itest.sca.tuscany.apache.org/\">A>") + public void testW2WNewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSourceArray. + */ + @Test + @Ignore("TUSCANY-2452") + public void testW2WNewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testW2WNewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testW2WNewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2WComponent"); + performTestNewUUIDArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testJ2WNewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testJ2WNewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testJ2WNewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testJ2WNewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testJ2WNewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testJ2WNewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDate. + */ + @Test + public void testJ2WNewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testJ2WNewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQName. + */ + @Test + public void testJ2WNewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testJ2WNewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURI. + */ + @Test + public void testJ2WNewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testJ2WNewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testJ2WNewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testJ2WNewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testJ2WNewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testJ2WNewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObject. + */ + @Test + public void testJ2WNewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testJ2WNewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImage. + */ + @Test + public void testJ2WNewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testJ2WNewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandler. + */ + @Test + @Ignore("TUSCANY-2451") + public void testJ2WNewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + @Ignore("TUSCANY-2451") + public void testJ2WNewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSource. + */ + @Test + //@Ignore("junit.framework.ComparisonFailure: null expected:<... encoding=\"UTF-8\"?><[a>A> but was:<... encoding=\"UTF-8\"?><[return xmlns=\"http://jaxb.databindings.itest.sca.tuscany.apache.org/\">A>") + public void testJ2WNewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSourceArray. + */ + @Test + @Ignore("TUSCANY-2452") + public void testJ2WNewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testJ2WNewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testJ2WNewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientJ2WComponent"); + performTestNewUUIDArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigInteger. + */ + @Test + public void testW2JNewBigInteger() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewBigInteger(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigIntegerArray. + */ + @Test + public void testW2JNewBigIntegerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewBigIntegerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimal. + */ + @Test + public void testW2JNewBigDecimal() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewBigDecimal(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewBigDecimalArray. + */ + @Test + public void testW2JNewBigDecimalArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewBigDecimalArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendar. + */ + @Test + public void testW2JNewCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewCalendarArray. + */ + @Test + public void testW2JNewCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDate. + */ + @Test + public void testW2JNewDate() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDate(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDateArray. + */ + @Test + public void testW2JNewDateArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDateArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQName. + */ + @Test + public void testW2JNewQName() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewQName(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewQNameArray. + */ + @Test + public void testW2JNewQNameArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewQNameArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURI. + */ + @Test + public void testW2JNewURI() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewURI(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewURIArray. + */ + @Test + public void testW2JNewURIArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewURIArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendar. + */ + @Test + public void testW2JNewXMLGregorianCalendar() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewXMLGregorianCalendar(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewXMLGregorianCalendarArray. + */ + @Test + public void testW2JNewXMLGregorianCalendarArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewXMLGregorianCalendarArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDuration. + */ + @Test + public void testW2JNewDuration() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDuration(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDurationArray. + */ + @Test + public void testW2JNewDurationArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDurationArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObject. + */ + @Test + public void testW2JNewObject() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewObject(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewObjectArray. + */ + @Test + public void testW2JNewObjectArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewObjectArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImage. + */ + @Test + public void testW2JNewImage() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewImage(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewImageArray. + */ + @Test + public void testW2JNewImageArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewImageArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandler. + */ + @Test + @Ignore("TUSCANY-2451") + public void testW2JNewDataHandler() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDataHandler(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewDataHandlerArray. + */ + @Test + @Ignore("TUSCANY-2451") + public void testW2JNewDataHandlerArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewDataHandlerArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSource. + */ + @Test + //@Ignore("junit.framework.ComparisonFailure: null expected:<... encoding=\"UTF-8\"?><[a>A> but was:<... encoding=\"UTF-8\"?><[return xmlns=\"http://jaxb.databindings.itest.sca.tuscany.apache.org/\">A>") + public void testW2JNewSource() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewSource(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewSourceArray. + */ + @Test + @Ignore("TUSCANY-2452") + public void testW2JNewSourceArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewSourceArray(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUID. + */ + @Test + public void testW2JNewUUID() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewUUID(serviceClient); + } + + /** + * Invokes the StandardTypesService service using WS binding. + * Service method invoked is getNewUUIDArray. + */ + @Test + public void testW2JNewUUIDArray() throws Exception { + StandardTypesServiceClient serviceClient = + domain.getService(StandardTypesServiceClient.class, "StandardTypesServiceClientW2JComponent"); + performTestNewUUIDArray(serviceClient); + } + + private void performTestNewBigInteger(StandardTypesServiceClient serviceClient) { + BigInteger bi = new BigInteger("1234567890123456789012345678901234"); + BigInteger expected = bi.negate(); + BigInteger actual = serviceClient.getNewBigIntegerForward(bi); + Assert.assertEquals(expected, actual); + } + + private void performTestNewBigIntegerArray(StandardTypesServiceClient serviceClient) { + BigInteger[] bia = new BigInteger[2]; + bia[0] = new BigInteger("1234567890123456789012345678901234"); + bia[1] = new BigInteger("-98765432109876543210987654321"); + BigInteger[] actual = serviceClient.getNewBigIntegerArrayForward(bia); + Assert.assertEquals(bia.length, actual.length); + for (int i = 0; i < bia.length; ++i) { + Assert.assertEquals(bia[i].negate(), actual[i]); + } + } + + private void performTestNewBigDecimal(StandardTypesServiceClient serviceClient) { + BigDecimal bd = new BigDecimal("12345678901234567890.12345678901234"); + BigDecimal expected = bd.negate(); + BigDecimal actual = serviceClient.getNewBigDecimalForward(bd); + Assert.assertEquals(expected, actual); + } + + private void performTestNewBigDecimalArray(StandardTypesServiceClient serviceClient) { + BigDecimal[] bda = new BigDecimal[2]; + bda[0] = new BigDecimal("1234567890123456.789012345678901234"); + bda[1] = new BigDecimal("-987654321098765.43210987654321"); + BigDecimal[] actual = serviceClient.getNewBigDecimalArrayForward(bda); + Assert.assertEquals(bda.length, actual.length); + for (int i = 0; i < bda.length; ++i) { + Assert.assertEquals(bda[i].negate(), actual[i]); + } + } + + private void performTestNewCalendar(StandardTypesServiceClient serviceClient) { + Calendar[] ca = new Calendar[3]; + String[] tz = {"GMT+05:30", "GMT+00:00", "GMT-05:00"}; + for (int i = 0; i < ca.length; ++i) { + ca[i] = Calendar.getInstance(TimeZone.getTimeZone(tz[i])); + ca[i].set(Calendar.DAY_OF_MONTH, i + 1); + } + for (int i = 0; i < ca.length; ++i) { + Calendar actual = serviceClient.getNewCalendarForward(ca[i]); + ca[i].add(Calendar.DAY_OF_MONTH, 5); + if (actual instanceof GregorianCalendar && ca[i] instanceof GregorianCalendar) { + // FIXME: Is this a problem? + // The instance returned by service method invoked over binding.ws seems to have a gregorianCutover + // different from the instance passed. Adjust the gregorianCutover as per the input instance. + ((GregorianCalendar)actual).setGregorianChange(((GregorianCalendar)ca[i]).getGregorianChange()); + } + Assert.assertEquals(ca[i], actual); + } + } + + private void performTestNewCalendarArray(StandardTypesServiceClient serviceClient) { + Calendar[] ca = new Calendar[3]; + String[] tz = {"GMT+05:30", "GMT+00:00", "GMT-05:00"}; + for (int i = 0; i < ca.length; ++i) { + ca[i] = Calendar.getInstance(TimeZone.getTimeZone(tz[i])); + ca[i].set(Calendar.DAY_OF_MONTH, i + 1); + } + Calendar[] actual = serviceClient.getNewCalendarArrayForward(ca); + Assert.assertEquals(ca.length, actual.length); + for (int i = 0; i < ca.length; ++i) { + ca[i].add(Calendar.DAY_OF_MONTH, 5); + if (actual[i] instanceof GregorianCalendar && ca[i] instanceof GregorianCalendar) { + // FIXME: Is this a problem? + // The instance returned by service method invoked over binding.ws seems to have a gregorianCutover + // different from the instance passed. Adjust the gregorianCutover as per the input instance. + ((GregorianCalendar)actual[i]).setGregorianChange(((GregorianCalendar)ca[i]).getGregorianChange()); + } + Assert.assertEquals(ca[i], actual[i]); + } + } + + private void performTestNewDate(StandardTypesServiceClient serviceClient) { + Date d = new Date(); + Date expected = new Date(d.getTime() + 5 * 24 * 60 * 60 * 1000); + Date actual = serviceClient.getNewDateForward(d); + Assert.assertEquals(expected, actual); + } + + private void performTestNewDateArray(StandardTypesServiceClient serviceClient) { + Date[] d = new Date[2]; + Date[] expected = new Date[d.length]; + for (int i = 0; i < d.length; ++i) { + d[i] = new Date(); + d[i].setTime(d[i].getTime() + i * 24 * 60 * 60 * 1000); + expected[i] = new Date(d[i].getTime() + 5 * 24 * 60 * 60 * 1000); + } + Date[] actual = serviceClient.getNewDateArrayForward(d); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < expected.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewQName(StandardTypesServiceClient serviceClient) { + QName[] qnames = new QName[3]; + qnames[0] = new QName("localPart"); + qnames[1] = new QName("namespaceUri", "localPart"); + qnames[2] = new QName("namespaceUri", "localPart", "prefix"); + QName[] expected = new QName[qnames.length]; + for (int i = 0; i < qnames.length; ++i) { + expected[i] = + new QName(qnames[i].getNamespaceURI() + "q", qnames[i].getLocalPart() + "q", + qnames[i].getPrefix() + "q"); + } + for (int i = 0; i < qnames.length; ++i) { + QName actual = serviceClient.getNewQNameForward(qnames[i]); + Assert.assertEquals(expected[i], actual); + } + } + + private void performTestNewQNameArray(StandardTypesServiceClient serviceClient) { + QName[] qnames = new QName[4]; + qnames[0] = new QName("localPart"); + qnames[1] = new QName("namespaceUri", "localPart"); + qnames[2] = new QName("namespaceUri", "localPart", "prefix"); + qnames[3] = new QName("localPart2"); + QName[] expected = new QName[qnames.length]; + for (int i = 0; i < qnames.length; ++i) { + expected[i] = + new QName(qnames[i].getNamespaceURI() + "q", qnames[i].getLocalPart() + "q", + qnames[i].getPrefix() + "q"); + } + QName[] actual = serviceClient.getNewQNameArrayForward(qnames); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < qnames.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewURI(StandardTypesServiceClient serviceClient) { + URI[] uris = new URI[4]; + uris[0] = URI.create("a/b/c"); + uris[1] = URI.create("http://abc/"); + uris[2] = URI.create("ftp://a/b"); + uris[3] = URI.create("http://abc/").resolve("xyz"); + + for (int i = 0; i < uris.length; ++i) { + URI expected = uris[i].resolve("uri"); + URI actual = serviceClient.getNewURIForward(uris[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewURIArray(StandardTypesServiceClient serviceClient) { + URI[] uris = new URI[4]; + uris[0] = URI.create("a/b/c"); + // [rfeng] We need to have a trialign / to avoid the resolving problem + // FIXME: [vamsi] This is actually a data transformation problem. The array being returned from the service method is + // not making to the caller intact. + uris[1] = URI.create("http://abc/"); + uris[2] = URI.create("ftp://a/b"); + uris[3] = URI.create("http://abc/").resolve("xyz"); + + URI[] expected = new URI[uris.length]; + for (int i = 0; i < uris.length; ++i) { + expected[i] = uris[i].resolve("uri"); + } + + URI[] actual = serviceClient.getNewURIArrayForward(uris); + Assert.assertEquals(expected.length, actual.length); + for (int i = 0; i < uris.length; ++i) { + Assert.assertEquals(expected[i], actual[i]); + } + } + + private void performTestNewXMLGregorianCalendar(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + XMLGregorianCalendar[] xgcals = new XMLGregorianCalendar[3]; + xgcals[0] = df.newXMLGregorianCalendar(new GregorianCalendar(1974, GregorianCalendar.APRIL, 19)); + xgcals[1] = df.newXMLGregorianCalendar(new GregorianCalendar(1978, GregorianCalendar.OCTOBER, 13)); + xgcals[2] = df.newXMLGregorianCalendar(new GregorianCalendar(2006, GregorianCalendar.JUNE, 16)); + + for (int i = 0; i < xgcals.length; ++i) { + XMLGregorianCalendar actual = serviceClient.getNewXMLGregorianCalendarForward(xgcals[i]); + xgcals[i].setDay(xgcals[i].getDay() + 5); + Assert.assertEquals(xgcals[i], actual); + } + } + + private void performTestNewXMLGregorianCalendarArray(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + XMLGregorianCalendar[] xgcals = new XMLGregorianCalendar[3]; + xgcals[0] = df.newXMLGregorianCalendar(new GregorianCalendar(1974, GregorianCalendar.APRIL, 19)); + xgcals[1] = df.newXMLGregorianCalendar(new GregorianCalendar(1978, GregorianCalendar.OCTOBER, 13)); + xgcals[2] = df.newXMLGregorianCalendar(new GregorianCalendar(2006, GregorianCalendar.JUNE, 16)); + + XMLGregorianCalendar[] actual = serviceClient.getNewXMLGregorianCalendarArrayForward(xgcals); + Assert.assertEquals(xgcals.length, actual.length); + for (int i = 0; i < xgcals.length; ++i) { + xgcals[i].setDay(xgcals[i].getDay() + 5); + Assert.assertEquals(xgcals[i], actual[i]); + } + } + + private void performTestNewDuration(StandardTypesServiceClient serviceClient) throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + Duration[] da = new Duration[3]; + da[0] = df.newDuration(1000000000000L); + da[1] = df.newDurationDayTime(1000000000000L); + da[2] = df.newDurationYearMonth(true, 1, 3); + + for (int i = 0; i < da.length; ++i) { + Assert.assertEquals(da[i].negate(), serviceClient.getNewDurationForward(da[i])); + } + } + + private void performTestNewObject(StandardTypesServiceClient serviceClient) { + Object[] objs = new Object[5]; + objs[0] = "Hello"; + objs[1] = 10; + objs[2] = null; + objs[3] = -1.0; + objs[4] = null; + + for (int i = 0; i < objs.length; ++i) { + Object expected = StandardTypesTransformer.getNewObject(objs[i]); + Object actual = serviceClient.getNewObjectForward(objs[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewObjectArray(StandardTypesServiceClient serviceClient) { + Object[] objs = new Object[5]; + objs[0] = "Hello"; + objs[1] = 10; + objs[2] = null; + objs[3] = -1.0; + objs[4] = null; + + Object[] actual = serviceClient.getNewObjectArrayForward(objs); + Assert.assertEquals(objs.length, actual.length); + for (int i = 0; i < objs.length; ++i) { + Object expected = StandardTypesTransformer.getNewObject(objs[i]); + Assert.assertEquals(expected, actual[i]); + } + } + + private void performTestNewImage(StandardTypesServiceClient serviceClient) throws InterruptedException { + // Create some images to test with. + Image[] imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + Image[] copy = imgs; + // Create the same images once again as the StandardTypesTransformer may manipulate the image passed. + imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + // Make sure the images and copies are equal using ImageInfo + for(int i = 0; i < imgs.length; ++i) { + Assert.assertEquals(new ImageInfo(imgs[i]), new ImageInfo(copy[i])); + } + + for (int i = 0; i < imgs.length; ++i) { + Image actual = serviceClient.getNewImageForward(imgs[i]); + Image expected = StandardTypesTransformer.getNewImage(copy[i]); + // Compare using ImageInfo + Assert.assertEquals(new ImageInfo(expected), new ImageInfo(actual)); + } + } + + private void performTestNewImageArray(StandardTypesServiceClient serviceClient) throws InterruptedException { + // Create some images to test with. + Image[] imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + Image[] copy = imgs; + // Create the same images once again as the StandardTypesTransformer may manipulate the image passed. + imgs = new Image[3]; + imgs[0] = new BufferedImage(10, 10, BufferedImage.TYPE_3BYTE_BGR); + imgs[1] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_ARGB); + imgs[2] = new BufferedImage(10, 10, BufferedImage.TYPE_INT_RGB); + imgs[0].getGraphics().drawLine(1, 1, 8, 8); + imgs[1].getGraphics().drawLine(8, 1, 1, 8); + imgs[2].getGraphics().drawLine(1, 8, 8, 1); + + // Make sure the images and copies are equal using ImageInfo + for(int i = 0; i < imgs.length; ++i) { + Assert.assertEquals(new ImageInfo(imgs[i]), new ImageInfo(copy[i])); + } + + Image[] actual = serviceClient.getNewImageArrayForward(imgs); + Assert.assertEquals(imgs.length, actual.length); + for (int i = 0; i < imgs.length; ++i) { + Image expected = StandardTypesTransformer.getNewImage(copy[i]); + // Compare using ImageInfo + Assert.assertEquals(new ImageInfo(expected), new ImageInfo(actual[i])); + } + } + + private void performTestNewDurationArray(StandardTypesServiceClient serviceClient) + throws DatatypeConfigurationException { + DatatypeFactory df = DatatypeFactory.newInstance(); + Duration[] da = new Duration[3]; + da[0] = df.newDuration(1000000000000L); + da[1] = df.newDurationDayTime(1000000000000L); + da[2] = df.newDurationYearMonth(true, 1, 3); + + Duration[] actual = serviceClient.getNewDurationArrayForward(da); + Assert.assertEquals(da.length, actual.length); + for (int i = 0; i < da.length; ++i) { + Assert.assertEquals(da[i].negate(), actual[i]); + } + } + + private void performTestNewDataHandler(StandardTypesServiceClient serviceClient) throws IOException { + DataHandler[] dha = new DataHandler[3]; + dha[0] = new DataHandler("Some data", "text/plain"); + dha[1] = new DataHandler(this.getClass().getClassLoader().getResource("standard-types-service.composite")); + dha[2] = new DataHandler(new ByteArrayDataSource("Some data2".getBytes())); + + for (int i = 0; i < dha.length; ++i) { + DataHandler actual = serviceClient.getNewDataHandlerForward(dha[i]); + // Note: The DataHandler returned may use a different type of DataSource. + // Compare the data content instead of using equals(). + Assert.assertTrue(compare(dha[i], actual)); + } + } + + private void performTestNewDataHandlerArray(StandardTypesServiceClient serviceClient) throws IOException { + DataHandler[] dha = new DataHandler[3]; + dha[0] = new DataHandler("Some data", "text/plain"); + dha[1] = new DataHandler(this.getClass().getClassLoader().getResource("standard-types-service.composite")); + dha[2] = new DataHandler(new ByteArrayDataSource("Some data2".getBytes())); + + DataHandler[] actual = serviceClient.getNewDataHandlerArrayForward(dha); + Assert.assertEquals(dha.length, actual.length); + for (int i = 0; i < dha.length; ++i) { + // Note: The DataHandler returned may use a different type of DataSource. + // Compare the data content instead of using equals(). + Assert.assertTrue(compare(dha[i], actual[i])); + } + } + + private void performTestNewSource(StandardTypesServiceClient serviceClient) throws Exception { + String xml = "ABC"; + Source[] srcs = new Source[3]; + srcs[0] = new DOMSource(new String2Node().transform(xml, null)); + srcs[1] = new SAXSource(new InputSource(new StringReader(xml))); + srcs[2] = new StreamSource(new StringReader(xml)); + + for (int i = 0; i < srcs.length; ++i) { + Source expected = StandardTypesTransformer.getNewSource(srcs[i]); + Source actual = serviceClient.getNewSourceForward(srcs[i]); + // [rfeng] The data may come back as a different source + Assert.assertEquals(sourceToString(expected), sourceToString(actual)); + } + } + + private void performTestNewSourceArray(StandardTypesServiceClient serviceClient) throws Exception { + String xml = "ABC"; + Source[] srcs = new Source[3]; + srcs[0] = new DOMSource(new String2Node().transform(xml, null)); + srcs[1] = new SAXSource(new InputSource(new StringReader(xml))); + srcs[2] = new StreamSource(new StringReader(xml)); + + Source[] actual = serviceClient.getNewSourceArrayForward(srcs); + Source[] expected = new Source[srcs.length]; + for(int i = 0; i < srcs.length; ++i) { + expected[i] = StandardTypesTransformer.getNewSource(srcs[i]); + } + Assert.assertEquals(srcs.length, actual.length); + for (int i = 0; i < srcs.length; ++i) { + // [rfeng] The data may come back as a different source + Assert.assertEquals(sourceToString(expected[i]), sourceToString(actual[i])); + } + + } + + private void performTestNewUUID(StandardTypesServiceClient serviceClient) { + UUID[] uuids = new UUID[3]; + uuids[0] = UUID.nameUUIDFromBytes("ABCDEFGHJKLMNOPQRSTUVWXYZ".getBytes()); + uuids[1] = UUID.nameUUIDFromBytes("abcdefghjklmnopqrstuvwxyz".getBytes()); + uuids[2] = UUID.randomUUID(); + + for (int i = 0; i < uuids.length; ++i) { + UUID expected = UUID.fromString(uuids[i].toString() + "AAA"); + UUID actual = serviceClient.getNewUUIDForward(uuids[i]); + Assert.assertEquals(expected, actual); + } + } + + private void performTestNewUUIDArray(StandardTypesServiceClient serviceClient) { + UUID[] uuids = new UUID[3]; + uuids[0] = UUID.nameUUIDFromBytes("ABCDEFGHJKLMNOPQRSTUVWXYZ".getBytes()); + uuids[1] = UUID.nameUUIDFromBytes("abcdefghjklmnopqrstuvwxyz".getBytes()); + uuids[2] = UUID.randomUUID(); + + UUID[] actual = serviceClient.getNewUUIDArrayForward(uuids); + for (int i = 0; i < uuids.length; ++i) { + UUID expected = UUID.fromString(uuids[i].toString() + "AAA"); + Assert.assertEquals(expected, actual[i]); + } + } + + /** + * This method compares two DataHandlers. + * @return true if the data in the two handlers is the same. + */ + private boolean compare(DataHandler dh1, DataHandler dh2) throws IOException { + InputStream inp1 = dh1.getInputStream(); + InputStream inp2 = dh2.getInputStream(); + for(;;) { + int i1 = inp1.read(); + int i2 = inp2.read(); + if(i1 == -1 && i2 == -1) { + return true; + } else if(i1 != -1 && i2 != -1) { + if(i1 != i2) { + return false; + } + } else { + return false; + } + } + } + + /** + * This method returns the content of a source object as String. + */ + private String sourceToString(Source s) throws Exception { + StringWriter sw = new StringWriter(); + Result r = new StreamResult(sw); + TransformerFactory.newInstance().newTransformer().transform(s, r); + sw.close(); + return sw.toString(); + } + + /** + * This class initializes with the width, height and pixel data of a java.awt.Image object. + */ + private static class ImageInfo { + private int h, w, pixels[]; + public ImageInfo(Image img) throws InterruptedException { + w = img.getWidth(null); + h = img.getHeight(null); + pixels = new int[w*h]; + PixelGrabber pg = new PixelGrabber(img, 0, 0, w, h, pixels, 0, w); + pg.grabPixels(); + } + + public boolean equals(Object that) { + if(that == null) { + return false; + } else if(!(that instanceof ImageInfo)) { + return false; + } + + ImageInfo that1 = (ImageInfo)that; + if(w != that1.w || h != that1.h || pixels == null || that1.pixels == null || pixels.length != that1.pixels.length) { + return false; + } + for(int i = 0; i < pixels.length; ++i) { + if(pixels[i] != that1.pixels[i]) { + return false; + } + } + return true; + } + + public String toString() { + return this.getClass().getSimpleName()+"[w = "+w+", h = "+h+", pixels = "+pixels+"]"; + } + } +} diff --git a/java/sca/contrib/itest/databindings/jaxbgen/pom.xml b/java/sca/contrib/itest/databindings/jaxbgen/pom.xml new file mode 100644 index 0000000000..fb88bcfff1 --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxbgen/pom.xml @@ -0,0 +1,262 @@ + + + + + org.apache.tuscany.sca + itest-databindings + 2.0-SNAPSHOT + + + 4.0.0 + + itest-databindings-jaxb + 2.0-SNAPSHOT + jar + Apache Tuscany SCA JAXB Databinding Integration Tests + + + + + true + + java.net + java.net Maven 1.x Repository + http://download.java.net/maven/1 + legacy + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + java.net2 + java.net Maven 2.x Repository + http://download.java.net/maven/2 + + + + + + org.apache.tuscany.sca + tuscany-binding-ws-axis2 + ${pom.version} + runtime + + + org.apache.tuscany.sca + tuscany-databinding-jaxb + ${pom.version} + runtime + + + org.apache.tuscany.sca + tuscany-databinding-sdo + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-databinding-axiom + ${pom.version} + compile + + + org.apache.tuscany.sca + itest-databindings-common + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-embedded + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-implementation-java-runtime + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-interface-java-xml + ${pom.version} + compile + + + org.apache.tuscany.sca + tuscany-host-jetty + 2.0-SNAPSHOT + runtime + + + javax.xml.bind + jaxb-api + 2.1 + compile + + + + com.sun.xml.ws + jaxws-rt + 2.1.3 + + + + commons-collections + commons-collections + 3.1 + + + log4j + log4j + 1.2.12 + provided + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + -Djava.endorsed.dirs=target/endorsed + + + + org.apache.maven.plugins + maven-dependency-plugin + + + generate-sources + + unpack + + + + + org.apache.tuscany.sca + itest-databindings-common + ${project.version} + true + ${project.build.directory}/classes + + + + + + copy + generate-sources + + copy + + + + + javax.xml.ws + jaxws-api + 2.1 + jar + + + javax.xml.bind + jaxb-api + 2.1 + jar + + + ${project.build.directory}/endorsed + false + true + + + + + + org.codehaus.mojo + build-helper-maven-plugin + 1.0 + + + add-test-source + generate-sources + + add-test-source + + + + target/jaxws-source + + + + + + + org.codehaus.mojo + exec-maven-plugin + + + generate-test-source + process-resources + + java + + + + + org.apache.tuscany.sca.itest.generate.Generate + + ${project.build.directory} + + + + + org.codehaus.mojo + jaxws-maven-plugin + 1.9 + + + process-resources + + wsimport + + + + + org.apache.tuscany.sca.itest.jaxbdatabinding.generated + ${project.build.directory}/classes/wsdl + + Greeter.wsdl + + ${project.build.directory}/jaxws-source + false + true + + + + + diff --git a/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/generate/generate.xml b/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/generate/generate.xml new file mode 100644 index 0000000000..8381a164ea --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/generate/generate.xml @@ -0,0 +1,172 @@ + + + + + + + + + + + + + Person.xsd + xsd + org.apache.tuscany.sca.itest.jaxbdatabinding.generated + ObjectFactory + http://apache.org/tuscany/sca/itest/databinding/types + p + + PersonType + + ObjectFactory factory = new ObjectFactory(); + param = factory.createPersonType(); + param.setFirstName("George"); + param.setLastName("Doors"); + + + param.setGreeting("Hello"); + + + assertNotSame("greetedPerson.getGreeting() not set", "", result.getGreeting()); + + + + + Interop.xsd + xsd + org.apache.tuscany.sca.itest.jaxbdatabinding.generated + ObjectFactory + http://www.apache.org/tuscany/interop + i + + + AttributeComplexType + + ObjectFactory factory = new ObjectFactory(); + org.apache.tuscany.sca.itest.jaxbdatabinding.generated.AttributeType attrib = factory.createAttributeType(); + attrib.setAttribute("SomeText"); + param = factory.createAttributeComplexType(); + param.setAttributeElement(attrib); + + + param.getAttributeElement().setAttribute("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getAttributeElement().getAttribute()); + + + + AttributeReferenceComplexType + + ObjectFactory factory = new ObjectFactory(); + param = factory.createAttributeReferenceComplexType(); + + param.setReferencedAttribute("SomeText"); + + + param.setReferencedAttribute("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getReferencedAttribute()); + + + + SimpleTypeWithAbstractComplexType + + ObjectFactory factory = new ObjectFactory(); + param = factory.createSimpleTypeWithAbstractComplexType(); + param.setSimpleTypeWithAbstractExtensionElement("SomeText"); + + + param.setSimpleTypeWithAbstractExtensionElement("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithAbstractExtensionElement()); + + + + SimpleTypeWithNameComplexType + + ObjectFactory factory = new ObjectFactory(); + param = factory.createSimpleTypeWithNameComplexType(); + param.setSimpleTypeWithNameElement("SomeText"); + + + param.setSimpleTypeWithNameElement("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithNameElement()); + + + + ComplexTypeWithContentType + + ObjectFactory factory = new ObjectFactory(); + param = factory.createComplexTypeWithContentType(); + param.setSimpleTypeWithName("SomeText"); + + + param.setSimpleTypeWithName("SomeChangedText");; + + + assertEquals("data not changed corretly", "SomeChangedText", result.getSimpleTypeWithName()); + + + + diff --git a/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/greeter.composite b/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/greeter.composite new file mode 100644 index 0000000000..ae0740e6fe --- /dev/null +++ b/java/sca/contrib/itest/databindings/jaxbgen/src/main/resources/greeter.composite @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/java/sca/contrib/itest/databindings/pom.xml b/java/sca/contrib/itest/databindings/pom.xml new file mode 100644 index 0000000000..43f99aff39 --- /dev/null +++ b/java/sca/contrib/itest/databindings/pom.xml @@ -0,0 +1,47 @@ + + + + + org.apache.tuscany.sca + tuscany-itest + 2.0-SNAPSHOT + ../pom.xml + + 4.0.0 + + org.apache.tuscany.sca + itest-databindings + Apache Tuscany SCA Databindings Integration Tests + 2.0-SNAPSHOT + + + pom + + install + + + common + sdogen + jaxbgen + jaxb-bottom-up + jaxb-top-down + interop + + diff --git a/java/sca/contrib/itest/databindings/readme.html b/java/sca/contrib/itest/databindings/readme.html new file mode 100644 index 0000000000..24a44e4ed7 --- /dev/null +++ b/java/sca/contrib/itest/databindings/readme.html @@ -0,0 +1,157 @@ + + + + + + + + + Tuscany SCA Integration Test Databindings + + + + + +

Tuscany SCA Integation Test Databindings

+ +

Overview

+ +

+This integration test tests the Tuscany SCA databinding implementation by passing various data structures +across various bindings using the supported databindings. There are tests for the individual databindings +which exercise various bindings with the same databinding at client and server ends of each binding. There +is also an integration test which exercises the transformer chains by specifying different databindings at +client and server ends of the binding. +

+

+In doing this testing it is apparent that there is a lot of repetition in creating client, services, idl and +type for each of the data types for each of the bindings for each of the databindings. To reduce the amount +of effort required to maintain the tests as new types, bindings and databindings are added the test cases +themselves are generated from configuration files. +

+ +

Test Structure

+ +Databindings/Common - hold files common across all tests
+Databindings/Interop - test the transformer chains with combinations of databindings
+Databindings/sdogen and jaxbgen - test each databindings independently
+ +

Test Generation

+

+To reduce the amount of manual effort involved in building and maintaining tests cases the test cases +themselves are generated at run time using a set of velocity templates. Each test module has a generate.xml +file in the resources/generate directory which tells the generator what to do. The file looks like this. +

+ +

+Each