private boolean _jspx_meth_html_xhtml_0(javax.servlet.jsp.PageContext pageContext)
     throws Throwable {
   JspWriter out = pageContext.getOut();
   /* ----  html:xhtml ---- */
   org.apache.struts.taglib.html.XhtmlTag _jspx_th_html_xhtml_0 =
       (org.apache.struts.taglib.html.XhtmlTag)
           _jspx_tagPool_html_xhtml_nobody.get(org.apache.struts.taglib.html.XhtmlTag.class);
   _jspx_th_html_xhtml_0.setPageContext(pageContext);
   _jspx_th_html_xhtml_0.setParent(null);
   int _jspx_eval_html_xhtml_0 = _jspx_th_html_xhtml_0.doStartTag();
   if (_jspx_th_html_xhtml_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_html_xhtml_nobody.reuse(_jspx_th_html_xhtml_0);
   return false;
 }
 private boolean _jspx_meth_c_url_0(javax.servlet.jsp.PageContext pageContext) throws Throwable {
   JspWriter out = pageContext.getOut();
   /* ----  c:url ---- */
   org.apache.taglibs.standard.tag.el.core.UrlTag _jspx_th_c_url_0 =
       (org.apache.taglibs.standard.tag.el.core.UrlTag)
           _jspx_tagPool_c_url_value_nobody.get(
               org.apache.taglibs.standard.tag.el.core.UrlTag.class);
   _jspx_th_c_url_0.setPageContext(pageContext);
   _jspx_th_c_url_0.setParent(null);
   _jspx_th_c_url_0.setValue("/jsp/scripts/general.js");
   int _jspx_eval_c_url_0 = _jspx_th_c_url_0.doStartTag();
   if (_jspx_th_c_url_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_c_url_value_nobody.reuse(_jspx_th_c_url_0);
   return false;
 }
 private boolean _jspx_meth_c_param_2(
     javax.servlet.jsp.tagext.Tag _jspx_th_c_import_0,
     javax.servlet.jsp.PageContext pageContext,
     int[] _jspx_push_body_count_c_import_0)
     throws Throwable {
   JspWriter out = pageContext.getOut();
   /* ----  c:param ---- */
   org.apache.taglibs.standard.tag.el.core.ParamTag _jspx_th_c_param_2 =
       (org.apache.taglibs.standard.tag.el.core.ParamTag)
           _jspx_tagPool_c_param_value_name_nobody.get(
               org.apache.taglibs.standard.tag.el.core.ParamTag.class);
   _jspx_th_c_param_2.setPageContext(pageContext);
   _jspx_th_c_param_2.setParent(_jspx_th_c_import_0);
   _jspx_th_c_param_2.setName("help");
   _jspx_th_c_param_2.setValue("monitoringadmin/license/WTHelp_License.html");
   int _jspx_eval_c_param_2 = _jspx_th_c_param_2.doStartTag();
   if (_jspx_th_c_param_2.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_c_param_value_name_nobody.reuse(_jspx_th_c_param_2);
   return false;
 }
 private boolean _jspx_meth_c_param_0(
     javax.servlet.jsp.tagext.Tag _jspx_th_c_import_0,
     javax.servlet.jsp.PageContext pageContext,
     int[] _jspx_push_body_count_c_import_0)
     throws Throwable {
   JspWriter out = pageContext.getOut();
   /* ----  c:param ---- */
   org.apache.taglibs.standard.tag.el.core.ParamTag _jspx_th_c_param_0 =
       (org.apache.taglibs.standard.tag.el.core.ParamTag)
           _jspx_tagPool_c_param_value_name_nobody.get(
               org.apache.taglibs.standard.tag.el.core.ParamTag.class);
   _jspx_th_c_param_0.setPageContext(pageContext);
   _jspx_th_c_param_0.setParent(_jspx_th_c_import_0);
   _jspx_th_c_param_0.setName("title");
   _jspx_th_c_param_0.setValue("Options & Settings - System Management - License Management");
   int _jspx_eval_c_param_0 = _jspx_th_c_param_0.doStartTag();
   if (_jspx_th_c_param_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_c_param_value_name_nobody.reuse(_jspx_th_c_param_0);
   return false;
 }
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    JspFactory _jspxFactory = null;
    javax.servlet.jsp.PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;

    try {
      _jspxFactory = JspFactory.getDefaultFactory();
      response.setContentType("text/html;charset=utf-8");
      pageContext =
          _jspxFactory.getPageContext(
              this, request, response, "/jsp/GeneralError.jsp", true, 8192, true);
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write("\n\n");
      out.write("\n");
      out.write("\n");
      out.write("\n\n");
      out.write("\n");
      out.write("\n\n");
      out.write("\n");
      java.util.Date now = null;
      synchronized (pageContext) {
        now = (java.util.Date) pageContext.getAttribute("now", PageContext.PAGE_SCOPE);
        if (now == null) {
          try {
            now =
                (java.util.Date)
                    java.beans.Beans.instantiate(
                        this.getClass().getClassLoader(), "java.util.Date");
          } catch (ClassNotFoundException exc) {
            throw new InstantiationException(exc.getMessage());
          } catch (Exception exc) {
            throw new ServletException("Cannot create bean of class " + "java.util.Date", exc);
          }
          pageContext.setAttribute("now", now, PageContext.PAGE_SCOPE);
        }
      }
      out.write("\n\n");
      out.write("\n");
      out.write("<script type=\"text/javascript\" src=\"");
      if (_jspx_meth_c_url_0(pageContext)) return;
      out.write("\">");
      out.write("</script>\n\n");
      out.write("\n");
      if (_jspx_meth_html_xhtml_0(pageContext)) return;
      out.write("\n");
      out.write("\n\n");
      out.write("\n");
      out.write("\n");
      out.write("\n\n\n\n");
      out.write("<html>\n");
      out.write("<head>\n  ");
      out.write("<title>WebTelemetry - Admin Settings | System Management | License Management");
      out.write("</title>\n  ");
      out.write("<base HREF=\"");
      out.print(org.opennms.web.Util.calculateUrlBase(request));
      out.write("\" />\n  ");
      out.write(
          "<link rel=\"stylesheet\" type=\"text/css\" href=\"/wt-portal/css/default.css\" />\n  ");
      out.write("<script type=\"text/javascript\" src=\"/wt-portal/javascript/WTtools.js\">");
      out.write("</script>\n");
      out.write("</HEAD>\n\n");
      out.write("<SCRIPT LANGUAGE=JAVASCRIPT>\nfunction checkError()\n{\n\t");
      if (request.getSession().getAttribute("thErrorMsg") != null) {
        out.write("\n\talert(\"");
        out.print(request.getSession().getAttribute("thErrorMsg"));
        out.write("\");\n    ");
        request.getSession().removeAttribute("thErrorMsg");
        out.write("\n\t");
      }
      out.write("\n\t");
      if (request.getAttribute("thErrorMsg") != null) {
        out.write("\n\talert(\"");
        out.print(request.getAttribute("thErrorMsg"));
        out.write("\");\n    ");
        request.removeAttribute("thErrorMsg");
        out.write("\n\t");
      }
      out.write("\n}\n");
      out.write("</SCRIPT>\n");
      out.write("<body onload=\"checkError();\">\n");
      /* ----  c:import ---- */
      org.apache.taglibs.standard.tag.el.core.ImportTag _jspx_th_c_import_0 =
          (org.apache.taglibs.standard.tag.el.core.ImportTag)
              _jspx_tagPool_c_import_url_context.get(
                  org.apache.taglibs.standard.tag.el.core.ImportTag.class);
      _jspx_th_c_import_0.setPageContext(pageContext);
      _jspx_th_c_import_0.setParent(null);
      _jspx_th_c_import_0.setContext("/wt-monitor");
      _jspx_th_c_import_0.setUrl("/includes/header.jsp");
      int[] _jspx_push_body_count_c_import_0 = new int[] {0};
      try {
        int _jspx_eval_c_import_0 = _jspx_th_c_import_0.doStartTag();
        if (_jspx_eval_c_import_0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
          if (_jspx_eval_c_import_0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
            javax.servlet.jsp.tagext.BodyContent _bc = pageContext.pushBody();
            _jspx_push_body_count_c_import_0[0]++;
            out = _bc;
            _jspx_th_c_import_0.setBodyContent(_bc);
            _jspx_th_c_import_0.doInitBody();
          }
          do {
            out.write("\n    ");
            if (_jspx_meth_c_param_0(
                _jspx_th_c_import_0, pageContext, _jspx_push_body_count_c_import_0)) return;
            out.write("\n    ");
            if (_jspx_meth_c_param_1(
                _jspx_th_c_import_0, pageContext, _jspx_push_body_count_c_import_0)) return;
            out.write("\n    ");
            if (_jspx_meth_c_param_2(
                _jspx_th_c_import_0, pageContext, _jspx_push_body_count_c_import_0)) return;
            out.write("\n");
            int evalDoAfterBody = _jspx_th_c_import_0.doAfterBody();
            if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
          } while (true);
          if (_jspx_eval_c_import_0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE)
            out = pageContext.popBody();
          _jspx_push_body_count_c_import_0[0]--;
        }
        if (_jspx_th_c_import_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return;
      } catch (Throwable _jspx_exception) {
        while (_jspx_push_body_count_c_import_0[0]-- > 0) out = pageContext.popBody();
        _jspx_th_c_import_0.doCatch(_jspx_exception);
      } finally {
        _jspx_th_c_import_0.doFinally();
        _jspx_tagPool_c_import_url_context.reuse(_jspx_th_c_import_0);
      }
      out.write("\n\n");

      String errorMsg = (String) request.getAttribute("error");
      if (errorMsg != null && !errorMsg.equals("")) {

        out.write("\n\n");
        out.write("<table width=\"98%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n    ");
        out.write("<tr class=\"tableHeader\">\n        ");
        out.write("<td class=\"tableHeader\">Internal Error");
        out.write("</td>\n    ");
        out.write("</tr>\n    ");
        out.write("<tr class=\"error\" >\n        ");
        out.write("<td class=\"error\">");
        out.write("<br>");
        out.print(errorMsg);
        out.write("\n        ");
        out.write("<br />");
        out.write("<br />");
        out.write("<a href=\"mailto:[email protected]\">[email protected]");
        out.write("</a>");
        out.write("<br />&nbsp;");
        out.write("</td>\n    ");
        out.write("</tr>\n");
        out.write("</table>\n");
      }
      out.write("\n\n");
      out.write("<!-- BEGIN FRAMING TABLE:open tags, keep at 100%-->\n");
      out.write("<table width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n\t");
      out.write("<tr>\n\t\t");
      out.write("<td width=\"10\">");
      out.write(
          "<img src=\"/wt-portal/images/spacers/spacer.gif\" height=\"1\" width=\"10\" border=\"0\" alt=\"WebTelemetry LLC\">");
      out.write("</td>\n\t\t");
      out.write("<td>\n");
      out.write("<!-- END FRAMING TABLE:open tags, keep at 100%-->\n\n");

      LicenseManager lim = (LicenseManager) request.getAttribute("licenseManager");
      boolean valid = false;
      boolean bIsAdmin = ((Boolean) request.getAttribute("bIsAdmin")).booleanValue();
      if (lim == null) {

        out.write("\n        ");
        out.write("<p class=\"error\">License File not found!\n        ");
        if (bIsAdmin) {
          out.write("\n            Please install a license file to run WebTelemetry.\n        ");
        } else {
          out.write(
              "\n            Please contact your System Administrator to rectify this problem.\n        ");
        }
        out.write("\n        ");
        out.write("</p>\n");

      } else {
        if (!lim.isSigValid()) {

          out.write("<p class=\"error\">License File corrupted!\n           ");
          if (bIsAdmin) {
            out.write(
                "\n                Please install a new license file to run WebTelemetry.\n           ");
          } else {
            out.write(
                "\n                Please contact your System Administrator to rectify this problem.\n           ");
          }
          out.write("\n              ");
          out.write("</p>");

        } else if (lim.daysLeft() == 0) {

          out.write("<p class=\"error\">License File expired!\n\t        ");
          if (bIsAdmin) {
            out.write(
                "\n\t            Please install a license file to run WebTelemetry.\n\t        ");
          } else {
            out.write(
                "\n\t            Please contact your System Administrator to rectify this problem.\n\t        ");
          }
          out.write("\n            ");
          out.write("</p>");

        } else {
          valid = true;
        }
      }

      out.write("\n");
      out.write("<table width=\"98%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n");
      if (bIsAdmin) {
        out.write("\n    ");
        out.write("<tr>\n\t\t");
        if (lim != null) {
          out.write("\n\t\t");
          out.write("<td colspan=\"2\" align=\"right\" valign=\"top\">\n\t\t");
        } else {
          out.write("\n\t\t");
          out.write("<td colspan=\"2\" align=\"left\" valign=\"top\">");
          out.write("<br>\n\t\t");
        }
        out.write("\n\t\t");
        out.write("<a href=\"/wt-core/license/manager.do?currentCommand=");
        out.print(WTLicenseForm.LICENSE_UPLOAD);
        out.write("\">");
        out.write(
            "<img src=\"/wt-portal/images/buttons/btn_install_license.gif\" border=\"0\" alt=\"Install a New License\" vspace=\"4\">");
        out.write("</a>\n        ");
        out.write("<a class=\"tt\" href=\"javascript:towerTip(");
        out.print(WTTips.TIP_LICENSE_UPLOAD);
        out.write(");\" title=\"Telemetry Tip\">");
        out.write("<img src=\"/wt-portal/images/icons/tower_tips.gif\" border=\"0\">");
        out.write("</a>\n&nbsp;&nbsp;\n\t\t");
        out.write("\n");
        out.write("</td>");
        out.write("</tr>\n");
      }
      out.write("\n    ");
      out.write("<tr>\n        ");
      out.write("<td colspan=\"2\">");
      out.write(
          "<img src=\"/wt-portal/images/spacers/spacer.gif\" height=\"4\" width=\"10\" border=\"0\" alt=\"WebTelemetry LLC\">");
      out.write("</td>\n    ");
      out.write("</tr>\n\n");

      if (lim != null) {
        String licStatus =
            valid ? "<span class='success'>Valid</span>" : "<span class='error'>Invalid</span>";
        String exp = lim.getFeature(License.WT_EXPIRATION_FIELD_NAME);

        int trCount = -1;

        out.write("\n\t     ");
        out.write("<tr class=\"tableHeader\">\n\t        ");
        out.write("<td class=\"tableHeader\" width=\"70%\">Attribute");
        out.write("<a class=\"tt\" href=\"javascript: towerTip(");
        out.print(WTTips.TIP_LICENSE_ATTRIBUTES);
        out.write(");\" title=\"Telemetry Tip\">");
        out.write("<img src=\"/wt-portal/images/icons/tower_tips.gif\" border=\"0\">");
        out.write("</a>");
        out.write("</td>\n\t        ");
        out.write("<td class=\"tableHeader\" width=\"30%\">Value");
        out.write("</td>\n\t    ");
        out.write("</tr>\n\n        ");
        String trColor = (++trCount % 2 == 0) ? "tableRowLight" : "tableRowDark";
        out.write("\n\t    ");
        out.write("<tr class=\"");
        out.print(trColor);
        out.write("\">\n\t        ");
        out.write("<td class=\"tableText\">Support License");
        out.write("</td>\n\t        ");
        out.write("<td class=\"tableText\">");
        out.print(licStatus);
        out.write("</td>\n\t    ");
        out.write("</tr>\n\n        ");
        trColor = (++trCount % 2 == 0) ? "tableRowLight" : "tableRowDark";
        out.write("\n\t    ");
        out.write("<tr class=\"");
        out.print(trColor);
        out.write("\">\n\t        ");
        out.write("<td class=\"tableText\">Support Licensor");
        out.write("</td>\n");
        out.write("<!-- \n\t        ");
        out.write("<td class=\"tableText\">");
        out.print(lim.getFeature(License.WT_LICENSOR_FIELD_NAME));
        out.write("</td>\n\t\t-->\n\t\t ");
        out.write("<td class=\"tableText\">WebTelemetry LLC");
        out.write("</td>\n\t    ");
        out.write("</tr>\n\n        ");
        trColor = (++trCount % 2 == 0) ? "tableRowLight" : "tableRowDark";
        out.write("\n\t    ");
        out.write("<tr class=\"");
        out.print(trColor);
        out.write("\">\n\t        ");
        out.write("<td class=\"tableText\">Support Licensee");
        out.write("</td>\n\n");
        out.write("<!--\n\t        ");
        out.write("<td class=\"tableText\">");
        out.print(lim.getFeature(License.WT_LICENSEE_FIELD_NAME));
        out.write("</td>\n-->\n\t\t ");
        out.write("<td class=\"tableText\">WebTelemetry LLC");
        out.write("</td>\n\n\t    ");
        out.write("</tr>\n\n\n");
        out.write("\n\n        ");
        trColor = (++trCount % 2 == 0) ? "tableRowLight" : "tableRowDark";
        out.write("\n\t    ");
        out.write("<tr class=\"");
        out.print(trColor);
        out.write("\">\n\t        ");
        out.write("<td class=\"tableText\">Discovery Engine");
        out.write("</td>\n\t    ");

        String safariStatus =
            (Integer.parseInt(lim.getFeature(License.WT_SAFARI_MASTER_ACCOUNT_ID_FIELD_NAME)) > 0
                    && Integer.parseInt(lim.getFeature(License.WT_SAFARI_USER_COUNT_FIELD_NAME))
                        > 0)
                ? "Enabled"
                : "Disabled";
        if (!"Disabled".equals(safariStatus)) {
          int safariDaysLeft = lim.daysLeft(License.WT_SAFARI_EXPIRATION_FIELD_NAME);
          if (safariDaysLeft == 0) safariStatus = "Expired";
        }

        out.write("\n\t        ");
        out.write("<td class=\"tableText\">");
        out.print(safariStatus);
        out.write("</td>\n\t    ");
        out.write("</tr>\n\n\t    ");

        if (!"Disabled".equals(safariStatus)) {

          out.write("\n            ");
          trColor = (++trCount % 2 == 0) ? "tableRowLight" : "tableRowDark";
          out.write("\n\t\t    ");
          out.write("<tr class=\"");
          out.print(trColor);
          out.write("\">\n\t\t        ");
          out.write("<td class=\"tableText\">Smart Discovery Expiration Date");
          out.write("</td>\n\t\t        ");
          out.write("<td class=\"tableText\">");
          out.print(lim.getFeature(License.WT_SAFARI_EXPIRATION_FIELD_NAME));
          out.write("\n\t\t    ");
          out.write("</tr>\n\t    ");
        }

        out.write("    \n");
      }

      out.write("\n");
      out.write("</table>\n\n");
      out.write("<!-- BEGIN FRAMING TABLE:close tags-->\n\t\t");
      out.write("</td>\n\t");
      out.write("</tr>\n");
      out.write("</table>\n");
      out.write("<!-- END FRAMING TABLE:close tags-->\n");
      out.write("<br>\n\n");
      JspRuntimeLibrary.include(
          request,
          response,
          "../includes/footer.jsp"
              + "?"
              + "location="
              + "admin"
              + "&"
              + "help="
              + "WTHelp_License.html",
          out,
          false);
      out.write("\n\n  ");
      out.write("</BODY>\n ");
      out.write("<!-- end list-organiztion.jsp -->\n");
      out.write("</HTML>\n");
    } catch (Throwable t) {
      out = _jspx_out;
      if (out != null && out.getBufferSize() != 0) out.clearBuffer();
      if (pageContext != null) pageContext.handlePageException(t);
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(pageContext);
    }
  }
 public void _jspDestroy() {
   _jspx_tagPool_c_url_value_nobody.release();
   _jspx_tagPool_html_xhtml_nobody.release();
   _jspx_tagPool_c_import_url_context.release();
   _jspx_tagPool_c_param_value_name_nobody.release();
 }