Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Side by Side Diff: components/rappor/bloom_filter.h

Issue 1090683003: Alternative Multi-dimensional Rappor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use 64-bit shift Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « components/rappor/BUILD.gn ('k') | components/rappor/bloom_filter.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef COMPONENTS_RAPPOR_BLOOM_FILTER_H_ 5 #ifndef COMPONENTS_RAPPOR_BLOOM_FILTER_H_
6 #define COMPONENTS_RAPPOR_BLOOM_FILTER_H_ 6 #define COMPONENTS_RAPPOR_BLOOM_FILTER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 29 matching lines...) Expand all
40 40
41 // The number of bits to set for each string added. 41 // The number of bits to set for each string added.
42 uint32_t hash_function_count_; 42 uint32_t hash_function_count_;
43 43
44 // A number add to a hash function index to get a seed for that hash function. 44 // A number add to a hash function index to get a seed for that hash function.
45 uint32_t hash_seed_offset_; 45 uint32_t hash_seed_offset_;
46 46
47 DISALLOW_COPY_AND_ASSIGN(BloomFilter); 47 DISALLOW_COPY_AND_ASSIGN(BloomFilter);
48 }; 48 };
49 49
50
51 namespace internal {
52
53 // A function for getting bloom filters less than or equal to 64 bits.
54 uint64_t GetBloomBits(uint32_t bytes_size,
55 uint32_t hash_function_count,
56 uint32_t hash_seed_offset,
57 const std::string& str);
58
59 } // namespace internal
60
50 } // namespace rappor 61 } // namespace rappor
51 62
52 #endif // COMPONENTS_RAPPOR_BLOOM_FILTER_H_ 63 #endif // COMPONENTS_RAPPOR_BLOOM_FILTER_H_
OLDNEW
« no previous file with comments | « components/rappor/BUILD.gn ('k') | components/rappor/bloom_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698