⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 _removegroup__jsp.java

📁 JSP聊天系统
💻 JAVA
字号:
/*
 * JSP generated by Resin 2.1.2 (built Tue Jun 11 08:26:56 PDT 2002)
 */

package _admin._forum;
import javax.servlet.*;
import javax.servlet.jsp.*;
import javax.servlet.http.*;
import java.util.*;
import com.coolservlets.forum.*;
import com.coolservlets.forum.util.*;
import com.coolservlets.forum.util.admin.*;

public class _removegroup__jsp extends com.caucho.jsp.JavaPage{
  private boolean _caucho_isDead;
  
  public void
  _jspService(javax.servlet.http.HttpServletRequest request,
              javax.servlet.http.HttpServletResponse response)
    throws java.io.IOException, javax.servlet.ServletException
  {
    com.caucho.jsp.QPageContext pageContext = (com.caucho.jsp.QPageContext) com.caucho.jsp.QJspFactory.create().getPageContext(this, request, response, null, true, 8192, true);
    javax.servlet.jsp.JspWriter out = (javax.servlet.jsp.JspWriter) pageContext.getOut();
    javax.servlet.ServletConfig config = getServletConfig();
    javax.servlet.Servlet page = this;
    javax.servlet.http.HttpSession session = pageContext.getSession();
    javax.servlet.ServletContext application = pageContext.getServletContext();
    response.setContentType("text/html;charset=gb2312");
    request.setCharacterEncoding("GB2312");
    try {
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      
/**
 *	$RCSfile: removeGroup.jsp,v $
 *	$Revision: 1.3 $
 *	$Date: 2000/12/18 02:06:21 $
 */

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string1, 0, _jsp_string1.length);
      com.coolservlets.forum.util.admin.AdminBean adminBean;
      synchronized (session) {
        adminBean = (com.coolservlets.forum.util.admin.AdminBean) session.getValue("adminBean");
        if (adminBean == null) {
          adminBean = new com.coolservlets.forum.util.admin.AdminBean();
          session.putValue("adminBean", adminBean);
        }
      }
      pageContext.write(_jsp_string1, 0, _jsp_string1.length);
      	////////////////////////////////
	// Jive authorization check
	
	// check the bean for the existence of an authorization token.
	// Its existence proves the user is valid. If it's not found, redirect
	// to the login page
	Authorization authToken = adminBean.getAuthToken();
	if( authToken == null ) {
		response.sendRedirect( "login.jsp" );
		return;
	}

      pageContext.write(_jsp_string2, 0, _jsp_string2.length);
      	////////////////////
	// Security check
	
	// make sure the user is authorized to administer users:
	ForumFactory forumFactory = ForumFactory.getInstance(authToken);
	boolean isSystemAdmin = ((Boolean)session.getValue("jiveAdmin.systemAdmin")).booleanValue();
	boolean isGroupAdmin  = ((Boolean)session.getValue("jiveAdmin.groupAdmin")).booleanValue();
	
	// redirect to error page if we're not a group admin or a system admin
	if( !isGroupAdmin && !isSystemAdmin ) {
		request.setAttribute("message","No permission to administer groups");
		response.sendRedirect("error.jsp");
		return;
	}

      pageContext.write(_jsp_string2, 0, _jsp_string2.length);
      	////////////////////
	// get parameters
	int groupID   = ParamUtils.getIntParameter(request,"group",-1);
	boolean doDelete = ParamUtils.getBooleanParameter(request,"doDelete");

      pageContext.write(_jsp_string2, 0, _jsp_string2.length);
      	//////////////////////////////////
	// global error variables
	
	String errorMessage = "";
	
	boolean noGroupSpecified = (groupID < 0);
	boolean errors = (noGroupSpecified);

      pageContext.write(_jsp_string1, 0, _jsp_string1.length);
      	////////////////////
	// make a profile manager
	ProfileManager manager = forumFactory.getProfileManager();

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      	/////////////////////
	// delete group if specified
	if( doDelete && !errors ) {
		System.err.println( "deleting group" );
		String message = "";
		try {
			Group group = manager.getGroup(groupID);
			manager.deleteGroup(group);
			message = "Group deleted successfully!";
		}
		catch( GroupNotFoundException fnfe ) {
			System.err.println( fnfe );
			message = "No group found";
		}
		catch( UnauthorizedException ue ) {
			System.err.println( ue );
			message = "Not authorized to delete this group";
		}
		System.err.println( "message: "+ message );
		request.setAttribute("message",message);
		response.sendRedirect("groups.jsp");
        return;
	}

      pageContext.write(_jsp_string3, 0, _jsp_string3.length);
      	///////////////////////
	// pageTitleInfo variable (used by include/pageTitle.jsp)
	String[] pageTitleInfo = { "组:删除组" };

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      	///////////////////
	// pageTitle include

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string1, 0, _jsp_string1.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      	if( pageTitleInfo != null ) { 
      pageContext.write(_jsp_string4, 0, _jsp_string4.length);
      	for( int i=0; i<pageTitleInfo.length; i++ ){ 
      pageContext.write(_jsp_string5, 0, _jsp_string5.length);
      out.print(( pageTitleInfo[i] ));
      pageContext.write(_jsp_string5, 0, _jsp_string5.length);
      	if( (i+1)<pageTitleInfo.length ) { 
      pageContext.write(_jsp_string6, 0, _jsp_string6.length);
      	} 
      pageContext.write(_jsp_string7, 0, _jsp_string7.length);
      	} 
      pageContext.write(_jsp_string8, 0, _jsp_string8.length);
      	} 
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string9, 0, _jsp_string9.length);
      	////////////////////
	// display a list of groups to edit if no group was specified:
	if( noGroupSpecified ) {
		String formAction = "remove";

      pageContext.write(_jsp_string5, 0, _jsp_string5.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      
/**
 *	$RCSfile: groupChooser.jsp,v $
 *	$Revision: 1.2 $
 *	$Date: 2000/12/18 02:06:21 $
 */

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      	/////////////////////
	// get an iterator of groups and display a list
	
	Iterator groupIterator = manager.groups();
	if( !groupIterator.hasNext() ) {

      pageContext.write(_jsp_string10, 0, _jsp_string10.length);
      
	}

      pageContext.write(_jsp_string11, 0, _jsp_string11.length);
      out.print(( formAction ));
      pageContext.write(_jsp_string12, 0, _jsp_string12.length);
      	while( groupIterator.hasNext() ) {
		Group group = (Group)groupIterator.next();

      pageContext.write(_jsp_string13, 0, _jsp_string13.length);
      out.print(( group.getID() ));
      pageContext.write(_jsp_string14, 0, _jsp_string14.length);
      out.print(( group.getName() ));
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      	}

      pageContext.write(_jsp_string15, 0, _jsp_string15.length);
      	if( formAction.equals("edit") ) { 
      pageContext.write(_jsp_string16, 0, _jsp_string16.length);
      	} else if( formAction.equals("remove") ) { 
      pageContext.write(_jsp_string17, 0, _jsp_string17.length);
      	} 
      pageContext.write(_jsp_string18, 0, _jsp_string18.length);
      		out.flush();
		return;
	}

      pageContext.write(_jsp_string19, 0, _jsp_string19.length);
      	/////////////////////
	// at this point, we know there is a group to work with:
    Group group = null;
	try {
		group = manager.getGroup(groupID);
	} catch( GroupNotFoundException gnfe ) {
	}

      pageContext.write(_jsp_string20, 0, _jsp_string20.length);
      out.print(( group.getName() ));
      pageContext.write(_jsp_string21, 0, _jsp_string21.length);
      out.print(( groupID ));
      pageContext.write(_jsp_string22, 0, _jsp_string22.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      JspFactory.getDefaultFactory().releasePageContext(pageContext);
    }
  }

