1 21 package oracle.toplink.essentials.internal.parsing; 23 24 import oracle.toplink.essentials.expressions.*; 25 26 35 public class ConcatNode extends StringFunctionNode { 36 37 40 public ConcatNode() { 41 super(); 42 } 43 44 48 public void validate(ParseTreeContext context) { 49 super.validate(context); 50 TypeHelper typeHelper = context.getTypeHelper(); 51 if ((left != null) && (right != null)) { 52 left.validateParameter(context, typeHelper.getStringType()); 53 right.validateParameter(context, typeHelper.getStringType()); 54 } 55 setType(typeHelper.getStringType()); 56 } 57 58 62 public Expression generateExpression(GenerationContext context) { 63 Expression whereClause = getLeft().generateExpression(context); 64 whereClause = whereClause.concat(getRight().generateExpression(context)); 65 return whereClause; 66 } 67 68 } 69 | Popular Tags |