KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > spi > project > DeleteOperationImplementation


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19 package org.netbeans.spi.project;
20
21 import java.io.IOException JavaDoc;
22
23 /**
24  * Project Delete Operation. Allows to gather information necessary for project
25  * delete and also provides callbacks to the project type to handle special
26  * checkpoints during the delete.
27  *
28  * An implementation of this interface may be registered in the project's lookup to support
29  * delete operation in the following cases:
30  * <ul>
31  * <li>The project type wants to use
32  * <a HREF="@org-netbeans-modules-projectuiapi@/org/netbeans/spi/project/ui/support/DefaultProjectOperations.html"><code>DefaultProjectOperations</code></a>
33  * to perform the delete operation.
34  * </li>
35  * <li>If this project may be part of of a compound project (like EJB project is a part of a J2EE project),
36  * and the compound project wants to delete all the sub-projects.
37  * </li>
38  * </ul>
39  *
40  * The project type is not required to put an implementation of this interface into the project's
41  * lookup if the above two cases should not be supported.
42  *
43  * @author Jan Lahoda
44  * @since 1.7
45  */

46 public interface DeleteOperationImplementation extends DataFilesProviderImplementation {
47     
48     /**Pre-delete notification. The exact meaning is left on the project implementors, but
49      * typically this means to undeploy the application and remove all artifacts
50      * created by the build project.
51      *
52      * @throws IOException if an I/O operation fails.
53      */

54     public void notifyDeleting() throws IOException JavaDoc;
55     
56     /**Notification that the delete operation has finished. Is supposed to perform
57      * final cleanup and to call {@link ProjectState#notifyDeleted}.
58      *
59      * @throws IOException if an I/O operation fails.
60      */

61     public void notifyDeleted() throws IOException JavaDoc;
62
63 }
64
Popular Tags