Class PathBasedSystemSettings
- java.lang.Object
-
- org.pentaho.platform.engine.core.system.PentahoBase
-
- org.pentaho.platform.engine.core.system.SystemSettings
-
- org.pentaho.platform.engine.core.system.PathBasedSystemSettings
-
- All Implemented Interfaces:
Serializable
,org.pentaho.platform.api.engine.ILogger
,org.pentaho.platform.api.engine.ISystemSettings
public class PathBasedSystemSettings extends SystemSettings
Behavior is identical toSystemSettings
except that the settings forPentahoSystem
can live in an arbitrary location in the file system (i.e. the file does not have to exist in the/system). The location of the file used to initialize PentahoSystem
is specified by theSystem
property whose key isSYSTEM_CFG_PATH_KEY
. If this key does not exist in theSystem
properties, then this class falls back on the behavior of SystemSettings (i.e. it gets the system settings from/system/pentaho.xml). - Author:
- Steven Barkdull
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
SYSTEM_CFG_PATH_KEY
key into System.property containing the path to the file containing settings information forPentahoSystem
.-
Fields inherited from class org.pentaho.platform.engine.core.system.SystemSettings
PENTAHOSETTINGSFILENAME
-
Fields inherited from class org.pentaho.platform.engine.core.system.PentahoBase
EMPTYLOGID, loggingLevel, LOGID_MASK1, LOGID_MASK2, LOGID_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description PathBasedSystemSettings()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected String
getAbsolutePath(String path)
Create a String containing the complete path to the system folder in the repository, and append the parameterpath
to it.org.dom4j.Document
getSettingsDocumentFromFile(File f)
String
getSystemCfgSourceName()
String
getSystemSetting(String settingName, String defaultValue)
List
getSystemSettings(String settingName)
-
Methods inherited from class org.pentaho.platform.engine.core.system.SystemSettings
getLogger, getSolutionPath, getSystemSetting, getSystemSettings, getSystemSettingsDocument, getSystemSettingsProperties, resetSettingsCache
-
Methods inherited from class org.pentaho.platform.engine.core.system.PentahoBase
debug, debug, error, error, fatal, fatal, genLogIdFromInfo, genLogIdFromInfo, genLogIdFromSession, getLoggingLevel, getLogId, getObjectName, info, info, setLoggingLevel, setLogId, trace, trace, warn, warn
-
-
-
-
Field Detail
-
SYSTEM_CFG_PATH_KEY
public static final String SYSTEM_CFG_PATH_KEY
key into System.property containing the path to the file containing settings information forPentahoSystem
.- See Also:
- Constant Field Values
-
-
Method Detail
-
getSystemSetting
public String getSystemSetting(String settingName, String defaultValue)
- Specified by:
getSystemSetting
in interfaceorg.pentaho.platform.api.engine.ISystemSettings
- Overrides:
getSystemSetting
in classSystemSettings
-
getSystemSettings
public List getSystemSettings(String settingName)
- Specified by:
getSystemSettings
in interfaceorg.pentaho.platform.api.engine.ISystemSettings
- Overrides:
getSystemSettings
in classSystemSettings
-
getAbsolutePath
protected String getAbsolutePath(String path)
Description copied from class:SystemSettings
Create a String containing the complete path to the system folder in the repository, and append the parameterpath
to it.- Overrides:
getAbsolutePath
in classSystemSettings
- Parameters:
path
- String containing the path of a file relative to the system folder in the repository- Returns:
- String containing the path
-
getSystemCfgSourceName
public String getSystemCfgSourceName()
- Specified by:
getSystemCfgSourceName
in interfaceorg.pentaho.platform.api.engine.ISystemSettings
- Overrides:
getSystemCfgSourceName
in classSystemSettings
-
getSettingsDocumentFromFile
public org.dom4j.Document getSettingsDocumentFromFile(File f) throws IOException, org.dom4j.DocumentException
- Overrides:
getSettingsDocumentFromFile
in classSystemSettings
- Throws:
IOException
org.dom4j.DocumentException
-
-