The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

File::IfModified - Perl extension for checking if-modified state of file

SYNOPSIS

  use File::IfModified qw(if_modified);

  my $cached_data;
  my $file = 'data for initialization of $cached_data';
  while( 1 ){
    if ( if_modified( $file ){
      
        # Open $file and
        # Init $cached_data
        ...
    } 
    # Use $cached_data
    ... 
    sleep 1;
  }

DESCRIPTION

  This module usefull for long running script with external dependenses on other files

EXPORT

None by default.

EXPORT_OK

if_modified( $file ) --- return status of $file for current script
touch( $file ) --- perl equivalent of unix touch
vtouch( $file ) --- virtual equivalent of touch: Flush internal cache "if_modified" for current file
vtouch_all( $file ) --- flush all "if_modified" cache.

SEE ALSO

    L<File-Modified>.

AUTHOR

A. G. Grishaev, <grian@cpan.org>

COPYRIGHT AND LICENSE

Copyright (C) 2011 by A. G. Grishaev

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.14.1 or, at your option, any later version of Perl 5 you may have available.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 87:

You forgot a '=back' before '=head1'