PHP 8.1.28 Released!

ResourceBundle::count

resourcebundle_count

(PHP 5 >= 5.3.2, PHP 7, PHP 8, PECL intl >= 2.0.0)

ResourceBundle::count -- resourcebundle_countバンドル内の要素数を取得する

説明

オブジェクト指向型

public ResourceBundle::count(): int

手続き型

resourcebundle_count(ResourceBundle $bundle): int

バンドル内の要素数を取得します。

パラメータ

bundle

ResourceBundle オブジェクト。

戻り値

バンドル内の要素数を返します。

例1 resourcebundle_count() の例

<?php
$r
= resourcebundle_create( 'es', "/usr/share/data/myapp");
echo
resourcebundle_count($r);
?>

例2 オブジェクト指向の例

<?php
$r
= new ResourceBundle( 'es', "/usr/share/data/myapp");
echo
$r->count();
?>

上の例の出力は以下となります。

42

参考

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top