public final class ReasonerConfig
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private static SimpleXMLConfigFile |
configFileXML
The XML configuration file as
SimpleXMLConfigFile object. |
private static java.lang.String |
REASONER_CONFIG_PATH_KEY
The property key which holds the path to to reasoner XML configuration file.
|
Modifier | Constructor and Description |
---|---|
private |
ReasonerConfig()
No instances of this utility class.
|
Modifier and Type | Method and Description |
---|---|
private static void |
checkLoad()
Ensures that the configuration file was at least tried to load once.
|
static java.lang.Boolean |
exists()
Determines if the XML configuration file exists.
|
static java.lang.String |
get(java.lang.String config)
Tries to fetch the value of the requested configuration variable from the XML source as
String . |
static <T> T |
get(java.lang.String config,
java.lang.Class<T> clazz)
Tries to fetch the value of the requested configuration variable from the XML source as object of clazz.
|
static void |
refresh()
Refreshes the local representation of the XML configuration file.
|
private static final java.lang.String REASONER_CONFIG_PATH_KEY
private static SimpleXMLConfigFile configFileXML
SimpleXMLConfigFile
object.public static java.lang.String get(java.lang.String config)
String
.config
- The name of the requested configuration variable as String
.null
.public static <T> T get(java.lang.String config, java.lang.Class<T> clazz)
T
- The result type is defined by clazz.config
- The name of the requested configuration variable as String
.clazz
- The object type as which the value shall be returned.null
.private static void checkLoad()
public static void refresh()
public static java.lang.Boolean exists()
true
if the XML configuration file exists, otherwise false
.