You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Ken X Horn <ho...@jpmorgan.com> on 2000/07/25 17:25:49 UTC

Re: [PROPOSAL] Jasper, Use XML parser to improve error reporting of JSP taglib problems

Slow, possibly, but at compile time who cares?

On a similar topic, instead of Jasper generating reams of reflection based code
for the JSP runtime, could CORBA style interfaces be generated for the tags
(should the tags implement these?) - to speed up the request processing - rather
than loading the tag instances via introspection? This isn't in the spec but i
think it would be a good way to move.






nixnixnix@yahoo.com on 25/07/2000 10:43:24

Please respond to tomcat-dev@jakarta.apache.org; Please respond to
      nixnixnix@yahoo.com

To:   tomcat-dev@jakarta.apache.org
cc:   (bcc: Ken X Horn)
Subject:  Re: [PROPOSAL] Jasper, Use XML parser to improve error reporting of
      JSP  taglib problems




Sounds like it would be slooooow.

--- Eduardo Pelegri--Llopart
<Ed...@eng.sun.com> wrote:

> > Proposal:
> >
> > Use an XML Parser to do validation of JSP pages
> which use a taglib.
> > An XML Parser does a much better job of reporting
> malformed XML than
> > Jasper does reporting errors when parsing tag lib
> elements.
> >
> > Implementation:
> >
> > Detect if one or more taglib directives are in
> jsp.
> >
> > Load and validate tld's for taglibs, create a DTD
> for
> > each tag lib. DTD's for taglibs should be cached
> by Jasper
> > for later reuse.  Perhaps XSLT could be used to
> transform
> > the tld into a dtd?
> >
> > Strip any HTML and/or scriptlets from the JSP that
> are not
> > inside an XML element, do not remove any lines so
> that any
> > errors report the correct line numbers. A regexp
> can probably
> > handle this.
> >
> > Add the correct XML document headers to the
> stripped JSP.
> > Each taglib being used in the JSP will have its
> own namespace.
> >
> > Pass the document to a DOM parser and report back
> any errors.
> >
> > Continue on with normal processing of JSP.
> >
> > In the future the parsed document may come in
> handy for
> > generating the servlet code.  But for now I am
> only interested
> > in bettor error reporting.
> >
> > Comments?
> >
> > Regards,



=====
# Nick Bauman
# Technical Programmer
# http://webhelp.com
# real software, real code, real time

__________________________________________________
Do You Yahoo!?
Get Yahoo! Mail ? Free email you can access from anywhere!
http://mail.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org








This communication is for informational purposes only.  It is not intended as
an offer or solicitation for the purchase or sale of any financial instrument
or as an official confirmation of any transaction. All market prices, data
and other information are not warranted as to completeness or accuracy and
are subject to change without notice. Any comments or statements made herein
do not necessarily reflect those of J.P. Morgan & Co. Incorporated, its
subsidiaries and affiliates.