KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jonas > web > AbsJWebContainerServiceImplMBean


1 /**
2  * JOnAS: Java(TM) Open Application Server
3  * Copyright (C) 1999-2005 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 hope that it 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: AbsJWebContainerServiceImplMBean.java,v 1.10 2005/05/05 16:09:14 benoitf Exp $
23  * --------------------------------------------------------------------------
24  */

25
26 package org.objectweb.jonas.web;
27
28 import java.rmi.RemoteException JavaDoc;
29 import java.util.List JavaDoc;
30 import java.util.Set JavaDoc;
31
32 /**
33  * This interface provides a description for the web container management.
34  * @author Ludovic Bert
35  * @author Florent Benoit
36  * @author Michel-Ange Anton (Contributor)
37  */

38 public interface AbsJWebContainerServiceImplMBean {
39
40     /**
41      * Register a WAR, this method is used for the JMX Management.
42      * @param fileName the name of the war to deploy.
43      * @throws RemoteException if rmi call failed.
44      * @throws JWebContainerServiceException if the registration of the WAR
45      * failed.
46      */

47     void registerWarMBean(String JavaDoc fileName) throws RemoteException JavaDoc, JWebContainerServiceException;
48
49     /**
50      * Unregister a WAR, this method is used for the JMX Management.
51      * @param fileName the name of the war to undeploy.
52      * @throws RemoteException if rmi call failed.
53      * @throws JWebContainerServiceException if the unregistration of the WAR
54      * failed.
55      */

56     void unRegisterWarMBean(String JavaDoc fileName) throws RemoteException JavaDoc, JWebContainerServiceException;
57
58     /**
59      * Return the list of installed web applications. The WAR files or the
60      * directories with expanded web application are searched in
61      * JONAS_BASE/webapps and all webapps directories 'autoload'.
62      * @return The list of WAR files or the directories with expanded web
63      * application found
64      * @throws Exception if the list can't be retrieved
65      */

66     List JavaDoc getInstalledWars() throws Exception JavaDoc;
67
68     /**
69      * @return current number of wars deployed in the JOnAS server
70      */

71     Integer JavaDoc getCurrentNumberOfWars();
72
73     /**
74      * This method is added temporarily. It will disapear when Wars will have
75      * their associated MBeans (when Wars will become manageable)
76      * @return the names of the wars currently deployed in the JOnAS server
77      */

78     Set JavaDoc getWarNames();
79
80     /**
81      * Test if the specified filename is already deployed or not
82      * @param fileName the name of the war file.
83      * @return true if the war is deployed, else false.
84      */

85     boolean isWarLoaded(String JavaDoc fileName);
86
87     /**
88      * Gets the name of the server which is the web container
89      * @return the name of the server which is the web container
90      */

91     String JavaDoc getServerName();
92
93     /**
94      * Gets the version of the server which is the web container
95      * @return the version of the server which is the web container
96      */

97     String JavaDoc getServerVersion();
98
99     /**
100      * Return the list of all loaded web applications.
101      * @return The list of deployed web applications
102      */

103     List JavaDoc getDeployedWars();
104
105     /**
106      * Return the list of installed web applications ready to deploy.
107      * @return The list of deployable web applications
108      * @throws Exception if the deployable wars can't be returned
109      */

110     List JavaDoc getDeployableWars() throws Exception JavaDoc;
111
112     /**
113      * Return the list of "autoload" directories for web applications.
114      * @return The list of all "autoload" directories
115      */

116     List JavaDoc getAutoloadDirectories();
117
118     /**
119      * Return the WebApps directory.
120      * @return The WebApps directory
121      */

122     String JavaDoc getWebappsDirectory();
123
124 }
125
Popular Tags