mirror of
https://github.com/php/doc-pt_br.git
synced 2026-03-24 07:02:09 +01:00
132 lines
3.7 KiB
XML
132 lines
3.7 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- EN-Revision: bc0556b65588379cb86511d5a0ff8ab4684e1d33 Maintainer: leonardolara Status: ready --><!-- CREDITS: leonardolara -->
|
|
<!-- Generated by xml_proto.php v2.0. Found in /scripts directory of phpdoc. -->
|
|
<refentry xml:id="function.xdiff-file-diff-binary" xmlns="http://docbook.org/ns/docbook">
|
|
<refnamediv>
|
|
<refname>xdiff_file_diff_binary</refname>
|
|
<refpurpose>&Alias; <function>xdiff_file_bdiff</function></refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>bool</type><methodname>xdiff_file_diff_binary</methodname>
|
|
<methodparam><type>string</type><parameter>old_file</parameter></methodparam>
|
|
<methodparam><type>string</type><parameter>new_file</parameter></methodparam>
|
|
<methodparam><type>string</type><parameter>dest</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
Cria uma comparação binária de dois arquivos e armazena o resultado em um arquivo de patch.
|
|
Esta função funciona tanto com arquivos de texto quanto com arquivos binários. O arquivo de patch
|
|
resultante pode ser aplicado posteriormente usando <function>xdiff_file_bpatch</function>.
|
|
</para>
|
|
<para>
|
|
A partir da versão 1.5.0, esta função é um sinônimo de <function>xdiff_file_bdiff</function>.
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="parameters">
|
|
&reftitle.parameters;
|
|
<para>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>old_file</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Caminho para o primeiro arquivo. Este arquivo atua como o arquivo "antigo".
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>new_file</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Caminho para o segundo arquivo. Este arquivo atua como um arquivo "novo".
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>dest</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Caminho do arquivo de patch resultante. O arquivo resultante contém diferenças
|
|
entre os arquivos "antigo" e "novo". Em formato binário e ilegível por humanos.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="returnvalues">
|
|
&reftitle.returnvalues;
|
|
<para>
|
|
&return.success;
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
&reftitle.examples;
|
|
<para>
|
|
<example>
|
|
<title>Exemplo de <function>xdiff_file_diff_binary</function></title>
|
|
<para>
|
|
O código a seguir faz uma comparação binária de dois arquivos.
|
|
</para>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
$old_version = 'my_script_1.0.tgz';
|
|
$new_version = 'my_script_1.1.tgz';
|
|
|
|
xdiff_file_diff_binary($old_version, $new_version, 'my_script.bdiff');
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
</example>
|
|
</para>
|
|
</refsect1>
|
|
|
|
<refsect1 role="notes">
|
|
&reftitle.notes;
|
|
<note>
|
|
<para>
|
|
Ambos os arquivos serão carregados na memória, portanto, certifique-se de que o limite de memória esteja
|
|
definido como alto o suficiente.
|
|
</para>
|
|
</note>
|
|
</refsect1>
|
|
|
|
<refsect1 role="seealso">
|
|
&reftitle.seealso;
|
|
<para>
|
|
<simplelist>
|
|
<member><function>xdiff_file_bdiff</function></member>
|
|
<member><function>xdiff_file_bpatch</function></member>
|
|
</simplelist>
|
|
</para>
|
|
</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
|
|
-->
|