java.lang.Object
org.miaixz.bus.setting.metric.setting.Setting
A utility class that provides static methods for accessing
Setting configuration
files, with caching support.- Since:
- Java 17+
- Author:
- Kimi Liu
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
Setting
public Setting()
-
-
Method Details
-
get
Gets a cachedSettinginstance for the given resource name. If the name has no extension,.settingis assumed. The file is loaded from the classpath.- Parameters:
name- The name of the settings file.- Returns:
- The cached or newly loaded
Settinginstance.
-
getFirstFound
Gets the firstSettinginstance that can be successfully loaded from a list of resource names. It tries each name in order until one is found.- Parameters:
names- The resource names to try. If a name has no extension,.settingis assumed.- Returns:
- The first found
Settinginstance, or null if none are found.
-