类 SysParam
java.lang.Object
com.sh.base.frame.common.SysParam
Title: 首亨软件 - 获取以及设置系统参数
Description: 首亨软件 - SHForce
Company:首亨软件(重庆)有限公司
Author:江兴春
-
字段概要
字段修饰符和类型字段说明static String已过时。static Stringstatic ConcurrentHashMap<String,String> 保存sys_const_table中的常量,构造规则为:key=const_type+const_name,value=const_valuestatic Stringstatic final Stringstatic Stringstatic booleanstatic final Stringstatic Stringstatic Stringstatic intstatic final Stringstatic final Stringstatic final Datestatic final DelayUtil.DelayNotifystatic long -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static UserInfogetCacheUserInfo(String userId) 系统启动时检查序列获取实现了DBQueue接口的类static Stringstatic StringgetDefaultHref(jakarta.servlet.http.HttpServletRequest request) static StringgetDefaultHref(jakarta.servlet.http.HttpServletRequest request, String userId) 默认A标签HREF值获取实现了DumpTasks接口的类getFrameConfList(String key) 获取frameConf.xml中配置的数据static intgetIEVersion(jakarta.servlet.http.HttpServletRequest request, String userId) 使用浏览器的最低版本 默认IE6static intgetIntParam(DataCenter dc, String constType, String paramName) 从系统表中获取int型参数的值static intgetIntParam(String constType, String paramName) 从系统表中获取int型参数的值static intgetIntParam(String constType, String paramName, int defaultValue) static StringgetParam(DataCenter dc, String constType, String paramName) 从系统表中获取参数的值static String获取系统属性static String获取系统属性static Stringstatic StringgetParamInner(jakarta.servlet.http.HttpServletRequest request, String constType, String constName) 获取系统属性static StringgetParamInner(String constType, String constName) static StringgetParamLanguage(String constType, String constName) 获取系统属性,并进行语言转换static StringgetServerAddr(String serverId) 获取服务器信息Shforce相关的JAR包static String获取当前皮肤使用版本static booleangetSystemBooleanValue(String key, String defaultValue) 获取系统BOOLEAN属性static booleangetSystemExBooleanValue(String key, String defaultValue) 获取BOOLEAN类型static intgetSystemExIntValue(String key, String defaultValue) 获取系统扩展整形属性static StringgetSystemExValue(String key) 获取系统扩展属性static StringgetSystemExValue(String key, String defaultValue) 获取系统扩展属性static intgetSystemIntValue(String key, String defaultValue) 获取系统整形属性static intgetSystemIntValue2(String key, int defaultValue) static DelayUtil.DelayNotifystatic StringgetSystemValue(String key) 获取系统(System.properties)属性static StringgetSystemValue(String key, String defaultValue) 获取系统属性获取实现了Task接口的类static voidstatic voidinitJ2SERuntime(Consumer consumer) 初始化J2EE运行环境static boolean是否使用用默认本地缓存作为登陆缓存static boolean判断是否开发模式static boolean服务端J2EE模式static boolean客户端J2SE模式static boolean是否使用用redis作为登陆缓存static booleanSpringboot模式static voidstatic void将sys_const_table中所有的参数一次性加载到HashMap中static boolean加载配置文件static void加载可访问服务器static voidloginServer(DataCenter dc, String userId, String serverId) 创建服务器static voidlogoutServer(DataCenter dc, String userId, String serverId) 退出服务器protected static voidputShforceJars(String jarName) 添加SHFORCE的JAR包static voidstatic voidstatic booleanrefreshSystemUser(DataCenter dc, String userId) 刷新登录用户static booleansaveParam(DataCenter dc, String constType, String paramName, String paramValue) 将参数值保存到数据库中sys_const_value表中static booleanstatic voidsetSystemExValue(String key, String value) 设置系统扩展属性static voidsetSystemValue(String key, String value) 设置系统变量static voidupdateParam(String constKey, String constValue) 已过时。static voidupdateParam(String constType, String constName, String constValue) 更新系统变量static voidupdateParam(String constType, String constName, String constValue, boolean triggerEvent) 更新系统变量static boolean阻塞等待系统初始化完毕
-
字段详细资料
-
VERSION
public static long VERSION -
classPath
-
constMap
保存sys_const_table中的常量,构造规则为:key=const_type+const_name,value=const_value -
SERVER_START_DAY
-
SERVER_START_TIME
-
SERVER_START_TIME_FULL
-
EVENT_INIT_FINISH
- 另请参阅:
-
isLoadSysParamFinish
public static boolean isLoadSysParamFinish -
SERVER_ALIAS
-
DEPLOY_DIR
-
EX_CONFIG_DIR
-
APP_ROOT_DIR
已过时。 -
LINE_SEPARATOR
-
SERVER_MODE
public static int SERVER_MODE -
SERVER_IP
-
systemStartupNotify
-
-
构造器详细资料
-
SysParam
public SysParam()
-
-
方法详细资料
-
initJ2SERuntime
public static void initJ2SERuntime() -
initJ2SERuntime
初始化J2EE运行环境 -
getSystemStartupNotify
-
waitSystemStartup
public static boolean waitSystemStartup()阻塞等待系统初始化完毕 -
isJ2SEModel
public static boolean isJ2SEModel()客户端J2SE模式- 返回:
- boolean
-
isJ2EEModel
public static boolean isJ2EEModel()服务端J2EE模式- 返回:
- boolean
-
isSpringbootModel
public static boolean isSpringbootModel()Springboot模式- 返回:
- boolean
-
getServerAddr
获取服务器信息- 参数:
serverId- String- 返回:
- String
-
isDevMode
public static boolean isDevMode()判断是否开发模式- 返回:
- true|false
-
getIEVersion
使用浏览器的最低版本 默认IE6- 参数:
request- HttpServletRequestuserId- String- 返回:
- int
-
getDefaultHref
默认A标签HREF值- 参数:
request- HttpServletRequestuserId- String- 返回:
- String
-
getDefaultHref
-
getDefaultHref
-
loadServerConfig
加载可访问服务器- 参数:
dc- DataCenter
-
loginServer
创建服务器- 参数:
dc- DataCenteruserId- StringserverId- String
-
logoutServer
退出服务器- 参数:
dc- DataCenteruserId- StringserverId- String
-
getShforceJars
Shforce相关的JAR包- 返回:
- List
-
putShforceJars
添加SHFORCE的JAR包- 参数:
jarName-
-
saveParam
-
saveParam
public static boolean saveParam(DataCenter dc, String constType, String paramName, String paramValue) 将参数值保存到数据库中sys_const_value表中- 参数:
dc- DataCenter对象constType- String参数类型paramName- String参数名称paramValue- String参数值- 返回:
- boolean是否成功,true成功,false失败
-
getParam
从系统表中获取参数的值- 参数:
dc- DataCenter 数据中心constType- String参数类型paramName- String 参数名称- 返回:
- String 取参数的值
-
getIntParam
从系统表中获取int型参数的值- 参数:
dc- DataCenter 数据中心constType- String参数类型paramName- String 参数名称- 返回:
- String int型参数的值
-
getIntParam
从系统表中获取int型参数的值- 参数:
constType- String参数类型paramName- String 参数名称- 返回:
- String int型参数的值
-
getIntParam
-
loadAllParamToMap
public static void loadAllParamToMap() -
refreshLoadParam
public static void refreshLoadParam() -
refreshLoadParam
-
loadAllParamToMap
将sys_const_table中所有的参数一次性加载到HashMap中- 参数:
dc- DataCenter对象- 抛出:
Exception- Exception
-
updateParam
更新系统变量- 参数:
constType- StringconstName- StringconstValue- String
-
updateParam
public static void updateParam(String constType, String constName, String constValue, boolean triggerEvent) 更新系统变量- 参数:
constType- StringconstName- StringconstValue- StringtriggerEvent- 触发事件
-
updateParam
已过时。更新系统变量- 参数:
constKey- StringconstValue- String
-
getParamInner
public static String getParamInner(jakarta.servlet.http.HttpServletRequest request, String constType, String constName) 获取系统属性- 参数:
request- HttpServletRequestconstType- StringconstName- String- 返回:
- String
-
getParam
public static String getParam(jakarta.servlet.http.HttpServletRequest request, String constType, String constName) 获取系统属性- 参数:
request- HttpServletRequestconstType- StringconstName- String- 返回:
- String
-
getParamInner
-
getParamLanguage
获取系统属性,并进行语言转换- 参数:
constType-constName-- 返回:
-
getParam
获取系统属性- 参数:
constType- StringconstName- String- 返回:
- String
-
getParam
-
getSystemValue
获取系统(System.properties)属性- 参数:
key- String- 返回:
- String
-
setSystemValue
设置系统变量- 参数:
key- Stringvalue- String
-
getSystemValue
获取系统属性- 参数:
key- StringdefaultValue- 默认值- 返回:
- String
-
getSystemIntValue
获取系统整形属性- 参数:
key- StringdefaultValue- String- 返回:
- int
-
getSystemIntValue2
-
getSystemBooleanValue
获取系统BOOLEAN属性- 参数:
key- StringdefaultValue- String- 返回:
- boolean
-
getSystemExValue
获取系统扩展属性- 参数:
key- String- 返回:
- String
-
setSystemExValue
设置系统扩展属性- 参数:
key- Stringvalue- String
-
getSystemExValue
获取系统扩展属性- 参数:
key- StringdefaultValue- 默认值- 返回:
- String
-
getSystemExIntValue
获取系统扩展整形属性- 参数:
key- StringdefaultValue- 默认值- 返回:
- int
-
getSystemExBooleanValue
获取BOOLEAN类型- 参数:
key- StringdefaultValue- String- 返回:
- boolean
-
loadFrameConf
public static boolean loadFrameConf()加载配置文件- 返回:
- boolean
-
getFrameConfList
获取frameConf.xml中配置的数据- 参数:
key- String- 返回:
- List
-
getDBQueueList
获取实现了DBQueue接口的类- 返回:
- List
-
getTaskList
获取实现了Task接口的类- 返回:
- List
-
getDumpTaskList
获取实现了DumpTasks接口的类- 返回:
- List
-
getCheckSequences
系统启动时检查序列- 返回:
- List
-
getSkinVersion
获取当前皮肤使用版本- 返回:
- String
-
isRedisLogin
public static boolean isRedisLogin()是否使用用redis作为登陆缓存- 返回:
- boolean
-
isDefaultCacheLogin
public static boolean isDefaultCacheLogin()是否使用用默认本地缓存作为登陆缓存- 返回:
- boolean
-
refreshSystemUser
刷新登录用户- 参数:
dc- DataCenteruserId- String- 返回:
- boolean
-
getCacheUserInfo
-