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

Side by Side Diff: chrome/browser/offline_pages/resource_loading_observer.h

Issue 2933193003: Headers for resource tracking. (Closed)
Patch Set: CR feedback from RyanSturm Created 3 years, 6 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/offline_pages/offliner_user_data.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_OFFLINE_PAGES_RESOURCE_LOADING_OBSERVER_H_
6 #define CHROME_BROWSER_OFFLINE_PAGES_RESOURCE_LOADING_OBSERVER_H_
7
8 #include <stdint.h>
9
10 namespace offline_pages {
11
12 // This interface is used by clients who want to be notified when a resource is
13 // requested or completes loading, and to report the size of the resource.
14 class ResourceLoadingObserver {
15 public:
16 enum ResourceDataType {
17 IMAGE,
18 TEXT_CSS,
19 OTHER,
20 RESOURCE_DATA_TYPE_COUNT,
21 };
22
23 // Report when a resource starts or completes loading.
24 virtual void ObserveResourceLoading(ResourceDataType type, bool started) = 0;
25
26 // Report how many bytes were received for a resource.
27 virtual void OnNetworkBytesChanged(int64_t received_bytes) = 0;
28 };
29
30 } // namespace offline_pages
31
32 #endif // CHROME_BROWSER_OFFLINE_PAGES_RESOURCE_LOADING_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/browser/offline_pages/offliner_user_data.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698