| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [View Raw Code] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
parent directory.. | ||||
To implement a central storage for objects often used throughout the application, is typically implemented using an abstract class with only static methods (or using the Singleton pattern). Remember that this introduces global state, which should be avoided at all times! Instead implement it using Dependency Injection!
You can also find these code on GitHub
Registry.php
.. literalinclude:: Registry.php :language: php :linenos:
Tests/RegistryTest.php
.. literalinclude:: Tests/RegistryTest.php :language: php :linenos:
| Back | FazBrowse Home | New Git URL |