Class BootConfig
java.lang.Object
org.summerboot.jexpress.boot.config.BootConfig
- All Implemented Interfaces:
JExpressConfig
- Direct Known Subclasses:
AuthConfig,GRPCClientConfig,GRPCServerConfig,HttpClientConfig,JPAConfig,NioConfig,SMTPClientConfig
- Author:
- Changski Tie Zheng Zhang 张铁铮, 魏泽北, 杜旺财, 杜富贵
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Fileprotected Stringprotected static final Stringstatic final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected booleanprotected org.apache.logging.log4j.Loggerprotected final Properties -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcreateIfNotExist(String fileName) static StringgenerateTemplate(Class configClass) info()static <T extends JExpressConfig>
TvoidLoad config settings with @Config, supported Java types:protected abstract voidloadCustomizedConfigs(File cfgFile, boolean isReal, ConfigUtil helper, Properties props) protected voidloadField(Field field, String configFolder, ConfigUtil helper, Properties props, boolean autoDecrypt) name()protected voidpreLoad(File cfgFile, boolean isReal, ConfigUtil helper, Properties props) temp()voidupdateConfigFile(Map<String, String> updatedCfgs) protected StringupdateFilePath(File domainDir, String fileName) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.summerboot.jexpress.boot.config.JExpressConfig
shutdown
-
Field Details
-
DESC_KMF
- See Also:
-
DESC_TMF
- See Also:
-
DESC_PLAINPWD
- See Also:
-
FILENAME_KEYSTORE
- See Also:
-
FILENAME_TRUSTSTORE_4SERVER
- See Also:
-
FILENAME_TRUSTSTORE_4CLIENT
- See Also:
-
logger
protected org.apache.logging.log4j.Logger logger -
generateTemplate
protected boolean generateTemplate -
props
-
cfgFile
-
configName
-
-
Constructor Details
-
BootConfig
protected BootConfig()
-
-
Method Details
-
instance
-
getProperties
-
temp
- Specified by:
tempin interfaceJExpressConfig- Returns:
- null - disable reload
-
name
- Specified by:
namein interfaceJExpressConfig
-
getCfgFile
- Specified by:
getCfgFilein interfaceJExpressConfig
-
info
- Specified by:
infoin interfaceJExpressConfig
-
createIfNotExist
-
preLoad
protected void preLoad(File cfgFile, boolean isReal, ConfigUtil helper, Properties props) throws Exception - Throws:
Exception
-
load
Load config settings with @Config, supported Java types:1. T, K: enum, String, boolean/Boolean, byte/Byte, char/short/Short, int/Integer, long/Long, float/Float, double/Double, BigDecimal, URI, URL, Path, File 2. <T>[] array 3. Immutable Set<T> 4. Immutable List<T> 5. Immutable Map<T, K> 6. KeyManagerFactory 7. TrustManagerFactory- Specified by:
loadin interfaceJExpressConfig- Parameters:
cfgFile-isReal-- Throws:
FileNotFoundExceptionIOException
-
loadCustomizedConfigs
protected abstract void loadCustomizedConfigs(File cfgFile, boolean isReal, ConfigUtil helper, Properties props) throws Exception - Throws:
Exception
-
loadField
protected void loadField(Field field, String configFolder, ConfigUtil helper, Properties props, boolean autoDecrypt) throws IllegalAccessException - Throws:
IllegalAccessException
-
updateFilePath
-
updateConfigFile
- Throws:
IOException
-
generateTemplate
-