cvs: phpdoc-es / translation.xml /reference/array/functions array-udiff.xml /reference/filesystem/functions disk-free-space.xml disk-total-space.xml
/reference/ftp reference.xml /reference/pgsql reference.xml /reference/stream/functions stream-filter-register.xml stream-socket-accept.xml
stream-socket-client.xml stream-socket-get-name.xml

From: Date: Sun, 28 Dec 2003 05:19:27 +0000
Subject: cvs: phpdoc-es / translation.xml /reference/array/functions array-udiff.xml /reference/filesystem/functions disk-free-space.xml disk-total-space.xml
/reference/ftp reference.xml /reference/pgsql reference.xml /reference/stream/functions stream-filter-register.xml stream-socket-accept.xml
stream-socket-client.xml stream-socket-get-name.xml
Groups: php.doc.es 
Request: Send a blank email to doc-es+get-456@lists.php.net to get a copy of this message
lboshell Sun Dec 28 00:19:27 2003 EDT Added files: /phpdoc-es/reference/stream/functions stream-socket-accept.xml stream-socket-client.xml stream-socket-get-name.xml Modified files: /phpdoc-es translation.xml /phpdoc-es/reference/array/functions array-udiff.xml /phpdoc-es/reference/filesystem/functions disk-free-space.xml disk-total-space.xml /phpdoc-es/reference/ftp reference.xml /phpdoc-es/reference/pgsql reference.xml /phpdoc-es/reference/stream/functions stream-filter-register.xml Log: Nuevos archivos de reference/stream. Actualizaciones y correcciones.

