ReflectionClass::getConstant 定義されている定数を取得する &reftitle.description; public mixedReflectionClass::getConstant stringname 定義されている定数を取得します。 &reftitle.parameters; name 取得する対象のクラス定数の名前。 &reftitle.returnvalues; name で指定した名前の定数の値を返します。 そのクラスに定数が見つからなかった場合は、&false; を返します。 &reftitle.examples; <methodname>ReflectionClass::getConstant</methodname> の使い方 getConstant('C1')); var_dump($reflection->getConstant('C2')); var_dump($reflection->getConstant('C3')); ?> ]]> &example.outputs; &reftitle.seealso; ReflectionClass::getConstants