org.jboss.test.util.test.concurrent
Class ThreadPoolTaskUnitTestCase.TestTask

java.lang.Object
  extended by org.jboss.test.util.test.concurrent.ThreadPoolTaskUnitTestCase.TestTask
All Implemented Interfaces:
org.jboss.util.threadpool.Task
Enclosing class:
ThreadPoolTaskUnitTestCase

public class ThreadPoolTaskUnitTestCase.TestTask
extends Object
implements org.jboss.util.threadpool.Task

Test task


Field Summary
 
Fields inherited from interface org.jboss.util.threadpool.Task
WAIT_FOR_COMPLETE, WAIT_FOR_START, WAIT_NONE
 
Constructor Summary
ThreadPoolTaskUnitTestCase.TestTask(int test, String data)
          Create a new TestTask
ThreadPoolTaskUnitTestCase.TestTask(int test, String data, long startTimeout, int waitType)
          Create a new TestTask
ThreadPoolTaskUnitTestCase.TestTask(int test, String data, long startTimeout, long completionTimeout, int waitType)
           
 
Method Summary
 void accepted(long time)
           
 void completed(long time, Throwable throwable)
           
 void execute()
           
 long getCompletionTimeout()
           
 int getPriority()
           
 long getStartTimeout()
           
 int getWaitType()
           
 void rejected(long time, Throwable throwable)
           
 void saveThreadName()
           
 void setRunSleepTime(long runSleepTime)
           
 void started(long time)
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThreadPoolTaskUnitTestCase.TestTask

public ThreadPoolTaskUnitTestCase.TestTask(int test,
                                           String data)
Create a new TestTask

Parameters:
test - the test
data - the test data

ThreadPoolTaskUnitTestCase.TestTask

public ThreadPoolTaskUnitTestCase.TestTask(int test,
                                           String data,
                                           long startTimeout,
                                           int waitType)
Create a new TestTask

Parameters:
test - the test
data - the test data
startTimeout - the start timeout
waitType - the wait type

ThreadPoolTaskUnitTestCase.TestTask

public ThreadPoolTaskUnitTestCase.TestTask(int test,
                                           String data,
                                           long startTimeout,
                                           long completionTimeout,
                                           int waitType)
Method Detail

execute

public void execute()
Specified by:
execute in interface org.jboss.util.threadpool.Task

saveThreadName

public void saveThreadName()

accepted

public void accepted(long time)
Specified by:
accepted in interface org.jboss.util.threadpool.Task

rejected

public void rejected(long time,
                     Throwable throwable)
Specified by:
rejected in interface org.jboss.util.threadpool.Task

started

public void started(long time)
Specified by:
started in interface org.jboss.util.threadpool.Task

completed

public void completed(long time,
                      Throwable throwable)
Specified by:
completed in interface org.jboss.util.threadpool.Task

getCompletionTimeout

public long getCompletionTimeout()
Specified by:
getCompletionTimeout in interface org.jboss.util.threadpool.Task

getPriority

public int getPriority()
Specified by:
getPriority in interface org.jboss.util.threadpool.Task

getStartTimeout

public long getStartTimeout()
Specified by:
getStartTimeout in interface org.jboss.util.threadpool.Task

getWaitType

public int getWaitType()
Specified by:
getWaitType in interface org.jboss.util.threadpool.Task

stop

public void stop()
Specified by:
stop in interface org.jboss.util.threadpool.Task

setRunSleepTime

public void setRunSleepTime(long runSleepTime)


Copyright © 2009 JBoss Inc.. All Rights Reserved.