Keith Wang
and 1 contributors

NAME

DynGig::Util::LockFile::Time - timed lock with an advisory file

SYNOPSIS

 use DynGig::Util::LockFile::Time;
 
 my $lock = '/lock/file/path';

 DynGig::Util::LockFile::Time->lock( $lock, epoch => 3600, duration => 1200 );

 die "locked\n" if my $seconds = DynGig::Util::LockFile::Time->check( $lock );

DESCRIPTION

lock( file, epoch => start, duration => seconds )

Writes time into the file.

check( file )

Returns true if time lock is active. Returns false otherwise.

NOTE

See DynGig::Util