rector/stubs-rector/Internal/EnumInterfaces.php
Tomas Votruba 755d463439 Updated Rector to commit 1f6c7a6a20
1f6c7a6a20 [Scoper] Clean up bootstrap.php: move enum definitions to dedicated file and require in BootstrapFilesIncluder (#2248)
2022-05-07 08:49:37 +00:00

34 lines
611 B
PHP

<?php
if (! interface_exists('UnitEnum')) {
/**
* @since 8.1
*/
interface UnitEnum
{
/**
* @return static[]
*/
public static function cases(): array;
}
}
if (! interface_exists('BackedEnum')) {
/**
* @since 8.1
*/
interface BackedEnum extends UnitEnum {
/**
* @param int|string $value
* @return $this
*/
public static function from($value);
/**
* @param int|string $value
* @return $this|null
*/
public static function tryFrom($value);
}
}