Class ManagedReloadingDetector

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private org.apache.commons.logging.Log log
      The logger.
      private boolean reloadingRequired
      A flag whether a reload is required.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean isReloadingRequired()
      Checks whether reloading is required.
      void refresh()
      Tells this strategy that the monitored configuration file should be refreshed.
      void reloadingPerformed()
      Notifies this object that a reload operation has been performed.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • log

        private final org.apache.commons.logging.Log log
        The logger.
      • reloadingRequired

        private volatile boolean reloadingRequired
        A flag whether a reload is required.
    • Constructor Detail

      • ManagedReloadingDetector

        public ManagedReloadingDetector()
    • Method Detail

      • isReloadingRequired

        public boolean isReloadingRequired()
        Checks whether reloading is required. This implementation checks whether the refresh() method has been invoked.
        Specified by:
        isReloadingRequired in interface ReloadingDetector
        Returns:
        a flag whether reloading is required
      • reloadingPerformed

        public void reloadingPerformed()
        Notifies this object that a reload operation has been performed. This method is called after reloadingRequired() has returned true. It can be used to reset internal state in order to detect the next reload operation. This implementation resets the internal flag indicating that a reload should be performed.
        Specified by:
        reloadingPerformed in interface ReloadingDetector