Query: module::refresh
OS: debian
Section: 3pm
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
Module::Refresh(3pm) User Contributed Perl Documentation Module::Refresh(3pm)NAMEModule::Refresh - Refresh %INC files when updated on diskSYNOPSIS# During each request, call this once to refresh changed modules: Module::Refresh->refresh; # Each night at midnight, you automatically download the latest # Acme::Current from CPAN. Use this snippet to make your running # program pick it up off disk: $refresher->refresh_module('Acme/Current.pm');DESCRIPTIONThis module is a generalization of the functionality provided by Apache::StatINC and Apache::Reload. It's designed to make it easy to do simple iterative development when working in a persistent environment. It does not require mod_perl. new Initialize the module refresher. refresh Refresh all modules that have mtimes on disk newer than the newest ones we've got. Calls "new" to initialize the cache if it had not yet been called. Specifically, it will renew any module that was loaded before the previous call to "refresh" (or "new") and has changed on disk since then. If a module was both loaded for the first time and changed on disk between the previous call and this one, it will not be reloaded by this call (or any future one); you will need to update the modification time again (by using the Unix "touch" command or making a change to it) in order for it to be reloaded. refresh_module_if_modified $module If $module has been modified on disk, refresh it. Otherwise, do nothing refresh_module $module Refresh a module. It doesn't matter if it's already up to date. Just do it. Note that it only accepts module names like "Foo/Bar.pm", not "Foo::Bar". unload_module $module Remove a module from %INC, and remove all subroutines defined in it. mtime $file Get the last modified time of $file in seconds since the epoch; update_cache $file Updates the cached "last modified" time for $file. unload_subs $file Wipe out subs defined in $file.BUGSWhen we walk the symbol table to whack reloaded subroutines, we don't have a good way to invalidate the symbol table properly, so we mess up on things like global variables that were previously set.SEE ALSOApache::StatINC, Module::ReloadCOPYRIGHTCopyright 2004,2011 by Jesse Vincent <jesse@bestpractical.com>, Audrey Tang <audreyt@audreyt.org> This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See <http://www.perl.com/perl/misc/Artistic.html> perl v5.12.4 2011-10-26 Module::Refresh(3pm)
Related Man Pages |
---|
module::loaded(3pm) - mojave |
apache::reload(3) - osx |
net::ldap::extension::refresh(3) - osx |
exporter::lite(3pm) - debian |
module::install::admin(3pm) - debian |
Similar Topics in the Unix Linux Community |
---|
Refresh ls list on screen (auto-refresh)? |
Finding the modified date time of a file |
Autosys_Query |
SAMBA Refresh problem for AIX |
Refresh the jobs in Autosys Scheduler |