<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/class.streamwrapper.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'zh',
  ),
  'this' => 
  array (
    0 => 'streamwrapper.stream-metadata.php',
    1 => 'streamWrapper::stream_metadata',
    2 => 'Change stream metadata',
  ),
  'up' => 
  array (
    0 => 'class.streamwrapper.php',
    1 => 'streamWrapper',
  ),
  'prev' => 
  array (
    0 => 'streamwrapper.stream-lock.php',
    1 => 'streamWrapper::stream_lock',
  ),
  'next' => 
  array (
    0 => 'streamwrapper.stream-open.php',
    1 => 'streamWrapper::stream_open',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/stream/streamwrapper/stream-metadata.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="streamwrapper.stream-metadata" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">streamWrapper::stream_metadata</h1>
  <p class="verinfo">(PHP 5 &gt;= 5.4.0, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">streamWrapper::stream_metadata</span> &mdash; <span class="dc-title">Change stream metadata</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-streamwrapper.stream-metadata-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="modifier">public</span> <span class="methodname"><strong>streamWrapper::stream_metadata</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$path</code></span>, <span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$option</code></span>, <span class="methodparam"><span class="type"><a href="language.types.mixed.php" class="type mixed">mixed</a></span> <code class="parameter">$value</code></span>): <span class="type"><a href="language.types.boolean.php" class="type bool">bool</a></span></div>

  <p class="para rdfs-comment">
   This method is called to set metadata on the stream. It is called when one of the following functions is called on a stream URL:
  <ul class="simplelist">
    <li><span class="function"><a href="function.touch.php" class="function">touch()</a></span></li>
    <li><span class="function"><a href="function.chmod.php" class="function">chmod()</a></span></li>
    <li><span class="function"><a href="function.chown.php" class="function">chown()</a></span></li>
    <li><span class="function"><a href="function.chgrp.php" class="function">chgrp()</a></span></li>
  </ul>
  Please note that some of these operations may not be available on your system.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-streamwrapper.stream-metadata-parameters">
  <h3 class="title">参数</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">path</code></dt>
     <dd>
      <p class="para">
       The file path or URL to set metadata.  Note that in the case of a URL, it must be a :// delimited
       URL.  Other URL forms are not supported.
      </p>
     </dd>
    
    
     <dt><code class="parameter">option</code></dt>
     <dd>
      <p class="para">
       One of:
       <ul class="simplelist">
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-touch">STREAM_META_TOUCH</a></code></strong> (The method was called in response to <span class="function"><a href="function.touch.php" class="function">touch()</a></span>)</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-owner-name">STREAM_META_OWNER_NAME</a></code></strong> (The method was called in response to <span class="function"><a href="function.chown.php" class="function">chown()</a></span> with string parameter)</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-owner">STREAM_META_OWNER</a></code></strong> (The method was called in response to  <span class="function"><a href="function.chown.php" class="function">chown()</a></span>)</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-group-name">STREAM_META_GROUP_NAME</a></code></strong> (The method was called in response to <span class="function"><a href="function.chgrp.php" class="function">chgrp()</a></span>)</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-group">STREAM_META_GROUP</a></code></strong> (The method was called in response to <span class="function"><a href="function.chgrp.php" class="function">chgrp()</a></span>)</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-access">STREAM_META_ACCESS</a></code></strong> (The method was called in response to  <span class="function"><a href="function.chmod.php" class="function">chmod()</a></span>)</li>
       </ul>
      </p>
     </dd>
    
    
     <dt><code class="parameter">value</code></dt>
     <dd>
      <p class="para">
       If <code class="parameter">option</code> is
       <ul class="simplelist">
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-touch">STREAM_META_TOUCH</a></code></strong>: <span class="type"><a href="language.types.array.php" class="type Array">Array</a></span> consisting of two arguments of the <span class="function"><a href="function.touch.php" class="function">touch()</a></span>
        function.</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-owner-name">STREAM_META_OWNER_NAME</a></code></strong> or <strong><code><a href="stream.constants.php#constant.stream-meta-group-name">STREAM_META_GROUP_NAME</a></code></strong>:
        The name of the owner user/group as <span class="type"><a href="language.types.string.php" class="type string">string</a></span>.</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-owner">STREAM_META_OWNER</a></code></strong> or <strong><code><a href="stream.constants.php#constant.stream-meta-group">STREAM_META_GROUP</a></code></strong>:
        The value owner user/group argument as <span class="type"><a href="language.types.integer.php" class="type int">int</a></span>.</li>
        <li><strong><code><a href="stream.constants.php#constant.stream-meta-access">STREAM_META_ACCESS</a></code></strong>: The argument of the <span class="function"><a href="function.chmod.php" class="function">chmod()</a></span> as <span class="type"><a href="language.types.integer.php" class="type int">int</a></span>.</li>
       </ul>
      </p>
     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-streamwrapper.stream-metadata-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">
   成功时返回 <strong><code><a href="reserved.constants.php#constant.true">true</a></code></strong>， 或者在失败时返回 <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong>。
   If <code class="parameter">option</code> is not implemented, <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> should be
   returned.
  </p>
 </div>




 <div class="refsect1 seealso" id="refsect1-streamwrapper.stream-metadata-seealso">
  <h3 class="title">参见</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.touch.php" class="function" rel="rdfs-seeAlso">touch()</a> - 设定文件的访问和修改时间</span></li>
    <li><span class="function"><a href="function.chmod.php" class="function" rel="rdfs-seeAlso">chmod()</a> - 改变文件模式</span></li>
    <li><span class="function"><a href="function.chown.php" class="function" rel="rdfs-seeAlso">chown()</a> - 改变文件的所有者</span></li>
    <li><span class="function"><a href="function.chgrp.php" class="function" rel="rdfs-seeAlso">chgrp()</a> - 改变文件所属的组</span></li>
   </ul>
  </p>
 </div>


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