X-Git-Url: http://git.tuebingen.mpg.de/?a=blobdiff_plain;f=bloom.h;h=e7f3cd33dc2018d03f410064731c0a8be97b6e59;hb=fa21c55adb75551452241369424a146c7acb71a4;hp=afb22980d504e9a1d70cc3622ea8d647ea2566a5;hpb=3e7ac6a3c698a28e9f0cd2b69b2a85f789524d96;p=adu.git diff --git a/bloom.h b/bloom.h index afb2298..e7f3cd3 100644 --- a/bloom.h +++ b/bloom.h @@ -1,8 +1,22 @@ +/* + * Copyright (C) 2008 Andre Noll + * + * Licensed under the GPL v2. For licencing details see COPYING. + */ + +/** \file bloom.h Struct bloom and bloom filter functions. */ + +/** Describes one instance of a bloom filter. */ struct bloom { + /** The bloom filter is of size 2^order bits. */ unsigned order; + /** Set that many bits in the filter per entry. */ unsigned num_hash_functions; + /** How many entries have been inserted so far. */ uint64_t num_entries; + /** Number of bits currently set. */ uint64_t num_set_bits; + /** The bit array. */ uint8_t *filter; };