| OLD | NEW |
| (Empty) |
| 1 | |
| 2 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> | |
| 3 <html><head><title>Python: module telemetry.internal.platform.platform_backend</
title> | |
| 4 <meta charset="utf-8"> | |
| 5 </head><body bgcolor="#f0f0f8"> | |
| 6 | |
| 7 <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading"> | |
| 8 <tr bgcolor="#7799ee"> | |
| 9 <td valign=bottom> <br> | |
| 10 <font color="#ffffff" face="helvetica, arial"> <br><big><big><strong><a hre
f="telemetry.html"><font color="#ffffff">telemetry</font></a>.<a href="telemetry
.internal.html"><font color="#ffffff">internal</font></a>.<a href="telemetry.int
ernal.platform.html"><font color="#ffffff">platform</font></a>.platform_backend<
/strong></big></big></font></td | |
| 11 ><td align=right valign=bottom | |
| 12 ><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href=
"../telemetry/internal/platform/platform_backend.py">telemetry/internal/platform
/platform_backend.py</a></font></td></tr></table> | |
| 13 <p><tt># Copyright 2013 The Chromium Authors.
All rights reserved.<br> | |
| 14 # Use of this source code is governed by
a BSD-style license that can be<br> | |
| 15 # found in the LICENSE file.</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> <br> | |
| 20 <font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big
></font></td></tr> | |
| 21 | |
| 22 <tr><td bgcolor="#aa55cc"><tt> </tt></td><td>
</td> | |
| 23 <td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=t
op><a href="telemetry.internal.forwarders.do_nothing_forwarder.html">telemetry.i
nternal.forwarders.do_nothing_forwarder</a><br> | |
| 24 </td><td width="25%" valign=top><a href="telemetry.internal.platform.network_con
troller_backend.html">telemetry.internal.platform.network_controller_backend</a>
<br> | |
| 25 </td><td width="25%" valign=top><a href="telemetry.internal.platform.tracing_con
troller_backend.html">telemetry.internal.platform.tracing_controller_backend</a>
<br> | |
| 26 </td><td width="25%" valign=top><a href="weakref.html">weakref</a><br> | |
| 27 </td></tr></table></td></tr></table><p> | |
| 28 <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section"> | |
| 29 <tr bgcolor="#ee77aa"> | |
| 30 <td colspan=3 valign=bottom> <br> | |
| 31 <font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big
></font></td></tr> | |
| 32 | |
| 33 <tr><td bgcolor="#ee77aa"><tt> </tt></td><td>
</td> | |
| 34 <td width="100%"><dl> | |
| 35 <dt><font face="helvetica, arial"><a href="__builtin__.html#object">__builtin__.
object</a> | |
| 36 </font></dt><dd> | |
| 37 <dl> | |
| 38 <dt><font face="helvetica, arial"><a href="telemetry.internal.platform.platform_
backend.html#PlatformBackend">PlatformBackend</a> | |
| 39 </font></dt></dl> | |
| 40 </dd> | |
| 41 </dl> | |
| 42 <p> | |
| 43 <table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section"> | |
| 44 <tr bgcolor="#ffc8d8"> | |
| 45 <td colspan=3 valign=bottom> <br> | |
| 46 <font color="#000000" face="helvetica, arial"><a name="PlatformBackend">class <s
trong>PlatformBackend</strong></a>(<a href="__builtin__.html#object">__builtin__
.object</a>)</font></td></tr> | |
| 47 | |
| 48 <tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td> | |
| 49 <td width="100%">Methods defined here:<br> | |
| 50 <dl><dt><a name="PlatformBackend-CanCaptureVideo"><strong>CanCaptureVideo</stron
g></a>(self)</dt></dl> | |
| 51 | |
| 52 <dl><dt><a name="PlatformBackend-CanFlushIndividualFilesFromSystemCache"><strong
>CanFlushIndividualFilesFromSystemCache</strong></a>(self)</dt></dl> | |
| 53 | |
| 54 <dl><dt><a name="PlatformBackend-CanLaunchApplication"><strong>CanLaunchApplicat
ion</strong></a>(self, application)</dt></dl> | |
| 55 | |
| 56 <dl><dt><a name="PlatformBackend-CanMeasurePerApplicationPower"><strong>CanMeasu
rePerApplicationPower</strong></a>(self)</dt></dl> | |
| 57 | |
| 58 <dl><dt><a name="PlatformBackend-CanMonitorNetworkData"><strong>CanMonitorNetwor
kData</strong></a>(self)</dt></dl> | |
| 59 | |
| 60 <dl><dt><a name="PlatformBackend-CanMonitorPower"><strong>CanMonitorPower</stron
g></a>(self)</dt></dl> | |
| 61 | |
| 62 <dl><dt><a name="PlatformBackend-CanMonitorThermalThrottling"><strong>CanMonitor
ThermalThrottling</strong></a>(self)</dt></dl> | |
| 63 | |
| 64 <dl><dt><a name="PlatformBackend-CanTakeScreenshot"><strong>CanTakeScreenshot</s
trong></a>(self)</dt></dl> | |
| 65 | |
| 66 <dl><dt><a name="PlatformBackend-CooperativelyShutdown"><strong>CooperativelyShu
tdown</strong></a>(self, proc, app_name)</dt><dd><tt>Cooperatively shut&nbs
p;down the given process from subprocess.Popen.<br> | |
| 67 <br> | |
| 68 Currently this is only implemented on Windows.&nbs
p;See<br> | |
| 69 crbug.com/424024 for background on why it was 
;added.<br> | |
| 70 <br> | |
| 71 Args:<br> | |
| 72 proc: a process <a href="__builtin__.html#object">obj
ect</a> returned from subprocess.Popen.<br> | |
| 73 app_name: on Windows, is the prefix of
the application's window<br> | |
| 74 class name that should b
e searched for. This helps ensure<br> | |
| 75 that only the application's&n
bsp;windows are closed.<br> | |
| 76 <br> | |
| 77 Returns True if it is believed the attempt&nb
sp;succeeded.</tt></dd></dl> | |
| 78 | |
| 79 <dl><dt><a name="PlatformBackend-DidCreateBrowser"><strong>DidCreateBrowser</str
ong></a>(self, browser, browser_backend)</dt></dl> | |
| 80 | |
| 81 <dl><dt><a name="PlatformBackend-DidStartBrowser"><strong>DidStartBrowser</stron
g></a>(self, browser, browser_backend)</dt></dl> | |
| 82 | |
| 83 <dl><dt><a name="PlatformBackend-FlushDnsCache"><strong>FlushDnsCache</strong></
a>(self)</dt></dl> | |
| 84 | |
| 85 <dl><dt><a name="PlatformBackend-FlushEntireSystemCache"><strong>FlushEntireSyst
emCache</strong></a>(self)</dt></dl> | |
| 86 | |
| 87 <dl><dt><a name="PlatformBackend-FlushSystemCacheForDirectory"><strong>FlushSyst
emCacheForDirectory</strong></a>(self, directory)</dt></dl> | |
| 88 | |
| 89 <dl><dt><a name="PlatformBackend-GetArchName"><strong>GetArchName</strong></a>(s
elf)</dt></dl> | |
| 90 | |
| 91 <dl><dt><a name="PlatformBackend-GetChildPids"><strong>GetChildPids</strong></a>
(self, pid)</dt></dl> | |
| 92 | |
| 93 <dl><dt><a name="PlatformBackend-GetCommandLine"><strong>GetCommandLine</strong>
</a>(self, pid)</dt></dl> | |
| 94 | |
| 95 <dl><dt><a name="PlatformBackend-GetCpuStats"><strong>GetCpuStats</strong></a>(s
elf, pid)</dt></dl> | |
| 96 | |
| 97 <dl><dt><a name="PlatformBackend-GetCpuTimestamp"><strong>GetCpuTimestamp</stron
g></a>(self)</dt></dl> | |
| 98 | |
| 99 <dl><dt><a name="PlatformBackend-GetDeviceTypeName"><strong>GetDeviceTypeName</s
trong></a>(self)</dt></dl> | |
| 100 | |
| 101 <dl><dt><a name="PlatformBackend-GetMemoryStats"><strong>GetMemoryStats</strong>
</a>(self, pid)</dt></dl> | |
| 102 | |
| 103 <dl><dt><a name="PlatformBackend-GetNetworkData"><strong>GetNetworkData</strong>
</a>(self, browser)</dt></dl> | |
| 104 | |
| 105 <dl><dt><a name="PlatformBackend-GetOSName"><strong>GetOSName</strong></a>(self)
</dt></dl> | |
| 106 | |
| 107 <dl><dt><a name="PlatformBackend-GetOSVersionName"><strong>GetOSVersionName</str
ong></a>(self)</dt></dl> | |
| 108 | |
| 109 <dl><dt><a name="PlatformBackend-GetRemotePort"><strong>GetRemotePort</strong></
a>(self, port)</dt></dl> | |
| 110 | |
| 111 <dl><dt><a name="PlatformBackend-GetSystemCommitCharge"><strong>GetSystemCommitC
harge</strong></a>(self)</dt></dl> | |
| 112 | |
| 113 <dl><dt><a name="PlatformBackend-GetSystemTotalPhysicalMemory"><strong>GetSystem
TotalPhysicalMemory</strong></a>(self)</dt></dl> | |
| 114 | |
| 115 <dl><dt><a name="PlatformBackend-HasBeenThermallyThrottled"><strong>HasBeenTherm
allyThrottled</strong></a>(self)</dt></dl> | |
| 116 | |
| 117 <dl><dt><a name="PlatformBackend-InitPlatformBackend"><strong>InitPlatformBacken
d</strong></a>(self)</dt></dl> | |
| 118 | |
| 119 <dl><dt><a name="PlatformBackend-InstallApplication"><strong>InstallApplication<
/strong></a>(self, application)</dt></dl> | |
| 120 | |
| 121 <dl><dt><a name="PlatformBackend-IsApplicationRunning"><strong>IsApplicationRunn
ing</strong></a>(self, application)</dt></dl> | |
| 122 | |
| 123 <dl><dt><a name="PlatformBackend-IsCooperativeShutdownSupported"><strong>IsCoope
rativeShutdownSupported</strong></a>(self)</dt><dd><tt>Indicates whether&nb
sp;CooperativelyShutdown, below, is supported.<br> | |
| 124 It is not necessary to implement it on a
ll platforms.</tt></dd></dl> | |
| 125 | |
| 126 <dl><dt><a name="PlatformBackend-IsDisplayTracingSupported"><strong>IsDisplayTra
cingSupported</strong></a>(self)</dt></dl> | |
| 127 | |
| 128 <dl><dt><a name="PlatformBackend-IsThermallyThrottled"><strong>IsThermallyThrott
led</strong></a>(self)</dt></dl> | |
| 129 | |
| 130 <dl><dt><a name="PlatformBackend-LaunchApplication"><strong>LaunchApplication</s
trong></a>(self, application, parameters<font color="#909090">=None</font>, elev
ate_privilege<font color="#909090">=False</font>)</dt></dl> | |
| 131 | |
| 132 <dl><dt><a name="PlatformBackend-PathExists"><strong>PathExists</strong></a>(sel
f, path, timeout<font color="#909090">=None</font>, retries<font color="#909090"
>=None</font>)</dt><dd><tt>Tests whether the given path 
;exists on the target platform.<br> | |
| 133 Args:<br> | |
| 134 path: path in request.<br> | |
| 135 timeout: timeout.<br> | |
| 136 retries: num of retries.<br> | |
| 137 Return:<br> | |
| 138 Whether the path exists on the target&
nbsp;platform.</tt></dd></dl> | |
| 139 | |
| 140 <dl><dt><a name="PlatformBackend-PurgeUnpinnedMemory"><strong>PurgeUnpinnedMemor
y</strong></a>(self)</dt></dl> | |
| 141 | |
| 142 <dl><dt><a name="PlatformBackend-ReadMsr"><strong>ReadMsr</strong></a>(self, msr
_number, start<font color="#909090">=0</font>, length<font color="#909090">=64</
font>)</dt><dd><tt>Read a CPU model-specific register (
MSR).<br> | |
| 143 <br> | |
| 144 Which MSRs are available depends on the CPU&n
bsp;model.<br> | |
| 145 On systems with multiple CPUs, this function
may run on any CPU.<br> | |
| 146 <br> | |
| 147 Args:<br> | |
| 148 msr_number: The number of the register 
;to read.<br> | |
| 149 start: The least significant bit to re
ad, zero-indexed.<br> | |
| 150 (Said another way, the n
umber of bits to right-shift the MSR value.)<
br> | |
| 151 length: The number of bits to read.&nb
sp;MSRs are 64 bits, even on 32-bit CPUs.</tt
></dd></dl> | |
| 152 | |
| 153 <dl><dt><a name="PlatformBackend-SetFullPerformanceModeEnabled"><strong>SetFullP
erformanceModeEnabled</strong></a>(self, enabled)</dt></dl> | |
| 154 | |
| 155 <dl><dt><a name="PlatformBackend-SetPlatform"><strong>SetPlatform</strong></a>(s
elf, platform)</dt></dl> | |
| 156 | |
| 157 <dl><dt><a name="PlatformBackend-StartDisplayTracing"><strong>StartDisplayTracin
g</strong></a>(self)</dt><dd><tt>Start gathering a trace wit
h frame timestamps close to physical<br> | |
| 158 display.</tt></dd></dl> | |
| 159 | |
| 160 <dl><dt><a name="PlatformBackend-StartMonitoringPower"><strong>StartMonitoringPo
wer</strong></a>(self, browser)</dt></dl> | |
| 161 | |
| 162 <dl><dt><a name="PlatformBackend-StartVideoCapture"><strong>StartVideoCapture</s
trong></a>(self, min_bitrate_mbps)</dt></dl> | |
| 163 | |
| 164 <dl><dt><a name="PlatformBackend-StopDisplayTracing"><strong>StopDisplayTracing<
/strong></a>(self)</dt><dd><tt>Stop gathering a trace with&n
bsp;frame timestamps close to physical display.<br> | |
| 165 <br> | |
| 166 Returns a raw tracing events that contains th
e timestamps of physical<br> | |
| 167 display.</tt></dd></dl> | |
| 168 | |
| 169 <dl><dt><a name="PlatformBackend-StopMonitoringPower"><strong>StopMonitoringPowe
r</strong></a>(self)</dt></dl> | |
| 170 | |
| 171 <dl><dt><a name="PlatformBackend-StopVideoCapture"><strong>StopVideoCapture</str
ong></a>(self)</dt></dl> | |
| 172 | |
| 173 <dl><dt><a name="PlatformBackend-TakeScreenshot"><strong>TakeScreenshot</strong>
</a>(self, file_path)</dt></dl> | |
| 174 | |
| 175 <dl><dt><a name="PlatformBackend-WillCloseBrowser"><strong>WillCloseBrowser</str
ong></a>(self, browser, browser_backend)</dt></dl> | |
| 176 | |
| 177 <dl><dt><a name="PlatformBackend-__init__"><strong>__init__</strong></a>(self, d
evice<font color="#909090">=None</font>)</dt><dd><tt>Initalize an inst
ance of <a href="#PlatformBackend">PlatformBackend</a> from
a device optionally.<br> | |
| 178 Call sites need to use SupportsDevice before
intialization to check<br> | |
| 179 whether this platform backend supports the device.
<br> | |
| 180 If device is None, this constructor returns t
he host platform backend<br> | |
| 181 which telemetry is running on.<br> | |
| 182 <br> | |
| 183 Args:<br> | |
| 184 device: an instance of telemetry.core.platform.d
evice.Device.</tt></dd></dl> | |
| 185 | |
| 186 <hr> | |
| 187 Class methods defined here:<br> | |
| 188 <dl><dt><a name="PlatformBackend-CreatePlatformForDevice"><strong>CreatePlatform
ForDevice</strong></a>(cls, device, finder_options)<font color="#909090"><font f
ace="helvetica, arial"> from <a href="__builtin__.html#type">__builtin__.type</a
></font></font></dt></dl> | |
| 189 | |
| 190 <dl><dt><a name="PlatformBackend-IsPlatformBackendForHost"><strong>IsPlatformBac
kendForHost</strong></a>(cls)<font color="#909090"><font face="helvetica, arial"
> from <a href="__builtin__.html#type">__builtin__.type</a></font></font></dt><d
d><tt>Returns whether this platform backend is the
platform backend to be used<br> | |
| 191 for the host device which telemetry is runnin
g on.</tt></dd></dl> | |
| 192 | |
| 193 <dl><dt><a name="PlatformBackend-SupportsDevice"><strong>SupportsDevice</strong>
</a>(cls, device)<font color="#909090"><font face="helvetica, arial"> from <a hr
ef="__builtin__.html#type">__builtin__.type</a></font></font></dt><dd><tt>Return
s whether this platform backend supports intializa
tion from the<br> | |
| 194 device.</tt></dd></dl> | |
| 195 | |
| 196 <hr> | |
| 197 Data descriptors defined here:<br> | |
| 198 <dl><dt><strong>__dict__</strong></dt> | |
| 199 <dd><tt>dictionary for instance variables (if defined)<
/tt></dd> | |
| 200 </dl> | |
| 201 <dl><dt><strong>__weakref__</strong></dt> | |
| 202 <dd><tt>list of weak references to the object 
;(if defined)</tt></dd> | |
| 203 </dl> | |
| 204 <dl><dt><strong>forwarder_factory</strong></dt> | |
| 205 </dl> | |
| 206 <dl><dt><strong>is_host_platform</strong></dt> | |
| 207 </dl> | |
| 208 <dl><dt><strong>is_video_capture_running</strong></dt> | |
| 209 </dl> | |
| 210 <dl><dt><strong>network_controller_backend</strong></dt> | |
| 211 </dl> | |
| 212 <dl><dt><strong>platform</strong></dt> | |
| 213 </dl> | |
| 214 <dl><dt><strong>running_browser_backends</strong></dt> | |
| 215 </dl> | |
| 216 <dl><dt><strong>tracing_controller_backend</strong></dt> | |
| 217 </dl> | |
| 218 <dl><dt><strong>wpr_ca_cert_path</strong></dt> | |
| 219 </dl> | |
| 220 <dl><dt><strong>wpr_http_device_port</strong></dt> | |
| 221 </dl> | |
| 222 <dl><dt><strong>wpr_https_device_port</strong></dt> | |
| 223 </dl> | |
| 224 </td></tr></table></td></tr></table> | |
| 225 </body></html> | |
| OLD | NEW |