AbstractEnum::__set( string $property, mixed $value )

In this article

Prevents property modification.

Parameters

$propertystringrequired
The property name.
$valuemixedrequired
The value to set.

Source

final public function __set(string $property, $value): void
{
    throw new BadMethodCallException(sprintf('Cannot modify property %s::%s - enum properties are read-only', static::class, $property));
}

Changelog

VersionDescription
0.1.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.