コード例 #1
0
 public void doTag() throws JspException, IOException {
   PageContext pageContext = (PageContext) getJspContext();
   Locale locale = I18nUtil.findLocale(pageContext);
   if (this.var == null) {
     pageContext.getOut().print(String.valueOf(locale));
   } else {
     pageContext.setAttribute(this.var, locale, this.scope);
   }
 }
コード例 #2
0
 private boolean _jspx_meth_s_005fform_005f0(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  s:form
   org.apache.struts2.views.jsp.ui.FormTag _jspx_th_s_005fform_005f0 =
       (org.apache.struts2.views.jsp.ui.FormTag)
           _005fjspx_005ftagPool_005fs_005fform_005ftheme_005fmethod_005fenctype_005faction.get(
               org.apache.struts2.views.jsp.ui.FormTag.class);
   _jspx_th_s_005fform_005f0.setPageContext(_jspx_page_context);
   _jspx_th_s_005fform_005f0.setParent(null);
   // /mr/main/receivedImport.jsp(69,4) name = action type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fform_005f0.setAction("/web/received-import!importRecved");
   // /mr/main/receivedImport.jsp(69,4) name = method type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fform_005f0.setMethod("post");
   // /mr/main/receivedImport.jsp(69,4) name = theme type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fform_005f0.setTheme("simple");
   // /mr/main/receivedImport.jsp(69,4) name = enctype type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fform_005f0.setEnctype("multipart/form-data");
   int _jspx_eval_s_005fform_005f0 = _jspx_th_s_005fform_005f0.doStartTag();
   if (_jspx_eval_s_005fform_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
     if (_jspx_eval_s_005fform_005f0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
       out = _jspx_page_context.pushBody();
       _jspx_th_s_005fform_005f0.setBodyContent((javax.servlet.jsp.tagext.BodyContent) out);
       _jspx_th_s_005fform_005f0.doInitBody();
     }
     do {
       out.write("\r\n");
       out.write("    \t\r\n");
       out.write("    \t");
       if (_jspx_meth_s_005ffile_005f0(_jspx_th_s_005fform_005f0, _jspx_page_context)) return true;
       out.write("\r\n");
       out.write("    \t<input type=\"button\" value=\"导入\" onclick=\"importRcved()\"/>\r\n");
       out.write("    ");
       int evalDoAfterBody = _jspx_th_s_005fform_005f0.doAfterBody();
       if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
     } while (true);
     if (_jspx_eval_s_005fform_005f0 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
       out = _jspx_page_context.popBody();
     }
   }
   if (_jspx_th_s_005fform_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fs_005fform_005ftheme_005fmethod_005fenctype_005faction.reuse(
         _jspx_th_s_005fform_005f0);
     return true;
   }
   _005fjspx_005ftagPool_005fs_005fform_005ftheme_005fmethod_005fenctype_005faction.reuse(
       _jspx_th_s_005fform_005f0);
   return false;
 }
コード例 #3
0
 private boolean _jspx_meth_ec_005fcolumn_005f0(
     javax.servlet.jsp.tagext.JspTag _jspx_th_ec_005frow_005f0,
     PageContext _jspx_page_context,
     int[] _jspx_push_body_count_ec_005frow_005f0)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  ec:column
   org.ecside.tag.ColumnTag _jspx_th_ec_005fcolumn_005f0 =
       (org.ecside.tag.ColumnTag)
           _005fjspx_005ftagPool_005fec_005fcolumn_005fvalue_005ftitle_005fproperty_005fnobody.get(
               org.ecside.tag.ColumnTag.class);
   _jspx_th_ec_005fcolumn_005f0.setPageContext(_jspx_page_context);
   _jspx_th_ec_005fcolumn_005f0.setParent(
       (javax.servlet.jsp.tagext.Tag) _jspx_th_ec_005frow_005f0);
   // /mr/main/receivedImport.jsp(91,4) name = property type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f0.setProperty("_0");
   // /mr/main/receivedImport.jsp(91,4) name = title type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f0.setTitle("序号");
   // /mr/main/receivedImport.jsp(91,4) name = value type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f0.setValue(
       (java.lang.Object)
           org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
               "${GLOBALROWCOUNT}",
               java.lang.Object.class,
               (PageContext) _jspx_page_context,
               null,
               false));
   int[] _jspx_push_body_count_ec_005fcolumn_005f0 = new int[] {0};
   try {
     int _jspx_eval_ec_005fcolumn_005f0 = _jspx_th_ec_005fcolumn_005f0.doStartTag();
     if (_jspx_th_ec_005fcolumn_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
       return true;
     }
   } catch (Throwable _jspx_exception) {
     while (_jspx_push_body_count_ec_005fcolumn_005f0[0]-- > 0) out = _jspx_page_context.popBody();
     _jspx_th_ec_005fcolumn_005f0.doCatch(_jspx_exception);
   } finally {
     _jspx_th_ec_005fcolumn_005f0.doFinally();
     _005fjspx_005ftagPool_005fec_005fcolumn_005fvalue_005ftitle_005fproperty_005fnobody.reuse(
         _jspx_th_ec_005fcolumn_005f0);
   }
   return false;
 }
コード例 #4
0
 private boolean _jspx_meth_s_005ffile_005f0(
     javax.servlet.jsp.tagext.JspTag _jspx_th_s_005fform_005f0, PageContext _jspx_page_context)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  s:file
   org.apache.struts2.views.jsp.ui.FileTag _jspx_th_s_005ffile_005f0 =
       (org.apache.struts2.views.jsp.ui.FileTag)
           _005fjspx_005ftagPool_005fs_005ffile_005fname_005fid_005fnobody.get(
               org.apache.struts2.views.jsp.ui.FileTag.class);
   _jspx_th_s_005ffile_005f0.setPageContext(_jspx_page_context);
   _jspx_th_s_005ffile_005f0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_s_005fform_005f0);
   // /mr/main/receivedImport.jsp(71,5) name = id type = java.lang.String reqTime = false required
   // = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_s_005ffile_005f0.setId("file");
   // /mr/main/receivedImport.jsp(71,5) name = name type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005ffile_005f0.setName("file");
   int _jspx_eval_s_005ffile_005f0 = _jspx_th_s_005ffile_005f0.doStartTag();
   if (_jspx_th_s_005ffile_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fs_005ffile_005fname_005fid_005fnobody.reuse(
         _jspx_th_s_005ffile_005f0);
     return true;
   }
   _005fjspx_005ftagPool_005fs_005ffile_005fname_005fid_005fnobody.reuse(
       _jspx_th_s_005ffile_005f0);
   return false;
 }
コード例 #5
0
 private boolean _jspx_meth_c_005fset_005f2(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  c:set
   org.apache.taglibs.standard.tag.rt.core.SetTag _jspx_th_c_005fset_005f2 =
       (org.apache.taglibs.standard.tag.rt.core.SetTag)
           _005fjspx_005ftagPool_005fc_005fset_0026_005fvar_005fvalue_005fnobody.get(
               org.apache.taglibs.standard.tag.rt.core.SetTag.class);
   _jspx_th_c_005fset_005f2.setPageContext(_jspx_page_context);
   _jspx_th_c_005fset_005f2.setParent(null);
   // /web/page/common/taglib.jsp(15,0) name = var type = java.lang.String reqTime = false required
   // = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_c_005fset_005f2.setVar("vs");
   // /web/page/common/taglib.jsp(15,0) name = value type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_c_005fset_005f2.setValue(
       (java.lang.Object)
           org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
               "${sysConfig.jsCssVersion}",
               java.lang.Object.class,
               (PageContext) _jspx_page_context,
               null,
               false));
   int _jspx_eval_c_005fset_005f2 = _jspx_th_c_005fset_005f2.doStartTag();
   if (_jspx_th_c_005fset_005f2.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fc_005fset_0026_005fvar_005fvalue_005fnobody.reuse(
         _jspx_th_c_005fset_005f2);
     return true;
   }
   _005fjspx_005ftagPool_005fc_005fset_0026_005fvar_005fvalue_005fnobody.reuse(
       _jspx_th_c_005fset_005f2);
   return false;
 }
