Class DefaultReloadingDetectorFactory
java.lang.Object
org.apache.commons.configuration2.builder.DefaultReloadingDetectorFactory
- All Implemented Interfaces:
ReloadingDetectorFactory
A default implementation of the ReloadingDetectorFactory interface.
This factory creates objects of type FileHandlerReloadingDetector. Instances have no state and can be shared
between multiple builders.
- Since:
- 2.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateReloadingDetector(FileHandler handler, FileBasedBuilderParametersImpl params) Creates a newReloadingDetectorobject based on the passed in parameters.
-
Constructor Details
-
DefaultReloadingDetectorFactory
public DefaultReloadingDetectorFactory()
-
-
Method Details
-
createReloadingDetector
public ReloadingDetector createReloadingDetector(FileHandler handler, FileBasedBuilderParametersImpl params) throws ConfigurationException Description copied from interface:ReloadingDetectorFactoryCreates a newReloadingDetectorobject based on the passed in parameters. TheFileHandlerpoints to the file to be monitored. (It may be different from theFileHandlermanaged by the parameters object.) TheFileBasedBuilderParametersImplobject may contain additional information for configuring the detector, for example a refresh delay.- Specified by:
createReloadingDetectorin interfaceReloadingDetectorFactory- Parameters:
handler- the handler of the file to be monitoredparams- parameters related to file-based configurations- Returns:
- the newly created
ReloadingDetector - Throws:
ConfigurationException- if an error occurs
-