[vcs-log] minor: convert anonymous to inner

This commit is contained in:
Julia Beliaeva
2016-12-13 20:53:02 +03:00
parent 65478ef19d
commit 2ecdd7625d
@@ -137,34 +137,7 @@ public class VcsLogFullDetailsIndex<T> implements Disposable {
protected void checkCanceled() {
ProgressManager.checkCanceled();
}
},
new ForwardIndex<Integer, T>() {
@NotNull
@Override
public InputKeyIterator<Integer, T> getInputKeys(int inputId) {
return EmptyInputKeyIterator.getInstance();
}
@Override
public void putInputData(int inputId, @NotNull Map<Integer, T> data) throws IOException {
}
@Override
public void flush() {
}
@Override
public void clear() throws IOException {
}
@Override
public void close() throws IOException {
}
});
}, new EmptyForwardIndex<>());
}
@Override
@@ -220,4 +193,28 @@ public class VcsLogFullDetailsIndex<T> implements Disposable {
return myVersion;
}
}
private static class EmptyForwardIndex<T> implements ForwardIndex<Integer, T> {
@NotNull
@Override
public InputKeyIterator<Integer, T> getInputKeys(int inputId) {
return EmptyInputKeyIterator.getInstance();
}
@Override
public void putInputData(int inputId, @NotNull Map<Integer, T> data) throws IOException {
}
@Override
public void flush() {
}
@Override
public void clear() throws IOException {
}
@Override
public void close() throws IOException {
}
}
}