| 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 #ifndef CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ |
| 6 #define CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ | 6 #define CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 // Returns number of registered resources. | 266 // Returns number of registered resources. |
| 267 int ResourceCount() const; | 267 int ResourceCount() const; |
| 268 // Returns number of registered groups. | 268 // Returns number of registered groups. |
| 269 int GroupCount() const; | 269 int GroupCount() const; |
| 270 | 270 |
| 271 // Methods to return raw resource information. | 271 // Methods to return raw resource information. |
| 272 int64 GetNetworkUsage(int index) const; | 272 int64 GetNetworkUsage(int index) const; |
| 273 double GetCPUUsage(int index) const; | 273 double GetCPUUsage(int index) const; |
| 274 int GetProcessId(int index) const; | 274 int GetProcessId(int index) const; |
| 275 int GetResourceUniqueId(int index) const; | 275 int GetResourceUniqueId(int index) const; |
| 276 // Returns the index of resource that has the given |unique_id|. Returns -1 if |
| 277 // no resouce has the |unique_id|. |
| 278 int GetResourceIndexByUniqueId(const int unique_id) const; |
| 276 | 279 |
| 277 // Methods to return formatted resource information. | 280 // Methods to return formatted resource information. |
| 278 string16 GetResourceTitle(int index) const; | 281 string16 GetResourceTitle(int index) const; |
| 279 string16 GetResourceProfileName(int index) const; | 282 string16 GetResourceProfileName(int index) const; |
| 280 string16 GetResourceNetworkUsage(int index) const; | 283 string16 GetResourceNetworkUsage(int index) const; |
| 281 string16 GetResourceCPUUsage(int index) const; | 284 string16 GetResourceCPUUsage(int index) const; |
| 282 string16 GetResourcePrivateMemory(int index) const; | 285 string16 GetResourcePrivateMemory(int index) const; |
| 283 string16 GetResourceSharedMemory(int index) const; | 286 string16 GetResourceSharedMemory(int index) const; |
| 284 string16 GetResourcePhysicalMemory(int index) const; | 287 string16 GetResourcePhysicalMemory(int index) const; |
| 285 string16 GetResourceProcessId(int index) const; | 288 string16 GetResourceProcessId(int index) const; |
| (...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 // A salt lick for the goats. | 533 // A salt lick for the goats. |
| 531 int goat_salt_; | 534 int goat_salt_; |
| 532 | 535 |
| 533 // Resource identifier that is unique within single session. | 536 // Resource identifier that is unique within single session. |
| 534 int last_unique_id_; | 537 int last_unique_id_; |
| 535 | 538 |
| 536 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel); | 539 DISALLOW_COPY_AND_ASSIGN(TaskManagerModel); |
| 537 }; | 540 }; |
| 538 | 541 |
| 539 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ | 542 #endif // CHROME_BROWSER_TASK_MANAGER_TASK_MANAGER_H_ |
| OLD | NEW |