LogFile
Logs a file into the log table and optionally locks the file
#include <\nlm\nit\nwsync.h> int LogFile ( char *fileName, BYTE lockDirective, WORD timeoutLimit);
For cross-platform functionality, call NWLogFileLock2.
A log table contains data-locking information used by a server. The server tracks this information. Whenever a file, logical record, or physical record is logged, information identifying the data being logged is placed in the log table. Normally a set of files or records are logged and then locked as a set. However, a single file or record can also be locked when it is placed in the log table.
When using log tables, an application first logs all files or records to complete a transaction. The application then attempts to lock the logged set of files or records. If some of the logged resources cannot be locked, the lock fails and none of the resources are locked. Therefore, either all of the resources needed to complete a transaction are locked or none of the resources are locked. This function cannot lock files that are exclusively locked by other applications.
When the lockDirective parameter specifies that the file should be locked when it is logged, the timeoutLimit parameter indicates how long the server should wait if it cannot lock the file immediately. The timeoutLimit parameter is specified in units of 1/18 of a second (0 means no wait).
The release functions are used to unlock a file (or set of files). The clear functions are used to unlock and remove a file (or set of files) from the log table.
SetCurrentNameSpace sets the name space which is used for parsing the path input to this function.