ReflectionMethod::export
(PHP 5, PHP 7)
ReflectionMethod::export — メソッドをエクスポートする
警告 この関数は PHP 7.4.0 で 非推奨になります。この関数に頼らないことを強く推奨します。
説明
public static ReflectionMethod::export
( string $class
, string $name
[, bool $return
= false
] ) : string
ReflectionMethod をエクスポートします。
警告 この関数は、 現在のところ詳細な情報はありません。引数のリストのみが 記述されています。
パラメータ
class
- クラス名。
name
- メソッド名。
return
true
に設定すると、エクスポートを発行するのではなく返します。false
(デフォルト) の場合はその逆です。
返り値
return
パラメータを
true
に設定すると、エクスポートを文字列で返します。それ以外の場合は
null
を返します。
参考
- ReflectionMethod::__construct() - ReflectionMethod を作成する
- ReflectionMethod::__toString() - ReflectionMethod オブジェクトの文字列表現を返す