Arch4J 1.1

org.arch4j.messaging
Class MessageQueueFacadeReceiverTest

java.lang.Object
  |
  +--org.arch4j.messaging.MessageQueueFacadeReceiverTest
All Implemented Interfaces:
javax.jms.MessageListener

public class MessageQueueFacadeReceiverTest
extends Object
implements javax.jms.MessageListener

This class is used in conjunction with MessageQueueFacadeSenderTest as a high level test of the SpiderLogic messege queue facade architecture.

To setup the environment for this test, a queue named "org.arch4j.testQueue" must exits in the JMS implementation. The messaging.properties property file must also be set up to reference the MessageQueueFacade implementation class. Run an instance of this class from the command line.

Version:
1.0
Author:
David Colwell

Constructor Summary
MessageQueueFacadeReceiverTest()
           
 
Method Summary
 void close()
          Close the queue receiver and message queue facade instance.
static void main(String[] args)
          Main program entry point.
 void onMessage(javax.jms.Message message)
          Satisfies the MessageListener interface.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageQueueFacadeReceiverTest

public MessageQueueFacadeReceiverTest()
Method Detail

onMessage

public void onMessage(javax.jms.Message message)
Satisfies the MessageListener interface. Print any incoming message text to standard output. It signals the main input loop to exit if receives the "quit" message.

Specified by:
onMessage in interface javax.jms.MessageListener

close

public void close()
Close the queue receiver and message queue facade instance.


main

public static void main(String[] args)
Main program entry point. It creates and runs an instance of this class. Sit in a wait loop until the onMessage method is called.


Arch4J 1.1

Copyright © 2000-2004 SpiderLogic, a service of Wipfli Ullrich Bertelson LLP.