A lock file is a file that, if it exists, indicates that a particular
resource is in use. The lock_files package contains procedures to create
and destroy lock files under any operating system. If a lock file cannot
be locked, an error is reported.
create a lock file named file in optional directory dir.
Retry up to
retries (natural) times, waiting for wait (duration)
seconds between retries. Default for wait/retries in 1.0 second and almost
Example: lock_files.lock_file( "test_lock.lck" );
Ada Equivalent: GNAT.Lock_Files.Lock_File
the directory to place the lock file in
the name of the lock file
the number of seconds to wait between retries
the maximum number of retries
If the file cannot be locked, SparForte reports an error.
lock_files.unlock_file( [dir,] file )
delete the lock file name file in optional directory dir.
Example: lock_files.unlock_file( "test_lock.lck" );
Ada Equivalent: GNAT.Lock_Files.Unlock_File