tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "bo" <b...@groupserve.com>
Subject RE: How to determing the relationship between tags
Date Wed, 05 Dec 2001 21:20:07 GMT
Thanks a lot!

Bo

-----Original Message-----
From: Shawn Bayern [mailto:bayern@essentially.net]
Sent: Wednesday, December 05, 2001 3:20 PM
To: Tag Libraries Users List; bo@groupserve.com
Subject: Re: How to determing the relationship between tags


On Wed, 5 Dec 2001, bo wrote:

> I wonder if I can determine the relationship among tags, such as tag A
> should be within tag B etc. Is that possible? Thanks!

You can use a TagLibraryValidator class to enforce arbitrary
characteristics of the XML view of a JSP page, including specific
relationships among tags.  For an example of a SAX-based approach to
validation, see the JstlCoreTLV class in the "Standard" taglib.

Tags can also, at runtime, gain access to their parent tag handlers.  The
most convenient mechanism for doing this is, in most cases, the static
TagSupport.findAncestorWithClass() method, part of the JSP API.

Hope that helps,

Shawn


--
To unsubscribe, e-mail:
<mailto:taglibs-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:taglibs-user-help@jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:taglibs-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:taglibs-user-help@jakarta.apache.org>


Mime
View raw message