Package org.neo4j.graphdb
Interface Lock
- All Superinterfaces:
AutoCloseable
An acquired lock on an entity for a transaction, acquired from
Transaction.acquireWriteLock(Entity)
or
Transaction.acquireReadLock(Entity)
this lock
can be released manually using release()
. If not released
manually it will be automatically released when the transaction owning
it finishes.-
Method Summary
-
Method Details
-
release
void release()Releases this lock before the transaction finishes. It is an optional operation and if not called, this lock will be released when the owning transaction finishes.- Throws:
IllegalStateException
- if this lock has already been released.
-
close
default void close()Release this lock as described byrelease()
method.- Throws:
IllegalStateException
- if this lock has already been released.
-