| net.sourceforge.groboutils.junit.v1.TestRunnable net.sourceforge.groboutils.junit.v1.TestMonitorRunnable
TestMonitorRunnable | abstract public class TestMonitorRunnable extends TestRunnable (Code) | | A helper class to more easily create monitors. TestRunnable monitors
do not have to extend this class, but it helps in becoming more
conformant to the requirements of the superclass.
author: Matt Albrecht groboclown@users.sourceforge.net version: $Date: 2003/09/29 21:09:40 $ since: July 12, 2003 |
Method Summary | |
abstract public void | runMonitor() Performs checks on the monitored object which is being subjected
to parallel processing. | public void | runTest() Performs all the necessary looping, end-of-threads, and interrupt
checking. | protected void | yieldProcessing() Instructs the thread to pause for a while. |
TestMonitorRunnable | public TestMonitorRunnable()(Code) | | |
runMonitor | abstract public void runMonitor() throws Throwable(Code) | | Performs checks on the monitored object which is being subjected
to parallel processing. This method should not perform looping
over the check(s), since the runTest() method will
perform these.
exception: Throwable - any exception may be thrown and will bereported as a test failure, except forInterruptedExceptions, which will be ignored. |
runTest | public void runTest() throws Throwable(Code) | | Performs all the necessary looping, end-of-threads, and interrupt
checking. The inner loop calls the runMonitor()
method.
|
yieldProcessing | protected void yieldProcessing() throws InterruptedException(Code) | | Instructs the thread to pause for a while. This method is called
by the runTest() method's loop, immediately after
each runMonitor() invocation. The default implementation
performs a Thread.yield() call, but by putting it into
this method, that behavior can be modified.
exception: InterruptedException - allows for overloading methods toperform a delay( long ) call within theirimplementation. |
Fields inherited from net.sourceforge.groboutils.junit.v1.TestRunnable | final protected static Logger LOG(Code)(Java Doc)
|
|
|