vito/app/Traits/Enum.php
2024-11-01 16:49:57 +01:00

14 lines
199 B
PHP

<?php
namespace App\Traits;
trait Enum
{
public static function all(): array
{
$reflection = new \ReflectionClass(self::class);
return $reflection->getConstants();
}
}