uTools-Manuals/docs/php/xhprof_sample_disable.html
2019-04-08 23:22:26 +08:00

69 lines
3.9 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>停止 xhprof 性能采样分析器</title>
</head>
<body class="docs"><div id="layout">
<div id="layout-content"><div id="function.xhprof-sample-disable" class="refentry">
<div class="refnamediv">
<h1 class="refname">xhprof_sample_disable</h1>
<p class="verinfo">(PECL xhprof &gt;= 0.9.0)</p><p class="refpurpose"><span class="refname">xhprof_sample_disable</span> &mdash; <span class="dc-title">停止 xhprof 性能采样分析器</span></p>
</div>
<div class="refsect1 description" id="refsect1-function.xhprof-sample-disable-description">
<h3 class="title">说明</h3>
<div class="methodsynopsis dc-description">
<span class="methodname"><strong>xhprof_sample_disable</strong></span>
( <span class="methodparam">void</span>
) : <span class="type">array</span></div>
<p class="para rdfs-comment">
停止采样模式的 xhprof 分析器。
</p>
</div>
<div class="refsect1 parameters" id="refsect1-function.xhprof-sample-disable-parameters">
<h3 class="title">参数</h3>
<p class="para">此函数没有参数。</p>
</div>
<div class="refsect1 returnvalues" id="refsect1-function.xhprof-sample-disable-returnvalues">
<h3 class="title">返回值</h3>
<p class="para">
本次运行的xhprof采样数据<span class="type"><a href="language.types.array.html" class="type array">array</a></span> 类型。
</p>
</div>
<div class="refsect1 examples" id="refsect1-function.xhprof-sample-disable-examples">
<h3 class="title">范例</h3>
<div class="example" id="example-640">
<p><strong>Example #1 <span class="function"><strong>xhprof_sample_disable()</strong></span> 范例</strong></p>
<div class="example-contents">
<div class="phpcode"><pre><span style="color: #000000">
<span style="color: #0000BB">&lt;?php<br />xhprof_sample_enable</span><span style="color: #007700">();<br /><br />for&nbsp;(</span><span style="color: #0000BB">$i&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">0</span><span style="color: #007700">;&nbsp;</span><span style="color: #0000BB">$i&nbsp;</span><span style="color: #007700">&lt;=&nbsp;</span><span style="color: #0000BB">10000</span><span style="color: #007700">;&nbsp;</span><span style="color: #0000BB">$i</span><span style="color: #007700">++)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$a&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">strlen</span><span style="color: #007700">(</span><span style="color: #0000BB">$i</span><span style="color: #007700">);<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$b&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">$i&nbsp;</span><span style="color: #007700">*&nbsp;</span><span style="color: #0000BB">$a</span><span style="color: #007700">;<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$c&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">rand</span><span style="color: #007700">();<br />}<br /><br /></span><span style="color: #0000BB">$xhprof_data&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">xhprof_sample_disable</span><span style="color: #007700">();<br /><br /></span><span style="color: #0000BB">print_r</span><span style="color: #007700">(</span><span style="color: #0000BB">$xhprof_data</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span>
</span>
</pre></div>
</div>
<div class="example-contents"><p>以上例程的输出类似于:</p></div>
<div class="example-contents screen">
<div class="cdata"><pre>
Array
(
[1272935300.800000] =&gt; main()
[1272935300.900000] =&gt; main()
)
</pre></div>
</div>
</div>
</div>
</div></div></div></body></html>