BBS-CS(天乙社区) v5.2.2源码版

源代码在线查看: sys.java

软件大小: 487 K
上传用户: GUAIGUAICHENGTI
关键词: BBS-CS 源码
下载地址: 免注册下载 普通下载 VIP

相关代码

				package com.laoer.bbscs.sysinfo;
				
				import java.util.*;
				import com.laoer.bbscs.util.*;
				
				public class Sys {
				
				  public static SysInfo SYSINFO;
				  public static Cache CACHE;
				  public static String[] WEBSITE;
				  public static Hashtable CSSHT;
				
				  //public static Hashtable THREADHT = new Hashtable();
				
				  public static int RESULT_RIGHT = 1;
				  public static int RESULT_ZERO = 0;
				  public static int RESULT_OBJECTEXCEPTION = -1;
				  public static int RESULT_OBJECTNOEXISTEXCEPTION = -2;
				  public static int RESULT_OTHER = -3;
				  public static int RESULT_OBJECTEXIST = -4;
				  public static Object RESULT_NULL = null;
				
				  public static String USERCLASS = "com.laoer.bbscs.bbs.business.DBUser";
				  public static String USERDETAILCLASS =
				      "com.laoer.bbscs.bbs.business.DBUserDetail";
				  public static String ADMINUSERINFOCLASS =
				      "com.laoer.bbscs.bbs.business.DBAdminUser";
				  public static String BOARDCLASS = "com.laoer.bbscs.bbs.business.DBBoard";
				  public static String BOARDSCLASS = "com.laoer.bbscs.bbs.business.DBBoards";
				  public static String USERONLINECLASS =
				      "com.laoer.bbscs.bbs.business.DBUserOnline";
				  public static String FRIENDCLASS = "com.laoer.bbscs.bbs.business.DBFriend";
				  public static String BOOKMARKCLASS =
				      "com.laoer.bbscs.bbs.business.DBBookMark";
				  public static String GUESTBOOKCLASS =
				      "com.laoer.bbscs.bbs.business.DBGuestBook";
				  public static String FORMCLASS = "com.laoer.bbscs.bbs.business.DBForum";
				  public static String SUBSCIBECLASS =
				      "com.laoer.bbscs.bbs.business.DBSubscibe";
				  public static String USERPICCLASS = "com.laoer.bbscs.bbs.business.DBUserPic";
				  public static String BULLETINCLASS =
				      "com.laoer.bbscs.bbs.business.DBBulletin";
				  public static String BLACKUSERCLASS =
				      "com.laoer.bbscs.bbs.business.DBBlackUser";
				  public static String CSSCLASS = "com.laoer.bbscs.bbs.business.DBCSS";
				  public static String ELITECLASS = "com.laoer.bbscs.bbs.business.DBElite";
				
				  public static Locale SYSLOCALE = Locale.getDefault();
				
				  public static Locale getLocale() {
				    return new Locale(Sys.SYSINFO.LANGUAGE, Sys.SYSINFO.COUNTRY);
				  }
				
				  public static boolean isLocale() {
				    Locale MYLOCALE = getLocale();
				    return MYLOCALE.equals(SYSLOCALE);
				  }
				
				  public static String[] getServerIP() {
				    int len = Sys.SYSINFO.SERVERSIP.size();
				    String[] serverip = new String[len];
				    for (int i = 0; i < len; i++) {
				      serverip[i] = (String) Sys.SYSINFO.SERVERSIP.get(i);
				    }
				    return serverip;
				  }
				
				  public static String getURL() {
				    int len = Sys.SYSINFO.SERVERSURL.size();
				    String[] serverurl = new String[len];
				    for (int i = 0; i < len; i++) {
				      serverurl[i] = (String) Sys.SYSINFO.SERVERSURL.get(i);
				    }
				    int n = (int) (Math.random() * len);
				    return serverurl[n] + Sys.SYSINFO.ROOTWEBPATH;
				  }
				
				}
							

相关资源