1 21 package oracle.toplink.essentials.internal.expressions; 23 24 import java.util.*; 25 import oracle.toplink.essentials.expressions.*; 26 27 30 public abstract class ExpressionIterator { 31 32 33 protected Object result; 34 35 36 protected SQLSelectStatement statement; 37 38 39 protected Object parameter; 40 41 44 public ExpressionIterator() { 45 super(); 46 } 47 48 public Object getResult() { 49 return result; 50 } 51 52 public SQLSelectStatement getStatement() { 53 return statement; 54 } 55 56 61 public boolean hasAlreadyVisited(Expression expression) { 62 return false; 63 } 64 65 69 public abstract void iterate(Expression expression); 70 71 74 public void iterateOn(Vector expressions) { 75 for (Enumeration expressionEnum = expressions.elements(); expressionEnum.hasMoreElements();) { 76 iterate((Expression)expressionEnum.nextElement()); 77 } 78 } 79 80 84 public void iterateOn(Expression expression) { 85 expression.iterateOn(this); 86 } 87 88 public void setResult(Object result) { 89 this.result = result; 90 } 91 92 public void setStatement(SQLSelectStatement statement) { 93 this.statement = statement; 94 } 95 96 102 public boolean shouldIterateOverSubSelects() { 103 return false; 104 } 105 } 106 | Popular Tags |