Sunday, January 1, 2012

Java Taglibs Apache objective Questions

1.Which of the following is/are interface:
a.Tag
b.BodyTag
c.TagSupport
d.BodyTagSupport
Answer.(a)(b)

2.doStartTag() returns:
a.EVAL_BODY_INCLUDE
B.SKIP_BODY
C.EVAL_BODY_TAG
D.all of the above
Answer:(d)


3.doEndTag() returns:
a.EVAL_PAGE
b.SKIP_PAGE
c.both
d.none
Answer:(C)

4.Which method is invoked after body content is evaluated:
a.doInitBody()
b.doAfterBody()
c.both
d.none

Answer:(b)

5.The BodyTagSupport class implements the BodyTag interface and adds additional convenience methods which is/are:
a.getter for the bodyContent property
b.getter for the previous out JSPWriter
c.both
d.none
Answer:(c)

6. Web Application handlers must reside in one of the following standard locations for Java classes:
a.in a JAR file in the /WEB-INF/lib directory
b.in a directory in the /WEB-INF/classes directory
c.both
d.none
Answer.(c)

7. If the tag is nested, the parent handler of the enclosing tag can be accessed by using:
a.TagSupport.getParent()
b.TagSupport.findAncestorWithClass(from, class)
c.both
d.none
Answer:(c)

8.TLD is:
a. Tag Library Descriptor
b. Tag library Destructor
c Tag library Deviator
d. none
Answer (a)

9.How can u locate a TLD.
a.web.xmltaglib element
b.default mapping
c.both
d.none
Answer:c

No comments:

Post a Comment

ec2-user@ec2 Permission denied