|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Tags are Java classes implementing JSP Tag extensions. The class must have a null argument public constructor and implement the tag attribute as setXXX methods, following the Beans spec.
MyTag tag = new MyTag(); tag.setPageContext(page); tag.setParent(...); tag.setFoo(...); tag.setBar(...); if (tag.doStartTag() == EVAL_BODY_INCLUDE) { ... } if (tag.doEndTag() == SKIP_PAGE) return; ... tag.setParent(...); tag.setFoo(...); if (tag.doStartTag() == EVAL_BODY_INCLUDE) { ... } if (tag.doEndTag() == SKIP_PAGE) return; ... tag.release();
Field Summary | |
static int |
EVAL_BODY_INCLUDE
|
static int |
EVAL_PAGE
|
static int |
SKIP_BODY
|
static int |
SKIP_PAGE
|
Method Summary | |
int |
doEndTag()
Callback to handle the end of a tag. |
int |
doStartTag()
Callback to handle the start of a tag. |
Tag |
getParent()
Returns the containing tag. |
void |
release()
Cleans up the tag at the end of the page. |
void |
setPageContext(PageContext page)
Sets the page context of this page. |
void |
setParent(Tag t)
Sets the containing tag. |
Field Detail |
public static final int SKIP_BODY
public static final int EVAL_BODY_INCLUDE
public static final int SKIP_PAGE
public static final int EVAL_PAGE
Method Detail |
public void setPageContext(PageContext page)
public void setParent(Tag t)
public Tag getParent()
public int doStartTag() throws JspException
public int doEndTag() throws JspException
public void release()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |