Class FileConfigurationMonitor

  extended by org.apache.logging.log4j.core.config.FileConfigurationMonitor
All Implemented Interfaces:

public class FileConfigurationMonitor
extends Object
implements ConfigurationMonitor

Configuration monitor that periodically checks the timestamp of the configuration file and calls the ConfigurationListeners when an update occurs.

Constructor Summary
FileConfigurationMonitor(Reconfigurable reconfigurable, File file, List<ConfigurationListener> listeners, int interval)
Method Summary
 void checkConfiguration()
          Called to determine if the configuration has changed.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public FileConfigurationMonitor(Reconfigurable reconfigurable,
                                File file,
                                List<ConfigurationListener> listeners,
                                int interval)

reconfigurable - The Configuration that can be reconfigured.
file - The File to monitor.
listeners - The List of ConfigurationListeners to notify upon a change.
interval - The monitor interval in seconds. The minimum interval is 5 seconds.
Method Detail


public void checkConfiguration()
Called to determine if the configuration has changed.

Specified by:
checkConfiguration in interface ConfigurationMonitor

Copyright © 1999-2014 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.