| Index: chrome/browser/task_manager/task_manager_interface.h
|
| diff --git a/chrome/browser/task_manager/task_manager_interface.h b/chrome/browser/task_manager/task_manager_interface.h
|
| index c4e31c24234f6f922dc8db5292a98befad2dbbd8..561ce1ccba26a215fa52fc1b471687cf677ce47b 100644
|
| --- a/chrome/browser/task_manager/task_manager_interface.h
|
| +++ b/chrome/browser/task_manager/task_manager_interface.h
|
| @@ -51,10 +51,15 @@ class TaskManagerInterface {
|
| static TaskManagerInterface* GetTaskManager();
|
|
|
| // This notification will be received on the IO thread from
|
| - // ChromeNetworkDelegate to update the task manager with network usage.
|
| + // ChromeNetworkDelegate to update the task manager with read network usage.
|
| static void OnRawBytesRead(const net::URLRequest& request,
|
| int64_t bytes_read);
|
|
|
| + // This notification will be received on the IO thread from
|
| + // ChromeNetworkDelegate to update the task manager with sent network usage.
|
| + static void OnRawBytesSent(const net::URLRequest& request,
|
| + int64_t bytes_sent);
|
| +
|
| void AddObserver(TaskManagerObserver* observer);
|
| void RemoveObserver(TaskManagerObserver* observer);
|
|
|
| @@ -177,6 +182,12 @@ class TaskManagerInterface {
|
| // usage.
|
| virtual int64_t GetNetworkUsage(TaskId task_id) const = 0;
|
|
|
| + // Returns the network usage during the current lifetime of the task
|
| + // for the task with |task_id|. A value of -1 means no valid value is
|
| + // currently available or that task has never been notified of any network
|
| + // usage.
|
| + virtual int64_t GetCumulativeNetworkUsage(TaskId task_id) const = 0;
|
| +
|
| // Returns the total network usage (in bytes per second) during the current
|
| // refresh cycle for the process on which the task with |task_id| is running.
|
| // This is the sum of all the network usage of the individual tasks (that
|
| @@ -184,6 +195,14 @@ class TaskManagerInterface {
|
| // usage calculation refresh is currently not available.
|
| virtual int64_t GetProcessTotalNetworkUsage(TaskId task_id) const = 0;
|
|
|
| + // Returns the total network usage during the lifetime of the process
|
| + // on which the task with |task_id| is running.
|
| + // This is the sum of all the network usage of the individual tasks (that
|
| + // can be gotten by the above GetTotalNetworkUsage()). A value of -1
|
| + // means network usage calculation refresh is currently not available.
|
| + virtual int64_t GetCumulativeProcessTotalNetworkUsage(
|
| + TaskId task_id) const = 0;
|
| +
|
| // Returns the Sqlite used memory (in bytes) for the task with |task_id|.
|
| // A value of -1 means no valid value is currently available.
|
| virtual int64_t GetSqliteMemoryUsed(TaskId task_id) const = 0;
|
|
|