From 7b4371ab7c6fcde998ab1336b1568dfc8e1ebd80 Mon Sep 17 00:00:00 2001 From: Nikita Date: Fri, 17 Jul 2015 14:27:33 +0300 Subject: [PATCH] RHyperLogLogAsync interface added. #186 --- .../java/org/redisson/core/RHyperLogLog.java | 14 +------- .../org/redisson/core/RHyperLogLogAsync.java | 34 +++++++++++++++++++ 2 files changed, 35 insertions(+), 13 deletions(-) create mode 100644 src/main/java/org/redisson/core/RHyperLogLogAsync.java diff --git a/src/main/java/org/redisson/core/RHyperLogLog.java b/src/main/java/org/redisson/core/RHyperLogLog.java index 55de3cdeb..967867bb1 100644 --- a/src/main/java/org/redisson/core/RHyperLogLog.java +++ b/src/main/java/org/redisson/core/RHyperLogLog.java @@ -15,11 +15,9 @@ */ package org.redisson.core; -import io.netty.util.concurrent.Future; - import java.util.Collection; -public interface RHyperLogLog extends RExpirable { +public interface RHyperLogLog extends RExpirable, RHyperLogLogAsync { boolean add(V obj); @@ -31,14 +29,4 @@ public interface RHyperLogLog extends RExpirable { void mergeWith(String ... otherLogNames); - Future addAsync(V obj); - - Future addAllAsync(Collection objects); - - Future countAsync(); - - Future countWithAsync(String ... otherLogNames); - - Future mergeWithAsync(String ... otherLogNames); - } diff --git a/src/main/java/org/redisson/core/RHyperLogLogAsync.java b/src/main/java/org/redisson/core/RHyperLogLogAsync.java new file mode 100644 index 000000000..82e453664 --- /dev/null +++ b/src/main/java/org/redisson/core/RHyperLogLogAsync.java @@ -0,0 +1,34 @@ +/** + * Copyright 2014 Nikita Koksharov, Nickolay Borbit + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.redisson.core; + +import io.netty.util.concurrent.Future; + +import java.util.Collection; + +public interface RHyperLogLogAsync extends RExpirableAsync { + + Future addAsync(V obj); + + Future addAllAsync(Collection objects); + + Future countAsync(); + + Future countWithAsync(String ... otherLogNames); + + Future mergeWithAsync(String ... otherLogNames); + +}