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

Side by Side Diff: chrome/browser/browsing_data/browsing_data_channel_id_helper.h

Issue 546663003: Remove Clone() from CannedBrowsingData*Helper classes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
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 CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_ 5 #ifndef CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_
6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_ 6 #define CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 }; 46 };
47 47
48 // This class is a thin wrapper around BrowsingDataChannelIDHelper that 48 // This class is a thin wrapper around BrowsingDataChannelIDHelper that
49 // does not fetch its information from the ChannelIDService, but gets them 49 // does not fetch its information from the ChannelIDService, but gets them
50 // passed as a parameter during construction. 50 // passed as a parameter during construction.
51 class CannedBrowsingDataChannelIDHelper 51 class CannedBrowsingDataChannelIDHelper
52 : public BrowsingDataChannelIDHelper { 52 : public BrowsingDataChannelIDHelper {
53 public: 53 public:
54 CannedBrowsingDataChannelIDHelper(); 54 CannedBrowsingDataChannelIDHelper();
55 55
56 // Return a copy of the ChannelID helper. Only one consumer can use the
57 // StartFetching method at a time, so we need to create a copy of the helper
58 // every time we instantiate a cookies tree model for it.
59 CannedBrowsingDataChannelIDHelper* Clone();
60
61 // Add an ChannelID to the set of canned channel IDs that is 56 // Add an ChannelID to the set of canned channel IDs that is
62 // returned by this helper. 57 // returned by this helper.
63 void AddChannelID( 58 void AddChannelID(
64 const net::ChannelIDStore::ChannelID& channel_id); 59 const net::ChannelIDStore::ChannelID& channel_id);
65 60
66 // Clears the list of canned channel IDs. 61 // Clears the list of canned channel IDs.
67 void Reset(); 62 void Reset();
68 63
69 // True if no ChannelIDs are currently stored. 64 // True if no ChannelIDs are currently stored.
70 bool empty() const; 65 bool empty() const;
(...skipping 13 matching lines...) Expand all
84 typedef std::map<std::string, net::ChannelIDStore::ChannelID> 79 typedef std::map<std::string, net::ChannelIDStore::ChannelID>
85 ChannelIDMap; 80 ChannelIDMap;
86 ChannelIDMap channel_id_map_; 81 ChannelIDMap channel_id_map_;
87 82
88 FetchResultCallback completion_callback_; 83 FetchResultCallback completion_callback_;
89 84
90 DISALLOW_COPY_AND_ASSIGN(CannedBrowsingDataChannelIDHelper); 85 DISALLOW_COPY_AND_ASSIGN(CannedBrowsingDataChannelIDHelper);
91 }; 86 };
92 87
93 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_ 88 #endif // CHROME_BROWSER_BROWSING_DATA_BROWSING_DATA_CHANNEL_ID_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698