ReflectionEnum 类

(PHP 8 >= 8.1.0)

简介

ReflectionEnum 类报告有关 Enum 的信息。

类摘要

class ReflectionEnum extends ReflectionClass {
/* 继承的常量 */
/* 继承的属性 */
public string $name;
/* 方法 */
public __construct(object|string $objectOrClass)
public getCases(): array
public hasCase(string $name): bool
public isBacked(): bool
/* 继承的方法 */
public static ReflectionClass::export(mixed $argument, bool $return = false): string
public ReflectionClass::getAttributes(?string $name = null, int $flags = 0): array
public ReflectionClass::getConstants(?int $filter = null): array
public ReflectionClass::getMethods(?int $filter = null): array
public ReflectionClass::getProperties(?int $filter = null): array
}

参见

目录

add a note add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top