as per what I understood is that simple tags can take both simple as well as classic tags as parents but for classic tags to have simple tags as parents, we might need to use Tag Adapter class.
I wanted to know if for exam considerations.
This is a valid combination ??? Since HFSJ didn't discuss TagAdapter classes, I was of impression that this should not be considered a valid option per exam objectives.
JSPFragments don't support scripting so that means that we can't pass on scriptlets in the body of SimpleTag? And webapp won't be deployed if in the TLD I set <body-content> value to be JSP ??
What about ClassicTags. It is not possible to find out from the TLD whether a tag is simple or classic one so how would the entry of JSP for <body-content> be invalidated only for SimpleTags
SCJP 1.4 90%, SCWCD5 94%, Next SCDJWS--> In Naescent stage. Researching abt exam and material itself.
Joined: May 12, 2008
1) Parents Topic
Yes this a valid combination. simpleTags can have classic parents and classicTag can also have simpleTag as their parent , but for that it require little extra work. TagAdapter will do the work for you. beacuse classicTag's getParent() method returns the Tag , but simpleTag 's getParent() methos retuens the JspTag. so extra work is needed here to type cast the Tag to JspTag.
Please refer to the JSP specification 2.0 for more detail