mirror of
https://github.com/php/doc-pt_br.git
synced 2026-03-23 22:52:12 +01:00
113 lines
3.6 KiB
XML
113 lines
3.6 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- EN-Revision: 804d8a05451c13328eb1192553dcb2374706cabb Maintainer: leonardolara Status: ready -->
|
|
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="apcuiterator.construct">
|
|
<refnamediv>
|
|
<refname>APCUIterator::__construct</refname>
|
|
<refpurpose>Constrói um objeto iterador APCUIterator</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<constructorsynopsis>
|
|
<modifier>public</modifier> <methodname>APCUIterator::__construct</methodname>
|
|
<methodparam choice="opt"><type class="union"><type>array</type><type>string</type><type>null</type></type><parameter>search</parameter><initializer>&null;</initializer></methodparam>
|
|
<methodparam choice="opt"><type>int</type><parameter>format</parameter><initializer>APC_ITER_ALL</initializer></methodparam>
|
|
<methodparam choice="opt"><type>int</type><parameter>chunk_size</parameter><initializer>100</initializer></methodparam>
|
|
<methodparam choice="opt"><type>int</type><parameter>list</parameter><initializer>APC_LIST_ACTIVE</initializer></methodparam>
|
|
</constructorsynopsis>
|
|
<simpara>
|
|
Constrói um <type>object</type> da classe <classname>APCUIterator</classname>.
|
|
</simpara>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>search</parameter></term>
|
|
<listitem>
|
|
<simpara>
|
|
Pode ser uma expressão regular <link linkend="book.pcre">PCRE</link> que
|
|
corresponda a nomes de chaves APCu, informada como uma &string;.
|
|
Ou um &array; de &string;s com nomes de chaves APCu.
|
|
Ou, opcionalmente, &null; para não fazer a pesquisa.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>format</parameter></term>
|
|
<listitem>
|
|
<simpara>
|
|
O formato desejado, como configurado com um ou mais das constantes
|
|
<link linkend="apcu.constants">APC_ITER_*</link>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>chunk_size</parameter></term>
|
|
<listitem>
|
|
<simpara>
|
|
O tamanho do pacote. Deve ser um valor maior que 0. O valor
|
|
padrão é 100.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>list</parameter></term>
|
|
<listitem>
|
|
<simpara>
|
|
O tipo a ser listado. Podem ser passadas as constantes <constant>APC_LIST_ACTIVE</constant>
|
|
ou <constant>APC_LIST_DELETED</constant>.
|
|
</simpara>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
&reftitle.examples;
|
|
<example>
|
|
<title>Um exemplo de <function>APCUIterator::__construct</function></title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
foreach (new APCUIterator('/^counter\./') as $counter) {
|
|
echo "$counter[key]: $counter[value]\n";
|
|
apc_dec($counter['key'], $counter['value']);
|
|
}
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<simplelist>
|
|
<member><function>apcu_exists</function></member>
|
|
<member><function>apcu_cache_info</function></member>
|
|
</simplelist>
|
|
</refsect1>
|
|
|
|
</refentry>
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|