« ReflectionExtension::getDependencies
ReflectionExtension::getINIEntries »

ReflectionExtension::getFunctions

(PHP 5, PHP 7, PHP 8)

ReflectionExtension::getFunctions — 拡張モジュールの関数を取得する

説明

public function ReflectionExtension::getFunctions(): array

拡張モジュールで定義されている関数を取得します。

パラメータ

この関数にはパラメータはありません。

戻り値

ReflectionFunction オブジェクトの連想配列を返します。 拡張モジュール内で定義されている関数名がキーとなります。 関数が定義されていない場合は空の配列を返します。

例

例1 ReflectionExtension::getFunctions() の例

<?php
$dom = new ReflectionExtension('SimpleXML');

print_r($dom->getFunctions());
?>

上の例の出力は、 たとえば以下のようになります。

Array
(
    [simplexml_load_file] => ReflectionFunction Object
        (
            [name] => simplexml_load_file
        )

    [simplexml_load_string] => ReflectionFunction Object
        (
            [name] => simplexml_load_string
        )

    [simplexml_import_dom] => ReflectionFunction Object
        (
            [name] => simplexml_import_dom
        )

)

参考

関連キーワード:
ReflectionExtension   simplexml   拡張   getFunctions   ReflectionFunction   load   import   getDependencies   getINIEntries   連想   キー   SimpleXML   print   参考   getClasses   extension   funcs
関連する関数・ページ:
class.reflectionextension   reflectionextension.tostring   reflectionextension.getname   reflectionextension.construct   reflectionextension.getversion   reflectionextension.getclassnames