public abstract class AbstractConfigFactory
extends java.lang.Object
| Constructor and Description |
|---|
AbstractConfigFactory() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract <T> java.lang.String |
configLocationFor(java.lang.Class<T> configInterface)
Calculates config location for config interface
|
<T> T |
createConfig(java.lang.Class<T> configInterface)
Creates and returns instance of config
|
protected abstract ConfigStorage |
getConfigStorage()
Gets config storage
|
HotConfig |
getOrCreateConfig(HotConfigDefinition configDefinition)
Creates and returns instance of hot config
|
protected java.lang.String |
replaceParametersInDefaultStrValue(java.lang.String value)
Replace parameters in
value with what you want and return it |
void |
reset()
Marks all configs to reread from storage
|
protected abstract ConfigStorage getConfigStorage()
protected abstract <T> java.lang.String configLocationFor(java.lang.Class<T> configInterface)
configInterface - config interfacepublic void reset()
public HotConfig getOrCreateConfig(HotConfigDefinition configDefinition)
configDefinition - definition of configpublic <T> T createConfig(java.lang.Class<T> configInterface)
configInterface - config interfaceprotected java.lang.String replaceParametersInDefaultStrValue(java.lang.String value)
value with what you want and return itvalue - value containing parameters