Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.webengine.notifier
Interface FileChangeListener

All Known Implementing Classes:
AbstractFileChangeListener, FileChangeNotifier

public interface FileChangeListener

An example of listener implementation:

 public class MyListener implements FileChangeListener {
 long lastNotif = 0;
 public void fileChanged(File file, long since, long now) {
       if (now == lastNotifFlush) return;
       if (isIntersetedInFile(file)) {
          lastNotif = now;
          flushCache(); // flush internal cache because file on disk changed
       }
  }
  }
 

Author:
Bogdan Stefanescu

Method Summary
 void filesCreated(java.util.List<java.io.File> entries)
           
 void filesModified(java.util.List<java.io.File> entries)
          Notifies that the given files changed.
 void filesRemoved(java.util.List<java.io.File> entries)
           
 

Method Detail

filesModified

void filesModified(java.util.List<java.io.File> entries)
                   throws java.lang.Exception
Notifies that the given files changed.

Throws:
java.lang.Exception

filesCreated

void filesCreated(java.util.List<java.io.File> entries)
                  throws java.lang.Exception
Throws:
java.lang.Exception

filesRemoved

void filesRemoved(java.util.List<java.io.File> entries)
                  throws java.lang.Exception
Throws:
java.lang.Exception

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.