|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.googlecode.lightest.core.QueuedDispatcherAssignmentStrategy
public abstract class QueuedDispatcherAssignmentStrategy
Assigns testcases to dispatchers in a FIFO manner. Each testcase passed into assign() waits in a queue until getAvailableDispatchers() returns an idle ITaskDispatcher object the testcase can be assigned to.
| Constructor Summary | |
|---|---|
QueuedDispatcherAssignmentStrategy()
|
|
| Method Summary | |
|---|---|
boolean |
assign(LightestTestCase testcase)
Assigns a dispatcher to a testcase, and the testcase to the dispatcher. |
protected List |
getAvailableDispatchers(LightestTestCase testcase)
Returns a potentially empty list of currently available (unassigned) task dispatchers for a given testcase. |
protected abstract List |
getCompatibleDispatchers(LightestTestCase testcase)
|
groovy.lang.MetaClass |
getMetaClass()
|
Object |
getProperty(String name)
|
Object |
invokeMethod(String name,
Object args)
|
void |
setAssignmentTimeout(long timeout)
Sets the maximum time a testcase will wait to have a task dispatcher assigned to it, before timing out. |
void |
setMetaClass(groovy.lang.MetaClass metaClass)
|
void |
setProperty(String name,
Object value)
|
void |
unassign(LightestTestCase testcase)
Breaks the bi-directional association between a dispatcher and a testcase. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.googlecode.lightest.core.IDispatcherAssignmentStrategy |
|---|
setDispatchers |
| Constructor Detail |
|---|
public QueuedDispatcherAssignmentStrategy()
| Method Detail |
|---|
public void setAssignmentTimeout(long timeout)
timeout - allotted time, in milliseconds. Non-positive values will
be considered infinite time.public boolean assign(LightestTestCase testcase)
assign in interface IDispatcherAssignmentStrategytestcase - public void unassign(LightestTestCase testcase)
IDispatcherAssignmentStrategy
unassign in interface IDispatcherAssignmentStrategyprotected List getAvailableDispatchers(LightestTestCase testcase)
testcase - the testcase for which to return the dispatchersprotected abstract List getCompatibleDispatchers(LightestTestCase testcase)
public groovy.lang.MetaClass getMetaClass()
getMetaClass in interface groovy.lang.GroovyObjectpublic void setMetaClass(groovy.lang.MetaClass metaClass)
setMetaClass in interface groovy.lang.GroovyObject
public Object invokeMethod(String name,
Object args)
invokeMethod in interface groovy.lang.GroovyObjectpublic Object getProperty(String name)
getProperty in interface groovy.lang.GroovyObject
public void setProperty(String name,
Object value)
setProperty in interface groovy.lang.GroovyObject
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||