站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc 5.0.0

ProjectState (NetBeans Project API) - NetBeans API Javadoc 5.0.0

 

org.netbeans.spi.project
Interface ProjectState


public interface ProjectState

Callback permitting Projects to inform the ProjectManager of important lifecycle events. Currently the only available events are modification of the project metadata and project deletion notification. However in the future other events may be added, such as moving the project, which the project manager would need to be informed of.

This interface may only be implemented by the project manager. A ProjectFactory will receive an instance in ProjectFactory.loadProject(org.openide.filesystems.FileObject, org.netbeans.spi.project.ProjectState).


Method Summary
 void markModified()
          Inform the manager that the project's in-memory state has been modified and that a call to ProjectFactory.saveProject(org.netbeans.api.project.Project) may be needed.
 void notifyDeleted()
          Inform the manager that the project has been deleted.
 

Method Detail

markModified

public void markModified()
Inform the manager that the project's in-memory state has been modified and that a call to ProjectFactory.saveProject(org.netbeans.api.project.Project) may be needed. May not be called during ProjectFactory.loadProject(org.openide.filesystems.FileObject, org.netbeans.spi.project.ProjectState).

Acquires write access.


notifyDeleted

public void notifyDeleted()
                   throws IllegalStateException

Inform the manager that the project has been deleted. The project will be removed from any ProjectManager's mappings. If ProjectManager.findProject(org.openide.filesystems.FileObject) is called on the project directory, the ProjectFactories are asked again to recognize the project.

The project is no longer recognized as created by the ProjectManager.

Acquires write access.

Throws:
IllegalStateException - if notifyDeleted is called more than once for a project.
Since:
1.6

 

Built on May 3 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.