コード例 #6
0
ファイル: updateUser_jsp.java プロジェクト: qq494679975/house
 private boolean _jspx_meth_s_005fselect_005f0(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  s:select
   org.apache.struts2.views.jsp.ui.SelectTag _jspx_th_s_005fselect_005f0 =
       (org.apache.struts2.views.jsp.ui.SelectTag)
           _005fjspx_005ftagPool_005fs_005fselect_0026_005fvalue_005fname_005flist_005fnobody.get(
               org.apache.struts2.views.jsp.ui.SelectTag.class);
   _jspx_th_s_005fselect_005f0.setPageContext(_jspx_page_context);
   _jspx_th_s_005fselect_005f0.setParent(null);
   // /main/systemjsp/updateUser.jsp(23,5) name = list type = java.lang.String reqTime = false
   // required = true fragment = false deferredValue = false expectedTypeName = null deferredMethod
   // = false methodSignature = null
   _jspx_th_s_005fselect_005f0.setList("familytype");
   // /main/systemjsp/updateUser.jsp(23,5) name = name type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fselect_005f0.setName("uifamilytype");
   // /main/systemjsp/updateUser.jsp(23,5) name = value type = java.lang.String reqTime = false
   // required = false fragment = false deferredValue = false expectedTypeName = null
   // deferredMethod = false methodSignature = null
   _jspx_th_s_005fselect_005f0.setValue("%{model.uifamilytype}");
   int _jspx_eval_s_005fselect_005f0 = _jspx_th_s_005fselect_005f0.doStartTag();
   if (_jspx_th_s_005fselect_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fs_005fselect_0026_005fvalue_005fname_005flist_005fnobody.reuse(
         _jspx_th_s_005fselect_005f0);
     return true;
   }
   _005fjspx_005ftagPool_005fs_005fselect_0026_005fvalue_005fname_005flist_005fnobody.reuse(
       _jspx_th_s_005fselect_005f0);
   return false;
 }
コード例 #7
0
ファイル: WebChartJSPTag.java プロジェクト: no2key/WebChart
  public String getAbsolutePath(String url) {
    int pos;
    if (url == null) return null;
    if (url.startsWith("/")) return url;
    HttpServletRequest request = (HttpServletRequest) (pageContext.getRequest());

    pos = request.getServletPath().lastIndexOf("/");
    return request.getServletPath().substring(0, pos + 1) + url;
  }
コード例 #8
0
 private boolean _jspx_meth_ec_005fcolumn_005f3(
     javax.servlet.jsp.tagext.JspTag _jspx_th_ec_005frow_005f0,
     PageContext _jspx_page_context,
     int[] _jspx_push_body_count_ec_005frow_005f0)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  ec:column
   org.ecside.tag.ColumnTag _jspx_th_ec_005fcolumn_005f3 =
       (org.ecside.tag.ColumnTag)
           _005fjspx_005ftagPool_005fec_005fcolumn_005ftitle_005fsortable_005fproperty_005fnobody
               .get(org.ecside.tag.ColumnTag.class);
   _jspx_th_ec_005fcolumn_005f3.setPageContext(_jspx_page_context);
   _jspx_th_ec_005fcolumn_005f3.setParent(
       (javax.servlet.jsp.tagext.Tag) _jspx_th_ec_005frow_005f0);
   // /mr/main/receivedImport.jsp(94,4) name = title type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f3.setTitle("收入(金额)");
   // /mr/main/receivedImport.jsp(94,4) name = property type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f3.setProperty("receivedAmount");
   // /mr/main/receivedImport.jsp(94,4) name = sortable type = null reqTime = true required = false
   // fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_ec_005fcolumn_005f3.setSortable("true");
   int[] _jspx_push_body_count_ec_005fcolumn_005f3 = new int[] {0};
   try {
     int _jspx_eval_ec_005fcolumn_005f3 = _jspx_th_ec_005fcolumn_005f3.doStartTag();
     if (_jspx_th_ec_005fcolumn_005f3.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
       return true;
     }
   } catch (Throwable _jspx_exception) {
     while (_jspx_push_body_count_ec_005fcolumn_005f3[0]-- > 0) out = _jspx_page_context.popBody();
     _jspx_th_ec_005fcolumn_005f3.doCatch(_jspx_exception);
   } finally {
     _jspx_th_ec_005fcolumn_005f3.doFinally();
     _005fjspx_005ftagPool_005fec_005fcolumn_005ftitle_005fsortable_005fproperty_005fnobody.reuse(
         _jspx_th_ec_005fcolumn_005f3);
   }
   return false;
 }
コード例 #9
0
 private boolean _jspx_meth_c_005fif_005f0(
     javax.servlet.jsp.tagext.JspTag _jspx_th_c_005fforEach_005f0,
     PageContext _jspx_page_context,
     int[] _jspx_push_body_count_c_005fforEach_005f0)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  c:if
   org.apache.taglibs.standard.tag.rt.core.IfTag _jspx_th_c_005fif_005f0 =
       (org.apache.taglibs.standard.tag.rt.core.IfTag)
           _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.get(
               org.apache.taglibs.standard.tag.rt.core.IfTag.class);
   _jspx_th_c_005fif_005f0.setPageContext(_jspx_page_context);
   _jspx_th_c_005fif_005f0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_c_005fforEach_005f0);
   // /web/page/fans/fansListCtx.jsp(28,7) name = test type = boolean reqTime = true required =
   // true fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_c_005fif_005f0.setTest(
       ((java.lang.Boolean)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${not empty fan.headImgUrl}",
                   java.lang.Boolean.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false))
           .booleanValue());
   int _jspx_eval_c_005fif_005f0 = _jspx_th_c_005fif_005f0.doStartTag();
   if (_jspx_eval_c_005fif_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
     do {
       out.write("\r\n");
       out.write("\t\t\t\t\t\t\t\t<img src=\"");
       out.write(
           (java.lang.String)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${empty fan.headImgUrl ?'-':fan.headImgUrl}",
                   java.lang.String.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false));
       out.write("\" width=\"30\" height=\"30\">\r\n");
       out.write("\t\t\t\t\t\t\t");
       int evalDoAfterBody = _jspx_th_c_005fif_005f0.doAfterBody();
       if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
     } while (true);
   }
   if (_jspx_th_c_005fif_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f0);
     return true;
   }
   _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f0);
   return false;
 }
コード例 #10
0
 private boolean _jspx_meth_c_005fif_005f3(
     javax.servlet.jsp.tagext.JspTag _jspx_th_c_005fforEach_005f2,
     PageContext _jspx_page_context,
     int[] _jspx_push_body_count_c_005fforEach_005f2)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  c:if
   org.apache.taglibs.standard.tag.rt.core.IfTag _jspx_th_c_005fif_005f3 =
       (org.apache.taglibs.standard.tag.rt.core.IfTag)
           _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.get(
               org.apache.taglibs.standard.tag.rt.core.IfTag.class);
   _jspx_th_c_005fif_005f3.setPageContext(_jspx_page_context);
   _jspx_th_c_005fif_005f3.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_c_005fforEach_005f2);
   // /web/page/workbench/myTemplate.jsp(42,6) name = test type = boolean reqTime = true required =
   // true fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_c_005fif_005f3.setTest(
       ((java.lang.Boolean)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${status.index!=0 }",
                   java.lang.Boolean.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false))
           .booleanValue());
   int _jspx_eval_c_005fif_005f3 = _jspx_th_c_005fif_005f3.doStartTag();
   if (_jspx_eval_c_005fif_005f3 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
     do {
       out.write("\r\n");
       out.write("\t\t\t\t\t\t\t/ ");
       out.write(
           (java.lang.String)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${tag.tagName}",
                   java.lang.String.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false));
       out.write("\r\n");
       out.write("\t\t\t\t\t\t");
       int evalDoAfterBody = _jspx_th_c_005fif_005f3.doAfterBody();
       if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
     } while (true);
   }
   if (_jspx_th_c_005fif_005f3.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f3);
     return true;
   }
   _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f3);
   return false;
 }
