1 16 17 package org.apache.taglibs.standard.lang.jpath.expression; 18 19 import javax.servlet.jsp.PageContext ; 20 21 import org.apache.taglibs.standard.lang.jpath.adapter.IterationContext; 22 23 30 public class NumberLiteral extends SimpleNode { 31 32 protected double val; 33 34 41 public NumberLiteral(int id) { 42 super(id); 43 } 44 45 53 public NumberLiteral(Parser p, int id) { 54 super(p, id); 55 } 56 57 67 public String toNormalizedString() { 68 return String.valueOf(val); 69 } 70 71 88 public Object evaluate(PageContext pageContext, IterationContext icontext) 89 throws EvaluationException { 90 return new Double (val); 91 } 92 } 93 | Popular Tags |