diff --git a/README.md b/README.md index c53db9b2..aeef0e89 100644 --- a/README.md +++ b/README.md @@ -44,6 +44,15 @@ Using an enum class provides many benefits: - Helps to describe how to read, serialize, export \[, ...\] an enumeration - Allow common libraries and frameworks integrations. +Why another library ? + +- [`myclabs/php-enum`](https://github.com/myclabs/php-enum) provides base enum implementation as a class, based on the `\SplEnum` object class. However, it doesn't provide as much features nor integrations as we wish to. +- [`commerceguys/enum`](https://github.com/commerceguys/enum) only acts as a utility class, but does not intend to instantiate enumerations. Hence, it doesn't allow as much features nor integrations with third-party libraries and frameworks. Manipulating enums as objects are also one of the first motivation of this project. +- [`yethee/BiplaneEnumBundle`](https://github.com/yethee/BiplaneEnumBundle) is the first library we got inspiration from. But it was designed as a Symfony Bundle, whereas we opt for a component first approach. Integrations are then provided in a dedicated `Bridge` namespace and are not restricted to Symfony. + +Finally, we used to create similar classes from scratch in some projects lately. +Providing our own package inspired from the best ones, on which we'll apply our own philosophy looks a better way to go. + # Features - Base implementation for simple, readable and flagged (bitmask) enumerations based on the [BiplaneEnumBundle](https://github.com/yethee/BiplaneEnumBundle) ones.