Class SystemProperties
- java.lang.Object
-
- com.sun.identity.saml2.idpdiscovery.SystemProperties
-
public class SystemProperties extends Object
This class provides functionality that allows single-point-of-access to all related system properties. The class tries to retrieve IDP discovery related properties in services, if not exists, find a fileIDPDiscoveryConfig.properties
in the CLASSPATH accessible to this code. If multiple servers are running, each may have their own configuration file. The naming convention for such scenarios isIDPDiscoveryConfig_serverName
.
-
-
Constructor Summary
Constructors Constructor Description SystemProperties()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
get(String key)
Returns system property of a given key.static void
initializeProperties(String fileName)
Initializes the properties.
-
-
-
Method Detail
-
initializeProperties
public static void initializeProperties(String fileName) throws FileNotFoundException, IOException
Initializes the properties.- Parameters:
fileName
- name of file containing the properties to be initialized.- Throws:
FileNotFoundException
IOException
-
get
public static String get(String key)
Returns system property of a given key. The method will get the property using SystemPropertiesManager first (server mode), if not found, get it from the locale file (IDP discovery WAR only mode).- Parameters:
key
- the key whose value to be returned.- Returns:
- the value if the key exists; otherwise returns
null
.
-
-