コード例 #11
0
ファイル: WebChartJSPTag.java プロジェクト: no2key/WebChart
 public String getClientIPAddr() {
   HttpServletRequest request = (HttpServletRequest) (pageContext.getRequest());
   String remoteAddr = request.getRemoteAddr();
   String x;
   if ((x = request.getHeader("X-FORWARDED-FOR")) != null) {
     remoteAddr = x;
     int idx = remoteAddr.indexOf(',');
     if (idx > -1) {
       remoteAddr = remoteAddr.substring(0, idx);
     }
   }
   return remoteAddr;
 }
コード例 #12
0
 private boolean _jspx_meth_c_005fif_005f6(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  c:if
   org.apache.taglibs.standard.tag.rt.core.IfTag _jspx_th_c_005fif_005f6 =
       (org.apache.taglibs.standard.tag.rt.core.IfTag)
           _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.get(
               org.apache.taglibs.standard.tag.rt.core.IfTag.class);
   _jspx_th_c_005fif_005f6.setPageContext(_jspx_page_context);
   _jspx_th_c_005fif_005f6.setParent(null);
   // /web/page/workbench/myTemplate.jsp(63,0) name = test type = boolean reqTime = true required =
   // true fragment = false deferredValue = false expectedTypeName = null deferredMethod = false
   // methodSignature = null
   _jspx_th_c_005fif_005f6.setTest(
       ((java.lang.Boolean)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${pageInfo.pageSize>1 && pageInfo.pageSize>pageInfo.curPage}",
                   java.lang.Boolean.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false))
           .booleanValue());
   int _jspx_eval_c_005fif_005f6 = _jspx_th_c_005fif_005f6.doStartTag();
   if (_jspx_eval_c_005fif_005f6 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
     do {
       out.write("\r\n");
       out.write("\t<div id=\"pageDiv\">\r\n");
       out.write("\t\t<input id=\"curPage\" name=\"curPage\" type=\"hidden\" value=\"");
       out.write(
           (java.lang.String)
               org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
                   "${pageInfo.curPage }",
                   java.lang.String.class,
                   (PageContext) _jspx_page_context,
                   null,
                   false));
       out.write("\">\r\n");
       out.write(
           "\t\t<div class=\"templet-more\"><a href=\"javascript:void(0);\" id=\"loadMore\">查看更多</a></div>\r\n");
       out.write("\t</div>\r\n");
       int evalDoAfterBody = _jspx_th_c_005fif_005f6.doAfterBody();
       if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
     } while (true);
   }
   if (_jspx_th_c_005fif_005f6.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f6);
     return true;
   }
   _005fjspx_005ftagPool_005fc_005fif_0026_005ftest.reuse(_jspx_th_c_005fif_005f6);
   return false;
 }
コード例 #13
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;
    PageContext _jspx_page_context = null;

    try {
      response.setContentType("text/html; charset=UTF-8");
      pageContext = _jspxFactory.getPageContext(this, request, response, null, true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;
      _jspx_resourceInjector =
          (org.apache.jasper.runtime.ResourceInjector)
              application.getAttribute("com.sun.appserv.jsp.resource.injector");

      out.write('\n');
      out.write('\n');
      out.write("\n<!DOCTYPE html>\n<html>\n<head>\n");
      JspHelper.createTitle(out, request, request.getParameter("filename"));
      out.write("\n</head>\n<body onload=\"document.goto.dir.focus()\">\n");

      Configuration conf = (Configuration) getServletContext().getAttribute(JspHelper.CURRENT_CONF);
      generateFileChunks(out, request, conf);

      out.write("\n<hr>\n");

      generateFileDetails(out, request, conf);

      out.write("\n\n<h2>Local logs</h2>\n<a href=\"/logs/\">Log</a> directory\n\n");

      out.println(ServletUtil.htmlFooter());

      out.write('\n');
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #14
0
  public void handlePageBody(PageContext pc) throws ServletException, IOException {
    ServletContext context = pc.getServletContext();
    Document doc = null;
    try {
      DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
      DocumentBuilder builder = factory.newDocumentBuilder();
      doc = builder.newDocument();
    } catch (Exception e) {
      throw new ServletException(e);
    }

    Element rootElem = doc.createElement("xaf");
    doc.appendChild(rootElem);

    try {
      DatabaseContextFactory.createCatalog(pc, rootElem);
      transform(pc, doc, ACE_CONFIG_ITEM_PROPBROWSERXSL);
    } catch (NamingException e) {
      PrintWriter out = pc.getResponse().getWriter();
      out.write(e.toString());
      e.printStackTrace(out);
    }
  }
コード例 #15
0
 private boolean _jspx_meth_fmt_message_2(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  fmt:message
   org.apache.taglibs.standard.tag.rt.fmt.MessageTag _jspx_th_fmt_message_2 =
       (org.apache.taglibs.standard.tag.rt.fmt.MessageTag)
           _jspx_tagPool_fmt_message_key.get(
               org.apache.taglibs.standard.tag.rt.fmt.MessageTag.class);
   _jspx_th_fmt_message_2.setPageContext(_jspx_page_context);
   _jspx_th_fmt_message_2.setParent(null);
   _jspx_th_fmt_message_2.setKey("system.emailtest.no_host");
   int _jspx_eval_fmt_message_2 = _jspx_th_fmt_message_2.doStartTag();
   if (_jspx_eval_fmt_message_2 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
     if (_jspx_eval_fmt_message_2 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
       out = _jspx_page_context.pushBody();
       _jspx_th_fmt_message_2.setBodyContent((javax.servlet.jsp.tagext.BodyContent) out);
       _jspx_th_fmt_message_2.doInitBody();
     }
     do {
       out.write("\n\t\t\t\t    ");
       if (_jspx_meth_fmt_param_0(_jspx_th_fmt_message_2, _jspx_page_context)) return true;
       out.write("\n\t\t\t\t    ");
       if (_jspx_meth_fmt_param_1(_jspx_th_fmt_message_2, _jspx_page_context)) return true;
       out.write("\n\t\t\t\t");
       int evalDoAfterBody = _jspx_th_fmt_message_2.doAfterBody();
       if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
     } while (true);
     if (_jspx_eval_fmt_message_2 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE)
       out = _jspx_page_context.popBody();
   }
   if (_jspx_th_fmt_message_2.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _jspx_tagPool_fmt_message_key.reuse(_jspx_th_fmt_message_2);
     return true;
   }
   _jspx_tagPool_fmt_message_key.reuse(_jspx_th_fmt_message_2);
   return false;
 }
コード例 #16
0
 private boolean _jspx_meth_bean_message_1(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  bean:message
   org.apache.struts.taglib.bean.MessageTag _jspx_th_bean_message_1 =
       (org.apache.struts.taglib.bean.MessageTag)
           _jspx_tagPool_bean_message_key_nobody.get(
               org.apache.struts.taglib.bean.MessageTag.class);
   _jspx_th_bean_message_1.setPageContext(_jspx_page_context);
   _jspx_th_bean_message_1.setParent(null);
   _jspx_th_bean_message_1.setKey("result.emptyResultSet");
   int _jspx_eval_bean_message_1 = _jspx_th_bean_message_1.doStartTag();
   if (_jspx_th_bean_message_1.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_bean_message_key_nobody.reuse(_jspx_th_bean_message_1);
   return false;
 }
コード例 #17
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

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

      out.write('\n');
      out.write('\n');
      out.write("\n\n\n\n<html>\n<head>\n");
      JspHelper.createTitle(out, request, request.getParameter("filename"));
      out.write("\n</head>\n<body>\n<form action=\"/tail.jsp\" method=\"GET\">\n");

      generateFileChunks(out, request);

      out.write("\n</form>\n<hr>\n\n<h2>Local logs</h2>\n<a href=\"/logs/\">Log</a> directory\n\n");

      out.println(ServletUtil.htmlFooter());

      out.write('\n');
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #18
0
 private boolean _jspx_meth_html_hidden_0(
     javax.servlet.jsp.tagext.JspTag _jspx_th_html_form_0, PageContext _jspx_page_context)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  html:hidden
   org.apache.struts.taglib.html.HiddenTag _jspx_th_html_hidden_0 =
       (org.apache.struts.taglib.html.HiddenTag)
           _jspx_tagPool_html_hidden_property_nobody.get(
               org.apache.struts.taglib.html.HiddenTag.class);
   _jspx_th_html_hidden_0.setPageContext(_jspx_page_context);
   _jspx_th_html_hidden_0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_html_form_0);
   _jspx_th_html_hidden_0.setProperty("crtPage");
   int _jspx_eval_html_hidden_0 = _jspx_th_html_hidden_0.doStartTag();
   if (_jspx_th_html_hidden_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_html_hidden_property_nobody.reuse(_jspx_th_html_hidden_0);
   return false;
 }
コード例 #19
0
 private boolean _jspx_meth_bean_message_2(
     javax.servlet.jsp.tagext.JspTag _jspx_th_html_form_0, PageContext _jspx_page_context)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  bean:message
   org.apache.struts.taglib.bean.MessageTag _jspx_th_bean_message_2 =
       (org.apache.struts.taglib.bean.MessageTag)
           _jspx_tagPool_bean_message_key_nobody.get(
               org.apache.struts.taglib.bean.MessageTag.class);
   _jspx_th_bean_message_2.setPageContext(_jspx_page_context);
   _jspx_th_bean_message_2.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_html_form_0);
   _jspx_th_bean_message_2.setKey("result.rowsPerPage");
   int _jspx_eval_bean_message_2 = _jspx_th_bean_message_2.doStartTag();
   if (_jspx_th_bean_message_2.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) return true;
   _jspx_tagPool_bean_message_key_nobody.reuse(_jspx_th_bean_message_2);
   return false;
 }
