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

Side by Side Diff: components/policy/core/common/external_data_manager.h

Issue 78763002: Move PolicyMap and its dependencies to components/policy/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_POLICY_EXTERNAL_DATA_MANAGER_H_ 5 #ifndef COMPONENTS_POLICY_CORE_COMMON_EXTERNAL_DATA_MANAGER_H_
6 #define CHROME_BROWSER_POLICY_EXTERNAL_DATA_MANAGER_H_ 6 #define COMPONENTS_POLICY_CORE_COMMON_EXTERNAL_DATA_MANAGER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "chrome/browser/policy/external_data_fetcher.h" 10 #include "components/policy/core/common/external_data_fetcher.h"
11 #include "components/policy/policy_export.h"
11 12
12 namespace policy { 13 namespace policy {
13 14
14 // Downloads, verifies, caches and retrieves external data referenced by 15 // Downloads, verifies, caches and retrieves external data referenced by
15 // policies. 16 // policies.
16 // An implementation of this abstract interface should be provided for each 17 // An implementation of this abstract interface should be provided for each
17 // policy source (cloud policy, platform policy) that supports external data 18 // policy source (cloud policy, platform policy) that supports external data
18 // references. 19 // references.
19 class ExternalDataManager { 20 class POLICY_EXPORT ExternalDataManager {
jochen (gone - plz use gerrit) 2013/11/21 13:55:25 you don't need to export pure virtual interfaces
dconnelly 2013/11/21 14:04:24 Done.
20 public: 21 public:
21 // Retrieves the external data referenced by |policy| and invokes |callback| 22 // Retrieves the external data referenced by |policy| and invokes |callback|
22 // with the result. If |policy| does not reference any external data, the 23 // with the result. If |policy| does not reference any external data, the
23 // |callback| is invoked with a NULL pointer. Otherwise, the |callback| is 24 // |callback| is invoked with a NULL pointer. Otherwise, the |callback| is
24 // invoked with the referenced data once it has been successfully retrieved. 25 // invoked with the referenced data once it has been successfully retrieved.
25 // If retrieval is temporarily impossible (e.g. no network connectivity), the 26 // If retrieval is temporarily impossible (e.g. no network connectivity), the
26 // |callback| will be invoked when the temporary hindrance is resolved. If 27 // |callback| will be invoked when the temporary hindrance is resolved. If
27 // retrieval is permanently impossible (e.g. |policy| references data that 28 // retrieval is permanently impossible (e.g. |policy| references data that
28 // does not exist on the server), the |callback| will never be invoked. 29 // does not exist on the server), the |callback| will never be invoked.
29 virtual void Fetch(const std::string& policy, 30 virtual void Fetch(const std::string& policy,
30 const ExternalDataFetcher::FetchCallback& callback) = 0; 31 const ExternalDataFetcher::FetchCallback& callback) = 0;
31 }; 32 };
32 33
33 } // namespace policy 34 } // namespace policy
34 35
35 #endif // CHROME_BROWSER_POLICY_EXTERNAL_DATA_MANAGER_H_ 36 #endif // COMPONENTS_POLICY_CORE_COMMON_EXTERNAL_DATA_MANAGER_H_
OLDNEW
« no previous file with comments | « components/policy/core/common/external_data_fetcher.cc ('k') | components/policy/core/common/policy_map.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698