public interface Cuckoo
Modifier and Type | Method and Description |
---|---|
boolean |
cfAdd(String key,
String item)
CF.ADD Adds an item to the cuckoo filter, creating the filter if it does not
exist
|
boolean |
cfAddNx(String key,
String item)
CF.ADDNX Adds an item to the cuckoo filter, only if it does not exist yet
|
long |
cfCount(String key,
String item)
CF.COUNT Returns the number of times an item may be in the filter.
|
void |
cfCreate(String key,
CFReserveOptions options)
CF.RESERVE Creates a Cuckoo Filter under key with the given parameters
|
void |
cfCreate(String key,
long capacity)
CF.RESERVE Creates a Cuckoo Filter under key with a single sub-filter for the
initial capacity
|
boolean |
cfDel(String key,
String item)
CF.DEL Deletes an item once from the filter.
|
boolean |
cfExists(String key,
String item)
CF.EXISTS Check if an item exists in a Cuckoo Filter
|
Map<String,Long> |
cfInfo(String key)
CF.INFO Return information about filter
|
List<Boolean> |
cfInsert(String key,
CFInsertOptions options,
String... items)
CF.INSERT Adds one or more items to a cuckoo filter, using the passed
options
|
List<Boolean> |
cfInsert(String key,
String... items)
CF.INSERT Adds one or more items to a cuckoo filter, creating it if it does
not exist yet.
|
List<Boolean> |
cfInsertNx(String key,
CFInsertOptions options,
String... items)
CF.INSERTNX Adds one or more items to a cuckoo filter, using the passed
options
|
List<Boolean> |
cfInsertNx(String key,
String... items)
CF.INSERTNX Adds one or more items to a cuckoo filter, only if it does not
exist yet
|
void |
cfLoadChunk(String key,
Map.Entry<Long,byte[]> iterAndData)
CF.LOADCHUNK Restores a filter previously saved using SCANDUMP .
|
Map.Entry<Long,byte[]> |
cfScanDump(String key,
long iterator)
CF.SCANDUMP Begins an incremental save of the cuckoo filter.
|
Iterator<Map.Entry<Long,byte[]>> |
cfScanDumpIterator(String key)
CF.SCANDUMP Begins an incremental save of the cuckoo filter.
|
java.util.stream.Stream<Map.Entry<Long,byte[]>> |
cfScanDumpStream(String key)
CF.SCANDUMP Begins an incremental save of the cuckoo filter.
|
void cfCreate(String key, CFReserveOptions options)
key
- The name of the filteroptions
- An instance of CFReserveOptions containing the options
(CAPACITY/BUCKESIZE/MAXITERATIONS/EXPANSION)void cfCreate(String key, long capacity)
key
- The key under which the filter is foundcapacity
- Estimated capacity for the filterboolean cfAdd(String key, String item)
key
- The name of the filteritem
- The item to addboolean cfAddNx(String key, String item)
key
- The name of the filteritem
- The item to addList<Boolean> cfInsert(String key, String... items)
key
- The name of the filteritems
- One or more items to addList<Boolean> cfInsert(String key, CFInsertOptions options, String... items)
key
- The name of the filteroptions
- An instance of CFInsertOptions containing the options
(CAPACITY/NOCREATE)items
- One or more items to addList<Boolean> cfInsertNx(String key, String... items)
key
- The name of the filteritems
- One or more items to addList<Boolean> cfInsertNx(String key, CFInsertOptions options, String... items)
key
- The name of the filteroptions
- An instance of CFInsertOptions containing the options
(CAPACITY/NOCREATE)items
- One or more items to addboolean cfExists(String key, String item)
key
- The name of the filteritem
- The item to check forboolean cfDel(String key, String item)
key
- The name of the filteritem
- The item to delete from the filterlong cfCount(String key, String item)
key
- The name of the filteritem
- The item to countMap.Entry<Long,byte[]> cfScanDump(String key, long iterator)
key
- Name of the filteriterator
- This is either 0, or the iterator from a previous invocation
of this commandIterator<Map.Entry<Long,byte[]>> cfScanDumpIterator(String key)
key
- Name of the filterjava.util.stream.Stream<Map.Entry<Long,byte[]>> cfScanDumpStream(String key)
void cfLoadChunk(String key, Map.Entry<Long,byte[]> iterAndData)
key
- Name of the filter to restoreiterAndData
- Pair of iterator and dataCopyright © 2021 RedisLabs. All rights reserved.