remove entries altogether
[jSite2.git] / src / net / pterodactylus / jsite / project / Project.java
index 5a3b848..04760e2 100644 (file)
@@ -26,9 +26,8 @@ import net.pterodactylus.util.beans.AbstractBean;
 /**
  * Container for project information. A Project is capable of notifying
  * {@link PropertyChangeListener}s if any of the contained properties change.
- * 
+ *
  * @author David ‘Bombe’ Roden <bombe@freenetproject.org>
- * @version $Id$
  */
 public class Project extends AbstractBean {
 
@@ -44,7 +43,7 @@ public class Project extends AbstractBean {
        /** Name of the “private key” property. */
        public static final String PROPERTY_PRIVATE_KEY = "privateKey";
 
-       /** Name of the “local path” property. */
+       /** Name of the “base path” property. */
        public static final String PROPERTY_BASE_PATH = "basePath";
 
        /** Internal ID. */
@@ -66,8 +65,28 @@ public class Project extends AbstractBean {
        private String basePath;
 
        /**
+        * Creates a new project.
+        */
+       public Project() {
+               /* do nothing. */
+       }
+
+       /**
+        * Clones the given project.
+        *
+        * @param project
+        */
+       Project(Project project) {
+               this.name = project.name;
+               this.description = project.description;
+               this.publicKey = project.publicKey;
+               this.privateKey = project.privateKey;
+               this.basePath = project.basePath;
+       }
+
+       /**
         * Returns the internal ID.
-        * 
+        *
         * @return The internal ID
         */
        String getId() {
@@ -76,7 +95,7 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the internal ID.
-        * 
+        *
         * @param id
         *            The internal ID
         */
@@ -86,7 +105,7 @@ public class Project extends AbstractBean {
 
        /**
         * Returns the name of the project.
-        * 
+        *
         * @return The name of the project
         */
        public String getName() {
@@ -95,7 +114,7 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the name of the project.
-        * 
+        *
         * @param name
         *            The name of the project
         */
@@ -107,7 +126,7 @@ public class Project extends AbstractBean {
 
        /**
         * Returns the description of the project.
-        * 
+        *
         * @return The description of the project
         */
        public String getDescription() {
@@ -116,7 +135,7 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the description of the project
-        * 
+        *
         * @param description
         *            The description of the project
         */
@@ -128,7 +147,7 @@ public class Project extends AbstractBean {
 
        /**
         * Returns the public key of the project.
-        * 
+        *
         * @return The public key of the project
         */
        public String getPublicKey() {
@@ -137,11 +156,11 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the public key of the project.
-        * 
+        *
         * @param publicKey
         *            The public key of the project
         */
-       public void setPublicKey(String publicKey) {
+       void setPublicKey(String publicKey) {
                String oldPublicKey = this.publicKey;
                this.publicKey = publicKey;
                fireIfPropertyChanged(PROPERTY_PUBLIC_KEY, oldPublicKey, publicKey);
@@ -149,7 +168,7 @@ public class Project extends AbstractBean {
 
        /**
         * Returns the private key of the project.
-        * 
+        *
         * @return The private key of the project
         */
        public String getPrivateKey() {
@@ -158,11 +177,11 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the private key of the project.
-        * 
+        *
         * @param privateKey
         *            The private key of the project
         */
-       public void setPrivateKey(String privateKey) {
+       void setPrivateKey(String privateKey) {
                String oldPrivateKey = this.privateKey;
                this.privateKey = privateKey;
                fireIfPropertyChanged(PROPERTY_PRIVATE_KEY, oldPrivateKey, privateKey);
@@ -170,7 +189,7 @@ public class Project extends AbstractBean {
 
        /**
         * Returns the base path of the project.
-        * 
+        *
         * @return The base path of the project
         */
        public String getBasePath() {
@@ -179,7 +198,7 @@ public class Project extends AbstractBean {
 
        /**
         * Sets the base path of the project.
-        * 
+        *
         * @param basePath
         *            The base path of the project
         */