org.apache.lucene.store

## Class NoLockFactory

- java.lang.Object
- - org.apache.lucene.store.LockFactory
  - - org.apache.lucene.store.NoLockFactory

-     public final class NoLockFactory
      extends LockFactory

  Use this `LockFactory` to disable locking entirely. This is a singleton, you have to use `INSTANCE`.
  See Also:
    `LockFactory`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static NoLockFactory` | `INSTANCE` The singleton

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Lock` | `obtainLock(Directory dir, String lockName)` Return a new obtained Lock instance identified by lockName.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### INSTANCE

          public static final NoLockFactory INSTANCE

      The singleton

  - ### Method Detail

    - #### obtainLock

          public Lock obtainLock(Directory dir,
                                 String lockName)

      Description copied from class: `LockFactory`
      Return a new obtained Lock instance identified by lockName.
      Specified by:
        `obtainLock` in class `LockFactory`
        `lockName` - name of the lock to be created.

Copyright © 2000-2019 Apache Software Foundation. All Rights Reserved.