« SplFixedArray::offsetExists
SplFixedArray::offsetSet »

SplFixedArray::offsetGet

(PHP 5 >= 5.3.0, PHP 7, PHP 8)

SplFixedArray::offsetGet — 指定した添字の値を返す

説明

public function SplFixedArray::offsetGet(int $index): mixed

index で指定した添字の値を返します。

パラメータ

index

値を取得したい添字。

戻り値

index で指定した添字の値を返します。

エラー / 例外

index が配列で定義されているサイズの範囲外の場合や index を数値として解釈できない場合に RuntimeException をスローします。

関連キーワード:
添字   SplFixedArray   index   offsetGet   offsetExists   offsetSet   mixed   範囲   数値   解釈   RuntimeException
関連する関数・ページ:
splfixedarray.offsetset   splfixedarray.offsetexists   splfixedarray.key   splfixedarray.offsetunset   class.splfixedarray   splfixedarray.current