class ActiveSupport::FileUpdateChecker
def initialize(files, dirs = {}, &block)
changes. The array of files and list of directories cannot be changed
This method must also receive a block that will be called once a path
watched under that directory.
have directories as keys and the value is an array of extensions to be
of files and the second is an optional hash of directories. The hash must
It accepts two parameters on initialization. The first is an array
def initialize(files, dirs = {}, &block) unless block raise ArgumentError, "A block is required to initialize a FileUpdateChecker" end @files = files.freeze @glob = compile_glob(dirs) @block = block @watched = nil @updated_at = nil @last_watched = watched @last_update_at = updated_at(@last_watched) end