[ Index ] |
PHP Cross Reference of phpBB-3.1.12-deutsch |
[Source view] [Print] [Project Stats]
This file is part of the phpBB Forum Software package.
Copyright: | (c) phpBB Limited |
License: | GNU General Public License, version 2 (GPL-2.0) |
File Size: | 141 lines (3 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
flock:: (4 methods):
__construct()
acquire()
owns_lock()
release()
__construct($path) X-Ref |
Constructor. You have to call acquire() to actually acquire the lock. param: string $path Path to the file to which access is controlled |
acquire() X-Ref |
Tries to acquire the lock. If the lock is already held by another process, this call will block until the other process releases the lock. If a lock is acquired and is not released before script finishes but the process continues to live (apache/fastcgi) then subsequent processes trying to acquire the same lock will be blocked forever. If the lock is already held by the same process via another instance of this class, this call will block forever. If flock function is disabled in php or fails to work, lock acquisition will fail and false will be returned. return: bool true if lock was acquired |
owns_lock() X-Ref |
Does this process own the lock? return: bool true if lock is owned |
release() X-Ref |
Releases the lock. The lock must have been previously obtained, that is, acquire() call was issued and returned true. Note: Attempting to release a lock that is already released, that is, calling release() multiple times, is harmless. return: null |
Generated: Thu Jan 11 00:25:41 2018 | Cross-referenced by PHPXref 0.7.1 |