summaryrefslogtreecommitdiffstats
path: root/chrome/browser/safe_browsing/prefix_set.h
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/safe_browsing/prefix_set.h')
-rw-r--r--chrome/browser/safe_browsing/prefix_set.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/chrome/browser/safe_browsing/prefix_set.h b/chrome/browser/safe_browsing/prefix_set.h
index 229b772..cb2cd9f 100644
--- a/chrome/browser/safe_browsing/prefix_set.h
+++ b/chrome/browser/safe_browsing/prefix_set.h
@@ -59,12 +59,16 @@ namespace safe_browsing {
class PrefixSet {
public:
- explicit PrefixSet(const std::vector<SBPrefix>& prefixes);
+ explicit PrefixSet(const std::vector<SBPrefix>& sorted_prefixes);
~PrefixSet();
// |true| if |prefix| was in |prefixes| passed to the constructor.
bool Exists(SBPrefix prefix) const;
+ // Regenerate the vector of prefixes passed to the constructor into
+ // |prefixes|. Prefixes will be added in sorted order.
+ void GetPrefixes(std::vector<SBPrefix>* prefixes);
+
private:
// Maximum delta that can be encoded in a 16-bit unsigned.
static const unsigned kMaxDelta = 256 * 256;