<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.exec.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'de',
  ),
  'this' => 
  array (
    0 => 'function.proc-nice.php',
    1 => 'proc_nice',
    2 => '&Auml;ndert die Priorit&auml;t des aktuellen Prozesses',
  ),
  'up' => 
  array (
    0 => 'ref.exec.php',
    1 => 'Funktionen zur Programmausf&uuml;hrung',
  ),
  'prev' => 
  array (
    0 => 'function.proc-get-status.php',
    1 => 'proc_get_status',
  ),
  'next' => 
  array (
    0 => 'function.proc-open.php',
    1 => 'proc_open',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'de',
    'path' => 'reference/exec/functions/proc-nice.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.proc-nice" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">proc_nice</h1>
  <p class="verinfo">(PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">proc_nice</span> &mdash; <span class="dc-title">Ändert die Priorität des aktuellen Prozesses</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-function.proc-nice-description">
  <h3 class="title">Beschreibung</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>proc_nice</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$priority</code></span>): <span class="type"><a href="language.types.boolean.php" class="type bool">bool</a></span></div>

  <p class="para rdfs-comment">
   <span class="function"><strong>proc_nice()</strong></span> ändert die Priorität des aktuellen Prozesses
   um den in <code class="parameter">priority</code> angegebenen Betrag. Ein positives
   <code class="parameter">priority</code> vermindert die Priorität des aktuellen
   Prozesses, während ein negatives <code class="parameter">priority</code> die
   Priorität erhöht.
  </p>
  <p class="para">
   <span class="function"><strong>proc_nice()</strong></span> ist in keiner Weise verwandt mit
   <span class="function"><a href="function.proc-open.php" class="function">proc_open()</a></span> und der dazugehörigen Funktionen.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.proc-nice-parameters">
  <h3 class="title">Parameter-Liste</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">priority</code></dt>
     <dd>
      <p class="para">
       Der neue Prioritätswert; dieser Wert ist plattformabhängig.
      </p>
      <p class="para">
       Unter Unix bedeutet ein niedriger Wert, wie beispielsweise
       <code class="literal">-20</code>, eine hohe Priorität, wohingegen ein positiver
       Wert eine niedrigere Priorität hat.
      </p>
      <p class="para">
       Unter Windows hat der Parameter <code class="parameter">priority</code> die
       folgende Bedeutung:
      </p>
      <table class="doctable informaltable">
       
        <thead>
         <tr>
          <th>Prioritätsklasse</th>
          <th>Mögliche Werte</th>
         </tr>

        </thead>

        <tbody class="tbody">
         <tr>
          <td style="vertical-align: top;">Hoch</td>
          <td style="vertical-align: top;">
           <code class="parameter">priority</code> <code class="literal">&lt; -9</code>
          </td>
         </tr>

         <tr>
          <td style="vertical-align: top;">Höher als normal</td>
          <td style="vertical-align: top;">
           <code class="parameter">priority</code> <code class="literal">&lt; -4</code>
          </td>
         </tr>

         <tr>
          <td style="vertical-align: top;">Normal</td>
          <td style="vertical-align: top;">
           <code class="parameter">priority</code> <code class="literal">&lt; 5</code> &amp;
           <code class="parameter">priority</code> <code class="literal">&gt; -5</code>
          </td>
         </tr>

         <tr>
          <td style="vertical-align: top;">Niedriger als normal</td>
          <td style="vertical-align: top;">
           <code class="parameter">priority</code> <code class="literal">&gt; 5</code>
          </td>
         </tr>

         <tr>
          <td style="vertical-align: top;">Leerlauf (Idle)</td>
          <td style="vertical-align: top;">
           <code class="parameter">priority</code> <code class="literal">&gt; 9</code>
          </td>
         </tr>

        </tbody>
       
      </table>

     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.proc-nice-returnvalues">
  <h3 class="title">Rückgabewerte</h3>
  <p class="para">
   Gibt bei Erfolg <strong><code><a href="reserved.constants.php#constant.true">true</a></code></strong> zurück. Bei einem Fehler wird <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> zurückgegeben.
   Wenn ein Fehler auftritt, zum Beispiel weil der User keine Berechtigung
   hat, die Priorität eines Prozesses zu ändern, wird ein Fehler der Stufe
   <strong><code><a href="errorfunc.constants.php#constant.e-warning">E_WARNING</a></code></strong> erzeugt.
  </p>
 </div>


 <div class="refsect1 changelog" id="refsect1-function.proc-nice-changelog">
  <h3 class="title">Changelog</h3>
  <p class="para">
   <table class="doctable informaltable">
    
     <thead>
      <tr>
       <th>Version</th>
       <th>Beschreibung</th>
      </tr>

     </thead>

     <tbody class="tbody">
      <tr>
       <td>7.2.0</td>
       <td>
        Diese Funktion steht nun unter Windows zur Verfügung.
       </td>
      </tr>

     </tbody>
    
   </table>

  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-function.proc-nice-examples">
  <h3 class="title">Beispiele</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>Beispiel #1 Verwendung von <span class="function"><strong>proc_nice()</strong></span>, um die Prozesspriorität auf hoch zu setzen</strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br /></span><span style="color: #FF8000">// höchste Priorität<br /></span><span style="color: #0000BB">proc_nice</span><span style="color: #007700">(-</span><span style="color: #0000BB">20</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

   </div>
  </p>

 </div>


 <div class="refsect1 notes" id="refsect1-function.proc-nice-notes">
  <h3 class="title">Anmerkungen</h3>
  <blockquote class="note"><p><strong class="note">Hinweis</strong>: 
   <strong>Verfügbarkeit</strong><br />
   <p class="para">
    <span class="function"><strong>proc_nice()</strong></span> existiert nur, wenn Ihr System mit &#039;nice&#039;
    umgehen kann. &#039;nice&#039; ist verfügbar unter: SVr4, SVID EXT, AT&amp;T, X/OPEN
    und BSD 4.3.
   </p>
  </p></blockquote>
  <blockquote class="note"><p><strong class="note">Hinweis</strong>: 
   <strong>Nur für Windows</strong><br />
   <p class="para">
    <span class="function"><strong>proc_nice()</strong></span> ändert die aktuelle
    <em>Prozess</em>priorität, selbst wenn PHP mit
    Threadsicherheit kompiliert wurde.
   </p>
  </p></blockquote>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.proc-nice-seealso">
  <h3 class="title">Siehe auch</h3>
  <ul class="simplelist">
   <li><span class="function"><a href="function.pcntl-setpriority.php" class="function" rel="rdfs-seeAlso">pcntl_setpriority()</a> - &Auml;ndert die Priorit&auml;t eines beliebigen Prozesses</span></li>
  </ul>
 </div>


</div><?php manual_footer($setup); ?>