コード例 #20
0
 private boolean _jspx_meth_fmt_message_5(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  fmt:message
   org.apache.taglibs.standard.tag.rt.fmt.MessageTag _jspx_th_fmt_message_5 =
       (org.apache.taglibs.standard.tag.rt.fmt.MessageTag)
           _jspx_tagPool_fmt_message_key_nobody.get(
               org.apache.taglibs.standard.tag.rt.fmt.MessageTag.class);
   _jspx_th_fmt_message_5.setPageContext(_jspx_page_context);
   _jspx_th_fmt_message_5.setParent(null);
   _jspx_th_fmt_message_5.setKey("archive.converations.no_conversations");
   int _jspx_eval_fmt_message_5 = _jspx_th_fmt_message_5.doStartTag();
   if (_jspx_th_fmt_message_5.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _jspx_tagPool_fmt_message_key_nobody.reuse(_jspx_th_fmt_message_5);
     return true;
   }
   _jspx_tagPool_fmt_message_key_nobody.reuse(_jspx_th_fmt_message_5);
   return false;
 }
コード例 #21
0
 private boolean _jspx_meth_fmt_message_14(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  fmt:message
   org.apache.taglibs.standard.tag.rt.fmt.MessageTag _jspx_th_fmt_message_14 =
       (org.apache.taglibs.standard.tag.rt.fmt.MessageTag)
           _jspx_tagPool_fmt_message_key_nobody.get(
               org.apache.taglibs.standard.tag.rt.fmt.MessageTag.class);
   _jspx_th_fmt_message_14.setPageContext(_jspx_page_context);
   _jspx_th_fmt_message_14.setParent(null);
   _jspx_th_fmt_message_14.setKey("system.emailtest.cancel");
   int _jspx_eval_fmt_message_14 = _jspx_th_fmt_message_14.doStartTag();
   if (_jspx_th_fmt_message_14.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _jspx_tagPool_fmt_message_key_nobody.reuse(_jspx_th_fmt_message_14);
     return true;
   }
   _jspx_tagPool_fmt_message_key_nobody.reuse(_jspx_th_fmt_message_14);
   return false;
 }
コード例 #22
0
 private boolean _jspx_meth_fmt_param_1(
     javax.servlet.jsp.tagext.JspTag _jspx_th_fmt_message_2, PageContext _jspx_page_context)
     throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  fmt:param
   org.apache.taglibs.standard.tag.rt.fmt.ParamTag _jspx_th_fmt_param_1 =
       (org.apache.taglibs.standard.tag.rt.fmt.ParamTag)
           _jspx_tagPool_fmt_param_value_nobody.get(
               org.apache.taglibs.standard.tag.rt.fmt.ParamTag.class);
   _jspx_th_fmt_param_1.setPageContext(_jspx_page_context);
   _jspx_th_fmt_param_1.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_fmt_message_2);
   _jspx_th_fmt_param_1.setValue(new String("</a>"));
   int _jspx_eval_fmt_param_1 = _jspx_th_fmt_param_1.doStartTag();
   if (_jspx_th_fmt_param_1.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_1);
     return true;
   }
   _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_1);
   return false;
 }
コード例 #23
0
ファイル: hello_jsp.java プロジェクト: 360keke/peds
 private boolean _jspx_meth_c_out_0(PageContext _jspx_page_context) throws Throwable {
   PageContext pageContext = _jspx_page_context;
   JspWriter out = _jspx_page_context.getOut();
   //  c:out
   org.apache.taglibs.standard.tag.rt.core.OutTag _jspx_th_c_out_0 =
       (org.apache.taglibs.standard.tag.rt.core.OutTag)
           _jspx_tagPool_c_out_value_nobody.get(
               org.apache.taglibs.standard.tag.rt.core.OutTag.class);
   _jspx_th_c_out_0.setPageContext(_jspx_page_context);
   _jspx_th_c_out_0.setParent(null);
   _jspx_th_c_out_0.setValue(
       (java.lang.Object)
           org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(
               "${now}", java.lang.Object.class, (PageContext) _jspx_page_context, null, false));
   int _jspx_eval_c_out_0 = _jspx_th_c_out_0.doStartTag();
   if (_jspx_th_c_out_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
     _jspx_tagPool_c_out_value_nobody.reuse(_jspx_th_c_out_0);
     return true;
   }
   _jspx_tagPool_c_out_value_nobody.reuse(_jspx_th_c_out_0);
   return false;
 }
