Ejemplo n.º 1
0
 public void destroy() {
   if (theServlet != null) {
     theServlet.destroy();
     InstanceManager instanceManager = InstanceManagerFactory.getInstanceManager(config);
     try {
       instanceManager.destroyInstance(theServlet);
     } catch (Exception e) {
       // Log any exception, since it can't be passed along
       log.error(Localizer.getMessage("jsp.error.file.not.found", e.getMessage()), e);
     }
   }
 }
 public void destroy() {
   if (theServlet != null) {
     theServlet.destroy();
     InstanceManager instanceManager = InstanceManagerFactory.getInstanceManager(config);
     try {
       instanceManager.destroyInstance(theServlet);
     } catch (Exception e) {
       Throwable t = ExceptionUtils.unwrapInvocationTargetException(e);
       ExceptionUtils.handleThrowable(t);
       // Log any exception, since it can't be passed along
       log.error(Localizer.getMessage("jsp.error.file.not.found", e.getMessage()), t);
     }
   }
 }
Ejemplo n.º 3
0
  public Servlet getServlet() throws ServletException {
    // DCL on 'reload' requires that 'reload' be volatile
    // (this also forces a read memory barrier, ensuring the
    // new servlet object is read consistently)
    if (reload) {
      synchronized (this) {
        // Synchronizing on jsw enables simultaneous loading
        // of different pages, but not the same page.
        if (reload) {
          // This is to maintain the original protocol.
          destroy();

          final Servlet servlet;

          try {
            InstanceManager instanceManager = InstanceManagerFactory.getInstanceManager(config);
            servlet = (Servlet) instanceManager.newInstance(ctxt.getFQCN(), ctxt.getJspLoader());
          } catch (IllegalAccessException e) {
            throw new JasperException(e);
          } catch (InstantiationException e) {
            throw new JasperException(e);
          } catch (Exception e) {
            throw new JasperException(e);
          }

          servlet.init(config);

          if (!firstTime) {
            ctxt.getRuntimeContext().incrementJspReloadCount();
          }

          theServlet = servlet;
          reload = false;
          // Volatile 'reload' forces in order write of 'theServlet' and new servlet object
        }
      }
    }
    return theServlet;
  }
Ejemplo n.º 4
0
 private boolean _jspx_meth_tags_005fpage_005f0(javax.servlet.jsp.PageContext _jspx_page_context)
     throws java.lang.Throwable {
   javax.servlet.jsp.PageContext pageContext = _jspx_page_context;
   javax.servlet.jsp.JspWriter out = _jspx_page_context.getOut();
   //  tags:page
   org.apache.jsp.tag.webpage_tag _jspx_th_tags_005fpage_005f0 =
       (new org.apache.jsp.tag.webpage_tag());
   _jsp_instancemanager.newInstance(_jspx_th_tags_005fpage_005f0);
   _jspx_th_tags_005fpage_005f0.setJspContext(_jspx_page_context);
   java.lang.String _jspx_temp0 = "User Management";
   // /User/view.jsp(6,0) null
   _jspx_th_tags_005fpage_005f0.setTitle(_jspx_temp0);
   javax.servlet.jsp.tagext.JspFragment _jspx_temp1 =
       new Helper(0, _jspx_page_context, _jspx_th_tags_005fpage_005f0, null);
   // /User/view.jsp(6,0) null
   _jspx_th_tags_005fpage_005f0.setScript(_jspx_temp1);
   _jspx_th_tags_005fpage_005f0.setJspBody(
       new Helper(1, _jspx_page_context, _jspx_th_tags_005fpage_005f0, null));
   _jspx_th_tags_005fpage_005f0.doTag();
   _jsp_instancemanager.destroyInstance(_jspx_th_tags_005fpage_005f0);
   return false;
 }
Ejemplo n.º 5
0
 private boolean _jspx_meth_sys_005fmessage_005f0(javax.servlet.jsp.PageContext _jspx_page_context)
     throws java.lang.Throwable {
   javax.servlet.jsp.PageContext pageContext = _jspx_page_context;
   javax.servlet.jsp.JspWriter out = _jspx_page_context.getOut();
   //  sys:message
   org.apache.jsp.tag.websys.message_tag _jspx_th_sys_005fmessage_005f0 =
       (new org.apache.jsp.tag.websys.message_tag());
   _jsp_instancemanager.newInstance(_jspx_th_sys_005fmessage_005f0);
   _jspx_th_sys_005fmessage_005f0.setJspContext(_jspx_page_context);
   // /WEB-INF/views/modules/sys/logList.jsp(36,1) name = content type = java.lang.String reqTime =
   // true required = true fragment = false deferredValue = false expectedTypeName =
   // java.lang.String deferredMethod = false methodSignature = null
   _jspx_th_sys_005fmessage_005f0.setContent(
       (java.lang.String)
           org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
               "${message}",
               java.lang.String.class,
               (javax.servlet.jsp.PageContext) _jspx_page_context,
               null,
               false));
   _jspx_th_sys_005fmessage_005f0.doTag();
   _jsp_instancemanager.destroyInstance(_jspx_th_sys_005fmessage_005f0);
   return false;
 }