summaryrefslogtreecommitdiffstats
path: root/components/search_provider_logos/google_logo_api.h
diff options
context:
space:
mode:
authornewt@chromium.org <newt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-30 21:55:16 +0000
committernewt@chromium.org <newt@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-30 21:55:16 +0000
commit12fad44d9e65df34ef7f71f53bf16e0d429a8aff (patch)
treed2199704d6e10040a68faba57c4ee89bbf02994a /components/search_provider_logos/google_logo_api.h
parent09bd7bc27cf7544bdfb58fe0e21465b6485d599e (diff)
downloadchromium_src-12fad44d9e65df34ef7f71f53bf16e0d429a8aff.zip
chromium_src-12fad44d9e65df34ef7f71f53bf16e0d429a8aff.tar.gz
chromium_src-12fad44d9e65df34ef7f71f53bf16e0d429a8aff.tar.bz2
Add LogoTracker to fetch search providers' logos.
The LogoTracker keeps track of the logo for a search provider. The logo is downloaded, cached on disk, and periodically revalidated. This code lives inside a component (search_provider_logos) so it can be used on both Android and iOS. BUG=178922 NOTRY=true Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267314 Review URL: https://codereview.chromium.org/162373002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@267349 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'components/search_provider_logos/google_logo_api.h')
-rw-r--r--components/search_provider_logos/google_logo_api.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/components/search_provider_logos/google_logo_api.h b/components/search_provider_logos/google_logo_api.h
new file mode 100644
index 0000000..569752d
--- /dev/null
+++ b/components/search_provider_logos/google_logo_api.h
@@ -0,0 +1,29 @@
+// 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 COMPONENTS_SEARCH_PROVIDER_LOGOS_GOOGLE_LOGO_API_H_
+#define COMPONENTS_SEARCH_PROVIDER_LOGOS_GOOGLE_LOGO_API_H_
+
+#include <string>
+
+#include "base/memory/scoped_ptr.h"
+#include "base/time/time.h"
+#include "components/search_provider_logos/logo_common.h"
+#include "url/gurl.h"
+
+namespace search_provider_logos {
+
+// Implements AppendFingerprintToLogoURL, defined in logo_tracker.h, for Google
+// doodles.
+GURL GoogleAppendFingerprintToLogoURL(const GURL& logo_url,
+ const std::string& fingerprint);
+
+// Implements ParseLogoResponse, defined in logo_tracker.h, for Google doodles.
+scoped_ptr<EncodedLogo> GoogleParseLogoResponse(
+ const scoped_ptr<std::string>& response,
+ base::Time response_time);
+
+} // namespace search_provider_logos
+
+#endif // COMPONENTS_SEARCH_PROVIDER_LOGOS_GOOGLE_LOGO_API_H_