php-doc-en/reference/stream/constants.xml
Hannes Magnusson c030e2adf7 Upgrade to DocBook5:
- All id attributes are now xml:id
 - Add docbook namespace to all root elements
 - Replace <ulink /> with <link xlink:href />
 - Minor markup fixes here and there


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@238160 c90b9560-bf6c-de11-be94-00142212c4b1
2007-06-20 22:25:43 +00:00

341 lines
11 KiB
XML

<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.16 $ -->
<section xml:id="stream.constants" xmlns="http://docbook.org/ns/docbook">
&reftitle.constants;
&extension.constants;
<para>
<informaltable>
<tgroup cols="2">
<thead>
<row>
<entry>Constant</entry>
<entry>Description</entry>
</row>
</thead>
<tbody>
<row>
<entry><constant>STREAM_FILTER_READ</constant> *</entry>
<entry>
Used with <function>stream_filter_append</function> and
<function>stream_filter_prepend</function> to indicate
that the specified filter should only be applied when
<emphasis>reading</emphasis>
</entry>
</row>
<row>
<entry><constant>STREAM_FILTER_WRITE</constant> *</entry>
<entry>
Used with <function>stream_filter_append</function> and
<function>stream_filter_prepend</function> to indicate
that the specified filter should only be applied when
<emphasis>writing</emphasis>
</entry>
</row>
<row>
<entry><constant>STREAM_FILTER_ALL</constant> *</entry>
<entry>
This constant is equivalent to
<code>STREAM_FILTER_READ | STREAM_FILTER_WRITE</code>
</entry>
</row>
<row>
<entry><constant>PSFS_PASS_ON</constant> *</entry>
<entry><literal>Return Code</literal> indicating that the
userspace filter returned buckets in <parameter>$out</parameter>.
</entry>
</row>
<row>
<entry><constant>PSFS_FEED_ME</constant> *</entry>
<entry><literal>Return Code</literal> indicating that the
userspace filter did not return buckets in <parameter>$out</parameter>
(i.e. No data available).
</entry>
</row>
<row>
<entry><constant>PSFS_ERR_FATAL</constant> *</entry>
<entry><literal>Return Code</literal> indicating that the
userspace filter encountered an unrecoverable error
(i.e. Invalid data received).
</entry>
</row>
<row>
<entry><constant>STREAM_USE_PATH</constant></entry>
<entry><literal>Flag</literal> indicating if the <literal>stream</literal>
used the include path.
</entry>
</row>
<row>
<entry><constant>STREAM_REPORT_ERRORS</constant></entry>
<entry><literal>Flag</literal> indicating if the <literal>wrapper</literal>
is responsible for raising errors using <function>trigger_error</function>
during opening of the stream. If this flag is not set, you
should not raise any errors.
</entry>
</row>
<row>
<entry><constant>STREAM_CLIENT_ASYNC_CONNECT</constant> *</entry>
<entry>Open client socket asynchronously. This option must be used
together with the <constant>STREAM_CLIENT_CONNECT</constant> flag.
Used with <function>stream_socket_client</function>.
</entry>
</row>
<row>
<entry><constant>STREAM_CLIENT_CONNECT</constant> *</entry>
<entry>Open client socket connection. Client sockets should always
include this flag. Used with <function>stream_socket_client</function>.
</entry>
</row>
<row>
<entry><constant>STREAM_CLIENT_PERSISTENT</constant> *</entry>
<entry>Client socket opened with <function>stream_socket_client</function>
should remain persistent between page loads.
</entry>
</row>
<row>
<entry><constant>STREAM_SERVER_BIND</constant> *</entry>
<entry>Tells a stream created with <function>stream_socket_server</function>
to bind to the specified target. Server sockets should always include this flag.
</entry>
</row>
<row>
<entry><constant>STREAM_SERVER_LISTEN</constant> *</entry>
<entry>Tells a stream created with <function>stream_socket_server</function>
and bound using the <constant>STREAM_SERVER_BIND</constant> flag to start
listening on the socket. Connection-orientated transports (such as TCP)
must use this flag, otherwise the server socket will not be enabled.
Using this flag for connect-less transports (such as UDP) is an error.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_RESOLVE</constant> *</entry>
<entry>
A remote address required for this stream has been resolved, or the resolution
failed. See <parameter>severity</parameter> for an indication of which happened.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_CONNECT</constant></entry>
<entry>
A connection with an external resource has been established.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_AUTH_REQUIRED</constant></entry>
<entry>
Additional authorization is required to access the specified resource.
Typical issued with <parameter>severity</parameter> level of
<constant>STREAM_NOTIFY_SEVERITY_ERR</constant>.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_MIME_TYPE_IS</constant></entry>
<entry>
The <literal>mime-type</literal> of resource has been identified,
refer to <parameter>message</parameter> for a description of the
discovered type.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_FILE_SIZE_IS</constant></entry>
<entry>
The <literal>size</literal> of the resource has been discovered.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_REDIRECTED</constant></entry>
<entry>
The external resource has redirected the stream to an alternate
location. Refer to <parameter>message</parameter>.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_PROGRESS</constant></entry>
<entry>
Indicates current progress of the stream transfer in
<parameter>bytes_transferred</parameter> and possibly
<parameter>bytes_max</parameter> as well.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_COMPLETED</constant> *</entry>
<entry>
There is no more data available on the stream.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_FAILURE</constant></entry>
<entry>
A generic error occurred on the stream, consult
<parameter>message</parameter> and <parameter>message_code</parameter>
for details.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_AUTH_RESULT</constant></entry>
<entry>
Authorization has been completed (with or without success).
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_SEVERITY_INFO</constant></entry>
<entry>
Normal, non-error related, notification.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_SEVERITY_WARN</constant></entry>
<entry>
Non critical error condition. Processing may continue.
</entry>
</row>
<row>
<entry><constant>STREAM_NOTIFY_SEVERITY_ERR</constant></entry>
<entry>
A critical error occurred. Processing cannot continue.
</entry>
</row>
<row>
<entry><constant>STREAM_IPPROTO_ICMP</constant> +</entry>
<entry>
Provides a ICMP socket.
</entry>
</row>
<row>
<entry><constant>STREAM_IPPROTO_IP</constant> +</entry>
<entry>
Provides a IP socket.
</entry>
</row>
<row>
<entry><constant>STREAM_IPPROTO_RAW</constant> +</entry>
<entry>
Provides a RAW socket.
</entry>
</row>
<row>
<entry><constant>STREAM_IPPROTO_TCP</constant> +</entry>
<entry>
Provides a TCP socket.
</entry>
</row>
<row>
<entry><constant>STREAM_IPPROTO_UDP</constant> +</entry>
<entry>
Provides a UDP socket.
</entry>
</row>
<row>
<entry><constant>STREAM_PF_INET</constant> +</entry>
<entry>
Internet Protocol Version 4 (IPv4).
</entry>
</row>
<row>
<entry><constant>STREAM_PF_INET6</constant> +</entry>
<entry>
Internet Protocol Version 6 (IPv6).
</entry>
</row>
<row>
<entry><constant>STREAM_PF_UNIX</constant> +</entry>
<entry>
Unix system internal protocols.
</entry>
</row>
<row>
<entry><constant>STREAM_SOCK_DGRAM</constant> +</entry>
<entry>
Provides datagrams, which are connectionless messages (UDP, for
example).
</entry>
</row>
<row>
<entry><constant>STREAM_SOCK_RAW</constant> +</entry>
<entry>
Provides a raw socket, which provides access to internal network
protocols and interfaces. Usually this type of socket is just available
to the root user.
</entry>
</row>
<row>
<entry><constant>STREAM_SOCK_RDM</constant> +</entry>
<entry>
Provides a RDM (Reliably-delivered messages) socket.
</entry>
</row>
<row>
<entry><constant>STREAM_SOCK_SEQPACKET</constant> +</entry>
<entry>
Provides a sequenced packet stream socket.
</entry>
</row>
<row>
<entry><constant>STREAM_SOCK_STREAM</constant> +</entry>
<entry>
Provides sequenced, two-way byte streams with a transmission mechanism
for out-of-band data (TCP, for example).
</entry>
</row>
<row>
<entry><constant>STREAM_SHUT_RD</constant></entry>
<entry>
Used with <function>stream_socket_shutdown</function> to disable
further receptions. Added in PHP 5.2.1.
</entry>
</row>
<row>
<entry><constant>STREAM_SHUT_WR</constant></entry>
<entry>
Used with <function>stream_socket_shutdown</function> to disable
further transmissions. Added in PHP 5.2.1.
</entry>
</row>
<row>
<entry><constant>STREAM_SHUT_RDWR</constant></entry>
<entry>
Used with <function>stream_socket_shutdown</function> to disable
further receptions and transmissions. Added in PHP 5.2.1.
</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
<note>
<simpara>
The constants marked with <literal>*</literal> are just available since
PHP 5.0.0.
</simpara>
</note>
<note>
<simpara>
The constants marked with <literal>+</literal> are available since PHP
5.1.0 and are meant to be used with
<function>stream_socket_pair</function>. Please note that some of these
constants might not be available in your system.
</simpara>
</note>
</section>
<!-- 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
-->