org.apache.commons.messagelet
Class Main

java.lang.Object
  extended by org.apache.commons.messagelet.Main

public class Main
extends Object

Main is a simple command line program that will create a number of subscriptions and consume messages using just regular MDO and MessageListener classes.

Version:
$Revision: 155459 $
Author:
James Strachan

Constructor Summary
Main()
           
 
Method Summary
protected  MessengerManager createMessengerManager()
           
protected  SubscriptionList createSubscriptionList()
           
 String getConnectionsConfig()
           
 Messenger getMessenger(String name)
           
 MessengerManager getMessengerManager()
           
protected  javax.servlet.ServletContext getServletContext()
           
 String getSubscriptionsConfig()
           
static void main(String[] args)
           
 void run()
          Starts all the JMS connections and consumes JMS messages, passing them onto the MessageListener and Message Driven Objects
 void setConnectionsConfig(String connectionsConfig)
           
 void setMessengerManager(MessengerManager manager)
           
 void setSubscriptionsConfig(String subscriptionsConfig)
           
protected  void waitForever()
          This method blocks the current thread indefinitely until the JVM is terminated.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Main

public Main()
Method Detail

main

public static void main(String[] args)

run

public void run()
         throws Exception
Starts all the JMS connections and consumes JMS messages, passing them onto the MessageListener and Message Driven Objects

Throws:
Exception

getMessenger

public Messenger getMessenger(String name)
                       throws javax.jms.JMSException
Throws:
javax.jms.JMSException

getConnectionsConfig

public String getConnectionsConfig()

setConnectionsConfig

public void setConnectionsConfig(String connectionsConfig)

getSubscriptionsConfig

public String getSubscriptionsConfig()

setSubscriptionsConfig

public void setSubscriptionsConfig(String subscriptionsConfig)

getMessengerManager

public MessengerManager getMessengerManager()
                                     throws javax.jms.JMSException
Throws:
javax.jms.JMSException

setMessengerManager

public void setMessengerManager(MessengerManager manager)

createMessengerManager

protected MessengerManager createMessengerManager()
                                           throws javax.jms.JMSException
Throws:
javax.jms.JMSException

createSubscriptionList

protected SubscriptionList createSubscriptionList()
                                           throws javax.jms.JMSException
Throws:
javax.jms.JMSException

getServletContext

protected javax.servlet.ServletContext getServletContext()

waitForever

protected void waitForever()
This method blocks the current thread indefinitely until the JVM is terminated.



Copyright © 2001-2010 The Apache Software Foundation. All Rights Reserved.