In PHP we have to jump through a few hoops to create an immutable class, due to lack of native immutability in PHP itself. This means that it cannot be changed after it has been created.
Table of contents
How to eliminate boilerplate code with PHP 8.1PHP 7.4PHP 8.0PHP 8.1PHP 8.2ConclusionSort: