pt.ua.concurrent
Interface InterruptibleAwaitingThreads

All Known Subinterfaces:
Signal, Sync, SyncCV
All Known Implementing Classes:
BinarySemaphore, BoundedSemaphore, CObject, DynamicBarrier, Event, Exchanger, FixedBarrier, GroupMutex, GroupMutexComposedCV, GroupMutexCV, Mutex, MutexCV, PersistentSignal, RWEx, RWExCV, Semaphore, TransientSignal

public interface InterruptibleAwaitingThreads

Java's interface to extend support for Interruptible Awaiting Threads.

This class follows DbC(tm) methodology (Wikipedia). Where possible, contracts are implement with native's Java assert.

Version:
0.5, October 2013
Author:
Miguel Oliveira e Silva (mos@ua.pt)

Method Summary
 void interruptWaitingThreads()
          Requests the interruption all threads blocked on current blocking module.
 boolean registerAwaitingThreads()
          Are threads registered when waiting (in await)?
 

Method Detail

registerAwaitingThreads

boolean registerAwaitingThreads()
Are threads registered when waiting (in await)?

Returns:
true, if threads are registered

interruptWaitingThreads

void interruptWaitingThreads()
                             throws ThreadInterruptedException
Requests the interruption all threads blocked on current blocking module.

Precondition:
registerAwaitingThreads() - registering of waiting threads activated

Throws:
ThreadInterruptedException