io.github.mike10004.debutils.BufferedDebContents Maven / Gradle / Ivy
package io.github.mike10004.debutils;
import javax.annotation.Nullable;
import java.util.List;
import java.util.function.Predicate;
class BufferedDebContents implements DebContents {
private final List index;
public BufferedDebContents(List index) {
this.index = List.copyOf(index);
}
@Override
@Nullable
public DebEntry findEntry(Predicate super DebEntry> filter) {
return index().stream().filter(filter).findFirst().orElse(null);
}
@Override
public List index() {
return index;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy