01: /* Generated By:JJTree: Do not edit this line. AstOr.java */
02:
03: package org.apache.el.parser;
04:
05: import javax.el.ELException;
06:
07: import org.apache.el.lang.EvaluationContext;
08:
09: /**
10: * @author Jacob Hookom [jacob@hookom.net]
11: * @version $Change: 181177 $$DateTime: 2001/06/26 08:45:09 $$Author: markt $
12: */
13: public final class AstOr extends BooleanNode {
14: public AstOr(int id) {
15: super (id);
16: }
17:
18: public Object getValue(EvaluationContext ctx) throws ELException {
19: Object obj = this .children[0].getValue(ctx);
20: Boolean b = coerceToBoolean(obj);
21: if (b.booleanValue()) {
22: return b;
23: }
24: obj = this .children[1].getValue(ctx);
25: b = coerceToBoolean(obj);
26: return b;
27: }
28: }
|