The ReflectionEnum class

(PHP 8 >= 8.1.0)

Introduction

The ReflectionEnum class reports information about an Enum.

Class synopsis

class ReflectionEnum extends ReflectionClass {
/* Inherited constants */
/* Inherited properties */
public string $name ;
/* Methods */
public function __construct (object |string $objectOrClass)
public function getBackingType (): ? ReflectionNamedType
public function getCase (string $name): ReflectionEnumUnitCase
public function getCases (): array
public function hasCase (string $name): bool
public function isBacked (): bool
/* Inherited methods */
public static function ReflectionClass::export (mixed $argument, bool $return = false ): string
public function ReflectionClass::getAttributes (? string $name = null , int $flags = 0): array
public function ReflectionClass::getConstant (string $name): mixed
public function ReflectionClass::getConstants (? int $filter = null ): array
public function ReflectionClass::getEndLine (): int |false
public function ReflectionClass::getMethods (? int $filter = null ): array
public function ReflectionClass::getModifiers (): int
public function ReflectionClass::getName (): string
public function ReflectionClass::getProperties (? int $filter = null ): array
public function ReflectionClass::getReflectionConstants (? int $filter = null ): array
public function ReflectionClass::getStaticPropertyValue (string $name, mixed &$default = ?): mixed
public function ReflectionClass::getTraits (): array
public function ReflectionClass::hasConstant (string $name): bool
public function ReflectionClass::hasMethod (string $name): bool
public function ReflectionClass::hasProperty (string $name): bool
public function ReflectionClass::inNamespace (): bool
public function ReflectionClass::isAbstract (): bool
public function ReflectionClass::isAnonymous (): bool
public function ReflectionClass::isCloneable (): bool
public function ReflectionClass::isEnum (): bool
public function ReflectionClass::isFinal (): bool
public function ReflectionClass::isInstance (object $object): bool
public function ReflectionClass::isInterface (): bool
public function ReflectionClass::isInternal (): bool
public function ReflectionClass::isIterable (): bool
public function ReflectionClass::isReadOnly (): bool
public function ReflectionClass::isTrait (): bool
public function ReflectionClass::newInstance (mixed ...$args): object
public function ReflectionClass::newInstanceArgs (array $args = []): ? object
public function ReflectionClass::newLazyGhost (callable $initializer, int $options = 0): object
public function ReflectionClass::newLazyProxy (callable $factory, int $options = 0): object
public function ReflectionClass::resetAsLazyGhost (object $object, callable $initializer, int $options = 0): void
public function ReflectionClass::resetAsLazyProxy (object $object, callable $factory, int $options = 0): void
public function ReflectionClass::setStaticPropertyValue (string $name, mixed $value): void
public function ReflectionClass::__toString (): string
}

See Also

Table of Contents

Found A Problem?

Learn How To Improve This PageSubmit a Pull RequestReport a Bug
+add a note

User Contributed Notes

There are no user contributed notes for this page.

AltStyle によって変換されたページ (->オリジナル) /