1 7 package com.inversoft.verge.mvc.view.jsp.model; 8 9 10 import javax.servlet.jsp.JspException ; 11 12 import com.inversoft.verge.mvc.model.ModelResolution; 13 14 15 22 public class PasswordTag extends com.inversoft.verge.mvc.view.jsp.html.PasswordTag { 23 24 protected ModelResolution modelResolution; 25 26 27 30 public PasswordTag() { 31 } 32 33 34 39 public void initialize() throws JspException { 40 41 super.initialize(); 43 super.initializeKeyProperty(); 44 45 modelResolution = ModelHelper.getModelResolution(key, property, pageContext); 46 if (modelResolution == null) { 47 throw new JspException ("Invalid model definition: " + getModel()); 48 } 49 } 50 51 61 protected void createPasswordTag(StringBuffer buf, String id, String name, 62 Object value) 63 throws JspException { 64 if (isGetValue()) { 65 value = ModelHelper.getValue(modelResolution, pageContext); 66 } 67 68 super.createPasswordTag(buf, id, name, value); 69 } 70 71 76 public int doEndTag() throws JspException { 77 super.doEndTag(); 78 79 if (isSetValue()) { 80 ModelHelper.outputModelExtra(modelResolution.getMetaData(), localName, 81 pageContext); 82 } 83 84 return EVAL_PAGE; 85 } 86 } | Popular Tags |