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

Side by Side Diff: components/ntp_snippets/ntp_snippets_service.h

Issue 2207493002: Add CategoryInfo for meta information of content suggestions Categories (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use base::Optional for ContentSuggestionsService::GetCategoryInfo Created 4 years, 4 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_ 5 #ifndef COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_ 6 #define COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 // (Re)schedules the periodic fetching of snippets. This is necessary because 131 // (Re)schedules the periodic fetching of snippets. This is necessary because
132 // the schedule depends on the time of day. 132 // the schedule depends on the time of day.
133 void RescheduleFetching(); 133 void RescheduleFetching();
134 134
135 // ContentSuggestionsProvider implementation 135 // ContentSuggestionsProvider implementation
136 // TODO(pke): At some point reorder the implementations in the .cc file 136 // TODO(pke): At some point reorder the implementations in the .cc file
137 // accordingly. 137 // accordingly.
138 std::vector<Category> GetProvidedCategories() override; 138 std::vector<Category> GetProvidedCategories() override;
139 CategoryStatus GetCategoryStatus(Category category) override; 139 CategoryStatus GetCategoryStatus(Category category) override;
140 CategoryInfo GetCategoryInfo(Category category) override;
140 void DismissSuggestion(const std::string& suggestion_id) override; 141 void DismissSuggestion(const std::string& suggestion_id) override;
141 void FetchSuggestionImage(const std::string& suggestion_id, 142 void FetchSuggestionImage(const std::string& suggestion_id,
142 const ImageFetchedCallback& callback) override; 143 const ImageFetchedCallback& callback) override;
143 void ClearCachedSuggestionsForDebugging() override; 144 void ClearCachedSuggestionsForDebugging() override;
144 void ClearDismissedSuggestionsForDebugging() override; 145 void ClearDismissedSuggestionsForDebugging() override;
145 146
146 // Returns the lists of suggestion hosts the snippets are restricted to. 147 // Returns the lists of suggestion hosts the snippets are restricted to.
147 std::set<std::string> GetSuggestionsHosts() const; 148 std::set<std::string> GetSuggestionsHosts() const;
148 149
149 // Returns the maximum number of snippets that will be shown at once. 150 // Returns the maximum number of snippets that will be shown at once.
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 bool fetch_after_load_; 307 bool fetch_after_load_;
307 308
308 const Category provided_category_; 309 const Category provided_category_;
309 310
310 DISALLOW_COPY_AND_ASSIGN(NTPSnippetsService); 311 DISALLOW_COPY_AND_ASSIGN(NTPSnippetsService);
311 }; 312 };
312 313
313 } // namespace ntp_snippets 314 } // namespace ntp_snippets
314 315
315 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_ 316 #endif // COMPONENTS_NTP_SNIPPETS_NTP_SNIPPETS_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698