Index: phpdoc-es/translation.xml diff -u phpdoc-es/translation.xml:1.109 phpdoc-es/translation.xml:1.110 --- phpdoc-es/translation.xml:1.109 Mon Dec 22 22:36:57 2003 +++ phpdoc-es/translation.xml Sun Dec 28 00:19:20 2003 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.109 $ --> +<!-- $Revision: 1.110 $ --> <!DOCTYPE translation SYSTEM "../entities/translation.dtd"> <translation> @@ -45,9 +45,6 @@ <file name="reference/errorfunc/functions/set-error-handler.xml" person="javi" type="translation" date="01.12.2003"/> <file name="reference/errorfunc/functions/trigger-error.xml" person="javi" type="translation" date="01.12.2003"/> <file name="reference/errorfunc/functions/user-error.xml" person="javi" type="translation" date="01.12.2003"/> -<file name="reference/stream/functions/stream-socket-accept.xml" person="lboshell" type="translation" date="16.12.2003"/> -<file name="reference/stream/functions/stream-socket-client.xml" person="lboshell" type="translation" date="16.12.2003"/> -<file name="reference/stream/functions/stream-socket-get-name.xml" person="lboshell" type="translation" date="16.12.2003"/> <file name="reference/stream/functions/stream-socket-recvfrom.xml" person="lboshell" type="translation" date="16.12.2003"/> <file name="reference/stream/functions/stream-socket-sendto.xml" person="lboshell" type="translation" date="16.12.2003"/> <file name="reference/stream/functions/stream-socket-server.xml" person="lboshell" type="translation" date="16.12.2003"/> Index: phpdoc-es/reference/array/functions/array-udiff.xml diff -u phpdoc-es/reference/array/functions/array-udiff.xml:1.3 phpdoc-es/reference/array/functions/array-udiff.xml:1.4 --- phpdoc-es/reference/array/functions/array-udiff.xml:1.3 Mon Dec 15 22:09:46 2003 +++ phpdoc-es/reference/array/functions/array-udiff.xml Sun Dec 28 00:19:24 2003 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- EN-Revision: 1.4 Maintainer: lboshell Status: ready --> +<!-- $Revision: 1.4 $ --> +<!-- EN-Revision: 1.5 Maintainer: lboshell Status: ready --> <!-- splitted from ./en/functions/array.xml, last change in rev 1.14 --> <refentry id="function.array-udiff"> <refnamediv> Index: phpdoc-es/reference/filesystem/functions/disk-free-space.xml diff -u phpdoc-es/reference/filesystem/functions/disk-free-space.xml:1.1 phpdoc-es/reference/filesystem/functions/disk-free-space.xml:1.2 --- phpdoc-es/reference/filesystem/functions/disk-free-space.xml:1.1 Thu Nov 13 01:38:53 2003 +++ phpdoc-es/reference/filesystem/functions/disk-free-space.xml Sun Dec 28 00:19:25 2003 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.1 $ --> -<!-- EN-Revision: 1.3 Maintainer: lboshell Status: ready --> +<!-- $Revision: 1.2 $ --> +<!-- EN-Revision: 1.4 Maintainer: lboshell Status: ready --> <!-- splitted from ./en/functions/filesystem.xml, last change in rev 1.86 --> <refentry id="function.disk-free-space"> <refnamediv> @@ -26,6 +26,10 @@ <?php // $df contiene el numero de bytes disponibles en "/" $df = disk_free_space("/"); + +// En Windows: +disk_free_space("C:"); +disk_free_space("D:"); ?> ]]> </programlisting> Index: phpdoc-es/reference/filesystem/functions/disk-total-space.xml diff -u phpdoc-es/reference/filesystem/functions/disk-total-space.xml:1.1 phpdoc-es/reference/filesystem/functions/disk-total-space.xml:1.2 --- phpdoc-es/reference/filesystem/functions/disk-total-space.xml:1.1 Thu Nov 13 01:38:53 2003 +++ phpdoc-es/reference/filesystem/functions/disk-total-space.xml Sun Dec 28 00:19:25 2003 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.1 $ --> -<!-- EN-Revision: 1.3 Maintainer: lboshell Status: ready --> +<!-- $Revision: 1.2 $ --> +<!-- EN-Revision: 1.4 Maintainer: lboshell Status: ready --> <!-- splitted from ./en/functions/filesystem.xml, last change in rev 1.64 --> <refentry id="function.disk-total-space"> <refnamediv> @@ -26,6 +26,10 @@ <?php // $df contiene el numero total de bytes disponible en "/" $df = disk_total_space("/"); + +// En Windows: +disk_total_space("C:"); +disk_total_space("D:"); ?> ]]> </programlisting> Index: phpdoc-es/reference/ftp/reference.xml diff -u phpdoc-es/reference/ftp/reference.xml:1.3 phpdoc-es/reference/ftp/reference.xml:1.4 --- phpdoc-es/reference/ftp/reference.xml:1.3 Fri Dec 12 01:41:03 2003 +++ phpdoc-es/reference/ftp/reference.xml Sun Dec 28 00:19:25 2003 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.3 $ --> -<!-- EN-Revision: 1.7 Maintainer: lboshell Status: ready --> +<!-- $Revision: 1.4 $ --> +<!-- EN-Revision: 1.8 Maintainer: lboshell Status: ready --> <reference id="ref.ftp"> <title>Funciones FTP</title> <titleabbrev>FTP</titleabbrev> @@ -13,7 +13,7 @@ servidores de archivos que entiendan el Protocolo de Transferencia de Archivos (FTP, por sus siglas en Ingl&eacute;s), tal y como se define en -<ulink url="&spec.ftp;">&spec.ftp;</ulink>. Esta extensi&oacute;n +<ulink url="&url.rfc;959">&url.rfc;959</ulink>. Esta extensi&oacute;n tiene como prop&oacute;sito el acceso detallado a un servidor FTP, brindando un amplio rango de control al script que se encuentre ejecutando. Si s&oacute;lo desea leer desde un archivo o escribir Index: phpdoc-es/reference/pgsql/reference.xml diff -u phpdoc-es/reference/pgsql/reference.xml:1.5 phpdoc-es/reference/pgsql/reference.xml:1.6 --- phpdoc-es/reference/pgsql/reference.xml:1.5 Mon Dec 15 23:43:37 2003 +++ phpdoc-es/reference/pgsql/reference.xml Sun Dec 28 00:19:26 2003 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.5 $ --> +<!-- $Revision: 1.6 $ --> <!-- EN-Revision: 1.18 Maintainer: lboshell Status: ready --> <reference id="ref.pgsql"> <title>Funciones PostgreSQL</title> @@ -15,7 +15,7 @@ de los conceptos de objetos y relacionales que ahora est&aacute;n apareciendo en algunas bases de datos comerciales. Provee soporte para lenguajes SQL92/SQL99, transacciones, integridad referencial, -prodecimientos almacenados y extensibilidad de tipos. PostgreSQL es un +procedimientos almacenados y extensibilidad de tipos. PostgreSQL es un descendiente de c&oacute;digo abierto de su c&oacute;digo original de Berkeley. </para> Index: phpdoc-es/reference/stream/functions/stream-filter-register.xml diff -u phpdoc-es/reference/stream/functions/stream-filter-register.xml:1.1 phpdoc-es/reference/stream/functions/stream-filter-register.xml:1.2 --- phpdoc-es/reference/stream/functions/stream-filter-register.xml:1.1 Fri Dec 19 00:17:58 2003 +++ phpdoc-es/reference/stream/functions/stream-filter-register.xml Sun Dec 28 00:19:27 2003 @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="iso-8859-1"?> -<!-- $Revision: 1.1 $ --> +<!-- $Revision: 1.2 $ --> <!-- EN-Revision: 1.5 Maintainer: lboshell Status: ready --> <refentry id="function.stream-filter-register"> <refnamediv> @@ -119,7 +119,7 @@ </simpara> <simpara> Cuando su filtro es instanciado por primera vez, -y <literal>sufiltro-&gt;oncreate()</literal> es llamado, se +y <literal>su_filtro-&gt;oncreate()</literal> es llamado, se colocar&aacute;n a su disposici&oacute;n un n&uacute;mero de propiedades, como lo muestra la siguiente tabla. </simpara> Index: phpdoc-es/reference/stream/functions/stream-socket-accept.xml +++ phpdoc-es/reference/stream/functions/stream-socket-accept.xml <?xml version="1.0" encoding="iso-8859-1"?> <!-- $Revision: 1.1 $ --> <!-- EN-Revision: 1.1 Maintainer: lboshell Status: ready --> <refentry id="function.stream-socket-accept"> <refnamediv> <refname>stream_socket_accept</refname> <refpurpose> Aceptar una conexi&oacute;n en un socket creado por <function>stream_socket_server</function> </refpurpose> </refnamediv> <refsect1> <title>Descripci&oacute;n</title> <methodsynopsis> <type>resource</type><methodname>stream_socket_accept</methodname> <methodparam><type>resource</type><parameter>socket_servidor</parameter></methodparam> <methodparam choice="opt"><type>int</type><parameter>tiempo_espera</parameter></methodparam> <methodparam choice="opt"><type>string</type><parameter>&amp;nombre_de_par</parameter></methodparam> </methodsynopsis> <para> Aceptar una conexi&oacute;n en un socket creado previamente por <function>stream_socket_server</function>. Si se especifica <parameter>tiempo_espera</parameter>, el tiempo de espera predeterminado para el proceso accept del socket ser&aacute; sobrescrito con el tiempo especificado en segundos. El nombre (direcci&oacute;n) del cliente que se ha conectado ser&aacute; pasado de vuelta en <parameter>nombre_de_par</parameter>, si se incluye y se encuentra disponible en el transporte seleccionado. </para> <simpara> Puede determinarse el valor de <parameter>nombre_de_par</parameter> tambi&eacute;n m&aacute;s adelante, usando <function>stream_socket_get_name</function>. </simpara> <simpara> Si el llamado falla, devolver&aacute; &false;. </simpara> <para> Vea tambi&eacute;n <function>stream_socket_server</function>, <function>stream_socket_get_name</function>, <function>stream_set_blocking</function>, <function>stream_set_timeout</function>, <function>fgets</function>, <function>fgetss</function>, <function>fputs</function>, <function>fclose</function>, <function>feof</function>, y la <link linkend="ref.curl">extensi&oacute;n Curl</link>. </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:"../../../../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 --> Index: phpdoc-es/reference/stream/functions/stream-socket-client.xml +++ phpdoc-es/reference/stream/functions/stream-socket-client.xml <?xml version="1.0" encoding="iso-8859-1"?> <!-- $Revision: 1.1 $ --> <!-- EN-Revision: 1.7 Maintainer: lboshell Status: ready --> <refentry id="function.stream-socket-client"> <refnamediv> <refname>stream_socket_client</refname> <refpurpose> Abrir una conexi&oacute;n de socket de dominio de Internet o Unix </refpurpose> </refnamediv> <refsect1> <title>Descripci&oacute;n</title> <methodsynopsis> <type>resource</type><methodname>stream_socket_client</methodname> <methodparam><type>string</type><parameter>socket_remoto</parameter></methodparam> <methodparam choice="opt"><type>int</type><parameter>&amp;errno</parameter></methodparam> <methodparam choice="opt"><type>string</type><parameter>&amp;errstr</parameter></methodparam> <methodparam choice="opt"><type>float</type><parameter>tiempo_espera</parameter></methodparam> <methodparam choice="opt"><type>int</type><parameter>banderas</parameter></methodparam> <methodparam choice="opt"><type>resource</type><parameter>contexto</parameter></methodparam> </methodsynopsis> <para> Inicia una conexi&oacute;n secuenciada o tipo datagrama al destino especificado por <parameter>socket_remoto</parameter>. El tipo de socket creado es determinado por el transporte especificado usando el formato de url est&aacute;ndar: <literal>transporte://destino</literal>. Para sockets de dominio de Internet (AF_INET) tales como TCP y UDP, la porci&oacute;n <literal>destino</literal> del par&aacute;metro <parameter>socket_remoto</parameter> debe consistir de un nombre de host o direcci&oacute;n IP seguido de un signo de dos puntos y un n&uacute;mero de puerto. Para sockets de dominio Unix, la porci&oacute;n <parameter>destino</parameter> debe apuntar al archivo de socket en el sistema de archivos. El <parameter>tiempo_espera</parameter> opcional puede ser usado para establecer un tiempo de espera m&aacute;ximo en segundos para el llamado de conexi&oacute;n del sistema. <parameter>banderas</parameter> es un campo de m&aacute;scara de bits que puede ser definido como una combinaci&oacute;n de banderas de conexi&oacute;n. Actualmente, las banderas de conexi&oacute;n disponibles est&aacute;n limitadas a <constant>STREAM_CLIENT_ASYNC_CONNECT</constant> y <constant>STREAM_CLIENT_PERSISTENT</constant>. </para> <note> <simpara> Si necesita establecer un tiempo de espera para la lectura/escritura de datos sobre el socket, use <function>stream_set_timeout</function>, ya que el par&aacute;metro <parameter>tiempo_espera</parameter> de <function>stream_socket_client</function> s&oacute;lo se aplica cuando se establece la conexi&oacute;n con el socket. </simpara> </note> <para> <function>stream_socket_client</function> devuelve un recurso de secuencia que puede ser usado junto con las otras funciones de archivos (tales como <function>fgets</function>, <function>fgetss</function>, <function>fputs</function>, <function>fclose</function>, y <function>feof</function>). </para> <para> Si la llamada falla, devolver&aacute; &false; y si los argumentos opcionales <parameter>errno</parameter> y <parameter>errstr</parameter> est&aacute;n presentes, &eacute;stos ser&aacute;n definidos de modo tal que indiquen el error de nivel de sistema actual que ocurri&oacute; en el llamado de nivel de sistema <literal>connect()</literal>. Si el valor devuelto en <parameter>errno</parameter> es <literal>0</literal> y la funci&oacute;n devolvi&oacute; &false;, es un indicio de que el error ocurri&oacute; antes del llamado a <literal>connect()</literal>. Esto es por lo general debido a un problema con la inicializaci&oacute;n del socket. Note que los argumentos <parameter>errno</parameter> y <parameter>errstr</parameter> ser&aacute;n siempre pasados por referencia. </para> <para> Dependiendo del entorno, el dominio Unix o el tiempo de espera de conexi&oacute;n opcional pueden no estar disponibles. Una lista de transportes disponibles puede ser recuperada usando <function>stream_get_transports</function>. Vea <xref linkend="transports"/> para consultar una lista de transportes incorporados. </para> <para> La secuencia ser&aacute; abierta por defecto en modo de bloqueo. Puede modificarla a modo de no-bloqueo usando <function>stream_set_blocking</function>. <example> <title>Ejemplo de <function>stream_socket_client</function></title> <programlisting role="php"> <![CDATA[ <?php $da = stream_socket_client("tcp://www.example.com:80", $errno, $errstr, 30); if (!$da) { echo "$errstr ($errno)<br />\n"; } else { fputs($da, "GET / HTTP/1.0\r\nHost: www.example.com\r\nAccept: */*\r\n\r\n"); while (!feof($da)) { echo fgets($da, 1024); } fclose($da); } ?> ]]> </programlisting> </example> El siguiente ejemplo muestra c&oacute;mo recuperar la fecha y hora desde el servicio UDP "daytime" (puerto 13) en su m&aacute;quina local. <example> <title>Uso de una conexi&oacute;n UDP</title> <programlisting role="php"> <![CDATA[ <?php $da = stream_socket_client("udp://127.0.0.1:13", $errno, $errstr); if (!$da) { echo "ERROR: $errno - $errstr<br />\n"; } else { fwrite($da, "\n"); echo fread($da, 26); fclose($da); } ?> ]]> </programlisting> </example> <warning> <simpara> Los sockeits UDP parecer&aacute;n haber sido abiertos sin error en ocasiones, incluso si el host remoto no ha podido ser contactado. El error solo se har&aacute; aparente cuando lea o escriba datos desde/hacia el socket. La raz&oacute;n de esto es que UDP es un protocolo "sin conexi&oacute;n", lo que quiere decir que el sistema operativo no intenta establecer un enlace para el socket hasta que realmente necesita enviar o recibir datos. </simpara> </warning> &ipv6.brackets; Vea tambi&eacute;n <function>stream_socket_server</function>, <function>stream_set_blocking</function>, <function>stream_set_timeout</function>, <function>fgets</function>, <function>fgetss</function>, <function>fputs</function>, <function>fclose</function>, <function>feof</function>, y la <link linkend="ref.curl">extensi&oacute;n Curl</link>. </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:"../../../../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 --> Index: phpdoc-es/reference/stream/functions/stream-socket-get-name.xml +++ phpdoc-es/reference/stream/functions/stream-socket-get-name.xml <?xml version="1.0" encoding="iso-8859-1"?> <!-- $Revision: 1.1 $ --> <!-- EN-Revision: 1.2 Maintainer: lboshell Status: ready --> <refentry id="function.stream-socket-get-name"> <refnamediv> <refname>stream_socket_get_name</refname> <refpurpose>Recuperar el nombre de los sockets locales o remotos</refpurpose> </refnamediv> <refsect1> <title>Descripci&oacute;n</title> <methodsynopsis> <type>string</type><methodname>stream_socket_get_name</methodname> <methodparam><type>resource</type><parameter>gestor</parameter></methodparam> <methodparam><type>bool</type><parameter>desea_nombre_del_par</parameter></methodparam> </methodsynopsis> <para> Devuelve el nombre local o remoto de una conexi&oacute;n de socket dada. Si <parameter>desea_nombre_del_par</parameter> es definido como &true;, el nombre de socket remoto ser&aacute; devuelto, si es definido como &false;, se devolver&aacute; el nombre de socket local. </para> <para> Vea tambi&eacute;n <function>stream_socket_accept</function> </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:"../../../../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 -->
« previous php.doc.es (#456) next »