se.kmr.scam.web.taglib.annotation
Class HasAnnotationTag

java.lang.Object
  extended byjavax.servlet.jsp.tagext.TagSupport
      extended byjavax.servlet.jsp.tagext.BodyTagSupport
          extended byse.kmr.scam.web.taglib.annotation.HasAnnotationTag
All Implemented Interfaces:
BodyTag, IterationTag, Serializable, Tag

public class HasAnnotationTag
extends BodyTagSupport

The body is evaluated if the subject is associated with an annotation.
Example:
If annotations exists for the given subject,then the number of annotations associated to that subject will be printed (if none exists then nothing will be prionted)

Version:
$Revision: 1.6 $
Author:
Jöran
See Also:
Serialized Form
Created:
den 23 april 2003

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
HasAnnotationTag()
           
 
Method Summary
 int doStartTag()
          Recives notification of the start of a tag.
 void setSubject(String subjectRef)
          Sets the resource attribute of the BaseTag object
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doEndTag, doInitBody, getBodyContent, getPreviousOut, release, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext, setParent
 

Constructor Detail

HasAnnotationTag

public HasAnnotationTag()
Method Detail

setSubject

public void setSubject(String subjectRef)
Sets the resource attribute of the BaseTag object

Parameters:
subjectRef - The new subject value

doStartTag

public int doStartTag()
               throws JspException
Recives notification of the start of a tag.

Returns:
the value EVAL_BODY_INCLUDE if the subject has annotations, otherwise SKIP_BODY .
Throws:
JspException


Copyright © 2003 SCAM. All Rights Reserved.