Class OneShotLock
java.lang.Object
org.apache.tapestry5.commons.internal.util.LockSupport
org.apache.tapestry5.ioc.internal.util.OneShotLock
Logic for handling one shot semantics for classes; classes that include a method (or methods) that "locks down" the
instance, to prevent it from being used again in the future.
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.tapestry5.commons.internal.util.LockSupport
acquireReadLock, downgradeWriteLockToReadLock, releaseReadLock, releaseWriteLock, takeWriteLock, upgradeReadLockToWriteLock
-
Constructor Details
-
OneShotLock
public OneShotLock()
-
-
Method Details
-
check
Checks to see if the lock has been set (vialock()
).- Throws:
IllegalStateException
- if the lock is set
-
lock
Checks the lock, then sets it.
-