class SynchronousFileWatcher {

    public boolean checkAndReset() throws IOException {
        if (checkUpdateMillis <= 0) { // if checkUpdateMillis <= 0, always check
            return checkForUpdate();
        } else {
            final StateWrapper stateWrapper = lastState.get();
            if (stateWrapper.getTimestamp() < System.currentTimeMillis() - checkUpdateMillis) {
                return checkForUpdate();
            }
            return false;
        }
    }

    public  SynchronousFileWatcher(final Path path, final UpdateMonitor monitor);
    public  SynchronousFileWatcher(final Path path, final UpdateMonitor monitor, final long checkMillis);

}