runAfter
public boolean runAfter(List tasks,
int size)
Returns true if the current instance of this task must be run
after at least one task in the task manager queue.
The criteria for determining what value to return:
If the task list contains any RegisterListenerTasks
or LookupTasks associated with this task's lookup service
(ProxyReg), and if those tasks were queued prior to this
task (have lower sequence numbers), then run those tasks
before this task (return true).
Additionally, if the task list contains any other
ServiceIdTasks associated with this task's service ID
which were queued prior to this task, then run those
tasks before this task.
If the criteria outlined above is not satisfied, then this
task can be run immediately (return false).
This method was added to address Bug ID 6291851.
- Specified by:
runAfter
in interface TaskManager.Task
- Overrides:
runAfter
in class ServiceDiscoveryManager.ServiceIdTask
- Parameters:
tasks
- the tasks to consider.size
- elements with index less than size are considered.