Index: components/proximity_auth/cryptauth/cryptauth_access_token_fetcher.h |
diff --git a/components/proximity_auth/cryptauth/cryptauth_access_token_fetcher.h b/components/proximity_auth/cryptauth/cryptauth_access_token_fetcher.h |
index 6287dfeabd21e7800072a735e72b2cf831eaa1d0..c5d58f3e910a92fec7f0636b792625291bbe5ec5 100644 |
--- a/components/proximity_auth/cryptauth/cryptauth_access_token_fetcher.h |
+++ b/components/proximity_auth/cryptauth/cryptauth_access_token_fetcher.h |
@@ -8,6 +8,9 @@ |
#include <string> |
#include "base/callback_forward.h" |
+#include "base/memory/scoped_ptr.h" |
+ |
+class OAuth2TokenService; |
namespace proximity_auth { |
@@ -18,6 +21,12 @@ class CryptAuthAccessTokenFetcher { |
public: |
virtual ~CryptAuthAccessTokenFetcher() {} |
+ // Creates a default CryptAuthAccessTokenFetcher instance. |
+ // |token_service| is not owned and should outlive the created instance. |
+ static scoped_ptr<CryptAuthAccessTokenFetcher> CreateDefault( |
+ OAuth2TokenService* token_service, |
+ const std::string& account_id); |
+ |
// Fetches the access token asynchronously, invoking the callback upon |
// completion. If the fetch fails, the callback will be invoked with an empty |
// string. |