threaddemo.locking |
General locking utilities.
The main interface is {@link threaddemo.locking.Lock} and lock instances may be created with the
{@link threaddemo.locking.Locks} factory class.
Intended as a replacement for {@link org.openide.util.Mutex}.
|
Java Source File Name | Type | Comment |
DuplexLock.java | Interface | Lock which supports
PrivilegedLock methods. |
EventHybridLock.java | Class | Special "event hybrid" lock. |
EventHybridLockTest.java | Class | Test Locks.eventHybrid. |
EventLock.java | Class | Lock impl that works in the event thread. |
EventLockTest.java | Class | Test Locks.event. |
LockAction.java | Interface | Action to be executed in a lock without throwing any checked exceptions. |
LockExceptionAction.java | Interface | Action to be executed in a lock, possibly throwing checked exceptions. |
Locks.java | Class | Factory for locks. |
MonitorLock.java | Class | Simple lock that actually just uses a simple synchronization monitor. |
PrivilegedLock.java | Class | Ability to acquire or release a lock by itself.
This class can be used when one wants to avoid creating a
bunch of Runnables. |
ReadWriteLockTest.java | Class | Test behavior of Locks.readWrite and PrivilegedLock. |
ReadWriteLockWrapper.java | Class | Implementation of a regular lock (read/write). |
RWLock.java | Interface | Some kind of a lock, with support for possible read and write modes. |
Worker.java | Class | Worker thread (off-AWT) that can run tasks asynch. |