File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes query Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "query" Watch "query" New topic
Author

query

geet rahane
Ranch Hand

Joined: Jul 06, 2009
Posts: 45
Question from jwebplus as.....

Consider the following description of a tag in a TLD:


Which of the following statements regarding the above tag are correct?

a It is an empty tag.

b It may be used as an empty tag.

c It must have a body.

d It must implement BodyTag interface.


e It may take an attribute named 'name'. But if present, its value must be dynamic.


correct answer is d; explanation given for it is"Since the body-content is tagdependent, it must implement the BodyTag interface."
is this the necessary condition for such tag whose body-content is tagdependent...???

please help..

Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
This sounds very twisted ... A body-content of tagdependent might well be implemented as a SimpleTag. The only restriction simple tag has is that it does not support JSP as a body content.


JDBCSupport - An easy to use, light-weight JDBC framework -
Ninad Kulkarni
Ranch Hand

Joined: Aug 31, 2007
Posts: 784

I am not getting why option d is correct


SCJP 5.0 - JavaRanch FAQ - Java Beginners FAQ - SCJP FAQ - SCJP Mock Tests - Tutorial - JavaSE7 - JavaEE6 -Generics FAQ - JLS - JVM Spec - Java FAQs - Smart Questions
geeta vemula
Ranch Hand

Joined: Jul 18, 2008
Posts: 208
I think the answer would be b. Lets see what others say!
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60050
    
  65

Please be sure to take the time to compose descriptive subjects for your posts; read this for more information.

A title such as "query" is not helpful. What would happen if all posts had such a title?

Please go back and change your post to add a more meaningful subject by clicking the button on your post.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Ninad Kulkarni
Ranch Hand

Joined: Aug 31, 2007
Posts: 784

Hi All,
Can anybody explain why option d is correct answer?
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

Can anybody explain why option d is correct answer?

Did you notice that everybody says that it's not correct ?


[My Blog]
All roads lead to JavaRanch
Ninad Kulkarni
Ranch Hand

Joined: Aug 31, 2007
Posts: 784

Ok.
Some members suggested some points about it like A body-content of tagdependent might well be implemented as a SimpleTag
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

A body-content of tagdependent might well be implemented as a SimpleTag

Do you agree ?
Ninad Kulkarni
Ranch Hand

Joined: Aug 31, 2007
Posts: 784

@Christophe
I am not agree because when tagdependent is defined in body-content then body content is treated as plain text even no EL expression is evaluated.
Thanks Christophe for clarification.
 
wood burning stoves
 
subject: query
 
Similar Threads
TLD Doubt
Question on Custom tags
body-content
Custom Tag : Mock exam question doubt
Question on tld