KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jonas_jms > api > JmsManager


1 /*
2  * JOnAS: Java(TM) Open Application Server
3  * Copyright (C) 1999 Bull S.A.
4  * Contact: jonas-team@objectweb.org
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or any later version.
10  *
11  * This library is distributed in the hoper that irt will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19  * USA
20  *
21  * --------------------------------------------------------------------------
22  * $Id: JmsManager.java,v 1.6 2004/04/28 15:31:20 durieuxp Exp $
23  * --------------------------------------------------------------------------
24  */

25
26 package org.objectweb.jonas_jms.api;
27
28 import java.util.Enumeration JavaDoc;
29 import javax.jms.ConnectionFactory JavaDoc;
30 import javax.jms.Queue JavaDoc;
31 import javax.jms.QueueConnectionFactory JavaDoc;
32 import javax.jms.Topic JavaDoc;
33 import javax.jms.TopicConnectionFactory JavaDoc;
34 import javax.jms.XAConnectionFactory JavaDoc;
35 import javax.jms.XAQueueConnectionFactory JavaDoc;
36 import javax.jms.XATopicConnectionFactory JavaDoc;
37 import org.objectweb.transaction.jta.TransactionManager;
38
39 /**
40  * JMS Manager interface.
41  * Implemented by the jms module (jonas_jms/JmsManagerImpl)
42  * This interface allows other jonas module to be independant
43  * of jonas_jms implementation.
44  * @author Philippe Coq
45  * Contributor(s):
46  * Jeff Mesnil: for JORAM 3.0 integration
47  * Frederic Maistre: for JORAM 3.4 (JMS 1.1) integration
48  */

49 public interface JmsManager {
50
51     /**
52      * Initialisation of JmsManager
53      *
54      * @param class cl class implementing administration process
55      * @param boolean true for launching the MOM in the same JVM
56      * @param String connexion url to the MOM (in case of remote mode)
57      * @param TransactionManager tm
58      * @exception Exception must be thrown if the MOM is unreachable
59      */

60     public void init(Class JavaDoc cl, boolean collocated, String JavaDoc url, TransactionManager tm) throws Exception JavaDoc;
61
62    /**
63      * Terminate the administering process
64      */

65     public void stop() throws Exception JavaDoc;
66
67     /**
68      * Create a Queue and bind it in the registry
69      */

70     public Queue JavaDoc createQueue(String JavaDoc name) throws Exception JavaDoc;
71
72     /**
73      * Get Queue (creates it if not exist)
74      */

75     public Queue JavaDoc getQueue(String JavaDoc name) throws Exception JavaDoc;
76
77     /**
78      * Get Queue Names
79      */

80     public Enumeration JavaDoc getQueuesNames();
81
82     /**
83      * Create a Topic and bind it in the registry
84      */

85     public Topic JavaDoc createTopic(String JavaDoc name) throws Exception JavaDoc;
86
87     /**
88      * Get Topic (creates it if not exist)
89      */

90     public Topic JavaDoc getTopic(String JavaDoc name) throws Exception JavaDoc;
91
92     /**
93      * Get Topic Names
94      */

95     public Enumeration JavaDoc getTopicsNames();
96
97     /**
98      * Get the unique ConnectionFactory
99      */

100     public ConnectionFactory JavaDoc getConnectionFactory();
101     
102     /**
103      * Get the unique XAConnectionFactory
104      */

105     public XAConnectionFactory JavaDoc getXAConnectionFactory();
106
107     /**
108      * Get the unique TopicConnectionFactory
109      */

110      public TopicConnectionFactory JavaDoc getTopicConnectionFactory();
111
112     /**
113      * Get the unique XATopicConnectionFactory
114      */

115     public XATopicConnectionFactory JavaDoc getXATopicConnectionFactory();
116
117     /**
118      * Get the unique QueueConnectionFactory
119      */

120     public QueueConnectionFactory JavaDoc getQueueConnectionFactory();
121
122     /**
123      * Get the unique XAQueueConnectionFactory
124      */

125      public XAQueueConnectionFactory JavaDoc getXAQueueConnectionFactory();
126 }
127
128
Popular Tags