Which of the following is a method of IterationTag interface?

Which of the following is a method of IterationTag interface?

IterationTag provides a new method: doAfterBody() . The doAfterBody() method is invoked after every body evaluation to control whether the body will be reevaluated or not. If doAfterBody() returns IterationTag.

What would be the return value of the doStartTag () method?

If the TagLibraryDescriptor file indicates that the action must always have an empty action, by an entry of “empty”, then the doStartTag() method must return SKIP_BODY. Otherwise, the doStartTag() method may return SKIP_BODY or EVAL_BODY_INCLUDE.

What is Eval_body_include?

EVAL_BODY_INCLUDE : It is an optional returned value but this value must be returned by the doStartTag() when you want to evaluate the body.

What is the default return type of doStartTag () method of the Bodytagsupport class?

javax.servlet.jsp.tagext Class BodyTagSupport

Method Summary
void doInitBody() Prepare for evaluation of the body just before the first body evaluation: no action.
int doStartTag() Default processing of the start tag returning EVAL_BODY_BUFFERED.
BodyContent getBodyContent() Get current bodyContent.

Which of the following interfaces is required to create an iterative custom tag?

By implementing one of three interfaces : SimpleTag , Tag or BodyTag , which define methods that are invoked during the life cycle of the tag. By extending an abstract base class that implements the SimpleTag , Tag , or BodyTag interfaces.

What JAR files are required for JSTL tags?

JSTL 1.1 requires a JSP 2.0 container. We recommend you test the Standard Taglib with Tomcat 5. x. JSTL 1.0 only required a JSP 1.2 container and is also available for download from Jakarta Taglibs….Getting started quickly.

Name Description Jar File Name
JSTL API classes JSTL API classes jstl.jar

What is the purpose of JSP tag extensions?

JSP tag extensions lets you create new tags that you can insert directly into a JavaServer Page. The JSP 2.0 specification introduced the Simple Tag Handlers for writing these custom tags.

Why taglib is used in JSP?

The taglib directive declares that your JSP page uses a set of custom tags, identifies the location of the library, and provides means for identifying the custom tags in your JSP page.

Why is taglib used?

The JSP taglib directive is used to define a tag library that defines many tags. We use the TLD (Tag Library Descriptor) file to define the tags. In the custom tag section we will use this tag so it will be better to learn it in custom tag.


Back to Top