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

Unified Diff: chrome/browser/signin/oauth2_token_service_request.h

Issue 12647008: Refactor OAuth2TokenService to have profile- and device-based implementations. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase again Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/signin/oauth2_token_service_request.h
diff --git a/chrome/browser/signin/oauth2_token_service_request.h b/chrome/browser/signin/oauth2_token_service_request.h
deleted file mode 100644
index 8ab4b79e64f0e65f609a7994f6fd7dbf131195e6..0000000000000000000000000000000000000000
--- a/chrome/browser/signin/oauth2_token_service_request.h
+++ /dev/null
@@ -1,51 +0,0 @@
-// Copyright 2012 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 CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_REQUEST_H_
-#define CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_REQUEST_H_
-
-#include <set>
-#include <string>
-
-#include "base/memory/ref_counted.h"
-#include "base/threading/non_thread_safe.h"
-#include "base/time.h"
-#include "chrome/browser/signin/oauth2_token_service.h"
-#include "google_apis/gaia/google_service_auth_error.h"
-
-class Profile;
-
-// OAuth2TokenServiceRequest represents a request to fetch an OAuth2 access
-// token for a given set of |scopes| by calling |profile|'s
-// OAuth2TokenService. A request can be created and started from any thread
-// with an object |consumer| that will be called back on the same thread when
-// fetching completes.
-// If the request is destructed before |consumer| is called, |consumer| will
-// never be called back. (Note the actual network activities are not canceled
-// and the cache in OAuth2TokenService will be populated with the fetched
-// results.)
-class OAuth2TokenServiceRequest : public OAuth2TokenService::Request,
- public base::NonThreadSafe {
- public:
- static OAuth2TokenServiceRequest* CreateAndStart(
- Profile* profile,
- const OAuth2TokenService::ScopeSet& scopes,
- OAuth2TokenService::Consumer* consumer);
-
- virtual ~OAuth2TokenServiceRequest();
-
- private:
- class Core;
- friend class Core;
-
- OAuth2TokenServiceRequest(Profile* profile,
- const OAuth2TokenService::ScopeSet& scopes,
- OAuth2TokenService::Consumer* consumer);
- OAuth2TokenService::Consumer* const consumer_;
- scoped_refptr<Core> core_;
-
- DISALLOW_COPY_AND_ASSIGN(OAuth2TokenServiceRequest);
-};
-
-#endif // CHROME_BROWSER_SIGNIN_OAUTH2_TOKEN_SERVICE_REQUEST_H_
« no previous file with comments | « chrome/browser/signin/oauth2_token_service_factory.cc ('k') | chrome/browser/signin/oauth2_token_service_request.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698