1 22 23 package org.xquark.extractor.algebra; 24 25 import java.util.List ; 26 27 import org.xquark.extractor.common.SqlWrapperException; 28 import org.xquark.extractor.sql.SqlExpression; 29 public final class OuterJoinPredicate extends Expression 31 { 32 33 private static final String RCSRevision = "$Revision: 1.3 $"; 34 private static final String RCSName = "$Name: $"; 35 36 protected RenameRelation _outerTable; 37 protected Expression _predicate; 38 39 42 public OuterJoinPredicate() 43 { 44 45 } 46 47 52 public OuterJoinPredicate(Expression predicate, RenameRelation outerTable) 53 { 54 setPredicate (predicate); 55 setOuterTable (outerTable); 56 } 57 58 63 public RenameRelation getOuterTable() 64 { 65 return _outerTable; 66 } 67 68 public List getOperands() 69 { 70 return null; 71 } 72 73 78 public void setOuterTable(RenameRelation aOuterTable) 79 { 80 _outerTable = aOuterTable; 81 } 82 83 88 public Expression getPredicate() 89 { 90 return _predicate; 91 } 92 93 98 public void setPredicate(Expression aPredicate) 99 { 100 _predicate = aPredicate; 101 } 102 103 public SqlExpression accept (GenSqlVisitor visitor) throws SqlWrapperException 104 { 105 return visitor.visit(this); 106 } 107 108 112 public void accept (AlgebraVisitor visitor) throws SqlWrapperException 113 { 114 visitor.visit(this); 115 } 116 117 120 public boolean deepEquals(Object o) 121 { 122 if (o instanceof OuterJoinPredicate) 123 { 124 OuterJoinPredicate cast = (OuterJoinPredicate)o; 125 return _outerTable.deepEquals(cast.getOuterTable()) 126 && _predicate.deepEquals(cast.getPredicate()); 127 } 128 return false; 129 } 130 } 131 | Popular Tags |