KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > deployment > phasing > DeploymentTarget


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23
24 /*
25  * DeploymentTarget.java
26  *
27  * Created on May 23, 2003, 3:47 PM
28  * @author sandhyae
29  * <BR> <I>$Source: /cvs/glassfish/appserv-core/src/java/com/sun/enterprise/deployment/phasing/DeploymentTarget.java,v $
30  *
31  */

32
33 package com.sun.enterprise.deployment.phasing;
34
35 import javax.enterprise.deploy.spi.Target JavaDoc;
36
37 import com.sun.enterprise.config.ConfigContext;
38 import com.sun.enterprise.deployment.backend.DeployableObjectType;
39
40 /**
41  * Abstract class extended by ServerDeploymentTarget, GroupDeploymentTarget
42  * @author Sandhya E
43  */

44 public interface DeploymentTarget extends Target JavaDoc{
45
46     /**
47      * Returns the list of modules of specified type and specified status.
48      * If enabled = true, all enabled modules of specified type are returned
49      * If enabled = false, all disabled modules of type are returned
50      * If enabled = null, all modules are returned
51      * @param type module type DeployableObjectType
52      * @param enabled status of module that have to be returned
53      */

54     public abstract String JavaDoc[] getModules(DeployableObjectType type, Boolean JavaDoc enabled)
55         throws DeploymentTargetException;
56     
57     /**
58      * Adds a reference to this application in server
59      * @param appName name of the application
60      * @param enabled if true application is marked as enabled
61      */

62     public abstract void addAppReference(String JavaDoc appName, boolean enabled, String JavaDoc virtualServers) throws DeploymentTargetException;
63     
64     /**
65      * Removes a reference to this app from the target
66      * @param appName name of the application
67      */

68     public abstract void removeAppReference(String JavaDoc appName) throws DeploymentTargetException;
69     
70     /**
71      * sends applicaiton/module start stop events to the target server.
72      * @param eventType
73      * @param appName name of the application/module
74      * @param moduleType ["ejb"/"web"/"connector"]
75      */

76     public abstract boolean sendStartEvent(int eventType, String JavaDoc appName, String JavaDoc moduleType) throws DeploymentTargetException;
77
78     /**
79      * sends applicaiton/module start stop events to the target server.
80      * @param eventType
81      * @param appName name of the application/module
82      * @param moduleType ["ejb"/"web"/"connector"]
83      * @param isForced indicates if the deployment is forced
84      */

85     public abstract boolean sendStartEvent(int eventType, String JavaDoc appName,
86            String JavaDoc moduleType, boolean isForced) throws DeploymentTargetException;
87
88     public abstract boolean sendStartEvent(int eventType, String JavaDoc appName,
89            String JavaDoc moduleType, boolean isForced, int loadUnloadAction) throws DeploymentTargetException;
90
91     public abstract boolean sendStopEvent(int eventType, String JavaDoc appName, String JavaDoc moduleType, boolean cascade) throws DeploymentTargetException;
92
93     public abstract boolean sendStopEvent(int eventType, String JavaDoc appName, String JavaDoc moduleType, boolean cascade, boolean force) throws DeploymentTargetException;
94
95     public abstract boolean sendStopEvent(int eventType, String JavaDoc appName, String JavaDoc moduleType, boolean cascade, boolean force, int loadUnloadAction) throws DeploymentTargetException;
96
97     public abstract com.sun.enterprise.admin.target.Target getTarget();
98         
99 }
100
Popular Tags