| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // This class gathers state related to a single user profile. | 5 // This class gathers state related to a single user profile. |
| 6 | 6 |
| 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_H_ | 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_H_ |
| 8 #define CHROME_BROWSER_PROFILES_PROFILE_H_ | 8 #define CHROME_BROWSER_PROFILES_PROFILE_H_ |
| 9 #pragma once | 9 #pragma once |
| 10 | 10 |
| (...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 // method returns data is not guaranteed to be deleted. | 483 // method returns data is not guaranteed to be deleted. |
| 484 virtual void ClearNetworkingHistorySince(base::Time time) = 0; | 484 virtual void ClearNetworkingHistorySince(base::Time time) = 0; |
| 485 | 485 |
| 486 // Returns the home page for this profile. | 486 // Returns the home page for this profile. |
| 487 virtual GURL GetHomePage() = 0; | 487 virtual GURL GetHomePage() = 0; |
| 488 | 488 |
| 489 // Returns the NetworkActionPredictor used by the Omnibox to decide when to | 489 // Returns the NetworkActionPredictor used by the Omnibox to decide when to |
| 490 // prerender or prefetch a result. | 490 // prerender or prefetch a result. |
| 491 virtual NetworkActionPredictor* GetNetworkActionPredictor() = 0; | 491 virtual NetworkActionPredictor* GetNetworkActionPredictor() = 0; |
| 492 | 492 |
| 493 // Makes the session state, e.g., cookies, persistent across the next restart. |
| 494 virtual void SaveSessionState() {} |
| 495 |
| 496 // Restores the saved session state, e.g., cookies, after a restart. |
| 497 virtual void RestoreSessionState() {} |
| 498 |
| 499 // Discards the saved session state, e.g., cookies, after a restart. |
| 500 virtual void DiscardSessionState() {} |
| 501 |
| 493 std::string GetDebugName(); | 502 std::string GetDebugName(); |
| 494 | 503 |
| 495 // Returns whether it is a guest session. | 504 // Returns whether it is a guest session. |
| 496 static bool IsGuestSession(); | 505 static bool IsGuestSession(); |
| 497 | 506 |
| 498 #ifdef UNIT_TEST | 507 #ifdef UNIT_TEST |
| 499 // Use with caution. GetDefaultRequestContext may be called on any thread! | 508 // Use with caution. GetDefaultRequestContext may be called on any thread! |
| 500 static void set_default_request_context(net::URLRequestContextGetter* c) { | 509 static void set_default_request_context(net::URLRequestContextGetter* c) { |
| 501 default_request_context_ = c; | 510 default_request_context_ = c; |
| 502 } | 511 } |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 564 struct hash<Profile*> { | 573 struct hash<Profile*> { |
| 565 std::size_t operator()(Profile* const& p) const { | 574 std::size_t operator()(Profile* const& p) const { |
| 566 return reinterpret_cast<std::size_t>(p); | 575 return reinterpret_cast<std::size_t>(p); |
| 567 } | 576 } |
| 568 }; | 577 }; |
| 569 | 578 |
| 570 } // namespace __gnu_cxx | 579 } // namespace __gnu_cxx |
| 571 #endif | 580 #endif |
| 572 | 581 |
| 573 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ | 582 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ |
| OLD | NEW |