<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<appendix xml:id="posix.constants" xmlns="http://docbook.org/ns/docbook">
 &reftitle.constants;
 &extension.constants;
 <section xml:id="posix.constants.access">
  <title><function>posix_access</function> constants</title>
  <note>
   <para>
    Please note that some of these constants may not be available on every system.
   </para>
  </note>
  <variablelist>
   <varlistentry xml:id="constant.posix-f-ok">
    <term>
     <constant>POSIX_F_OK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Check whether the file exists.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-r-ok">
    <term>
     <constant>POSIX_R_OK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Check whether the file exists and has read permissions.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-w-ok">
    <term>
     <constant>POSIX_W_OK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Check whether the file exists and has write permissions.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-x-ok">
    <term>
     <constant>POSIX_X_OK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Check whether the file exists and has execute permissions.
     </simpara>
    </listitem>
   </varlistentry>
  </variablelist>
 </section>

 <section xml:id="posix.constants.mknod">
  <title><function>posix_mknod</function> constants</title>
  <note>
   <para>
    Please note that some of them may not be available on your system.
   </para>
  </note>
  <variablelist>
   <varlistentry xml:id="constant.posix-s-ifblk">
    <term>
     <constant>POSIX_S_IFBLK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Block special file
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-s-ifchr">
    <term>
     <constant>POSIX_S_IFCHR</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Character special file
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-s-ififo">
    <term>
     <constant>POSIX_S_IFIFO</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      FIFO (named pipe) special file
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-s-ifreg">
    <term>
     <constant>POSIX_S_IFREG</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Normal file
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-s-ifsock">
    <term>
     <constant>POSIX_S_IFSOCK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Socket
     </simpara>
    </listitem>
   </varlistentry>
  </variablelist>
 </section>

 <section xml:id="posix.constants.setrlimit">
  <title><function>posix_setrlimit</function> constants</title>
  <note>
   <para>
    Please note that some of them may not be available on your system.
   </para>
  </note>
  <note>
   <para>
    You may wish to read the below notes in conjunction with the manpage for
    <function>setrlimit</function> on your specific operating system, as there
    is variance in how these limits are interpreted, even across operating
    systems that claim to implement POSIX in full.
   </para>
  </note>
  <variablelist>
   <varlistentry xml:id="constant.posix-rlimit-as">
    <term>
     <constant>POSIX_RLIMIT_AS</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of the process's address space in bytes. See also PHP's
      <link linkend="ini.memory-limit">memory_limit</link> configuration
      directive.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-core">
    <term>
     <constant>POSIX_RLIMIT_CORE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of a core file. If the limit is set to 0, no core file
      will be generated.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-cpu">
    <term>
     <constant>POSIX_RLIMIT_CPU</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum amount of CPU time that the process can use, in seconds.
      When the soft limit is hit, a <literal>SIGXCPU</literal> signal will be
      sent, which can be caught with <function>pcntl_signal</function>.
      Depending on the operating system, additional <literal>SIGXCPU</literal>
      signals may be sent each second until the hard limit is hit, at which
      point an uncatchable <literal>SIGKILL</literal> signal is sent.
     </simpara>
     <simpara>
      See also <function>set_time_limit</function>.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-data">
    <term>
     <constant>POSIX_RLIMIT_DATA</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of the process's data segment, in bytes. It is
      extremely unlikely that this will have any effect on the execution of
      PHP unless an extension is in use that calls <function>brk</function> or
      <function>sbrk</function>.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-fsize">
    <term>
     <constant>POSIX_RLIMIT_FSIZE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of files that the process can create, in bytes.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-locks">
    <term>
     <constant>POSIX_RLIMIT_LOCKS</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of locks that the process can create. This is only
      supported on extremely old Linux kernels.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-memlock">
    <term>
     <constant>POSIX_RLIMIT_MEMLOCK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes that can be locked into memory.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-msgqueue">
    <term>
     <constant>POSIX_RLIMIT_MSGQUEUE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes that can be allocated for POSIX message
      queues. PHP does not ship with support for POSIX message queues, so this
      limit will not have any effect unless you are using an extension that
      implements that support.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-nice">
    <term>
     <constant>POSIX_RLIMIT_NICE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum value to which the process can be
      <link linkend="function.pcntl-setpriority">reniced</link> to. The value
      that will be used will be <literal>20 - limit</literal>, as resource
      limit values cannot be negative.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-nofile">
    <term>
     <constant>POSIX_RLIMIT_NOFILE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      A value one greater than the maximum file descriptor number that can be
      opened by this process.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-nproc">
    <term>
     <constant>POSIX_RLIMIT_NPROC</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of processes (and/or threads, on some operating
      systems) that can be created for the real user ID of the process.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-rss">
    <term>
     <constant>POSIX_RLIMIT_RSS</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of the process's resident set, in pages.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-rtprio">
    <term>
     <constant>POSIX_RLIMIT_RTPRIO</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum real time priority that can be set via the
      <function>sched_setscheduler</function> and
      <function>sched_setparam</function> system calls.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-rttime">
    <term>
     <constant>POSIX_RLIMIT_RTTIME</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum amount of CPU time, in microseconds, that the process can
      consume without making a blocking system call if it is using real time
      scheduling.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-sigpending">
    <term>
     <constant>POSIX_RLIMIT_SIGPENDING</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of signals that can be queued for the real user ID of
      the process.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-stack">
    <term>
     <constant>POSIX_RLIMIT_STACK</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum size of the process stack, in bytes.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-infinity">
    <term>
     <constant>POSIX_RLIMIT_INFINITY</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      Used to indicate an infinite value for a resource limit.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-kqueues">
    <term>
     <constant>POSIX_RLIMIT_KQUEUES</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of kqueues this user id is allowed to create (FreeBSD).
      Available as of PHP 8.1.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-rlimit-npts">
    <term>
     <constant>POSIX_RLIMIT_NPTS</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of pseudo-terminals this user id is allowed to create (FreeBSD).
      Available as of PHP 8.1.0.
     </simpara>
    </listitem>
   </varlistentry>
  </variablelist>
 </section>

 <section xml:id="posix.constants.pathconf">
  <title><function>posix_pathconf</function> constants</title>
  <variablelist>
   <varlistentry xml:id="constant.posix-pc-link-max">
    <term>
     <constant>POSIX_PC_LINK_MAX</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of links a given file or directory can have.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-max-canon">
    <term>
     <constant>POSIX_PC_MAX_CANON</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes in a terminal canonical input buffer
      (pathname being then a character special file).
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-max-input">
    <term>
     <constant>POSIX_PC_MAX_INPUT</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes of a terminal input queue
      (pathname being then a character special file).
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-name-max">
    <term>
     <constant>POSIX_PC_NAME_MAX</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of characters for a file name alone, not its path.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-path-max">
    <term>
     <constant>POSIX_PC_PATH_MAX</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of characters for a full path name.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-pipe-buf">
    <term>
     <constant>POSIX_PC_PIPE_BUF</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes that can be written to a pipe in one operation.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-chown-restricted">
    <term>
     <constant>POSIX_PC_CHOWN_RESTRICTED</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      If privileges are required to be allow <function>chown</function> to work.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-no-trunc">
    <term>
     <constant>POSIX_PC_NO_TRUNC</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      If a file name (or files under a directory) is longer than <constant>POSIX_PC_NAME_MAX</constant>.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-alloc-size-min">
    <term>
     <constant>POSIX_PC_ALLOC_SIZE_MIN</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The minimum number of bytes of storage allocated for any portion of a file.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-pc-symlink-max">
    <term>
     <constant>POSIX_PC_ALLOC_SYMLINK_MAX</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of symbolic links a given file or directory can have.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
  </variablelist>
 </section>

 <section xml:id="posix.constants.sysconf">
  <title><function>posix_sysconf</function> constants</title>
  <variablelist>
   <varlistentry xml:id="constant.posix-sc-arg-max">
    <term>
     <constant>POSIX_SC_ARG_MAX</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The maximum number of bytes the arguments (and environment variables) can have.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-sc-pagesize">
    <term>
     <constant>POSIX_SC_PAGESIZE</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The number of bytes of the current page.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-sc-nprocessors-conf">
    <term>
     <constant>POSIX_SC_NPROCESSORS_CONF</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The number of cpus configured system wise.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
   <varlistentry xml:id="constant.posix-sc-nprocessors-onln">
    <term>
     <constant>POSIX_SC_NPROCESSORS_ONLN</constant>
     (<type>int</type>)
    </term>
    <listitem>
     <simpara>
      The number of cpus currently active system wise.
      Available as of PHP 8.3.0.
     </simpara>
    </listitem>
   </varlistentry>
  </variablelist>
 </section>
</appendix>
<!-- 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
-->
