ReflectionEnum::getCasesReturns a list of all cases on an Enum
&reftitle.description;
publicarrayReflectionEnum::getCases
An Enum may contain zero or more cases. This method retrieves all defined cases,
in lexical order (that is, the order they appear in the source code).
&reftitle.parameters;
&no.function.parameters;
&reftitle.returnvalues;
An array of Enum reflection objects, one for each case in the Enum. For a Unit Enum,
they will all be instances of ReflectionEnumUnitCase. For a Backed
Enum, they will all be instances of ReflectionEnumBackedCase.
&reftitle.examples;
ReflectionEnum::getCases example
getCases();
foreach ($cases as $rCase) {
var_dump($rCase->getValue());
}
?>
]]>
&example.outputs;
&reftitle.seealso;
EnumerationsReflectionEnum::getCaseReflectionEnum::isBacked