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

Side by Side Diff: components/signin/core/browser/webdata/token_web_data.h

Issue 2672833002: [Desktop] Add diagnostics about loading the refresh tokens. (Closed)
Patch Set: Fix compile Created 3 years, 10 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 // Chromium settings and storage represent user-selected preferences and 5 // Chromium settings and storage represent user-selected preferences and
6 // information and MUST not be extracted, overwritten or modified except 6 // information and MUST not be extracted, overwritten or modified except
7 // through Chromium defined APIs. 7 // through Chromium defined APIs.
8 8
9 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__ 9 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__
10 #define COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__ 10 #define COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__
11 11
12 #include <map> 12 #include <map>
13 #include <string> 13 #include <string>
14 #include <vector> 14 #include <vector>
15 15
16 #include "base/callback_forward.h" 16 #include "base/callback_forward.h"
17 #include "base/files/file_path.h" 17 #include "base/files/file_path.h"
18 #include "base/location.h" 18 #include "base/location.h"
19 #include "base/macros.h" 19 #include "base/macros.h"
20 #include "base/memory/ref_counted.h" 20 #include "base/memory/ref_counted.h"
21 #include "components/signin/core/browser/webdata/token_service_table.h"
21 #include "components/webdata/common/web_data_results.h" 22 #include "components/webdata/common/web_data_results.h"
22 #include "components/webdata/common/web_data_service_base.h" 23 #include "components/webdata/common/web_data_service_base.h"
23 #include "components/webdata/common/web_data_service_consumer.h" 24 #include "components/webdata/common/web_data_service_consumer.h"
24 #include "components/webdata/common/web_database.h" 25 #include "components/webdata/common/web_database.h"
25 26
26 namespace base { 27 namespace base {
27 class SingleThreadTaskRunner; 28 class SingleThreadTaskRunner;
28 } 29 }
29 30
30 class TokenWebDataBackend; 31 class TokenWebDataBackend;
31 class WebDatabaseService; 32 class WebDatabaseService;
32 class WebDataServiceConsumer; 33 class WebDataServiceConsumer;
33 34
35 // The result of a get tokens operation.
36 struct TokenResult {
37 TokenResult();
38 TokenResult(const TokenResult& other);
39 ~TokenResult();
40
41 TokenServiceTable::Result db_result;
42 std::map<std::string, std::string> tokens;
43 };
44
34 // TokenWebData is a data repository for storage of authentication tokens. 45 // TokenWebData is a data repository for storage of authentication tokens.
35 46
36 class TokenWebData : public WebDataServiceBase { 47 class TokenWebData : public WebDataServiceBase {
37 public: 48 public:
38 TokenWebData(scoped_refptr<WebDatabaseService> wdbs, 49 TokenWebData(scoped_refptr<WebDatabaseService> wdbs,
39 scoped_refptr<base::SingleThreadTaskRunner> ui_thread, 50 scoped_refptr<base::SingleThreadTaskRunner> ui_thread,
40 scoped_refptr<base::SingleThreadTaskRunner> db_thread, 51 scoped_refptr<base::SingleThreadTaskRunner> db_thread,
41 const ProfileErrorCallback& callback); 52 const ProfileErrorCallback& callback);
42 53
43 TokenWebData(scoped_refptr<base::SingleThreadTaskRunner> ui_thread, 54 TokenWebData(scoped_refptr<base::SingleThreadTaskRunner> ui_thread,
(...skipping 18 matching lines...) Expand all
62 73
63 ~TokenWebData() override; 74 ~TokenWebData() override;
64 75
65 private: 76 private:
66 scoped_refptr<TokenWebDataBackend> token_backend_; 77 scoped_refptr<TokenWebDataBackend> token_backend_;
67 78
68 DISALLOW_COPY_AND_ASSIGN(TokenWebData); 79 DISALLOW_COPY_AND_ASSIGN(TokenWebData);
69 }; 80 };
70 81
71 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__ 82 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_WEBDATA_TOKEN_WEB_DATA_H__
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698