• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1
2<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
3<html><head><title>Python: module telemetry.core.timeline.model</title>
4</head><body bgcolor="#f0f0f8">
5
6<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
7<tr bgcolor="#7799ee">
8<td valign=bottom>&nbsp;<br>
9<font color="#ffffff" face="helvetica, arial">&nbsp;<br><big><big><strong><a href="telemetry.html"><font color="#ffffff">telemetry</font></a>.<a href="telemetry.core.html"><font color="#ffffff">core</font></a>.<a href="telemetry.core.timeline.html"><font color="#ffffff">timeline</font></a>.model</strong></big></big></font></td
10><td align=right valign=bottom
11><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="../telemetry/core/timeline/model.py">telemetry/core/timeline/model.py</a></font></td></tr></table>
12    <p><tt>A&nbsp;container&nbsp;for&nbsp;timeline-based&nbsp;events&nbsp;and&nbsp;traces&nbsp;and&nbsp;can&nbsp;handle&nbsp;importing<br>
13raw&nbsp;event&nbsp;data&nbsp;from&nbsp;different&nbsp;sources.&nbsp;This&nbsp;model&nbsp;closely&nbsp;resembles&nbsp;that&nbsp;in&nbsp;the<br>
14trace_viewer&nbsp;project:<br>
15https://code.google.com/p/trace-viewer/</tt></p>
16<p>
17<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
18<tr bgcolor="#aa55cc">
19<td colspan=3 valign=bottom>&nbsp;<br>
20<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
21
22<tr><td bgcolor="#aa55cc"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
23<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="telemetry.core.timeline.bounds.html">telemetry.core.timeline.bounds</a><br>
24<a href="telemetry.core.browser.html">telemetry.core.browser</a><br>
25</td><td width="25%" valign=top><a href="telemetry.core.timeline.empty_timeline_data_importer.html">telemetry.core.timeline.empty_timeline_data_importer</a><br>
26<a href="telemetry.core.timeline.inspector_importer.html">telemetry.core.timeline.inspector_importer</a><br>
27</td><td width="25%" valign=top><a href="telemetry.core.timeline.trace_event_importer.html">telemetry.core.timeline.trace_event_importer</a><br>
28<a href="telemetry.core.timeline.process.html">telemetry.core.timeline.process</a><br>
29</td><td width="25%" valign=top><a href="weakref.html">weakref</a><br>
30<a href="telemetry.core.web_contents.html">telemetry.core.web_contents</a><br>
31</td></tr></table></td></tr></table><p>
32<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
33<tr bgcolor="#ee77aa">
34<td colspan=3 valign=bottom>&nbsp;<br>
35<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
36
37<tr><td bgcolor="#ee77aa"><tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
38<td width="100%"><dl>
39<dt><font face="helvetica, arial"><a href="__builtin__.html#object">__builtin__.object</a>
40</font></dt><dd>
41<dl>
42<dt><font face="helvetica, arial"><a href="telemetry.core.timeline.model.html#TimelineModel">TimelineModel</a>
43</font></dt></dl>
44</dd>
45<dt><font face="helvetica, arial"><a href="exceptions.html#Exception">exceptions.Exception</a>(<a href="exceptions.html#BaseException">exceptions.BaseException</a>)
46</font></dt><dd>
47<dl>
48<dt><font face="helvetica, arial"><a href="telemetry.core.timeline.model.html#MarkerMismatchError">MarkerMismatchError</a>
49</font></dt><dt><font face="helvetica, arial"><a href="telemetry.core.timeline.model.html#MarkerOverlapError">MarkerOverlapError</a>
50</font></dt></dl>
51</dd>
52</dl>
53 <p>
54<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
55<tr bgcolor="#ffc8d8">
56<td colspan=3 valign=bottom>&nbsp;<br>
57<font color="#000000" face="helvetica, arial"><a name="MarkerMismatchError">class <strong>MarkerMismatchError</strong></a>(<a href="exceptions.html#Exception">exceptions.Exception</a>)</font></td></tr>
58
59<tr><td bgcolor="#ffc8d8"><tt>&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
60<td width="100%"><dl><dt>Method resolution order:</dt>
61<dd><a href="telemetry.core.timeline.model.html#MarkerMismatchError">MarkerMismatchError</a></dd>
62<dd><a href="exceptions.html#Exception">exceptions.Exception</a></dd>
63<dd><a href="exceptions.html#BaseException">exceptions.BaseException</a></dd>
64<dd><a href="__builtin__.html#object">__builtin__.object</a></dd>
65</dl>
66<hr>
67Methods defined here:<br>
68<dl><dt><a name="MarkerMismatchError-__init__"><strong>__init__</strong></a>(self)</dt></dl>
69
70<hr>
71Data descriptors defined here:<br>
72<dl><dt><strong>__weakref__</strong></dt>
73<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
74</dl>
75<hr>
76Data and other attributes inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
77<dl><dt><strong>__new__</strong> = &lt;built-in method __new__ of type object&gt;<dd><tt>T.<a href="#MarkerMismatchError-__new__">__new__</a>(S,&nbsp;...)&nbsp;-&gt;&nbsp;a&nbsp;new&nbsp;<a href="__builtin__.html#object">object</a>&nbsp;with&nbsp;type&nbsp;S,&nbsp;a&nbsp;subtype&nbsp;of&nbsp;T</tt></dl>
78
79<hr>
80Methods inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
81<dl><dt><a name="MarkerMismatchError-__delattr__"><strong>__delattr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__delattr__">__delattr__</a>('name')&nbsp;&lt;==&gt;&nbsp;del&nbsp;x.name</tt></dd></dl>
82
83<dl><dt><a name="MarkerMismatchError-__getattribute__"><strong>__getattribute__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__getattribute__">__getattribute__</a>('name')&nbsp;&lt;==&gt;&nbsp;x.name</tt></dd></dl>
84
85<dl><dt><a name="MarkerMismatchError-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__getitem__">__getitem__</a>(y)&nbsp;&lt;==&gt;&nbsp;x[y]</tt></dd></dl>
86
87<dl><dt><a name="MarkerMismatchError-__getslice__"><strong>__getslice__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__getslice__">__getslice__</a>(i,&nbsp;j)&nbsp;&lt;==&gt;&nbsp;x[i:j]<br>
88&nbsp;<br>
89Use&nbsp;of&nbsp;negative&nbsp;indices&nbsp;is&nbsp;not&nbsp;supported.</tt></dd></dl>
90
91<dl><dt><a name="MarkerMismatchError-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
92
93<dl><dt><a name="MarkerMismatchError-__repr__"><strong>__repr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__repr__">__repr__</a>()&nbsp;&lt;==&gt;&nbsp;repr(x)</tt></dd></dl>
94
95<dl><dt><a name="MarkerMismatchError-__setattr__"><strong>__setattr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__setattr__">__setattr__</a>('name',&nbsp;value)&nbsp;&lt;==&gt;&nbsp;x.name&nbsp;=&nbsp;value</tt></dd></dl>
96
97<dl><dt><a name="MarkerMismatchError-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
98
99<dl><dt><a name="MarkerMismatchError-__str__"><strong>__str__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerMismatchError-__str__">__str__</a>()&nbsp;&lt;==&gt;&nbsp;str(x)</tt></dd></dl>
100
101<dl><dt><a name="MarkerMismatchError-__unicode__"><strong>__unicode__</strong></a>(...)</dt></dl>
102
103<hr>
104Data descriptors inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
105<dl><dt><strong>__dict__</strong></dt>
106</dl>
107<dl><dt><strong>args</strong></dt>
108</dl>
109<dl><dt><strong>message</strong></dt>
110</dl>
111</td></tr></table> <p>
112<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
113<tr bgcolor="#ffc8d8">
114<td colspan=3 valign=bottom>&nbsp;<br>
115<font color="#000000" face="helvetica, arial"><a name="MarkerOverlapError">class <strong>MarkerOverlapError</strong></a>(<a href="exceptions.html#Exception">exceptions.Exception</a>)</font></td></tr>
116
117<tr><td bgcolor="#ffc8d8"><tt>&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
118<td width="100%"><dl><dt>Method resolution order:</dt>
119<dd><a href="telemetry.core.timeline.model.html#MarkerOverlapError">MarkerOverlapError</a></dd>
120<dd><a href="exceptions.html#Exception">exceptions.Exception</a></dd>
121<dd><a href="exceptions.html#BaseException">exceptions.BaseException</a></dd>
122<dd><a href="__builtin__.html#object">__builtin__.object</a></dd>
123</dl>
124<hr>
125Methods defined here:<br>
126<dl><dt><a name="MarkerOverlapError-__init__"><strong>__init__</strong></a>(self)</dt></dl>
127
128<hr>
129Data descriptors defined here:<br>
130<dl><dt><strong>__weakref__</strong></dt>
131<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
132</dl>
133<hr>
134Data and other attributes inherited from <a href="exceptions.html#Exception">exceptions.Exception</a>:<br>
135<dl><dt><strong>__new__</strong> = &lt;built-in method __new__ of type object&gt;<dd><tt>T.<a href="#MarkerOverlapError-__new__">__new__</a>(S,&nbsp;...)&nbsp;-&gt;&nbsp;a&nbsp;new&nbsp;<a href="__builtin__.html#object">object</a>&nbsp;with&nbsp;type&nbsp;S,&nbsp;a&nbsp;subtype&nbsp;of&nbsp;T</tt></dl>
136
137<hr>
138Methods inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
139<dl><dt><a name="MarkerOverlapError-__delattr__"><strong>__delattr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__delattr__">__delattr__</a>('name')&nbsp;&lt;==&gt;&nbsp;del&nbsp;x.name</tt></dd></dl>
140
141<dl><dt><a name="MarkerOverlapError-__getattribute__"><strong>__getattribute__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__getattribute__">__getattribute__</a>('name')&nbsp;&lt;==&gt;&nbsp;x.name</tt></dd></dl>
142
143<dl><dt><a name="MarkerOverlapError-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__getitem__">__getitem__</a>(y)&nbsp;&lt;==&gt;&nbsp;x[y]</tt></dd></dl>
144
145<dl><dt><a name="MarkerOverlapError-__getslice__"><strong>__getslice__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__getslice__">__getslice__</a>(i,&nbsp;j)&nbsp;&lt;==&gt;&nbsp;x[i:j]<br>
146&nbsp;<br>
147Use&nbsp;of&nbsp;negative&nbsp;indices&nbsp;is&nbsp;not&nbsp;supported.</tt></dd></dl>
148
149<dl><dt><a name="MarkerOverlapError-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
150
151<dl><dt><a name="MarkerOverlapError-__repr__"><strong>__repr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__repr__">__repr__</a>()&nbsp;&lt;==&gt;&nbsp;repr(x)</tt></dd></dl>
152
153<dl><dt><a name="MarkerOverlapError-__setattr__"><strong>__setattr__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__setattr__">__setattr__</a>('name',&nbsp;value)&nbsp;&lt;==&gt;&nbsp;x.name&nbsp;=&nbsp;value</tt></dd></dl>
154
155<dl><dt><a name="MarkerOverlapError-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
156
157<dl><dt><a name="MarkerOverlapError-__str__"><strong>__str__</strong></a>(...)</dt><dd><tt>x.<a href="#MarkerOverlapError-__str__">__str__</a>()&nbsp;&lt;==&gt;&nbsp;str(x)</tt></dd></dl>
158
159<dl><dt><a name="MarkerOverlapError-__unicode__"><strong>__unicode__</strong></a>(...)</dt></dl>
160
161<hr>
162Data descriptors inherited from <a href="exceptions.html#BaseException">exceptions.BaseException</a>:<br>
163<dl><dt><strong>__dict__</strong></dt>
164</dl>
165<dl><dt><strong>args</strong></dt>
166</dl>
167<dl><dt><strong>message</strong></dt>
168</dl>
169</td></tr></table> <p>
170<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
171<tr bgcolor="#ffc8d8">
172<td colspan=3 valign=bottom>&nbsp;<br>
173<font color="#000000" face="helvetica, arial"><a name="TimelineModel">class <strong>TimelineModel</strong></a>(<a href="__builtin__.html#object">__builtin__.object</a>)</font></td></tr>
174
175<tr><td bgcolor="#ffc8d8"><tt>&nbsp;&nbsp;&nbsp;</tt></td><td>&nbsp;</td>
176<td width="100%">Methods defined here:<br>
177<dl><dt><a name="TimelineModel-AddCoreObjectToContainerMapping"><strong>AddCoreObjectToContainerMapping</strong></a>(self, core_object, container)</dt><dd><tt>Add&nbsp;a&nbsp;mapping&nbsp;from&nbsp;a&nbsp;core&nbsp;<a href="__builtin__.html#object">object</a>&nbsp;to&nbsp;a&nbsp;timeline&nbsp;container.<br>
178&nbsp;<br>
179Used&nbsp;for&nbsp;example&nbsp;to&nbsp;map&nbsp;a&nbsp;Tab&nbsp;to&nbsp;its&nbsp;renderer&nbsp;process&nbsp;in&nbsp;the&nbsp;timeline&nbsp;model.</tt></dd></dl>
180
181<dl><dt><a name="TimelineModel-FinalizeImport"><strong>FinalizeImport</strong></a>(self, shift_world_to_zero<font color="#909090">=False</font>, importers<font color="#909090">=None</font>)</dt></dl>
182
183<dl><dt><a name="TimelineModel-FindTimelineMarkers"><strong>FindTimelineMarkers</strong></a>(self, timeline_marker_names)</dt><dd><tt>Find&nbsp;the&nbsp;timeline&nbsp;events&nbsp;with&nbsp;the&nbsp;given&nbsp;names.<br>
184&nbsp;<br>
185If&nbsp;the&nbsp;number&nbsp;and&nbsp;order&nbsp;of&nbsp;events&nbsp;found&nbsp;does&nbsp;not&nbsp;match&nbsp;the&nbsp;names,<br>
186raise&nbsp;an&nbsp;error.</tt></dd></dl>
187
188<dl><dt><a name="TimelineModel-GetAllContainers"><strong>GetAllContainers</strong></a>(self)</dt></dl>
189
190<dl><dt><a name="TimelineModel-GetAllEvents"><strong>GetAllEvents</strong></a>(self)</dt></dl>
191
192<dl><dt><a name="TimelineModel-GetAllEventsOfName"><strong>GetAllEventsOfName</strong></a>(self, name, only_root_events<font color="#909090">=False</font>)</dt></dl>
193
194<dl><dt><a name="TimelineModel-GetAllProcesses"><strong>GetAllProcesses</strong></a>(self)</dt></dl>
195
196<dl><dt><a name="TimelineModel-GetAllThreads"><strong>GetAllThreads</strong></a>(self)</dt></dl>
197
198<dl><dt><a name="TimelineModel-GetEventOfName"><strong>GetEventOfName</strong></a>(self, name, only_root_events<font color="#909090">=False</font>, fail_if_more_than_one<font color="#909090">=False</font>)</dt></dl>
199
200<dl><dt><a name="TimelineModel-GetOrCreateProcess"><strong>GetOrCreateProcess</strong></a>(self, pid)</dt></dl>
201
202<dl><dt><a name="TimelineModel-GetRendererProcessFromTab"><strong>GetRendererProcessFromTab</strong></a>(self, tab)</dt></dl>
203
204<dl><dt><a name="TimelineModel-GetRendererThreadFromTab"><strong>GetRendererThreadFromTab</strong></a>(self, tab)</dt></dl>
205
206<dl><dt><a name="TimelineModel-ImportTraces"><strong>ImportTraces</strong></a>(self, timeline_data, shift_world_to_zero<font color="#909090">=True</font>)</dt></dl>
207
208<dl><dt><a name="TimelineModel-IterAllEvents"><strong>IterAllEvents</strong></a>(self)</dt></dl>
209
210<dl><dt><a name="TimelineModel-ShiftWorldToZero"><strong>ShiftWorldToZero</strong></a>(self)</dt></dl>
211
212<dl><dt><a name="TimelineModel-UpdateBounds"><strong>UpdateBounds</strong></a>(self)</dt></dl>
213
214<dl><dt><a name="TimelineModel-__init__"><strong>__init__</strong></a>(self, timeline_data<font color="#909090">=None</font>, shift_world_to_zero<font color="#909090">=True</font>)</dt><dd><tt>Initializes&nbsp;a&nbsp;<a href="#TimelineModel">TimelineModel</a>.&nbsp;timeline_data&nbsp;can&nbsp;be&nbsp;a&nbsp;single&nbsp;TimelineData<br>
215<a href="__builtin__.html#object">object</a>,&nbsp;a&nbsp;list&nbsp;of&nbsp;TimelineData&nbsp;objects,&nbsp;or&nbsp;None.&nbsp;If&nbsp;timeline_data&nbsp;is&nbsp;not<br>
216None,&nbsp;all&nbsp;events&nbsp;from&nbsp;it&nbsp;will&nbsp;be&nbsp;imported&nbsp;into&nbsp;the&nbsp;model.&nbsp;The&nbsp;events&nbsp;will<br>
217be&nbsp;shifted&nbsp;such&nbsp;that&nbsp;the&nbsp;first&nbsp;event&nbsp;starts&nbsp;at&nbsp;time&nbsp;0,&nbsp;if<br>
218shift_world_to_zero&nbsp;is&nbsp;True.</tt></dd></dl>
219
220<hr>
221Data descriptors defined here:<br>
222<dl><dt><strong>__dict__</strong></dt>
223<dd><tt>dictionary&nbsp;for&nbsp;instance&nbsp;variables&nbsp;(if&nbsp;defined)</tt></dd>
224</dl>
225<dl><dt><strong>__weakref__</strong></dt>
226<dd><tt>list&nbsp;of&nbsp;weak&nbsp;references&nbsp;to&nbsp;the&nbsp;object&nbsp;(if&nbsp;defined)</tt></dd>
227</dl>
228<dl><dt><strong>bounds</strong></dt>
229</dl>
230<dl><dt><strong>browser_process</strong></dt>
231</dl>
232<dl><dt><strong>processes</strong></dt>
233</dl>
234<dl><dt><strong>thread_time_bounds</strong></dt>
235</dl>
236</td></tr></table></td></tr></table>
237</body></html>