PHP Enums

 7 months ago 1,219 views
Presented by Ayesh Karunaratne

April 22, 2021

PHP 8.1 brings Enums, one of the most requested features in PHP.

Enums, or Enumerations, allow creating strict and type-safe structures for fixed values. An Enum structure can hold a number of values that can also be backed with integer or string values.

In this comprehensive session, we will discover what Enums are, why they are useful, how to apply them on our applications including Drupal, and things to watch out for when using Enums.

About Ayesh Karunaratne
Ayesh Karunaratne is the author of PHP.Watch (, where he provides in-depth articles and documents on PHP and latest changes to the language.
Tags: php,enums



No comments found.


PHP Tutorials and Videos