コード例 #24
0
ファイル: extension_jsp.java プロジェクト: vanjakom/base
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

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

      out.write(
          "<!--\n Licensed to Cloudera, Inc. under one\n or more contributor license agreements.  See the NOTICE file\n distributed with this work for additional information\n regarding copyright ownership.  Cloudera, Inc. licenses this file\n to you under the Apache License, Version 2.0 (the\n \"License\"); you may not use this file except in compliance\n with the License.  You may obtain a copy of the License at\n\n     http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n-->\n<html><head>\n<!-- Copyright (c) 2010 Cloudera, Inc.  All rights reserved. -->\n<!-- Retro web 1.0 flume Agent configuration display -->\n\n<title>Flume Node: ");
      out.print(FlumeNode.getInstance().getPhysicalNodeName());
      out.write(
          " :: Sources and Sinks</title>\n\n<link rel=\"stylesheet\" type=\"text/css\" href=\"/flume.css\" />\n\n</head>\n<body>\n");
      org.apache.jasper.runtime.JspRuntimeLibrary.include(
          request, response, "menu_agent.jsp", out, false);
      out.write("\n\n<h1>Flume Node: ");
      out.print(FlumeNode.getInstance().getPhysicalNodeName());
      out.write(" :: Extensions - Sink/Source/Decorator</h1>\n\n");
      org.apache.jasper.runtime.JspRuntimeLibrary.include(
          request, response, "version.jsp", out, false);
      out.write("\n<hr>\n\n\n<div id=\"sinks\">\n<h2>Sinks</h2>\n\n<table>\n\n");

      // treeset so that the list is sorted
      for (String n : new TreeSet<String>(FlumeBuilder.getSinkNames())) {

        out.write("\n    <tr><td>");
        out.print(n);
        out.write("</td></tr>\n");
      }

      out.write("\n\n</table>\n</div>\n\n<div id=\"sources\">\n<h2>Sources</h2>\n<table>\n\n");

      // treeset so that the list is sorted
      for (String n : new TreeSet<String>(FlumeBuilder.getSourceNames())) {

        out.write("\n    <tr><td>");
        out.print(n);
        out.write("</td></tr>\n");
      }

      out.write("\n\n</table>\n</div>\n\n<div id=\"decos\">\n<h2>Decorators</h2>\n<table>\n\n");

      // treeset so that the list is sorted
      for (String n : new TreeSet<String>(FlumeBuilder.getDecoratorNames())) {

        out.write("\n    <tr><td>");
        out.print(n);
        out.write("</td></tr>\n");
      }

      out.write("\n\n</table>\n</div>\n</body></html>\n");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #25
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

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

      out.write("\r\n\r\n\r\n\r\n\r\n");

      PresencePlugin plugin =
          (PresencePlugin) XMPPServer.getInstance().getPluginManager().getPlugin("presence");

      // Get parameters
      boolean save = request.getParameter("save") != null;
      boolean success = request.getParameter("success") != null;
      boolean presencePublic = ParamUtils.getBooleanParameter(request, "presencePublic");
      String unavailableStatus =
          ParamUtils.getParameter(request, "presenceUnavailableStatus", false);
      if (unavailableStatus == null) {
        unavailableStatus = plugin.getUnavailableStatus();
      }

      // Handle a save
      if (save) {
        plugin.setPresencePublic(presencePublic);
        plugin.setUnavailableStatus(unavailableStatus);
        response.sendRedirect("presence-service.jsp?success=true");
        return;
      }

      presencePublic = plugin.isPresencePublic();

      out.write(
          "\r\n\r\n<html>\r\n    <head>\r\n        <title>Presence Service</title>\r\n        <meta name=\"pageID\" content=\"presence-service\"/>\r\n    </head>\r\n    <body>\r\n\r\n<div class=\"information\">\r\n    ");

      String serverName = XMPPServer.getInstance().getServerInfo().getXMPPDomain();
      int port = JiveGlobals.getXMLProperty("adminConsole.port", -1);
      int securePort = JiveGlobals.getXMLProperty("adminConsole.securePort", -1);
      boolean secureOnly = (port == -1);

      out.write("\r\n\r\n    Presence Service URL:<br>\r\n    <tt>");
      out.print(secureOnly ? "https" : "http");
      out.write(':');
      out.write('/');
      out.write('/');
      out.print(serverName);
      out.write(':');
      out.print(secureOnly ? securePort : port);
      out.write("/plugins/presence/status</tt>\r\n    <br><br>\r\n    Example:<br>\r\n    <tt>");
      out.print(secureOnly ? "https" : "http");
      out.write(':');
      out.write('/');
      out.write('/');
      out.print(serverName);
      out.write(':');
      out.print(secureOnly ? securePort : port);
      out.write("/plugins/presence/status?jid=admin@");
      out.print(serverName);
      out.write(
          "</tt>  \r\n\r\n\r\n</div>\r\n\r\n<p>\r\nUse the form below to configure user presence visibility. By default, user\r\npresence should only be visible to those users that are authorized.<br>\r\n</p>\r\n\r\n");
      if (success) {
        out.write(
            "\r\n\r\n    <div class=\"jive-success\">\r\n    <table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\r\n    <tbody>\r\n        <tr><td class=\"jive-icon\"><img src=\"images/success-16x16.gif\" width=\"16\" height=\"16\" border=\"0\"></td>\r\n        <td class=\"jive-icon-label\">\r\n            Presence service properties edited successfully.\r\n        </td></tr>\r\n    </tbody>\r\n    </table>\r\n    </div><br>\r\n");
      }
      out.write(
          "\r\n\r\n<form action=\"presence-service.jsp?save\" method=\"post\">\r\n\r\n<fieldset>\r\n    <legend>Presence visibility</legend>\r\n    <div>\r\n    <p>\r\n    For security reasons, users control which users are authorized to see their presence. However,\r\n    it is posible to configure the service so that anyone has access to all presence information.\r\n    Use this option with caution.\r\n    </p>\r\n    <table cellpadding=\"3\" cellspacing=\"0\" border=\"0\" width=\"100%\">\r\n    <tbody>\r\n        <tr>\r\n            <td width=\"1%\">\r\n            <input type=\"radio\" name=\"presencePublic\" value=\"true\" id=\"rb01\"\r\n             ");
      out.print(((presencePublic) ? "checked" : ""));
      out.write(
          ">\r\n            </td>\r\n            <td width=\"99%\">\r\n                <label for=\"rb01\"><b>Anyone</b> - Anyone may get presence information.</label>\r\n            </td>\r\n        </tr>\r\n        <tr>\r\n            <td width=\"1%\">\r\n            <input type=\"radio\" name=\"presencePublic\" value=\"false\" id=\"rb02\"\r\n             ");
      out.print(((!presencePublic) ? "checked" : ""));
      out.write(
          ">\r\n            </td>\r\n            <td width=\"99%\">\r\n                <label for=\"rb02\"><b>Subscribed</b> - Presence information is only visibile to authorized users.</label>\r\n            </td>\r\n        </tr>\r\n    </tbody>\r\n    </table>\r\n    </div>\r\n</fieldset>\r\n\r\n<br>\r\n    \r\n<fieldset>\r\n    <legend>Plain Text 'Unavailable' Status Message</legend>\r\n    <div>\r\n    <p>\r\n    In &quot;text&quot; mode the status message for unavailable users is &quot;Unavailable&quot;\r\n    by default. It is possible to change the unavailable status message by setting this property.\r\n    </p>\r\n    <p>\r\n        <input type=\"text\" name=\"presenceUnavailableStatus\" value=\"");
      out.print(unavailableStatus);
      out.write(
          "\">\r\n    </p>\r\n    </div>\r\n</fieldset>\r\n\r\n<br><br>\r\n\r\n<input type=\"submit\" value=\"Save Properties\">\r\n</form>\r\n\r\n</body>\r\n</html>");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #26
