latest quantum sources 2.3.2
[phpeclipse.git] / archive / net.sourceforge.phpeclipse.quantum.sql / src / com / quantum / model / Schema.java
index 154e15b..62d7cd3 100644 (file)
@@ -8,7 +8,7 @@ public class Schema implements Comparable {
     private String name;
     private String displayName;
     private boolean isDefault;
-    
+    private boolean exists = true;
     
     public Schema() {
     }
@@ -27,14 +27,14 @@ public class Schema implements Comparable {
      * @return
      */
     public String getName() {
-        return name;
+        return this.name;
     }
 
     /**
      * @param string
      */
-    public void setName(String string) {
-        name = string;
+    public void setName(String name) {
+        this.name = name;
     }
 
     /**
@@ -67,7 +67,7 @@ public class Schema implements Comparable {
         }
     }
     public int hashCode() {
-        int hashCode = super.hashCode();
+        int hashCode = 51;
         if (this.name != null) {
             hashCode ^= this.name.hashCode();
         }
@@ -82,7 +82,7 @@ public class Schema implements Comparable {
      * @return
      */
     public boolean isDefault() {
-        return isDefault;
+        return this.isDefault;
     }
 
     /**
@@ -96,14 +96,25 @@ public class Schema implements Comparable {
      * @return
      */
     public String getDisplayName() {
-        return displayName;
+        return this.displayName;
     }
 
     /**
      * @param string
      */
-    public void setDisplayName(String string) {
-        displayName = string;
+    public void setDisplayName(String displayName) {
+        this.displayName = displayName;
     }
 
+    public boolean exists() {
+       return this.exists;
+    }
+    
+    void setExists(boolean exists) {
+       this.exists = exists;
+    }
+    
+    public String toString() {
+       return this.displayName == null ? this.name : this.displayName;
+    }
 }