CavalliumDBEngine/src/main/java/it/cavallium/dbengine/database/LLSearchResult.java

18 lines
432 B
Java
Raw Normal View History

package it.cavallium.dbengine.database;
import java.util.function.BiFunction;
import lombok.Value;
import org.jetbrains.annotations.NotNull;
import reactor.core.publisher.Flux;
@Value
public class LLSearchResult {
Flux<LLSearchResultShard> results;
@NotNull
public static BiFunction<LLSearchResult, LLSearchResult, LLSearchResult> accumulator() {
2021-03-03 15:03:25 +01:00
return (a, b) -> new LLSearchResult(Flux.merge(a.results, b.results));
}
}