0
ファイル: hello_jsp.java プロジェクト: 360keke/peds
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

    try {
      _jspxFactory = JspFactory.getDefaultFactory();
      response.setContentType("text/html;charset=ISO-8859-1");
      pageContext = _jspxFactory.getPageContext(this, request, response, null, true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write('\r');
      out.write('\n');

      String path = request.getContextPath();
      String basePath =
          request.getScheme()
              + "://"
              + request.getServerName()
              + ":"
              + request.getServerPort()
              + path
              + "/";

      out.write('\r');
      out.write('\n');
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\r\n");
      out.write("<html>\r\n");
      out.write("\t<head>\r\n");
      out.write("\t\t<base href=\"");
      out.print(basePath);
      out.write("\">\r\n");
      out.write("\r\n");
      out.write("\t\t<title>My JSP 'hello.jsp' starting page</title>\r\n");
      out.write("\r\n");
      out.write("\t\t<meta http-equiv=\"pragma\" content=\"no-cache\">\r\n");
      out.write("\t\t<meta http-equiv=\"cache-control\" content=\"no-cache\">\r\n");
      out.write("\t\t<meta http-equiv=\"expires\" content=\"0\">\r\n");
      out.write("\t\t<meta http-equiv=\"keywords\" content=\"keyword1,keyword2,keyword3\">\r\n");
      out.write("\t\t<meta http-equiv=\"description\" content=\"This is my page\">\r\n");
      out.write("\t\t<!--\r\n");
      out.write("\t<link rel=\"stylesheet\" type=\"text/css\" href=\"styles.css\">\r\n");
      out.write("\t-->\r\n");
      out.write("\r\n");
      out.write("\t</head>\r\n");
      out.write("\r\n");
      out.write("\t<body>\r\n");
      out.write("\t\t");
      if (_jspx_meth_c_out_0(_jspx_page_context)) return;
      out.write("\r\n");
      out.write("\t</body>\r\n");
      out.write("</html>\r\n");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #27
0
ファイル: SaveName_jsp.java プロジェクト: waijie666/pbss
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;
    PageContext _jspx_page_context = null;

    try {
      response.setContentType("text/html;charset=UTF-8");
      pageContext = _jspxFactory.getPageContext(this, request, response, null, true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;
      _jspx_resourceInjector =
          (org.apache.jasper.runtime.ResourceInjector)
              application.getAttribute("com.sun.appserv.jsp.resource.injector");

      out.write("\n");
      out.write("\n");
      out.write("\n");
      out.write("\n");
      out.write("\n");
      out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\n");
      out.write("   \"http://www.w3.org/TR/html4/loose.dtd\">\n");
      out.write("\n");
      out.write("<html>\n");
      out.write("<body>\n");
      out.write('\n');
      out.write('\n');

      PrintWriter write =
          new PrintWriter(
              new BufferedWriter(new FileWriter((getServletContext().getRealPath("/output.csv")))));
      int i;
      String[] NoofBusstop = request.getParameterValues("NoofbusStop");
      String[] routeID = request.getParameterValues("routeID");
      String[] routeInterval = request.getParameterValues("routeInterval");
      String[] busStopID = request.getParameterValues("busStopID");
      String[] busStopName = request.getParameterValues("busStopName");
      String[] busStopDescription = request.getParameterValues("busStopDescription");
      String[] busStopOrder = request.getParameterValues("busStopOrder");
      String[] busStopStatus = request.getParameterValues("busStopStatus");
      String[] busStopPeopleNum = request.getParameterValues("busStopPeopleNum");

      int a = 0;
      int b = 0;
      int count = 0;
      int NoofBusstops = 0;
      out.println(
          "\"routeID\",\"routeInterval \",\"busStopID\",\"busStopName\",\"busStopDescription\",\"busStopOrder\",\"busStopStatus\",\"busStopPeopleNum\"");
      write.println(
          "\"routeID\",\"routeInterval \",\"busStopID\",\"busStopName\",\"busStopDescription\",\"busStopOrder\",\"busStopStatus\",\"busStopPeopleNum\"");

      out.println("<BR>");
      for (i = 0; i < busStopID.length; i++) {

        NoofBusstops = Integer.parseInt(NoofBusstop[b]);
        count++;
        if (count > NoofBusstops) {
          a++;
          b++;
          count = 1;
        }

        out.println(
            routeID[a]
                + ","
                + routeInterval[a]
                + ","
                + busStopID[i]
                + ",\""
                + busStopName[i]
                + "\",\""
                + busStopDescription[i]
                + "\","
                + busStopOrder[i]
                + ","
                + busStopStatus[i]
                + ","
                + busStopPeopleNum[i]
                + "<BR>");

        write.println(
            routeID[a]
                + ","
                + routeInterval[a]
                + ","
                + busStopID[i]
                + ",\""
                + busStopName[i]
                + "\",\""
                + busStopDescription[i]
                + "\","
                + busStopOrder[i]
                + ","
                + busStopStatus[i]
                + ","
                + busStopPeopleNum[i]);
      }

      write.close();

      /*
      out.println(request.getParameter("routeInterval")+"<BR>");
      out.println(request.getParameter("busStopID")+"<BR>");
      out.println(request.getParameter("busStopName")+"<BR>");
      out.println(request.getParameter("busStopDescription")+"<BR>");
      out.println(request.getParameter("busStopOrder")+"<BR>");
      out.println(request.getParameter("busStopStatus")+"<BR>");
      out.println(request.getParameter("busStopPeopleNum")+"<BR>");
      */

      out.write("\n");
      out.write("\n");
      out.write("</body>\n");
      out.write("</html>");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #28
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;
    PageContext _jspx_page_context = null;

    try {
      response.setContentType("text/html");
      pageContext = _jspxFactory.getPageContext(this, request, response, null, true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write("\r\n\r\n");

      final DisplayState theDisplayState = (DisplayState) request.getAttribute(MasterServlet.STATE);
      final Frame frame = (Frame) request.getAttribute(AbstractChip.FRAME_KEY);

      /*
       //to be definitive NOT serializable
      InputStream noser = (InputStream)session.getAttribute( "NOT_SERIALIZABLE");
      if( noser==null )
      {
      	session.setAttribute( "NOT_SERIALIZABLE", new ByteArrayInputStream( new byte[0] ));
      }
      */

      out.write('\r');
      out.write('\n');

      final AbstractItemTreeNodeChip theChip =
          (AbstractItemTreeNodeChip) request.getAttribute(AbstractChip.CHIP_KEY);

      out.write("\r\n<input type=\"hidden\" name=\"");
      out.print(theChip.getEventID(AbstractTreeNodeChip.EDIT));
      out.write("\" value=\"");
      out.print(AbstractChip.FALSE);
      out.write(
          "\" />\r\n<table class=\"abstractItemTreeNodeChip\" cellspacing=\"0\" cellpadding=\"0\">\r\n\t<tr>\r\n\t\t<td class=\"aitncIcon\">\r\n\t\t\t<div onclick=\"document.editorForm.elements['");
      out.print(theChip.getEventID(AbstractTreeNodeChip.EDIT));
      out.write("'].value='");
      out.print(AbstractChip.TRUE);
      out.write("';setScrollAndSubmit();\">\r\n\t\t\t\t<img src=\"");
      out.print(theChip.getIcon());
      out.write(
          "\" border=\"0\">\r\n\t\t\t</div>\r\n\t\t</td>\r\n\t\t<td class=\"aitncName\">\r\n\t\t\t<div onclick=\"document.editorForm.elements['");
      out.print(theChip.getEventID(AbstractTreeNodeChip.EDIT));
      out.write("'].value='");
      out.print(AbstractChip.TRUE);
      out.write("';setScrollAndSubmit();\">\r\n\t\t\t\t");
      out.print(theChip.getName());
      out.write("\r\n\t\t\t</div>\r\n\t\t</td>\r\n\t</tr>\r\n\t");

      if (theChip.isExpanded()) {
        for (final Iterator it = theChip.getAllChildren().iterator(); it.hasNext(); ) {
          final AbstractTreeNodeChip child = (AbstractTreeNodeChip) it.next();

          out.write("\r\n\t\t\t\t\t<tr>\r\n\t\t\t\t\t\t<td class=\"aitncTreeIMG\" background=\"");
          out.print(it.hasNext() ? "images/vert.gif" : "");
          out.write("\">\r\n\t\t\t\t\t\t\t");

          if (child.hasChildren()) {
            if (child.isExpanded()) {

              out.write("<input type=\"hidden\" name=\"");
              out.print(child.getEventID(AbstractTreeNodeChip.COLLAPSE));
              out.write("\" value=\"");
              out.print(AbstractChip.FALSE);
              out.write("\" /><div onclick=\"document.editorForm.elements['");
              out.print(child.getEventID(AbstractTreeNodeChip.COLLAPSE));
              out.write("'].value='");
              out.print(AbstractChip.TRUE);
              out.write("';setScrollAndSubmit();\">");

              if (it.hasNext()) {

                out.write("<img src=\"images/minus.gif\"></td>");

              } else {

                out.write("<img src=\"images/minusend.gif\"></td>");
              }

              out.write("</div>");

            } else {

              out.write("<input type=\"hidden\" name=\"");
              out.print(child.getEventID(AbstractTreeNodeChip.EXPAND));
              out.write("\" value=\"");
              out.print(AbstractChip.FALSE);
              out.write("\" /><div onclick=\"document.editorForm.elements['");
              out.print(child.getEventID(AbstractTreeNodeChip.EXPAND));
              out.write("'].value='");
              out.print(AbstractChip.TRUE);
              out.write("';setScrollAndSubmit();\">");

              if (it.hasNext()) {

                out.write("<img src=\"images/plus.gif\"></td>");

              } else {

                out.write("<img src=\"images/plusend.gif\"></td>");
              }

              out.write("</div>");
            }
          } else {
            if (it.hasNext()) {

              out.write("<img src=\"images/horiz.gif\"></td>");

            } else {

              out.write("<img src=\"images/end.gif\"></td>");
            }
          }

          out.write("\r\n\t\t\t\t\t\t</td>\r\n\t\t\t\t\t\t<td class=\"aitncContext\">");
          child.render(pageContext);
          out.write("</td>\r\n\t\t\t\t\t</tr>\r\n\t\t\t\t");
        }
      }

      out.write("\r\n</table>\r\n");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0)
          try {
            out.clearBuffer();
          } catch (java.io.IOException e) {
          }
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
        else log(t.getMessage(), t);
      }
    } finally {
      _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #29
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

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

      out.write("\n\n\n\n\n\n\n\n\n\n\n\n\n");

      // Get handle on the Monitoring plugin
      MonitoringPlugin plugin =
          (MonitoringPlugin) XMPPServer.getInstance().getPluginManager().getPlugin("monitoring");
      ConversationManager conversationManager =
          (ConversationManager) plugin.getModule(ConversationManager.class);

      XMPPServer server = XMPPServer.getInstance();
      UserManager userManager = UserManager.getInstance();

      out.write(
          "\n\n<html>\n    <head>\n        <title>Conversations</title>\n        <meta name=\"pageID\" content=\"active-conversations\"/>\n        <script src=\"/js/prototype.js\" type=\"text/javascript\"></script>\n        <script src=\"/js/scriptaculous.js\" type=\"text/javascript\"></script>\n        <script src=\"/plugins/monitoring/dwr/engine.js\" type=\"text/javascript\" ></script>\n        <script src=\"/plugins/monitoring/dwr/util.js\" type=\"text/javascript\" ></script>\n        <script src=\"/plugins/monitoring/dwr/interface/conversations.js\" type=\"text/javascript\"></script>\n    </head>\n    <body>\n\n<style type=\"text/css\">\n\t@import \"style/style.css\";\n</style>\n<script type=\"text/javascript\">\nDWREngine.setErrorHandler(handleError);\nwindow.onerror = handleError;\nfunction handleError() {\n    // swallow errors: probably caused by the server being down\n}\n\nvar peConversations = new PeriodicalExecuter(conversationUpdater, 10);\n\nfunction conversationUpdater() {\n    try {\n        conversations.getConversations(updateConversations, true);\n    } catch(err) {\n");
      out.write(
          "        // swallow errors\n    }\n}\n\nfunction updateConversations(data) {\n    conversationsTable = $('conversations');\n    rows = conversationsTable.getElementsByTagName(\"tr\");\n    // loop over existing rows in the table\n    var rowsToDelete = new Array();\n    for (i = 0; i < rows.length; i++) {\n        // is this a conversation row?\n        if (rows[i].id == 'noconversations') {\n            rowsToDelete.push(i);\n        } else if (rows[i].id != '') {\n            // does the conversation exist in update we received?\n            convID = rows[i].id.replace('conversation-', '');\n            if (data[convID] != undefined) {\n\n                row = rows[i];\n                cells = row.getElementsByTagName('td');\n                conversation = data[convID];\n                if (cells[3].innerHTML != conversation.messageCount) {\n                    users = conversation.participant1 + '<br />' + conversation.participant2;\n                    cells[0].innerHTML = users;\n                    cells[1].innerHTML = conversation.duration;\n");
      out.write(
          "                    cells[2].innerHTML = conversation.lastActivity;\n                    cells[3].innerHTML = conversation.messageCount;\n                    new Effect.Highlight(row, {duration: 3.0});\n                }\n            // doesn't exist in update, delete from table\n            } else {\n                rowsToDelete.push(i);\n            }\n        }\n    }\n\n    for (i=0; i<rowsToDelete.length; i++) {\n        conversationsTable.deleteRow(rowsToDelete[i]);\n    }\n\n\n    // then add any new conversations from the update\n    counter = 0;\n    for (var c in data) {\n        counter++;\n        // does this conversation already exist?\n        if ($('conversation-' + c) == undefined) {\n            conversation = data[c];\n            users = conversation.participant1 + '<br />' + conversation.participant2;\n            var newTR = document.createElement(\"tr\");\n            newTR.setAttribute('id', 'conversation-' + c)\n            conversationsTable.appendChild(newTR);\n            var TD = document.createElement(\"TD\");\n");
      out.write(
          "            TD.innerHTML = users;\n            newTR.appendChild(TD);\n\n            TD = document.createElement(\"TD\");\n            TD.innerHTML = conversation.duration;\n            newTR.appendChild(TD);\n\n            TD = document.createElement(\"TD\");\n            TD.innerHTML = conversation.lastActivity;\n            newTR.appendChild(TD);\n\n            TD = document.createElement(\"TD\");\n            TD.innerHTML = conversation.messageCount;\n            newTR.appendChild(TD);\n        }\n    }\n\n    // update activeConversations number\n    $('activeConversations').innerHTML = counter;\n}\n\n</script>\n\n<!-- <a href=\"#\" onclick=\"conversationUpdater(); return false;\">click me</a> -->\n<p>\n    ");
      if (_jspx_meth_fmt_message_0(_jspx_page_context)) return;
      out.write("\n    <span id=\"activeConversations\">");
      out.print(conversationManager.getConversationCount());
      out.write("</span\n</p>\n\n");

      Collection<Conversation> conversations = conversationManager.getConversations();

      out.write(
          "\n\n\n<div class=\"jive-table\">\n<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\" width=\"100%\" id=\"conversations\">\n<thead>\n    <tr>\n        <th nowrap>");
      if (_jspx_meth_fmt_message_1(_jspx_page_context)) return;
      out.write("</th>\n        <th nowrap>");
      if (_jspx_meth_fmt_message_2(_jspx_page_context)) return;
      out.write("</th>\n        <th nowrap>");
      if (_jspx_meth_fmt_message_3(_jspx_page_context)) return;
      out.write("</th>\n        <th nowrap>");
      if (_jspx_meth_fmt_message_4(_jspx_page_context)) return;
      out.write("</th>\n    </tr>\n</thead>\n<tbody>\n    ");

      if (conversations.isEmpty()) {

        out.write(
            "\n        <tr id=\"noconversations\">\n            <td colspan=\"4\">\n                ");
        if (_jspx_meth_fmt_message_5(_jspx_page_context)) return;
        out.write("\n            </td>\n        </tr>\n\n    ");
      }
      out.write("\n    ");

      for (Conversation conversation : conversations) {
        Collection<JID> participants = conversation.getParticipants();

        out.write("\n    <tr id=\"conversation-");
        out.print(conversation.getConversationID());
        out.write("\">\n        <td>\n            ");
        if (conversation.getRoom() == null) {
          out.write("\n                ");
          for (JID jid : participants) {
            out.write("\n                    ");
            if (server.isLocal(jid) && userManager.isRegisteredUser(jid.getNode())) {
              out.write("\n                        <a href=\"/user-properties.jsp?username="******"');
              out.write('>');
              out.print(jid);
              out.write("</a><br />\n                    ");
            } else {
              out.write("\n                        ");
              out.print(jid.toBareJID());
              out.write("<br/>\n                    ");
            }
            out.write("\n                ");
          }
          out.write("\n            ");
        } else {
          out.write("\n                ");
          //  fmt:message
          org.apache.taglibs.standard.tag.rt.fmt.MessageTag _jspx_th_fmt_message_6 =
              (org.apache.taglibs.standard.tag.rt.fmt.MessageTag)
                  _jspx_tagPool_fmt_message_key.get(
                      org.apache.taglibs.standard.tag.rt.fmt.MessageTag.class);
          _jspx_th_fmt_message_6.setPageContext(_jspx_page_context);
          _jspx_th_fmt_message_6.setParent(null);
          _jspx_th_fmt_message_6.setKey("archive.group_conversation");
          int _jspx_eval_fmt_message_6 = _jspx_th_fmt_message_6.doStartTag();
          if (_jspx_eval_fmt_message_6 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
            if (_jspx_eval_fmt_message_6 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
              out = _jspx_page_context.pushBody();
              _jspx_th_fmt_message_6.setBodyContent((javax.servlet.jsp.tagext.BodyContent) out);
              _jspx_th_fmt_message_6.doInitBody();
            }
            do {
              out.write("\n                    ");
              //  fmt:param
              org.apache.taglibs.standard.tag.rt.fmt.ParamTag _jspx_th_fmt_param_0 =
                  (org.apache.taglibs.standard.tag.rt.fmt.ParamTag)
                      _jspx_tagPool_fmt_param_value_nobody.get(
                          org.apache.taglibs.standard.tag.rt.fmt.ParamTag.class);
              _jspx_th_fmt_param_0.setPageContext(_jspx_page_context);
              _jspx_th_fmt_param_0.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_fmt_message_6);
              _jspx_th_fmt_param_0.setValue(
                  "<a href='../../muc-room-occupants.jsp?roomJID="
                      + URLEncoder.encode(conversation.getRoom().toBareJID(), "UTF-8")
                      + "'>");
              int _jspx_eval_fmt_param_0 = _jspx_th_fmt_param_0.doStartTag();
              if (_jspx_th_fmt_param_0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
                _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_0);
                return;
              }
              _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_0);
              out.write("\n                    ");
              //  fmt:param
              org.apache.taglibs.standard.tag.rt.fmt.ParamTag _jspx_th_fmt_param_1 =
                  (org.apache.taglibs.standard.tag.rt.fmt.ParamTag)
                      _jspx_tagPool_fmt_param_value_nobody.get(
                          org.apache.taglibs.standard.tag.rt.fmt.ParamTag.class);
              _jspx_th_fmt_param_1.setPageContext(_jspx_page_context);
              _jspx_th_fmt_param_1.setParent((javax.servlet.jsp.tagext.Tag) _jspx_th_fmt_message_6);
              _jspx_th_fmt_param_1.setValue("</a>");
              int _jspx_eval_fmt_param_1 = _jspx_th_fmt_param_1.doStartTag();
              if (_jspx_th_fmt_param_1.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
                _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_1);
                return;
              }
              _jspx_tagPool_fmt_param_value_nobody.reuse(_jspx_th_fmt_param_1);
              out.write("\n                ");
              int evalDoAfterBody = _jspx_th_fmt_message_6.doAfterBody();
              if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN) break;
            } while (true);
            if (_jspx_eval_fmt_message_6 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE)
              out = _jspx_page_context.popBody();
          }
          if (_jspx_th_fmt_message_6.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
            _jspx_tagPool_fmt_message_key.reuse(_jspx_th_fmt_message_6);
            return;
          }
          _jspx_tagPool_fmt_message_key.reuse(_jspx_th_fmt_message_6);
          out.write("\n            ");
        }
        out.write("\n        </td>\n        ");

        long duration =
            conversation.getLastActivity().getTime() - conversation.getStartDate().getTime();

        out.write("\n        <td>");
        out.print(StringUtils.getTimeFromLong(duration));
        out.write("</td>\n        <td>");
        out.print(JiveGlobals.formatTime(conversation.getLastActivity()));
        out.write("</td>\n        <td>");
        out.print(conversation.getMessageCount());
        out.write("</td>\n    </tr>\n    ");
      }
      out.write("\n</tbody>\n</table>\n</div>\n\n</body>\n</html>");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }
