org.apache.cassandra.utils

## Class BloomFilter

- java.lang.Object
- - org.apache.cassandra.utils.BloomFilter

All Implemented Interfaces:
  java.io.Closeable, java.lang.AutoCloseable, IFilter

Direct Known Subclasses:
  Murmur3BloomFilter

    public abstract class BloomFilter
    extends java.lang.Object
    implements IFilter

### Field Summary

Fields
`IBitSet` `bitset`
`int` `hashCount`

### Method Summary

Methods
`void` `add(java.nio.ByteBuffer key)`
`void` `clear()`
`void` `close()`
`long[]` `getHashBuckets(java.nio.ByteBuffer key, int hashCount, long max)`
`protected abstract void` `hash(java.nio.ByteBuffer b, int position, int remaining, long seed, long[] result)`
`boolean` `isPresent(java.nio.ByteBuffer key)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.apache.cassandra.utils.IFilter

`serializedSize`

### Field Detail

#### bitset

    public final IBitSet bitset

#### hashCount

    public final int hashCount

### Method Detail

#### hash

    protected abstract void hash(java.nio.ByteBuffer b,
            int position,
            int remaining,
            long seed,
            long[] result)

#### getHashBuckets

    public long[] getHashBuckets(java.nio.ByteBuffer key,
                        int hashCount,
                        long max)

#### add

    public void add(java.nio.ByteBuffer key)

Specified by:
  `add` in interface `IFilter`

#### isPresent

    public final boolean isPresent(java.nio.ByteBuffer key)

Specified by:
  `isPresent` in interface `IFilter`

#### clear

    public void clear()

Specified by:
  `clear` in interface `IFilter`

#### close

    public void close()

Specified by:
  `close` in interface `java.io.Closeable`
Specified by:
  `close` in interface `java.lang.AutoCloseable`
Specified by:
  `close` in interface `IFilter`