package io.trygvis.queue; import java.util.EnumMap; public class QueueStats { public final String name; public final long totalTaskCount; public final EnumMap states; public QueueStats(String name, EnumMap states) { this.name = name; this.states = states; long c = 0; for (Long l : states.values()) { c += l; } this.totalTaskCount = c; } }