1 7 package org.jboss.test.xml.multispaced.pm.jdbc; 8 9 13 public class JDBCPm 14 { 15 private String datasource; 16 private String table; 17 18 public String getDatasource() 19 { 20 return datasource; 21 } 22 23 public void setDatasource(String datasource) 24 { 25 this.datasource = datasource; 26 } 27 28 public String getTable() 29 { 30 return table; 31 } 32 33 public void setTable(String table) 34 { 35 this.table = table; 36 } 37 38 public String toString() 39 { 40 return "[datasource=" + datasource + ", table=" + table + ']'; 41 } 42 43 public boolean equals(Object o) 44 { 45 if(this == o) return true; 46 if(!(o instanceof JDBCPm)) return false; 47 48 final JDBCPm jdbcPm = (JDBCPm)o; 49 50 if(datasource != null ? !datasource.equals(jdbcPm.datasource) : jdbcPm.datasource != null) return false; 51 if(table != null ? !table.equals(jdbcPm.table) : jdbcPm.table != null) return false; 52 53 return true; 54 } 55 56 public int hashCode() 57 { 58 int result; 59 result = (datasource != null ? datasource.hashCode() : 0); 60 result = 29 * result + (table != null ? table.hashCode() : 0); 61 return result; 62 } 63 } 64 | Popular Tags |