add method to remove project
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Tue, 27 May 2008 18:39:08 +0000 (20:39 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Tue, 27 May 2008 18:39:08 +0000 (20:39 +0200)
src/net/pterodactylus/jsite/project/ProjectManager.java

index 5434842..4480faa 100644 (file)
@@ -219,6 +219,21 @@ public class ProjectManager implements PropertyChangeListener {
                return project;
        }
 
+       /**
+        * Removes the given project.
+        * 
+        * @param project
+        *            The project to remove
+        */
+       public void removeProject(Project project) {
+               projects.remove(project);
+               try {
+                       save();
+               } catch (IOException ioe1) {
+                       /* ignore. */
+               }
+       }
+
        //
        // INTERFACE PropertyChangeListener
        //