Ejemplo n.º 1
0
 @Override
 public boolean equals(Object obj) {
   if (this == obj) return true;
   if (obj == null) return false;
   if (getClass() != obj.getClass()) return false;
   SQLSelectQueryBlock other = (SQLSelectQueryBlock) obj;
   if (parenthesized ^ other.parenthesized) return false;
   if (distionOption != other.distionOption) return false;
   if (from == null) {
     if (other.from != null) return false;
   } else if (!from.equals(other.from)) return false;
   if (groupBy == null) {
     if (other.groupBy != null) return false;
   } else if (!groupBy.equals(other.groupBy)) return false;
   if (into == null) {
     if (other.into != null) return false;
   } else if (!into.equals(other.into)) return false;
   if (selectList == null) {
     if (other.selectList != null) return false;
   } else if (!selectList.equals(other.selectList)) return false;
   if (where == null) {
     if (other.where != null) return false;
   } else if (!where.equals(other.where)) return false;
   return true;
 }
Ejemplo n.º 2
0
 @Override
 public int hashCode() {
   final int prime = 31;
   int result = 1;
   result = prime * result + (Boolean.valueOf(parenthesized).hashCode());
   result = prime * result + distionOption;
   result = prime * result + ((from == null) ? 0 : from.hashCode());
   result = prime * result + ((groupBy == null) ? 0 : groupBy.hashCode());
   result = prime * result + ((into == null) ? 0 : into.hashCode());
   result = prime * result + ((selectList == null) ? 0 : selectList.hashCode());
   result = prime * result + ((where == null) ? 0 : where.hashCode());
   return result;
 }