summaryrefslogtreecommitdiffstats
path: root/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-02-16 15:43:08 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2012-02-16 15:43:08 +0000
commit08adcf2e783e4733e0fd646d353db3592c62140d (patch)
tree6e3df9c577025d7f1934b1a3523b20bc7a55df64 /sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services
parent7c60dda128ad42687f78d62c43603bb5d9e9c263 (diff)
Delete old RC tags
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1245046 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services')
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryService.java45
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryServiceImpl.java57
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/Customer.java70
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerService.java46
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerServiceImpl.java58
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/Echo.java41
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/EchoImpl.java45
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Catalog.java51
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverter.java29
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverterImpl.java38
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/FruitsCatalogImpl.java76
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Item.java50
-rw-r--r--sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Items.java37
13 files changed, 0 insertions, 643 deletions
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryService.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryService.java
deleted file mode 100644
index 4749383a0c..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryService.java
+++ /dev/null
@@ -1,45 +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 services.binary;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-import javax.activation.DataSource;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-/**
- *
- */
-@Remotable
-public interface BinaryService {
- @GET
- InputStream get();
-
- @PUT
- void update(InputStream is) throws IOException;
-
- @POST
- void create(DataSource dataSource) throws IOException;
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryServiceImpl.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryServiceImpl.java
deleted file mode 100644
index aefbf64504..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/binary/BinaryServiceImpl.java
+++ /dev/null
@@ -1,57 +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 services.binary;
-
-import java.io.ByteArrayInputStream;
-import java.io.IOException;
-import java.io.InputStream;
-
-import javax.activation.DataSource;
-
-import org.oasisopen.sca.annotation.Scope;
-
-/**
- *
- */
-@Scope("COMPOSITE")
-public class BinaryServiceImpl implements BinaryService {
- private byte[] content;
- private int length;
-
- public void create(DataSource dataSource) throws IOException {
- content = new byte[10240];
- InputStream is = dataSource.getInputStream();
- length = is.read(content);
- System.out.println("Content received: " + length);
- }
-
- public InputStream get() {
- byte[] bytes = new byte[length];
- System.arraycopy(content, 0, bytes, 0, length);
- System.out.println("Content sent: " + length);
- return new ByteArrayInputStream(bytes);
- }
-
- public void update(InputStream is) throws IOException {
- length = is.read(content);
- System.out.println("Content updated: " + length);
- }
-
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/Customer.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/Customer.java
deleted file mode 100644
index 08506ebd48..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/Customer.java
+++ /dev/null
@@ -1,70 +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 services.customer;
-
-
-/**
- * Customer data
- */
-public class Customer {
- private String id;
- private String email;
- private String name;
-
- public Customer() {
- super();
- }
-
- public Customer(String id, String name, String email) {
- super();
- this.id = id;
- this.email = email;
- this.name = name;
- }
-
- public String getId() {
- return id;
- }
-
- public void setId(String id) {
- this.id = id;
- }
-
- public String getEmail() {
- return email;
- }
-
- public void setEmail(String email) {
- this.email = email;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String toString() {
- return "id: " + id + " name: " + name + " e-mail: " + email;
- }
-
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerService.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerService.java
deleted file mode 100644
index 94ebc1e1b8..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerService.java
+++ /dev/null
@@ -1,46 +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 services.customer;
-
-import javax.jws.WebResult;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-import javax.ws.rs.core.Response;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface CustomerService {
-
- @GET
- @WebResult(name = "Customer", targetNamespace = "")
- Customer get();
-
- @GET
- @WebResult(name = "Customer", targetNamespace = "")
- Response getResponse();
-
- @POST
- Response addCustomer(Customer customer);
-
- @PUT
- void updateCustomer(Customer customer);
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerServiceImpl.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerServiceImpl.java
deleted file mode 100644
index 22e63e0f91..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/customer/CustomerServiceImpl.java
+++ /dev/null
@@ -1,58 +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 services.customer;
-
-import java.net.URI;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.ws.rs.core.Response;
-
-import org.oasisopen.sca.annotation.Init;
-import org.oasisopen.sca.annotation.Scope;
-
-@Scope("COMPOSITE")
-public class CustomerServiceImpl implements CustomerService {
- private Map<String, Customer> customers = new HashMap<String, Customer>();
-
- @Init
- public void init() {
- customers.put("John", new Customer("John", "John", "john@domain.com"));
- }
-
- public Customer get() {
- return customers.values().iterator().next();
- }
-
- public Response getResponse() {
- return Response.ok(get()).build();
- }
-
- public Response addCustomer(Customer customer) {
- customers.put(customer.getName(), customer);
- return Response.created(URI.create("/001")).build();
- }
-
- public void updateCustomer(Customer customer) {
- if(customers.get(customer.getName()) != null) {
- customers.put(customer.getName(), customer);
- }
- }
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/Echo.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/Echo.java
deleted file mode 100644
index b93ff0838b..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/Echo.java
+++ /dev/null
@@ -1,41 +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 services.echo;
-
-import javax.ws.rs.QueryParam;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-/**
- * Interface of our sample JSONRPC service.
- *
- * @version $Rev$ $Date$
- */
-@Remotable
-public interface Echo {
-
- String echo(@QueryParam("msg") String msg);
-
- int echoInt(@QueryParam("param") int param);
-
- String [] echoArrayString(@QueryParam("msgArray") String[] stringArray);
-
- int [] echoArrayInt(@QueryParam("intArray") int[] intArray);
-
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/EchoImpl.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/EchoImpl.java
deleted file mode 100644
index 6bc22bd41a..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/echo/EchoImpl.java
+++ /dev/null
@@ -1,45 +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 services.echo;
-
-
-/**
- * A simple client component that uses a reference with an JSONRPC binding.
- *
- * @version $Rev$ $Date$
- */
-public class EchoImpl implements Echo {
-
- public String echo(String msg) {
- return msg;
- }
-
- public int echoInt(int param) {
- int value = param;
- return value;
- }
-
- public String[] echoArrayString(String[] stringArray) {
- return stringArray;
- }
-
- public int[] echoArrayInt(int[] intArray) {
- return intArray;
- }
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Catalog.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Catalog.java
deleted file mode 100644
index 7e579c6aba..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Catalog.java
+++ /dev/null
@@ -1,51 +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 services.store;
-
-import javax.ws.rs.DELETE;
-import javax.ws.rs.GET;
-import javax.ws.rs.POST;
-import javax.ws.rs.PUT;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-
-@Remotable
-public interface Catalog {
-
- @GET
- Items getItem();
-
- @GET
- @Path("{id}")
- Item getItemById(@PathParam("id") String itemId);
-
- @POST
- void addItem(Item item);
-
- @PUT
- void updateItem(Item item);
-
- @DELETE
- @Path("{id}")
- void deleteItem(@PathParam("id") String itemId);
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverter.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverter.java
deleted file mode 100644
index 45f8949633..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverter.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package services.store;
-
-import org.oasisopen.sca.annotation.Remotable;
-
-@Remotable
-public interface CurrencyConverter {
- public double getConversion(String fromCurrenycCode, String toCurrencyCode, double amount);
-
- public String getCurrencySymbol(String currencyCode);
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverterImpl.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverterImpl.java
deleted file mode 100644
index 9956e207e1..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/CurrencyConverterImpl.java
+++ /dev/null
@@ -1,38 +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 services.store;
-
-public class CurrencyConverterImpl implements CurrencyConverter {
- public double getConversion(String fromCurrencyCode, String toCurrencyCode, double amount) {
- if (toCurrencyCode.equals("USD"))
- return amount;
- else if (toCurrencyCode.equals("EUR"))
- return ((double)Math.round(amount * 0.7256 * 100)) /100;
- return 0;
- }
-
- public String getCurrencySymbol(String currencyCode) {
- if (currencyCode.equals("USD"))
- return "$";
- else if (currencyCode.equals("EUR"))
- return "E"; //"€";
- return "?";
- }
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/FruitsCatalogImpl.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/FruitsCatalogImpl.java
deleted file mode 100644
index afe3d3863e..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/FruitsCatalogImpl.java
+++ /dev/null
@@ -1,76 +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 services.store;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.oasisopen.sca.annotation.Init;
-import org.oasisopen.sca.annotation.Property;
-import org.oasisopen.sca.annotation.Reference;
-import org.oasisopen.sca.annotation.Scope;
-
-@Scope("COMPOSITE")
-public class FruitsCatalogImpl implements Catalog {
-
- @Property
- public String currencyCode = "USD";
-
- @Reference
- public CurrencyConverter currencyConverter;
-
- private Map<String, Item> catalog = new HashMap<String, Item>();
-
- @Init
- public void init() {
- String currencySymbol = currencyConverter.getCurrencySymbol(currencyCode);
- catalog.put("Apple", new Item("Apple", currencySymbol + currencyConverter.getConversion("USD", currencyCode, 2.99)));
- catalog.put("Orange", new Item("Orange", currencySymbol + currencyConverter.getConversion("USD", currencyCode, 3.55)));
- catalog.put("Pear", new Item("Pear", currencySymbol + currencyConverter.getConversion("USD", currencyCode, 1.55)));
- }
-
- public Items getItem() {
- Items items = new Items();
- items.setItems(new ArrayList<Item>(catalog.values()));
- return items;
- }
-
- public Item getItemById(String itemId) {
- return catalog.get(itemId);
- }
-
- public void addItem(Item item) {
- catalog.put(item.getName(),item);
- }
-
- public void updateItem(Item item) {
- if(catalog.get(item.getName()) != null) {
- catalog.put(item.getName(), item);
- }
- }
-
- public void deleteItem(String itemId) {
- if(catalog.get(itemId) != null) {
- catalog.remove(itemId);
- }
- }
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Item.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Item.java
deleted file mode 100644
index d5a298eee5..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Item.java
+++ /dev/null
@@ -1,50 +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 services.store;
-
-public class Item {
- private String name;
- private String price;
-
- public Item() {
- }
-
- public Item(String name, String price) {
- this.name = name;
- this.price = price;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getPrice() {
- return price;
- }
-
- public void setPrice(String price) {
- this.price = price;
- }
-
-}
diff --git a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Items.java b/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Items.java
deleted file mode 100644
index 82a995943d..0000000000
--- a/sca-java-2.x/tags/2.0-Beta2-RC1/modules/binding-rest-runtime/src/test/java/services/store/Items.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package services.store;
-
-import java.util.List;
-
-/**
- *
- */
-public class Items {
- private List<Item> items;
-
- public List<Item> getItems() {
- return items;
- }
-
- public void setItems(List<Item> items) {
- this.items = items;
- }
-}