| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ | 5 #ifndef CHROME_BROWSER_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ |
| 6 #define CHROME_BROWSER_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ | 6 #define CHROME_BROWSER_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "chrome/browser/google_apis/base_operations.h" | 10 #include "chrome/browser/google_apis/base_operations.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 // True if an OAuth2 refresh token is present. Its absence means that user | 48 // True if an OAuth2 refresh token is present. Its absence means that user |
| 49 // is not properly authenticated. | 49 // is not properly authenticated. |
| 50 // The refresh token is used to get the access token. | 50 // The refresh token is used to get the access token. |
| 51 virtual bool HasRefreshToken() const = 0; | 51 virtual bool HasRefreshToken() const = 0; |
| 52 | 52 |
| 53 // Returns OAuth2 access token. | 53 // Returns OAuth2 access token. |
| 54 virtual const std::string& access_token() const = 0; | 54 virtual const std::string& access_token() const = 0; |
| 55 | 55 |
| 56 // Clears OAuth2 access token. | 56 // Clears OAuth2 access token. |
| 57 virtual void ClearAccessToken() = 0; | 57 virtual void ClearAccessToken() = 0; |
| 58 |
| 59 protected: |
| 60 virtual ~AuthServiceInterface() { } |
| 58 }; | 61 }; |
| 59 | 62 |
| 60 } // namespace google_apis | 63 } // namespace google_apis |
| 61 | 64 |
| 62 #endif // CHROME_BROWSER_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ | 65 #endif // CHROME_BROWSER_GOOGLE_APIS_AUTH_SERVICE_INTERFACE_H_ |
| OLD | NEW |