All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.darwinsys.locks.Lock Maven / Gradle / Ivy

There is a newer version: 1.8.0
Show newest version
package com.darwinsys.locks;

/** The representation of one lock in the
 * PessimisticLockManager.
 */
public interface Lock {
	
	/** Release this lock
	 * @return true if we released it, false if it was already released.
	 */
	public boolean release();
	
	/** Find out if this lock got released
	 * (typically due to being timed out)
	 * before we commit the action based on it.
	 * @return True if the lock has been released
	 */
	public boolean isReleased();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy