OLD | NEW |
| (Empty) |
1 // Copyright (c) 2012 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 [ | |
6 { | |
7 "namespace": "experimental.processes", | |
8 "nodoc": true, | |
9 "types": [ | |
10 { | |
11 "id": "Process", | |
12 "type": "object", | |
13 "description": "An object containing information about one of the browse
r's processes.", | |
14 "properties": { | |
15 "id": { | |
16 "type": "integer", | |
17 "description": "The ID of the process, as provided by the OS." | |
18 }, | |
19 "type": { | |
20 "type": "string", | |
21 "enum": ["browser", "renderer", "extension", "notification", "plugin
", "worker", "nacl", "utility", "gpu", "other"], | |
22 "description": "The type of process." | |
23 }, | |
24 "cpu": { | |
25 "type": "number", | |
26 "description": "The most recent measurement of the process's CPU usa
ge, between 0 and 100%." | |
27 }, | |
28 "network": { | |
29 "type": "number", | |
30 "description": "The most recent measurement of the process's network
usage, in bytes per second." | |
31 }, | |
32 "privateMemory": { | |
33 "type": "number", | |
34 "description": "The most recent measurement of the process's private
memory usage, in bytes." | |
35 }, | |
36 "sharedMemory": { | |
37 "type": "number", | |
38 "description": "The most recent measurement of the process's shared
memory usage, in bytes." | |
39 } | |
40 } | |
41 } | |
42 ], | |
43 "functions": [ | |
44 { | |
45 "name": "getProcessIdForTab", | |
46 "type": "function", | |
47 "description": "Returns the ID of the renderer process for the specified
tab.", | |
48 "parameters": [ | |
49 { | |
50 "name": "tabId", | |
51 "type": "integer", | |
52 "minimum": 0 | |
53 }, | |
54 { | |
55 "type": "function", | |
56 "name": "callback", | |
57 "parameters": [ | |
58 { | |
59 "name": "processId", | |
60 "type": "integer", | |
61 "description": "Process ID of the tab's renderer process." | |
62 } | |
63 ] | |
64 } | |
65 ] | |
66 } | |
67 ], | |
68 "events": [ | |
69 { | |
70 "name": "onUpdated", | |
71 "type": "function", | |
72 "description": "Fired each time the Task Manager updates its process sta
tistics, providing the dictionary of updated Process objects, indexed by process
ID.", | |
73 "parameters": [ | |
74 { | |
75 "name": "processes", | |
76 "type": "object", | |
77 "additionalProperties": { "$ref": "Process" } | |
78 } | |
79 ] | |
80 } | |
81 ] | |
82 } | |
83 ] | |
OLD | NEW |