OLD | NEW |
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 SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_IMP
L_H_ | 5 #ifndef SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_IMP
L_H_ |
6 #define SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_IMP
L_H_ | 6 #define SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_IMP
L_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 | 9 |
10 #include "mojo/public/cpp/bindings/error_handler.h" | 10 #include "mojo/public/cpp/bindings/error_handler.h" |
11 #include "mojo/public/cpp/bindings/interface_request.h" | 11 #include "mojo/public/cpp/bindings/interface_request.h" |
12 #include "mojo/public/cpp/bindings/strong_binding.h" | 12 #include "mojo/public/cpp/bindings/strong_binding.h" |
13 #include "mojo/services/authenticating_url_loader/public/interfaces/authenticati
ng_url_loader_factory.mojom.h" | 13 #include "mojo/services/authenticating_url_loader/public/interfaces/authenticati
ng_url_loader_factory.mojom.h" |
14 #include "mojo/services/authentication/public/interfaces/authentication.mojom.h" | 14 #include "mojo/services/authentication/public/interfaces/authentication.mojom.h" |
15 #include "mojo/services/network/public/interfaces/network_service.mojom.h" | 15 #include "mojo/services/network/public/interfaces/network_service.mojom.h" |
| 16 #include "url/gurl.h" |
16 | 17 |
17 namespace mojo { | 18 namespace mojo { |
18 | 19 |
19 class ApplicationImpl; | 20 class ApplicationImpl; |
20 | 21 |
21 class AuthenticatingURLLoaderImpl; | 22 class AuthenticatingURLLoaderImpl; |
22 | 23 |
23 class AuthenticatingURLLoaderFactoryImpl | 24 class AuthenticatingURLLoaderFactoryImpl |
24 : public AuthenticatingURLLoaderFactory, | 25 : public AuthenticatingURLLoaderFactory, |
25 public ErrorHandler { | 26 public ErrorHandler { |
(...skipping 13 matching lines...) Expand all Loading... |
39 // ErrorHandler: | 40 // ErrorHandler: |
40 void OnConnectionError() override; | 41 void OnConnectionError() override; |
41 | 42 |
42 void DeleteURLLoader(AuthenticatingURLLoaderImpl* url_loader); | 43 void DeleteURLLoader(AuthenticatingURLLoaderImpl* url_loader); |
43 | 44 |
44 StrongBinding<AuthenticatingURLLoaderFactory> binding_; | 45 StrongBinding<AuthenticatingURLLoaderFactory> binding_; |
45 ApplicationImpl* app_; | 46 ApplicationImpl* app_; |
46 authentication::AuthenticationServicePtr authentication_service_; | 47 authentication::AuthenticationServicePtr authentication_service_; |
47 NetworkServicePtr network_service_; | 48 NetworkServicePtr network_service_; |
48 std::vector<std::unique_ptr<AuthenticatingURLLoaderImpl>> url_loaders_; | 49 std::vector<std::unique_ptr<AuthenticatingURLLoaderImpl>> url_loaders_; |
| 50 std::map<GURL, std::string> cached_tokens_; |
49 }; | 51 }; |
50 | 52 |
51 } // namespace mojo | 53 } // namespace mojo |
52 | 54 |
53 #endif // SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_
IMPL_H_ | 55 #endif // SERVICES_AUTHENTICATING_URL_LOADER_AUTHENTICATING_URL_LOADER_FACTORY_
IMPL_H_ |
OLD | NEW |