1 package jalview.ws2.operations;
3 import java.util.ArrayList;
5 import jalview.ws2.WSJob;
7 public class WSJobList<T extends WSJob> extends ArrayList<T>
9 private static final long serialVersionUID = -1684855135603987602L;
11 public int countSubmitted() {
13 for (WSJob job : this) {
14 if (job.getStatus().isSubmitted()) {
21 public int countQueuing() {
23 for (WSJob job : this) {
24 if (job.getStatus().isQueuing()) count++;
29 public int countRunning() {
31 for (WSJob job : this) {
32 if (job.getStatus().isRunning()) count++;
37 public int countDone() {
39 for (WSJob job : this) {
40 if (job.getStatus().isDone()) count++;
45 public int countFailed() {
47 for (WSJob job : this) {
48 if (job.getStatus().isFailed()) count++;
53 public int countSuccessful() {
54 return countDone() - countFailed() - countCancelled();
57 public int countCancelled() {
59 for (WSJob job : this) {
60 if (job.getStatus().isCancelled()) count++;