|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.quartz.impl.jdbcjobstore.StdRowLockSemaphore
An interface for providing thread/resource locking in order to protect resources from being altered by multiple threads at the same time.
Field Summary | |
static java.lang.String |
SELECT_FOR_LOCK
|
Constructor Summary | |
StdRowLockSemaphore(java.lang.String tablePrefix,
java.lang.String selectWithLockSQL)
|
Method Summary | |
boolean |
isLockOwner(java.sql.Connection conn,
java.lang.String lockName)
Determine whether the calling thread owns a lock on the identified resource. |
boolean |
obtainLock(java.sql.Connection conn,
java.lang.String lockName)
Grants a lock on the identified resource to the calling thread (blocking until it is available). |
void |
releaseLock(java.sql.Connection conn,
java.lang.String lockName)
Release the lock on the identified resource if it is held by the calling thread. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String SELECT_FOR_LOCK
Constructor Detail |
public StdRowLockSemaphore(java.lang.String tablePrefix, java.lang.String selectWithLockSQL)
Method Detail |
public boolean obtainLock(java.sql.Connection conn, java.lang.String lockName) throws LockException
obtainLock
in interface Semaphore
LockException
public void releaseLock(java.sql.Connection conn, java.lang.String lockName)
releaseLock
in interface Semaphore
public boolean isLockOwner(java.sql.Connection conn, java.lang.String lockName)
isLockOwner
in interface Semaphore
|
Quartz Project Page | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |