public abstract class

FileWatchdog

extends Thread
java.lang.Object
   ↳ java.lang.Thread
     ↳ org.apache.log4j.helpers.FileWatchdog

Class Overview

Check every now and then that a certain file has not changed. If it has, then call the doOnChange() method.

Summary

Constants
long DEFAULT_DELAY The default delay between every file modification check, set to 60 seconds.
[Expand]
Inherited Constants
From class java.lang.Thread
Fields
protected long delay The delay to observe between every check.
protected String filename The name of the file to observe for changes.
Protected Constructors
FileWatchdog(String filename)
Public Methods
void run()
void setDelay(long delay)
Set the delay to observe between each check of the file changes.
Protected Methods
void checkAndConfigure()
abstract void doOnChange()
[Expand]
Inherited Methods
From class java.lang.Thread
From class java.lang.Object
From interface java.lang.Runnable

Constants

public static final long DEFAULT_DELAY

The default delay between every file modification check, set to 60 seconds.

Constant Value: 60000 (0x000000000000ea60)

Fields

protected long delay

The delay to observe between every check. By default set DEFAULT_DELAY.

protected String filename

The name of the file to observe for changes.

Protected Constructors

protected FileWatchdog (String filename)

Public Methods

public void run ()

public void setDelay (long delay)

Set the delay to observe between each check of the file changes.

Protected Methods

protected void checkAndConfigure ()

protected abstract void doOnChange ()