Index: net/reporting/reporting_observer.h |
diff --git a/net/reporting/reporting_observer.h b/net/reporting/reporting_observer.h |
index fe2ab5c79f1cb4a9780441ed4f72e5a3915d1c1c..86e5c7c77a51e09eb3ac270766329d5a19b20c26 100644 |
--- a/net/reporting/reporting_observer.h |
+++ b/net/reporting/reporting_observer.h |
@@ -12,6 +12,24 @@ namespace net { |
class NET_EXPORT ReportingObserver { |
public: |
+ // Called during ReportingContext::Initialize, before any calls to |
+ // OnContextInitialized. |
+ // |
+ // This is the correct time to preload or restore data in the |
+ // ReportingCache, since other observers won't act on it until all observers |
+ // have had a chance to initialize. |
+ virtual void OnContextInitializing(); |
+ |
+ // Called during ReportingContext::Initialize, after all calls to |
+ // OnContextInitializing. |
+ // |
+ // This is the correct time to start timers or network requests based on data |
+ // restored by other observers. |
+ virtual void OnContextInitialized(); |
+ |
+ // Once ReportingContext::Initialize has called OnContextInitializing on all |
+ // Observers, OnCacheUpdated will be called on any update to the |
+ // ReportingCache. |
virtual void OnCacheUpdated(); |
protected: |