Top Description Methods
org.testng.thread

public Interface IWorker<T>

extends Runnable, Comparable<IWorker<T>>
Known Direct Implementers
org.testng.internal.invokers.TestMethodWorker, org.testng.internal.thread.graph.PhoneyWorker, org.testng.internal.thread.graph.TestNGFutureTask, org.testng.SuiteRunnerWorker
Imports
java.util.List

A runnable object that is used by GraphThreadPoolExecutor to execute tasks

Method Summary

Modifier and TypeMethod and Description
public default boolean
public default long
public int

Returns:

the priority of this task.
getPriority
()

public List<T>

Returns:

list of tasks this worker is working on.
getTasks
()

public default long
public long

Returns:

the maximum time allowed for the worker to complete the task.
getTimeOut
()

public default void
setThreadIdToRunOn(long threadIdToRunOn)

Inherited from java.lang.Comparable:
compareTo
Inherited from java.lang.Runnable:
run

Method Detail

completedback to summary
public default boolean completed()
getCurrentThreadIdback to summary
public default long getCurrentThreadId()
getPriorityback to summary
public int getPriority()
Returns:int

the priority of this task.

getTasksback to summary
public List<T> getTasks()
Returns:List<T>

list of tasks this worker is working on.

getThreadIdToRunOnback to summary
public default long getThreadIdToRunOn()
getTimeOutback to summary
public long getTimeOut()
Returns:long

the maximum time allowed for the worker to complete the task.

setThreadIdToRunOnback to summary
public default void setThreadIdToRunOn(long threadIdToRunOn)