summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks
diff options
context:
space:
mode:
Diffstat (limited to 'sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks')
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/build.xml22
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/pom.xml84
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/Tours.java26
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/impl/TourProviderImpl.java28
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/goodvaluetrips/Trips.java26
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Bookings.java26
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Checkout.java28
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Updates.java26
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/ShoppingCartImpl.java49
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/TripBookingImpl.java39
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/scatours/impl/TripProviderImpl.java28
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/META-INF/sca-contribution.xml27
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-appl.composite54
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl-include.composite33
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl.composite34
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours.composite43
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplIncludeTestCase.java66
-rw-r--r--sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplTestCase.java65
18 files changed, 0 insertions, 704 deletions
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/build.xml b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/build.xml
deleted file mode 100644
index 1e23144229..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/build.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-
-<project name="scatours-contribution-buildingblocks" default="compile">
- <import file="../../antdefs.xml"/>
-</project>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/pom.xml b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/pom.xml
deleted file mode 100644
index bf5ad5c51a..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/pom.xml
+++ /dev/null
@@ -1,84 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<project>
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>scatours</artifactId>
- <version>2.0-SNAPSHOT</version>
- <relativePath>../../pom.xml</relativePath>
- </parent><version>2.0-SNAPSHOT</version>
- <artifactId>scatours-contribution-buildingblocks</artifactId>
- <name>Apache Tuscany SCA Tours Building Blocks Contribution</name>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-sca-api</artifactId>
- <version>${tuscany.version}</version>
- </dependency>
-
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-implementation-java-runtime</artifactId>
- <version>${tuscany.version}</version>
- <scope>runtime</scope>
- </dependency>
-
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-binding-ws-runtime-axis2</artifactId>
- <version>${tuscany.version}</version>
- <scope>runtime</scope>
- </dependency>
-
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-binding-jms-runtime</artifactId>
- <version>${tuscany.version}</version>
- <scope>runtime</scope>
- </dependency>
-
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>scatours-contribution-introducing-trips</artifactId>
- <version>${pom.version}</version>
- <scope>provided</scope>
- </dependency>
-
- <dependency>
- <groupId>org.apache.tuscany.sca</groupId>
- <artifactId>tuscany-node-api</artifactId>
- <version>${tuscany.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>4.5</version>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
- <build>
- <finalName>${artifactId}</finalName>
- </build>
-</project>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/Tours.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/Tours.java
deleted file mode 100644
index 748e88ee09..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/Tours.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.budgettours;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Tours {
- String checkAvailability(String trip, int people);
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/impl/TourProviderImpl.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/impl/TourProviderImpl.java
deleted file mode 100644
index 8e48625f0c..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/budgettours/impl/TourProviderImpl.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.budgettours.impl;
-
-import com.budgettours.Tours;
-
-public class TourProviderImpl implements Tours {
- public String checkAvailability(String trip, int people) {
- // call non-SCA code to reserve trip and return booking code
- return "5Q87X";
- }
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/goodvaluetrips/Trips.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/goodvaluetrips/Trips.java
deleted file mode 100644
index 5026d23c95..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/goodvaluetrips/Trips.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.goodvaluetrips;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Trips {
- String checkAvailability(String trip, int people);
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Bookings.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Bookings.java
deleted file mode 100644
index 4ddd145778..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Bookings.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tuscanyscatours;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Bookings {
- String newBooking(String trip, int people);
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Checkout.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Checkout.java
deleted file mode 100644
index 4e8f1481f5..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Checkout.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tuscanyscatours;
-
-import java.math.BigDecimal;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Checkout {
- void makePayment(BigDecimal amount, String cardInfo);
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Updates.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Updates.java
deleted file mode 100644
index beb5f529b1..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/Updates.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tuscanyscatours;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface Updates {
- void addTrip(String resCode);
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/ShoppingCartImpl.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/ShoppingCartImpl.java
deleted file mode 100644
index 629ea7b5ec..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/ShoppingCartImpl.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tuscanyscatours.impl;
-
-import java.math.BigDecimal;
-import java.util.ArrayList;
-import java.util.List;
-
-import com.tuscanyscatours.Checkout;
-import com.tuscanyscatours.Updates;
-
-public class ShoppingCartImpl implements Checkout, Updates {
- private static List<String> bookedTrips = new ArrayList<String>();
-
- protected String currency = "USD";
-
- public void makePayment(BigDecimal amount, String cardInfo) {
- System.out.print("Charged " + currency + " " + amount
- + " to card "
- + cardInfo
- + " for "
- + (bookedTrips.size() > 1 ? "trips" : "trip"));
- for (String trip : bookedTrips) {
- System.out.print(" " + trip);
- }
- System.out.println();
- bookedTrips.clear();
- }
-
- public void addTrip(String resCode) {
- bookedTrips.add(resCode);
- }
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/TripBookingImpl.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/TripBookingImpl.java
deleted file mode 100644
index 1259fa7d82..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/com/tuscanyscatours/impl/TripBookingImpl.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package com.tuscanyscatours.impl;
-
-import org.oasisopen.sca.annotation.Reference;
-
-import com.goodvaluetrips.Trips;
-import com.tuscanyscatours.Bookings;
-import com.tuscanyscatours.Updates;
-
-public class TripBookingImpl implements Bookings {
- @Reference
- protected Trips mytrips;
-
- @Reference
- protected Updates cart;
-
- public String newBooking(String trip, int people) {
- String resCode = mytrips.checkAvailability(trip, people);
- cart.addTrip(resCode);
- return "GV" + resCode;
- }
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/scatours/impl/TripProviderImpl.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/scatours/impl/TripProviderImpl.java
deleted file mode 100644
index a95f01c519..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/java/scatours/impl/TripProviderImpl.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package scatours.impl;
-
-import com.goodvaluetrips.Trips;
-
-public class TripProviderImpl implements Trips {
- public String checkAvailability(String trip, int people) {
- // scaffolded test code to return an arbitrary booking code
- return "7S09Z";
- }
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/META-INF/sca-contribution.xml b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/META-INF/sca-contribution.xml
deleted file mode 100644
index 697b706163..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/META-INF/sca-contribution.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<contribution xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- xmlns:tst="http://tuscanyscatours.com/">
- <deployable composite="tst:ToursAppl" />
- <deployable composite="tst:ToursImpl" />
- <deployable composite="tst:ToursImplInclude" />
- <import namespace="http://goodvaluetrips.com/" />
- <export namespace="http://tuscanyscatours.com/" />
-</contribution>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-appl.composite b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-appl.composite
deleted file mode 100644
index 6d0a1c1f0d..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-appl.composite
+++ /dev/null
@@ -1,54 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- targetNamespace="http://tuscanyscatours.com/"
- xmlns:bb="http://bb.tuscanyscatours.com/"
- xmlns:gvt="http://goodvaluetrips.com/"
- name="ToursAppl">
-
- <component name="WSTours">
- <implementation.composite name="bb:Tours" />
- <service name="BookTrip">
- <binding.ws uri="http://localhost:8081/BookTrip" />
- </service>
- <service name="Checkout">
- <binding.ws uri="http://localhost:8081/Checkout" />
- </service>
- <reference name="trips" target="TripProvider/Trips" />
- </component>
-
- <component name="JMSTours">
- <implementation.composite name="bb:Tours" />
- <service name="BookTrip">
- <binding.jms uri="jms:BookTrip" />
- </service>
- <service name="Checkout">
- <binding.jms uri="jms:Checkout" />
- </service>
- <reference name="trips" target="TourProvider/Tours" />
- </component>
-
- <include name="gvt:Trips" />
-
- <component name="TourProvider">
- <implementation.java class="com.budgettours.impl.TourProviderImpl" />
- <service name="Tours" />
- </component>
-</composite>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl-include.composite b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl-include.composite
deleted file mode 100644
index 1441702a98..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl-include.composite
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- targetNamespace="http://tuscanyscatours.com/"
- xmlns:bb="http://bb.tuscanyscatours.com/"
- xmlns:gvt="http://goodvaluetrips.com/"
- name="ToursImplInclude">
-
- <component name="MyTours">
- <implementation.composite name="bb:Tours" />
- <reference name="trips" target="TripProvider/Trips" />
- <property name="currency">GBP</property>
- </component>
-
- <include name="gvt:Trips" />
-</composite>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl.composite b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl.composite
deleted file mode 100644
index c1a7643df6..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours-impl.composite
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- targetNamespace="http://tuscanyscatours.com/"
- xmlns:bb="http://bb.tuscanyscatours.com/"
- name="ToursImpl">
-
- <component name="MyTours">
- <implementation.composite name="bb:Tours" />
- <reference name="trips" target="TripProvider/Trips" />
- <property name="currency">GBP</property>
- </component>
-
- <component name="TripProvider">
- <implementation.java class="scatours.impl.TripProviderImpl" />
- </component>
-</composite>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours.composite b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours.composite
deleted file mode 100644
index d2d74d08fc..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/main/resources/tours.composite
+++ /dev/null
@@ -1,43 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
--->
-<composite xmlns="http://docs.oasis-open.org/ns/opencsa/sca/200912"
- targetNamespace="http://bb.tuscanyscatours.com/"
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- name="Tours">
-
- <service name="BookTrip" promote="TripBooking/Bookings" />
- <service name="Checkout" promote="ShoppingCart/Checkout" />
- <reference name="trips" promote="TripBooking/mytrips" />
- <property name="currency" type="xs:string">USD</property>
-
- <component name="TripBooking">
- <implementation.java class="com.tuscanyscatours.impl.TripBookingImpl" />
- <service name="Bookings" />
- <reference name="mytrips" />
- <reference name="cart" target="ShoppingCart/Updates" />
- </component>
-
- <component name="ShoppingCart">
- <implementation.java class="com.tuscanyscatours.impl.ShoppingCartImpl"/>
- <service name="Updates" />
- <service name="Checkout" />
- <property name="currency" source="$currency"/>
- </component>
-</composite>
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplIncludeTestCase.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplIncludeTestCase.java
deleted file mode 100644
index 6c9079e5ab..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplIncludeTestCase.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package scatours;
-
-import java.math.BigDecimal;
-
-import com.tuscanyscatours.Bookings;
-import com.tuscanyscatours.Checkout;
-
-import org.apache.tuscany.sca.node.Node;
-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.Before;
-import org.junit.Test;
-
-/**
- * Tests the Building Blocks Composite Implementation Include scenario
- */
-public class BuildingBlocksImplIncludeTestCase {
-
- private Node node;
-
- @Before
- public void startServer() throws Exception {
- node = NodeFactory.getInstance().createNode("tours-impl-include.composite",
- new Contribution("introducing-trips", "../introducing-trips/target/classes"),
- new Contribution("buildingblocks", "./target/classes"));
- node.start();
- }
-
- @Test
- public void testImplInclude() {
- Bookings bookings = ((Node)node).getService(Bookings.class, "MyTours/BookTrip");
- String bookingCode = bookings.newBooking("FS1APR4", 1);
- System.out.println("Booking code is " + bookingCode);
-
- Checkout checkout = ((Node)node).getService(Checkout.class, "MyTours/Checkout");
- checkout.makePayment(new BigDecimal("1995.00"), "1234567801234567 11/10");
- }
-
- @After
- public void stopServer() throws Exception {
- if (node != null) {
- node.stop();
- }
- }
-}
diff --git a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplTestCase.java b/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplTestCase.java
deleted file mode 100644
index f74304409d..0000000000
--- a/sca-java-2.x/trunk/tutorials/travelsample/contributions/buildingblocks/src/test/java/scatours/BuildingBlocksImplTestCase.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package scatours;
-
-import java.math.BigDecimal;
-
-import com.tuscanyscatours.Bookings;
-import com.tuscanyscatours.Checkout;
-
-import org.apache.tuscany.sca.node.Node;
-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.Before;
-import org.junit.Test;
-
-/**
- * Tests the Building Blocks Composite Implementation scenario
- */
-public class BuildingBlocksImplTestCase {
-
- private Node node;
-
- @Before
- public void startServer() throws Exception {
- node = NodeFactory.getInstance().createNode("tours-impl.composite",
- new Contribution("buildingblocks", "./target/classes"));
- node.start();
- }
-
- @Test
- public void testImpl() {
- Bookings bookings = ((Node)node).getService(Bookings.class, "MyTours/BookTrip");
- String bookingCode = bookings.newBooking("FS1APR4", 1);
- System.out.println("Booking code is " + bookingCode);
-
- Checkout checkout = ((Node)node).getService(Checkout.class, "MyTours/Checkout");
- checkout.makePayment(new BigDecimal("1995.00"), "1234567843218765 10/10");
- }
-
- @After
- public void stopServer() throws Exception {
- if (node != null) {
- node.stop();
- }
- }
-}