On Sat, 23 Nov 2002, Peter Lin wrote:
> Date: Sat, 23 Nov 2002 12:36:50 -0800 (PST) > From: Peter Lin <[EMAIL PROTECTED]> > Reply-To: Tomcat Developers List <[EMAIL PROTECTED]> > To: Tomcat Developers List <[EMAIL PROTECTED]> > Subject: RE: [Jasper2] framework for tag optimization > > > So it would seam having a plugin framework wouldn't necessarily break > conformance. On the otherhand, I would still like to see the expert > group to seriously consider making plugin framework a standard feature > of JSP compiler. Beyond performance, there are other good reasons to do > so. > The best place for this feedback would be to the JSP 2.0 expert group ([EMAIL PROTECTED]). Personally, I'd be surprised if such a suggestion were implemented, since there is very little in the JSP spec (or most Java specs) about implementation. In particular, there is no requirement that there even be such a thing as a JSP page compiler -- an interpreted implementation would be legal as well. > For one, JSTL pages generate a lot of out.print("\r\n") when > <c:choose> statemetns are used. AFAIK, the <c:choose> and other tags don't actually generate *any* output of their own -- the extra line breaks you are seeing are undoubtedly those you've put in the source JSP page itself. > Rather than have a tag handle the > body and trim, I would prefer to see a plugin framework that gives > application developers the ability to strip out extra control linefeeds > or spaces. For example, some one may want to format their jsp code so it > is easier to read, but often it breaks HTML formatting. There should be > an easy way for page developers to write basic filters for jasper that > allows a plugin to strip tabs and control linefeeds. Not only would this > reduce the size of the generated page, but it should provide significant > improvement for pages with lots and lots of tags. > Can't you do this with a standard javax.servlet.Filter, without needing to integrate it into a compiler? A custom BodyTag of your own could certainly do the job as well. > peter lin Craig -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>