<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/class.resourcebundle.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'ja',
  ),
  'this' => 
  array (
    0 => 'resourcebundle.locales.php',
    1 => 'ResourceBundle::getLocales',
    2 => 'サポートするロケールを取得する',
  ),
  'up' => 
  array (
    0 => 'class.resourcebundle.php',
    1 => 'ResourceBundle',
  ),
  'prev' => 
  array (
    0 => 'resourcebundle.geterrormessage.php',
    1 => 'ResourceBundle::getErrorMessage',
  ),
  'next' => 
  array (
    0 => 'class.spoofchecker.php',
    1 => 'Spoofchecker',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'ja',
    'path' => 'reference/intl/resourcebundle/locales.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="resourcebundle.locales" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">ResourceBundle::getLocales</h1>
  <h1 class="refname">resourcebundle_locales</h1>
  <p class="verinfo">(PHP 5 &gt;= 5.3.2, PHP 7, PHP 8, PECL intl &gt;= 2.0.0)</p><p class="refpurpose"><span class="refname">ResourceBundle::getLocales</span> -- <span class="refname">resourcebundle_locales</span> &mdash; <span class="dc-title">サポートするロケールを取得する</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-resourcebundle.locales-description">
  <h3 class="title">説明</h3>
  <p class="para">
   オブジェクト指向型
  </p>
  <div class="methodsynopsis dc-description">
   <span class="modifier">public</span> <span class="modifier">static</span> <span class="methodname"><strong>ResourceBundle::getLocales</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$bundle</code></span>): <span class="type"><span class="type"><a href="language.types.array.php" class="type array">array</a></span>|<span class="type"><a href="language.types.singleton.php" class="type false">false</a></span></span></div>

  <p class="para rdfs-comment">
   手続き型
  </p>
  <div class="methodsynopsis dc-description"><span class="methodname"><strong>resourcebundle_locales</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$bundle</code></span>): <span class="type"><span class="type"><a href="language.types.array.php" class="type array">array</a></span>|<span class="type"><a href="language.types.singleton.php" class="type false">false</a></span></span></div>

  <p class="para rdfs-comment">
   ResourceBundle 名を指定して、サポートするロケールを取得します。
   </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-resourcebundle.locales-parameters">
  <h3 class="title">パラメータ</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">bundle</code></dt>
     <dd>
      <p class="para">
       ロケールを取得したい ResourceBundle のパス、あるいは
       空文字列を指定するとデフォルトのロケール一覧を取得できます。
      </p>
     </dd>
    
   </dl>
  </p>
 </div>



 <div class="refsect1 returnvalues" id="refsect1-resourcebundle.locales-returnvalues">
  <h3 class="title">戻り値</h3>
  <p class="para">
   このバンドルがサポートするロケールの一覧を返します。
   失敗した場合は <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> を返します。
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-resourcebundle.locales-examples">
  <h3 class="title">例</h3>
  <div class="example" id="example-1">
   <p><strong>例1 <span class="function"><strong>resourcebundle_locales()</strong></span> の例</strong></p>
   <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />$bundle </span><span style="color: #007700">= </span><span style="color: #DD0000">"/user/share/data/myapp"</span><span style="color: #007700">;<br />echo </span><span style="color: #0000BB">join</span><span style="color: #007700">(</span><span style="color: #0000BB">PHP_EOL</span><span style="color: #007700">, </span><span style="color: #0000BB">resourcebundle_locales</span><span style="color: #007700">(</span><span style="color: #0000BB">$bundle</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
   </div>

   <div class="example-contents"><p>上の例の出力は、
たとえば以下のようになります。</p></div>
   <div class="example-contents screen">
<div class="examplescode"><pre class="examplescode">es
root</pre>
</div>
   </div>
  </div>
  <div class="example" id="example-2">
   <p><strong>例2 オブジェクト指向の例</strong></p>
   <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />$bundle </span><span style="color: #007700">= </span><span style="color: #DD0000">"/usr/share/data/myapp"</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">$r </span><span style="color: #007700">= new </span><span style="color: #0000BB">ResourceBundle</span><span style="color: #007700">( </span><span style="color: #DD0000">'es'</span><span style="color: #007700">, </span><span style="color: #0000BB">$bundle</span><span style="color: #007700">);<br />echo </span><span style="color: #0000BB">join</span><span style="color: #007700">(</span><span style="color: #DD0000">"\n"</span><span style="color: #007700">, </span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getLocales</span><span style="color: #007700">(</span><span style="color: #0000BB">$bundle</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
   </div>

  <div class="example-contents"><p>上の例の出力は、
たとえば以下のようになります。</p></div>
  <div class="example-contents screen">
<div class="examplescode"><pre class="examplescode">es
root</pre>
</div>
  </div>
  </div>
 </div>


 <div class="refsect1 seealso" id="refsect1-resourcebundle.locales-seealso">
  <h3 class="title">参考</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="resourcebundle.get.php" class="function" rel="rdfs-seeAlso">resourcebundle_get()</a> - バンドルからデータを取得する</span></li>
   </ul>
  </p>
 </div>

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