  private com.caucho.java.LineMap _caucho_line_map;
  private java.util.ArrayList _caucho_depends = new java.util.ArrayList();

  public boolean _caucho_isModified()
  {
    if (_caucho_isDead)
      return true;
    if (com.caucho.util.CauchoSystem.getVersionId() != 2057024144)
      return true;
    for (int i = _caucho_depends.size() - 1; i >= 0; i--) {
      com.caucho.vfs.Depend depend;
      depend = (com.caucho.vfs.Depend) _caucho_depends.get(i);
      if (depend.isModified())
        return true;
    }
    return false;
  }

  public long _caucho_lastModified()
  {
    return 0;
  }

  public com.caucho.java.LineMap _caucho_getLineMap()
  {
    return _caucho_line_map;
  }

  public void destroy()
  {
      _caucho_isDead = true;
      super.destroy();
  }

  public void init(com.caucho.java.LineMap lineMap,
                   com.caucho.vfs.Path appDir)
    throws javax.servlet.ServletException
  {
    com.caucho.vfs.Path resinHome = com.caucho.util.CauchoSystem.getResinHome();
    com.caucho.vfs.MergePath mergePath = new com.caucho.vfs.MergePath();
    mergePath.addMergePath(appDir);
    mergePath.addMergePath(resinHome);
    mergePath.addClassPath(getClass().getClassLoader());
    _caucho_line_map = new com.caucho.java.LineMap("_removegroup__jsp.java", "e:\\jnjt\\admin\\forum\\removeGroup.jsp");
    _caucho_line_map.add("/admin/forum/removeGroup.jsp", 10, 1);
    _caucho_line_map.add("/admin/forum/groupChooser.jsp", 9, 1);
    _caucho_line_map.add("/admin/forum/removeGroup.jsp", 2, 32);
    _caucho_line_map.add(9, 40);
    _caucho_line_map.add(15, 42);
    _caucho_line_map.add(18, 51);
    _caucho_line_map.add(66, 100);
    _caucho_line_map.add(98, 125);
    _caucho_line_map.add(102, 130);
    _caucho_line_map.add(105, 134);
    _caucho_line_map.add("/admin/forum/include/pageTitle.jsp", 9, 137);
    _caucho_line_map.add(14, 139);
    _caucho_line_map.add(15, 141);
    _caucho_line_map.add(16, 143);
    _caucho_line_map.add(19, 147);
    _caucho_line_map.add(24, 149);
    _caucho_line_map.add("e:\\jnjt\\admin\\forum\\removeGroup.jsp", 108, 152);
    _caucho_line_map.add(113, 158);
    _caucho_line_map.add("/admin/forum/groupChooser.jsp", 2, 159);
    _caucho_line_map.add(9, 167);
    _caucho_line_map.add(26, 185);
    _caucho_line_map.add(26, 187);
    _caucho_line_map.add(27, 189);
    _caucho_line_map.add("e:\\jnjt\\admin\\forum\\removeGroup.jsp", 114, 198);
    _caucho_line_map.add(120, 203);
    _caucho_line_map.add(130, 212);
    _caucho_line_map.add(141, 214);
    com.caucho.vfs.Depend depend;
    depend = new com.caucho.vfs.Depend(mergePath.lookup("file:/e:/jnjt/admin/forum/include/pageTitle.jsp"), 989631934000L, 553L);
    _caucho_depends.add(depend);
    depend = new com.caucho.vfs.Depend(mergePath.lookup("file:/e:/jnjt/admin/forum/groupChooser.jsp"), 1021630008000L, 790L);
    _caucho_depends.add(depend);
    depend = new com.caucho.vfs.Depend(mergePath.lookup("file:/e:/jnjt/admin/forum/removeGroup.jsp"), 1029827433478L, 4219L);
    _caucho_depends.add(depend);
  }

