Commit f58efa9a authored by Michael Ritter's avatar Michael Ritter

Update default visibility of fields

parent f19393f2
......@@ -28,7 +28,7 @@ public class KSFuture<V extends Runnable> extends KnownFuture<Submittable<V>> {
}
private void beforeExecute(Submittable<V> result) {
Collection c = result.collection;
Collection c = result.getCollection();
Semaphore semaphore = locks.get(c);
// LOG.debug(info(result) + " acquiring semaphore");
semaphore.acquireUninterruptibly();
......@@ -37,7 +37,7 @@ public class KSFuture<V extends Runnable> extends KnownFuture<Submittable<V>> {
}
private void afterExecute(Submittable<V> result) {
Collection c = result.collection;
Collection c = result.getCollection();
Semaphore semaphore = locks.get(c);
semaphore.release();
LOG.debug(info(result) + " released semaphore");
......@@ -54,7 +54,7 @@ public class KSFuture<V extends Runnable> extends KnownFuture<Submittable<V>> {
}
private String info(Submittable s) {
Collection c = s.collection;
Collection c = s.getCollection();
String group = c.getGroup();
if (group == null) {
group = "";
......
......@@ -9,10 +9,10 @@ import edu.umiacs.ace.monitor.core.Collection;
* Created by shake on 9/11/15.
*/
public class Submittable<V extends Runnable> implements Comparable<Submittable> {
final Collection collection;
final V runnable;
final RunType type;
RunState state;
private final Collection collection;
private final V runnable;
private final RunType type;
private RunState state;
Submittable(Collection collection, RunType type, V runnable) {
this.collection = collection;
......@@ -37,6 +37,10 @@ public class Submittable<V extends Runnable> implements Comparable<Submittable>
return type;
}
public Collection getCollection() {
return collection;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment