Checks if this enum is the same instance type and value as another enum.
Parameters
$otherselfrequired- The other enum to compare.
Source
final public function is(self $other): bool
{
return $this === $other;
// Since we're using singletons, we can use identity comparison
}
Changelog
| Version | Description |
|---|---|
| 0.1.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.