public class Configuration extends Object
Modifier and Type | Field and Description |
---|---|
static String |
DATABASE_PROPERTIES_FILENAME
Filename of the
database.properties file |
static int |
DAYS_BEFORE_SUPPRESSION
Numbers of days between an entry is set to be deleted and its actual
deletion.
|
static String |
DN_ACCOUNTS |
static String |
DN_ENHANCED_SCHEMA |
static String |
DN_LDAP_SCHEMA |
static String |
DN_PEOPLE |
static String |
DN_REAL_ROOT |
static String |
DN_STRUCTURES |
static String |
location
Default location for configuration filename
|
static String |
LSC_SYNCOPTIONS_PREFIX
Prefix for syncoptions configuration elements in lsc.properties
|
static String |
LSC_TASKS_PREFIX
Prefix for tasks configuration elements in lsc.properties
|
static int |
MAX_CONCURRENT_SYNCHRONIZED
The maximum limit of data that can be synchronized by a synchronous task
|
static String |
OBJECTCLASS_EMPLOYEE |
static String |
OBJECTCLASS_PERSON |
static String |
PROPERTIES_FILENAME
Filename of the
lsc.properties file |
static int |
UID_MAX_LENGTH |
Modifier and Type | Method and Description |
---|---|
static void |
assertPropertyNotEmpty(String propertyName,
String propertyValue,
String location)
Helper method to check that a String read in from a property is not empty or null
|
static Properties |
getAsProperties(org.apache.commons.configuration.PropertiesConfiguration propsConf,
String prefix)
Deprecated.
|
static Properties |
getAsProperties(String prefix)
Deprecated.
|
static Properties |
getAsProperties(String filename,
String prefix)
Deprecated.
|
static String |
getConfigurationDirectory()
Get the path to the directory where configuration files
are stored, with a "/" at the end (or "\" on Windows).
|
static Properties |
getDstProperties()
Deprecated.
|
static int |
getInt(String key,
int defaultValue)
Deprecated.
|
static Properties |
getPropertiesFromFile(String pathToFile)
Deprecated.
|
static Properties |
getPropertiesFromFileInConfigDir(String fileName)
Deprecated.
|
static Properties |
getPropertiesSubset(Properties originalProperties,
String prefix) |
static Properties |
getSrcProperties()
Deprecated.
|
static String |
getString(String key)
Deprecated.
|
static String |
getString(String key,
String defaultValue)
Deprecated.
|
static boolean |
isLoggingSetup()
Get the flag to determine if logging is configured or not yet
|
static void |
setLoggingSetup(boolean loggingSetup)
Set the flag to determine if logging is configured or not yet
|
static void |
setProperties(String prefix,
Properties props)
Set the new properties
|
static void |
setUp()
Set up configuration for the given location, including logback.
|
static void |
setUp(String lscConfigurationPath)
Set up configuration for the given location, including logback.
|
static void |
setUp(String lscConfigurationPath,
boolean validate)
Set up configuration for the given location, including logback.
|
public static final String PROPERTIES_FILENAME
lsc.properties
filepublic static final String DATABASE_PROPERTIES_FILENAME
database.properties
filepublic static String location
public static String DN_PEOPLE
public static String DN_LDAP_SCHEMA
public static String DN_ENHANCED_SCHEMA
public static String DN_STRUCTURES
public static String DN_ACCOUNTS
public static String OBJECTCLASS_PERSON
public static String OBJECTCLASS_EMPLOYEE
public static int DAYS_BEFORE_SUPPRESSION
public static String DN_REAL_ROOT
public static int UID_MAX_LENGTH
public static final String LSC_TASKS_PREFIX
public static final String LSC_SYNCOPTIONS_PREFIX
public static final int MAX_CONCURRENT_SYNCHRONIZED
@Deprecated public static Properties getSrcProperties() throws LscConfigurationException
LscConfigurationException
@Deprecated public static Properties getDstProperties() throws LscConfigurationException
LscConfigurationException
@Deprecated public static Properties getAsProperties(String prefix)
prefix
- The prefix used to select the properties.@Deprecated public static Properties getAsProperties(String filename, String prefix)
@Deprecated public static Properties getAsProperties(org.apache.commons.configuration.PropertiesConfiguration propsConf, String prefix)
public static Properties getPropertiesSubset(Properties originalProperties, String prefix)
@Deprecated public static int getInt(String key, int defaultValue)
key
- The property key.defaultValue
- The default value.@Deprecated public static String getString(String key)
key
- The property key.@Deprecated public static String getString(String key, String defaultValue)
key
- The property key.defaultValue
- The default value.public static String getConfigurationDirectory()
public static void setProperties(String prefix, Properties props) throws org.apache.commons.configuration.ConfigurationException
prefix
- the prefix or nullprops
- the news propertiesorg.apache.commons.configuration.ConfigurationException
@Deprecated public static Properties getPropertiesFromFile(String pathToFile) throws FileNotFoundException, IOException
pathToFile
- Absolute filename on the filesystem to read.FileNotFoundException
IOException
@Deprecated public static Properties getPropertiesFromFileInConfigDir(String fileName) throws FileNotFoundException, IOException
fileName
- Filename relative to the configuration directory.FileNotFoundException
IOException
public static void setUp()
public static void setUp(String lscConfigurationPath) throws LscException
lscConfigurationPath
- LscException
public static void setUp(String lscConfigurationPath, boolean validate) throws LscException
lscConfigurationPath
- LscException
public static void assertPropertyNotEmpty(String propertyName, String propertyValue, String location) throws LscConfigurationException
Helper method to check that a String read in from a property is not empty or null
propertyName
- Name of the property key as read from lsc.propertiespropertyValue
- Value read from the configurationlocation
- Where this property is read from, to display a meaningful error message (example: class name, task name, etc)RuntimeException
- If the property is null or empty.LscConfigurationException
public static void setLoggingSetup(boolean loggingSetup)
loggingSetup
- Is logging setup yet?public static boolean isLoggingSetup()
Copyright © 2005-2024 LSC project. All Rights Reserved.