private <T> Mono<T> createMono(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createMono(connection -> function.apply(connection.zSetCommands())); }
private <T> Flux<T> createFlux(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createFlux(connection -> function.apply(connection.zSetCommands())); }
@Override @SafeVarargs public final Mono<Long> remove(K key, V... members) { Assert.notNull(key, "Key must not be null!"); Assert.notEmpty(members, "Members must not be null or empty!"); Assert.noNullElements(members, "Members must not contain null elements!"); return template.createMono(connection -> Flux.fromArray(members) // .map(this::rawValue) // .collectList() // .flatMap(serialized -> connection.zSetCommands().zRem(rawKey(key), serialized))); }
private <T> Mono<T> createMono(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createMono(connection -> function.apply(connection.zSetCommands())); }
private <T> Flux<T> createFlux(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createFlux(connection -> function.apply(connection.zSetCommands())); }
private <T> Mono<T> createMono(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createMono(connection -> function.apply(connection.zSetCommands())); }
private <T> Flux<T> createFlux(Function<ReactiveZSetCommands, Publisher<T>> function) { Assert.notNull(function, "Function must not be null!"); return template.createFlux(connection -> function.apply(connection.zSetCommands())); }
@Override @SafeVarargs public final Mono<Long> remove(K key, V... members) { Assert.notNull(key, "Key must not be null!"); Assert.notEmpty(members, "Members must not be null or empty!"); Assert.noNullElements(members, "Members must not contain null elements!"); return template.createMono(connection -> Flux.fromArray(members) // .map(this::rawValue) // .collectList() // .flatMap(serialized -> connection.zSetCommands().zRem(rawKey(key), serialized))); }
@Override @SafeVarargs public final Mono<Long> remove(K key, V... members) { Assert.notNull(key, "Key must not be null!"); Assert.notEmpty(members, "Members must not be null or empty!"); Assert.noNullElements(members, "Members must not contain null elements!"); return template.createMono(connection -> Flux.fromArray(members) // .map(this::rawValue) // .collectList() // .flatMap(serialized -> connection.zSetCommands().zRem(rawKey(key), serialized))); }