public class HGLock extends Object implements ReadWriteLock
An implementation of ReadWriteLock
that will use the currently
active database transaction if there is one (through BDBTxLock
)
or a default ReentrantReadWriteLock
if there is no current transaction.
The implementation is useful for runtime data structures that need protection
from concurrent access and that may or may not participate in a database
transaction.
Constructor and Description |
---|
HGLock(HyperGraph graph,
byte[] objectId)
Deprecated.
|
public HGLock(HyperGraph graph, byte[] objectId)
public Lock readLock()
readLock
in interface ReadWriteLock
public Lock writeLock()
writeLock
in interface ReadWriteLock
Copyright © 2015. All rights reserved.