Package org.qiunet.cfg.manager.json
Class NestMapJsonCfgManager<ID,SubId,Cfg extends INestMapCfg<ID,SubId>>
java.lang.Object
org.qiunet.cfg.manager.base.BaseCfgManager<ID,Cfg>
org.qiunet.cfg.manager.json.NestMapJsonCfgManager<ID,SubId,Cfg>
- All Implemented Interfaces:
ICfgManager<ID,,Cfg> INestMapCfgManager<ID,,SubId, Cfg> ICfgWrapper<ID,,Cfg> INestMapCfgWrapper<ID,SubId, Cfg>
public class NestMapJsonCfgManager<ID,SubId,Cfg extends INestMapCfg<ID,SubId>>
extends BaseCfgManager<ID,Cfg>
implements INestMapCfgManager<ID,SubId,Cfg>
- Author:
- zhengj Date: 2019/6/6. Time: 16:10. To change this template use File | Settings | File Templates.
-
Field Summary
FieldsFields inherited from class org.qiunet.cfg.manager.base.BaseCfgManager
cfgClass, fileName, logger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionallCfgs()得到所有的配置protected CfggeneralCfg(com.alibaba.fastjson.JSONObject jsonObject) 通过反射得到一个cfggetCfgByIdAndSubId(ID id, SubId subId) 根据id 和 subId 得到一条cfg数据得到一个一定格式的嵌套map 格式: key 对应 Map[subKey, cfg]list()voidloadCfg()设定加载Methods inherited from class org.qiunet.cfg.manager.base.BaseCfgManager
afterLoad, fileChangeListener, getCfgClass, getLoadFileName, handlerObjConvertAndAssign, orderMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.qiunet.cfg.manager.base.ICfgManager
getCfgClass, getLoadFileName, loadCfg, orderMethods inherited from interface org.qiunet.cfg.wrapper.ICfgWrapper
getCfgClass, listMethods inherited from interface org.qiunet.cfg.wrapper.INestMapCfgWrapper
contains, contains, getCfgById, getCfgsById, size
-
Field Details
-
cfgList
-
-
Constructor Details
-
NestMapJsonCfgManager
-
-
Method Details
-
getCfgByIdAndSubId
根据id 和 subId 得到一条cfg数据- Parameters:
id-subId-- Returns:
-
getNestMapCfg
得到一个一定格式的嵌套map 格式: key 对应 Map[subKey, cfg]- Returns:
- Throws:
Exception
-
allCfgs
Description copied from interface:INestMapCfgWrapper得到所有的配置- Specified by:
allCfgsin interfaceINestMapCfgWrapper<ID,SubId, Cfg extends INestMapCfg<ID, SubId>> - Returns:
-
loadCfg
Description copied from interface:ICfgManager设定加载- Throws:
Exception
-
list
-
generalCfg
通过反射得到一个cfg- Returns:
-