You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by cameron <ca...@ogmios.ca> on 2004/03/17 04:38:13 UTC
JSP code template
When a JSP is compiled the following is always placed into the
_jspService method along with the code you create:
JspFactory _jspxFactory = null;
PageContext pageContext = null;
HttpSession session = null;
ServletContext application = null;
ServletConfig config = null;
JspWriter out = null;
Object page = this;
JspWriter _jspx_out = null;
try
{
// your code
} catch (Throwable t) {
if (!(t instanceof SkipPageException)){
out = _jspx_out;
if (out != null && out.getBufferSize() != 0)
out.clearBuffer();
if (pageContext != null) pageContext.handlePageException(t);
}
} finally {
if (_jspxFactory != null)
_jspxFactory.releasePageContext(pageContext);
}
Is it possible to change the code that is automatically inserted? I know
I can get a JSP to inhert but then the code is outside of the
_jspService method. I would like do something before the page context is
released and it needs to be in the 'finally' piece of the code.
Thanks
-Cam
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org