Reusable, composable object traits for PHP 8.4+.
π Documentation
Narrative user guides (FR + EN), with examples:
- π¬π§ English documentation
- π«π· Documentation franΓ§aise
You are currently browsing the auto-generated API reference (phpDocumentor).
π Features
- π§© DI-container awareness β
ContainerTrait. - π€ Lazy & π lockable state β
LazyTrait,LockableTrait. - π Identifiers β
IDTrait,QueryIDTrait. - ποΈ Config & key-value access β
ConfigTrait,KeyValueTrait,JsonOptionsTrait. - π URI building, stringable & expression helpers β
UriTrait,ToStringTrait,strings\ExpressionTrait. - π§ͺ 100% unit-test line coverage.
π¦ Installation
This library requires PHP 8.4+ and is installed via Composer:
composer require oihana/php-traits
π§Ύ License
This project is licensed under the Mozilla Public License 2.0 (MPL-2.0).
π€ About the Author
- Name: Marc ALCARAZ (aka eKameleon)
- Website: www.ooop.fr
- Email: marc@ooop.fr
π Related packages
- oihana/php-core β core helpers and utilities.
- oihana/php-enums β strongly-typed constant enumerations.
- oihana/php-reflect β reflection and hydration utilities.
π Project on GitHub
View the full source code and contribute on GitHub: github.com/BcommeBois/oihana-php-traits.