コード例 #30
0
  public void _jspService(HttpServletRequest request, HttpServletResponse response)
      throws java.io.IOException, ServletException {

    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;
    PageContext _jspx_page_context = null;

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

      out.write("\n\n\n\n\n");

      boolean exportUsers = request.getParameter("exportUsers") != null;
      boolean success = request.getParameter("success") != null;
      boolean exportToFile = ParamUtils.getBooleanParameter(request, "exporttofile", true);

      ImportExportPlugin plugin =
          (ImportExportPlugin)
              XMPPServer.getInstance().getPluginManager().getPlugin("userimportexport");

      String exportText = "";

      Map<String, String> errors = new HashMap<String, String>();
      if (exportUsers) {
        if (exportToFile) {
          String file = ParamUtils.getParameter(request, "exportFile");
          if ((file == null) || (file.length() <= 0)) {
            errors.put("missingFile", "missingFile");
          } else {
            response.sendRedirect("export-file.jsp?fileName=" + file);
          }
        } else {
          try {
            exportText = plugin.exportUsersToString();
          } catch (IOException e) {
            errors.put("IOException", "IOException");
          }
        }
      }

      out.write(
          "\n\n<html>\n    <head>\n        <title>Export User Data</title>\n        <meta name=\"pageID\" content=\"import-export-selection\"/>\n    </head>\n    <body>\n\n");
      if (errors.size() > 0) {
        out.write(
            "\n\n    <div class=\"jive-error\">\n    <table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n    <tbody>\n        <tr>\n            <td class=\"jive-icon\"><img src=\"images/error-16x16.gif\" width=\"16\" height=\"16\" border=\"0\"></td>\n            <td class=\"jive-icon-label\">\n            ");
        if (errors.containsKey("missingFile")) {
          out.write("\n                Missing or bad file name.\n            ");
        } else if (errors.containsKey("IOException") || errors.containsKey("fileNotCreated")) {
          out.write("\n                Couldn't create export file.\n            ");
        }
        out.write(
            "\n            </td>\n        </tr>\n    </tbody>\n    </table>\n    </div>\n    <br>\n\n");
      } else if (ParamUtils.getBooleanParameter(request, "success")) {
        out.write(
            "\n\n    <div class=\"jive-success\">\n    <table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n    <tbody>\n        <tr>\n            <td class=\"jive-icon\"><img src=\"images/success-16x16.gif\" width=\"16\" height=\"16\" border=\"0\"></td>\n            <td class=\"jive-icon-label\">User data successfully exported.</td>\n        </tr>\n    </tbody>\n    </table>\n    </div>\n    <br>\n    \n");
      }
      out.write(
          "\n\n<form action=\"export-user-data.jsp?exportUsers\" method=\"post\">\n\n<div class=\"jive-contentBoxHeader\">Export Options</div>\n<div class=\"jive-contentBox\">\n    <p>\n    Select the radio button next to the desired export option and then click on the Export button.\n    </p>\n    \n    <table cellpadding=\"3\" cellspacing=\"0\" border=\"0\" width=\"100%\">\n    <tbody>\n        <tr>\n            <td width=\"1%\"><input type=\"radio\" name=\"exporttofile\" value=\"true\" ");
      out.print(exportToFile ? "checked" : "");
      out.write(
          " id=\"rb01\"></td>\n            <td width=\"99%\"><label for=\"rb01\"><b>To File</b></label> - Save user data to the specified file location.</td>\n        </tr>\n        <tr>\n            <td width=\"1%\">&nbsp;</td>\n            <td width=\"99%\">Export File Name:&nbsp;<input type=\"text\" size=\"30\" maxlength=\"150\" name=\"exportFile\"></td>\n        </tr>\n        <tr>\n            <td width=\"1%\"><input type=\"radio\" name=\"exporttofile\" value=\"false\" ");
      out.print(!exportToFile ? "checked" : "");
      out.write(
          " id=\"rb02\"></td>\n            <td width=\"99%\"><label for=\"rb02\"><b>To Screen</b></label> - Display user data in the text area below.</td>            \n        </tr>\n        <tr>\n            <td width=\"1%\">&nbsp;</td>\n            <td width=\"99%\"><textarea cols=\"80\" rows=\"20\" wrap=off>");
      out.print(exportText);
      out.write(
          "</textarea></td>\n        </tr>\n    </tbody>\n    </table>\n</div>\n\n<input type=\"submit\" value=\"Export\">\n</form>\n\n</body>\n</html>");
    } catch (Throwable t) {
      if (!(t instanceof SkipPageException)) {
        out = _jspx_out;
        if (out != null && out.getBufferSize() != 0) out.clearBuffer();
        if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
      }
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(_jspx_page_context);
    }
  }