public static class EntityResource.InterestingTasksFirstComparator extends java.lang.Object implements java.util.Comparator<Task<?>>
So if there was a manual "foo" effector invoked via REST on this entity a day ago, a "bar" effector invoked from a parent effector would only be preferred if invoked in the last two hours; active subtasks of "bar" would be preferred if submitted within the last 12 minutes, unstarted subtasks if submitted within 2 minutes, and completed subtasks if within the last 12 seconds. Thus there is a heavy bias over time to show the top-level tasks, but there is also a bias for detail for very recent activity.
It's far from perfect but provides a way -- when there are lots of tasks -- that we can show important things, where important things are the top level and very recent.
Constructor and Description |
---|
InterestingTasksFirstComparator() |
InterestingTasksFirstComparator(Entity entity) |
Modifier and Type | Method and Description |
---|---|
int |
compare(Task<?> o1,
Task<?> o2) |
public InterestingTasksFirstComparator()
public InterestingTasksFirstComparator(Entity entity)