organize and clean up
This commit is contained in:
@@ -5,6 +5,14 @@ import org.slf4j.Logger;
|
||||
import java.util.function.Consumer;
|
||||
|
||||
public interface LogAggregator {
|
||||
static LogAggregator empty() {
|
||||
return with(s -> {});
|
||||
}
|
||||
|
||||
static LogAggregator stdout() {
|
||||
return with(System.out::println);
|
||||
}
|
||||
|
||||
static LogAggregator with(final Consumer<String> consumer) {
|
||||
return new LogAggregatorImpl(consumer);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user