Override toString() to output sensible information.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 9 Mar 2009 14:35:05 +0000 (15:35 +0100)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Mon, 9 Mar 2009 14:35:05 +0000 (15:35 +0100)
src/net/pterodactylus/arachne/core/Edition.java
src/net/pterodactylus/arachne/core/Page.java
src/net/pterodactylus/arachne/core/Site.java

index 5fbc41f..547c83c 100644 (file)
@@ -51,4 +51,18 @@ public class Edition {
                return edition;
        }
 
+       //
+       // OBJECT METHODS
+       //
+
+       /**
+        * {@inheritdoc}
+        *
+        * @see java.lang.Object#toString()
+        */
+       @Override
+       public String toString() {
+               return getClass().getName() + "[site=" + site + ",edition=" + edition + "]";
+       }
+
 }
index a833fab..2a87224 100644 (file)
@@ -48,4 +48,18 @@ public class Page {
                return path;
        }
 
+       //
+       // OBJECT METHODS
+       //
+
+       /**
+        * {@inheritdoc}
+        *
+        * @see java.lang.Object#toString()
+        */
+       @Override
+       public String toString() {
+               return getClass().getName() + "[edition=" + edition + ",path=" + path + "]";
+       }
+
 }
index 86f1fe1..699b38f 100644 (file)
@@ -51,4 +51,18 @@ public class Site {
                return basename;
        }
 
+       //
+       // OBJECT METHODS
+       //
+
+       /**
+        * {@inheritdoc}
+        *
+        * @see java.lang.Object#toString()
+        */
+       @Override
+       public String toString() {
+               return getClass().getName() + "[key=" + key + ",basename=" + basename + "]";
+       }
+
 }