  private static byte []_jsp_string2;
  private static byte []_jsp_string18;
  private static byte []_jsp_string10;
  private static byte []_jsp_string6;
  private static byte []_jsp_string7;
  private static byte []_jsp_string4;
  private static byte []_jsp_string15;
  private static byte []_jsp_string9;
  private static byte []_jsp_string11;
  private static byte []_jsp_string19;
  private static byte []_jsp_string8;
  private static byte []_jsp_string0;
  private static byte []_jsp_string14;
  private static byte []_jsp_string20;
  private static byte []_jsp_string17;
  private static byte []_jsp_string16;
  private static byte []_jsp_string13;
  private static byte []_jsp_string22;
  private static byte []_jsp_string21;
  private static byte []_jsp_string12;
  private static byte []_jsp_string1;
  private static byte []_jsp_string3;
  private static byte []_jsp_string5;
  static {
    try {
      _jsp_string2 = "\r\n \r\n".getBytes("GB2312");
      _jsp_string18 = "\r\n</form>\r\n\r\n\r\n".getBytes("GB2312");
      _jsp_string10 = "\r\n		没有组被修改!\r\n".getBytes("GB2312");
      _jsp_string6 = "\r\n			&nbsp;:&nbsp;\r\n		".getBytes("GB2312");
      _jsp_string7 = "\r\n	".getBytes("GB2312");
      _jsp_string4 = "\r\n	<table class=\"pageHeaderBg\" cellpadding=\"1\" cellspacing=\"0\" border=\"0\" width=\"100%\">\r\n	<td><table class=\"pageHeaderFg\" cellpadding=\"3\" cellspacing=\"0\" border=\"0\" width=\"100%\">\r\n	<td>\r\n	<span class=\"pageTitle\">\r\n	".getBytes("GB2312");
      _jsp_string15 = "\r\n</select>\r\n".getBytes("GB2312");
      _jsp_string9 = "\r\n\r\n\r\n\r\n\r\n<p>\r\n\r\n".getBytes("GB2312");
      _jsp_string11 = "\r\n\r\n<form action=\"".getBytes("GB2312");
      _jsp_string19 = "\r\n\r\n\r\n".getBytes("GB2312");
      _jsp_string8 = "\r\n	</span>\r\n	</td>\r\n	</table></td>\r\n	</table>\r\n".getBytes("GB2312");
      _jsp_string0 = "\r\n".getBytes("GB2312");
      _jsp_string14 = "\">".getBytes("GB2312");
      _jsp_string20 = "\r\n\r\n\r\n删除<b>".getBytes("GB2312");
      _jsp_string17 = "\r\n	<input type=\"submit\" value=\"删除组...\">\r\n".getBytes("GB2312");
      _jsp_string16 = "\r\n	<input type=\"submit\" value=\"修改组...\">\r\n".getBytes("GB2312");
      _jsp_string13 = "\r\n		<option value=\"".getBytes("GB2312");
      _jsp_string22 = "\">\r\n	<input type=\"submit\" value=\"确定\">\r\n	&nbsp;\r\n	<input type=\"submit\" name=\"cancel\" value=\"取消\" style=\"font-weight:bold;\"\r\n	 onclick=\"location.href='groups.jsp';return false;\">\r\n</form>\r\n\r\n<script language=\"JavaScript\" type=\"text/javascript\">\r\n<!--\r\ndocument.deleteForm.cancel.focus();\r\n//-->\r\n</script>\r\n\r\n\r\n\r\n</body>\r\n</html>\r\n\r\n".getBytes("GB2312");
      _jsp_string21 = "</b>?\r\n\r\n<p>\r\n\r\n<ul>\r\n警告:这将永久删除这个用户组。您确定您真的想这样做吗?(这将<b>不会</b>删除那些于这个组相联系的用户,但是将删除这些用户的由组成员授权的组许可).\r\n	 \r\n</ul>\r\n\r\n<form action=\"removeGroup.jsp\" name=\"deleteForm\">\r\n<input type=\"hidden\" name=\"doDelete\" value=\"true\">\r\n<input type=\"hidden\" name=\"group\" value=\"".getBytes("GB2312");
      _jsp_string12 = "Group.jsp\">\r\n<select name=\"group\">\r\n".getBytes("GB2312");
      _jsp_string1 = "\r\n\r\n".getBytes("GB2312");
      _jsp_string3 = "\r\n\r\n<html>\r\n<head>\r\n	<title></title>\r\n	<link rel=\"stylesheet\" href=\"style/global.css\">\r\n</head>\r\n\r\n<body background=\"../images/background.gif\" bgcolor=\"#ffffff\" text=\"#000000\" link=\"#0000ff\" vlink=\"#800080\" alink=\"#ff0000\">\r\n".getBytes("GB2312");
      _jsp_string5 = "\r\n		".getBytes("GB2312");
    } catch (java.io.UnsupportedEncodingException e) {
      e.printStackTrace();
    }
  }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -