HH\Lib\File\Lock

Facebook Engineer?

This function is available as File\Lock() in Facebook's www repository.

A File Lock, which is unlocked as a disposable

To acquire one, call lock on a Base object.

Note that in some cases, such as the non-blocking lock types, we may throw an LockAcquisitionException instead of acquiring the lock. If this is not desired behavior it should be guarded against.

Interface Synopsis

namespace HH\Lib\File;

final class Lock implements \IDisposable {...}

Public Methods