summaryrefslogtreecommitdiffstats
path: root/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache
diff options
context:
space:
mode:
authorantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2008-08-11 07:29:53 +0000
committerantelder <antelder@13f79535-47bb-0310-9956-ffa450edef68>2008-08-11 07:29:53 +0000
commit23297fa3b1f66d74325c8352cb8f5aae599a3090 (patch)
tree2c3017479edf2ae3f45e656975db5a53eed71b10 /branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache
parentc5ab90dd4248519034478db64a9c32a0c3f91f3a (diff)
Start branch for 1.3.1, the only changes in this commit are for the version
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@684661 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache')
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.java28
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.java30
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.java45
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.java32
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.java41
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.java26
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.java30
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java41
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.java29
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.java34
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java29
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java34
-rw-r--r--branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.java57
13 files changed, 456 insertions, 0 deletions
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.java
new file mode 100644
index 0000000000..7b1c63d437
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/CheckedExcpetion.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.binding.jms;
+
+public class CheckedExcpetion extends Exception {
+ private static final long serialVersionUID = 1L;
+
+ public CheckedExcpetion(String s) {
+ super(s);
+ }
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.java
new file mode 100644
index 0000000000..46bf911def
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionService.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.binding.jms;
+
+import org.osoa.sca.annotations.Remotable;
+
+@Remotable
+public interface ExceptionService {
+
+ public void throwChecked() throws CheckedExcpetion;
+
+ public void throwUnChecked();
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.java
new file mode 100644
index 0000000000..cd3c09e17f
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceClient.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.binding.jms;
+
+import org.osoa.sca.annotations.Reference;
+import org.osoa.sca.annotations.Service;
+
+/**
+ * This class implements the HelloWorld service.
+ */
+@Service(ExceptionService.class)
+public class ExceptionServiceClient implements ExceptionService {
+
+ private ExceptionService service;
+
+ @Reference
+ public void setService(ExceptionService service) {
+ this.service = service;
+ }
+
+ public void throwChecked() throws CheckedExcpetion {
+ service.throwChecked();
+ }
+
+ public void throwUnChecked() {
+ service.throwUnChecked();
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.java
new file mode 100644
index 0000000000..ab293a5df1
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/ExceptionServiceImpl.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.binding.jms;
+
+public class ExceptionServiceImpl implements ExceptionService {
+
+ public void throwChecked() throws CheckedExcpetion {
+ throw new CheckedExcpetion("foo");
+ }
+
+ public void throwUnChecked() {
+ throw new RuntimeException("bla");
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.java
new file mode 100644
index 0000000000..86d4719646
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldClientImpl.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.binding.jms;
+
+import org.osoa.sca.annotations.Reference;
+import org.osoa.sca.annotations.Service;
+
+/**
+ * This class implements the HelloWorld service.
+ */
+@Service(HelloWorldService.class)
+public class HelloWorldClientImpl implements HelloWorldService {
+
+ private HelloWorldService serviceA;
+
+ @Reference
+ public void setServiceA(HelloWorldService service) {
+ this.serviceA = service;
+ }
+
+ public String sayHello(String name) {
+ return serviceA.sayHello(name);
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.java
new file mode 100644
index 0000000000..abb29aec4c
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldService.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.binding.jms;
+
+import org.osoa.sca.annotations.Remotable;
+
+@Remotable
+public interface HelloWorldService {
+ String sayHello(String name);
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.java
new file mode 100644
index 0000000000..21d2de2cf0
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/HelloWorldServiceImpl.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.binding.jms;
+
+public class HelloWorldServiceImpl implements HelloWorldService {
+
+ public String sayHello(String name) {
+ if ("bang".equals(name)) {
+ throw new RuntimeException("blem wit");
+ }
+ return "jmsHello " + name;
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.java
new file mode 100644
index 0000000000..218cccf64c
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayClientImpl.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.binding.jms;
+
+import org.osoa.sca.annotations.Reference;
+import org.osoa.sca.annotations.Service;
+
+/**
+ * This class implements the OneWay service.
+ */
+@Service(OneWayService.class)
+public class OneWayClientImpl implements OneWayService {
+
+ private OneWayService serviceA;
+
+ @Reference
+ public void setServiceA(OneWayService service) {
+ this.serviceA = service;
+ }
+
+ public void sayHello(String name) {
+ serviceA.sayHello(name);
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.java
new file mode 100644
index 0000000000..9795089952
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectService.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.binding.jms;
+
+import org.osoa.sca.annotations.OneWay;
+import org.osoa.sca.annotations.Remotable;
+
+@Remotable
+public interface OneWayObjectService {
+
+ @OneWay
+ void sayHello(Object name);
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.java
new file mode 100644
index 0000000000..25a89fc5b4
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayObjectServiceImpl.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.binding.jms;
+
+public class OneWayObjectServiceImpl implements OneWayObjectService {
+
+ public static Object mutex = new Object();
+ public static Object name;
+
+ public void sayHello(Object name) {
+ OneWayObjectServiceImpl.name = name;
+ synchronized (OneWayObjectServiceImpl.mutex) {
+ OneWayObjectServiceImpl.mutex.notify();
+ }
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.java
new file mode 100644
index 0000000000..f16f853ba7
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayService.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.binding.jms;
+
+import org.osoa.sca.annotations.OneWay;
+import org.osoa.sca.annotations.Remotable;
+
+@Remotable
+public interface OneWayService {
+
+ @OneWay
+ void sayHello(String name);
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.java
new file mode 100644
index 0000000000..bff4536fa0
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/OneWayServiceImpl.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.binding.jms;
+
+public class OneWayServiceImpl implements OneWayService {
+
+ public static Object mutex = new Object();
+ public static String name;
+
+ public void sayHello(String name) {
+ OneWayServiceImpl.name = name;
+ synchronized (OneWayServiceImpl.mutex) {
+ OneWayServiceImpl.mutex.notify();
+ }
+ }
+
+}
diff --git a/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.java b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.java
new file mode 100644
index 0000000000..cfe7a649d9
--- /dev/null
+++ b/branches/sca-java-1.3.1/itest/jms/src/main/java/org/apache/tuscany/sca/binding/jms/TestMessageProcessor.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.binding.jms;
+
+import javax.jms.Message;
+import javax.jms.Session;
+
+import org.apache.tuscany.sca.binding.jms.impl.JMSBinding;
+import org.apache.tuscany.sca.binding.jms.provider.XMLTextMessageProcessor;
+
+public class TestMessageProcessor extends XMLTextMessageProcessor {
+
+ public static boolean insertPayloadIntoJMSMessageCalled;
+ public static boolean extractPayloadFromJMSMessageCalled;
+ public static boolean setOperationNameCalled;
+
+ public TestMessageProcessor(JMSBinding jmsBinding) {
+ super(jmsBinding);
+ }
+ public Object extractPayloadFromJMSMessage(Message message) {
+ extractPayloadFromJMSMessageCalled = true;
+ return super.extractPayloadFromJMSMessage(message);
+ }
+
+ public String getOperationName(Message message) {
+ // is this used?
+ return super.getOperationName(message);
+ }
+
+ public Message insertPayloadIntoJMSMessage(Session session, Object payload) {
+ insertPayloadIntoJMSMessageCalled = true;
+ return super.insertPayloadIntoJMSMessage(session, payload);
+ }
+
+ public void setOperationName(String operationName, Message message) {
+ setOperationNameCalled = true;
+ super.setOperationName(operationName, message);
+ }
+
+}