1 18 19 package org.apache.strutsel.taglib.bean; 20 21 import org.apache.struts.taglib.bean.PageTag; 22 import javax.servlet.jsp.JspException ; 23 import org.apache.strutsel.taglib.utils.EvalHelper; 24 25 37 public class ELPageTag extends PageTag { 38 39 43 private String idExpr; 44 48 private String propertyExpr; 49 50 54 public String getIdExpr() { return (idExpr); } 55 59 public String getPropertyExpr() { return (propertyExpr); } 60 61 65 public void setIdExpr(String idExpr) { this.idExpr = idExpr; } 66 70 public void setPropertyExpr(String propertyExpr) { this.propertyExpr = propertyExpr; } 71 72 75 public void release() 76 { 77 super.release(); 78 setIdExpr(null); 79 setPropertyExpr(null); 80 } 81 82 87 public int doStartTag() throws JspException { 88 evaluateExpressions(); 89 return (super.doStartTag()); 90 } 91 92 98 private void evaluateExpressions() throws JspException { 99 String string = null; 100 101 102 if ((string = EvalHelper.evalString("id", getIdExpr(), 103 this, pageContext)) != null) 104 setId(string); 105 106 if ((string = EvalHelper.evalString("property", getPropertyExpr(), 107 this, pageContext)) != null) 108 setProperty(string); 109 } 110 } 111 | Popular Tags |