Class SingleInstanceLockFactory
Implements LockFactory for a single in-process instance, meaning all locking will take place through this one instance. Only use this LockFactory when you are certain all IndexReaders and IndexWriters for a given index are running against a single shared in-process Directory instance. This is currently the default locking for RAMDirectory.
Inherited Members
Namespace: Lucene.Net.Store
Assembly: Lucene.Net.dll
Syntax
public class SingleInstanceLockFactory : LockFactory
Methods
ClearLock(string)
Attempt to clear (forcefully unlock and remove) the specified lock. Only call this at a time when you are certain this lock is no longer in use.
Declaration
public override void ClearLock(string lockName)
Parameters
Type | Name | Description |
---|---|---|
string | lockName | name of the lock to be cleared. |
Overrides
See Also
MakeLock(string)
Return a new Lock instance identified by lockName
.
Declaration
public override Lock MakeLock(string lockName)
Parameters
Type | Name | Description |
---|---|---|
string | lockName | name of the lock to be created. |
Returns
Type | Description |
---|---|
Lock |