Statement on glibc/iconv Vulnerability

ReflectionReference::fromArrayElement

(PHP 7 >= 7.4.0, PHP 8)

ReflectionReference::fromArrayElement配列の要素から、ReflectionReference を生成する

説明

public static ReflectionReference::fromArrayElement(array $array, int|string $key): ?ReflectionReference

配列の要素から、ReflectionReference を生成します。

パラメータ

array

リファレンスの情報が含まれる array

key

キー。int または string

戻り値

$array[$key] がリファレンスの場合、 ReflectionReference のインスタンスを返します。 そうでない場合、null を返します。

エラー / 例外

arrayarray でない場合、 または keyint でも string でもない場合、 TypeError がスローされます。 $array[$key] が存在しない場合、 ReflectionException がスローされます。

add a note

User Contributed Notes

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