pike.git / lib / modules / Filesystem.pmod / Monitor.pmod / basic.pike

version» Context lines:

pike.git/lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1:   //   // Basic filesystem monitor.   // - // $Id: basic.pike,v 1.35 2010/02/02 14:34:47 grubba Exp $ + // $Id: basic.pike,v 1.36 2010/02/03 15:24:41 grubba Exp $   //   // 2009-07-09 Henrik Grubbström   //      //! Basic filesystem monitor.   //!   //! This module is intended to be used for incremental scanning of   //! a filesystem.      //! The default maximum number of seconds between checks of directories
pike.git/lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:340:       //! Check if this monitor should be removed automatically.    void check_for_release(int mask, int flags)    {    if ((this_program::flags & mask) == flags) {    m_delete(monitors, path);    release_monitor(this);    }    }    +  //! Called to create a sub monitor. +  protected void monitor(string path, int flags, int max_dir_interval, +  int file_interval_factor, int stable_time) +  { +  global::monitor(path, flags, max_dir_check_interval, +  file_interval_factor, stable_time); +  } +     //! Called when the status has changed for an existing file.    protected int(0..1) status_change(Stdio.Stat old_st, Stdio.Stat st,    int orig_flags)    {    if (st->isdir) {    array(string) files = get_dir(path) || ({});    array(string) new_files = files;    array(string) deleted_files = ({});    if (this_program::files) {    new_files -= this_program::files;