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

Unified Diff: extensions/browser/updater/manifest_fetch_data_delegate.h

Issue 465543004: Factor Chrome details out of update manifest fetching. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
Index: extensions/browser/updater/manifest_fetch_data_delegate.h
diff --git a/extensions/browser/updater/manifest_fetch_data_delegate.h b/extensions/browser/updater/manifest_fetch_data_delegate.h
new file mode 100644
index 0000000000000000000000000000000000000000..f749a40cd261b703a25ac7bfdcbfa8adea7ec3e3
--- /dev/null
+++ b/extensions/browser/updater/manifest_fetch_data_delegate.h
@@ -0,0 +1,41 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef EXTENSIONS_BROWSER_UPDATER_MANIFEST_FETCH_DATA_DELEGATE_H_
+#define EXTENSIONS_BROWSER_UPDATER_MANIFEST_FETCH_DATA_DELEGATE_H_
+
+#include <string>
+
+#include "extensions/browser/updater/manifest_fetch_data.h"
+
+namespace extensions {
+
+class ManifestFetchDataDelegate {
+ public:
+ ManifestFetchDataDelegate() {}
+ virtual ~ManifestFetchDataDelegate() {}
+
+ // Returns baseline query parameters to include with every update manifest
+ // fetch request.
+ virtual std::string GetBaseQueryParams() = 0;
+
+ // Indicates whether or not the Chrome Webstore update service should
+ // also be checked for updates when an item's update URL points elsewhere.
+ virtual bool ShouldAlwaysCheckWebstore() = 0;
+
+ // Returns a brand code to be submitted with manifest fetch requests. If
+ // this is an empty string, no brand code is submitted.
+ virtual std::string GetBrandCode() = 0;
+
+ // Returns a string of ping-related query parameters to be appended to a
+ // manifest fetch given an extension ID to be fetched and existing PingData.
+ virtual std::string GetPingParamsAndData(
+ const std::string& extension_id,
+ const ManifestFetchData::PingData& old_ping_data,
+ ManifestFetchData::PingData* new_ping_data) = 0;
+};
+
+} // namespace extensions
+
+#endif // EXTENSIONS_BROWSER_UPDATER_MANIFEST_FETCH_DATA_DELEGATE_H_

Powered by Google App Engine
This is Rietveld 408576698