?? manageruser.java
字號:
package com.laoer.bbscs.user;import java.sql.*;import java.io.*;import java.util.*;import com.laoer.bbscs.db.*;//import com.laoer.bbscs.txthtml.*;/** * <p>Title: BBS-CS</p> * <p>Description: BBS-CS(BBS式虛擬社區系統)</p> * <p>Copyright: Copyright (c) 2002</p> * <p>Company: loveroom.com.cn</p> * @author 龔天乙(laoer) * @version 3.0 */public class ManagerUser { String SQL = ""; DbTrans DBSQL; //DoText myDoText; ResultSet rs = null; private boolean isSuper = false; private boolean isBoard = false; private boolean isBulletin = false; private boolean isUserAdmin = false; public ManagerUser() { this.DBSQL = new DbTrans(); } public void getManagerUser(String strUserID) { SQL = "select * from adminuser where UID="+strUserID; try { rs = DBSQL.executeQuery(SQL); if (rs.next()) { if (rs.getInt("superadmin")==1) { this.isSuper = true; } if (rs.getInt("board")==1) { this.isBoard = true; } if (rs.getInt("bulletin")==1) { this.isBulletin = true; } if (rs.getInt("useradmin")==1) { this.isUserAdmin = true; } } rs.close(); } catch (SQLException e){ } } public boolean getIsSuper() { return this.isSuper; } public boolean getIsBoard() { return this.isBoard; } public boolean getIsBulletin() { return this.isBulletin; } public boolean getUserAdmin() { return this.isUserAdmin; } public void close() { try { DBSQL.close(); } catch (SQLException e){ } }}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -