Interface ProjectState
public interface ProjectState
Callback permitting
Project
s 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
Modifier and TypeMethodDescriptionvoid
Inform the manager that the project's in-memory state has been modified and that a call toProjectFactory.saveProject(org.netbeans.api.project.Project)
may be needed.void
Inform the manager that the project has been deleted.
-
Method Details
-
markModified
void markModified()Inform the manager that the project's in-memory state has been modified and that a call toProjectFactory.saveProject(org.netbeans.api.project.Project)
may be needed. May not be called duringProjectFactory.loadProject(org.openide.filesystems.FileObject, org.netbeans.spi.project.ProjectState)
.Acquires write access.
-
notifyDeleted
Inform the manager that the project has been deleted. The project will be removed from any
ProjectManager
's mappings. IfProjectManager.findProject(org.openide.filesystems.FileObject)
is called on the project directory, theProjectFactories
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
-