Recommend this page to a friend! |
Download .zip |
Info | Example | View files (15) | Download .zip | Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2016-07-10 (3 months ago) | Not enough user ratings | Total: 228 This week: 2 | All time: 7,593 This week: 591 |
Version | License | PHP version | Categories | |||
singleton-trait 3.2 | MIT/X Consortium ... | 5.4 | PHP 5, Language, Design Patterns, Traits |
Description | Author | |
This is a trait that adds singleton pattern to a class. |
Files |
File | Role | Description | ||
---|---|---|---|---|
Falcraft (1 directory) | ||||
src (1 directory) | ||||
tests (1 directory) | ||||
composer.json | Conf. | Composer File | ||
LICENSE.txt | Lic. | License (MIT) | ||
phpunit.xml | Test | Unit Testing | ||
README.txt | Doc. | README |
Files | / | Falcraft | / | Patterns |
File | Role | Description | ||
---|---|---|---|---|
Exception (2 files) | ||||
Resource (1 file) | ||||
SingletonExampleAndTest.php | Example | A registry singleton example | ||
SingletonTrait.php | Class | The Singleton Trait |
Files | / | Falcraft | / | Patterns | / | Exception |
File | Role | Description |
---|---|---|
ExceptionInterface.php | Class | Custom/Local Exception Interface |
RuntimeException.php | Class | Custom/Local Runtime Exception |
Files | / | Falcraft | / | Patterns | / | Resource |
File | Role | Description |
---|---|---|
SingletonInterface.php | Class | An interface to identify singletons, separate from trait |
Files | / | src | / | Phabstractic |
File | Role | Description | ||
---|---|---|---|---|
Patterns (2 directories) | ||||
falcraftLoad.php | Conf. | Loader |
Files | / | src | / | Phabstractic | / | Patterns | / | Exception |
File | Role | Description |
---|---|---|
ExceptionInterface.php | Class | exception classification |
RuntimeException.php | Class | exception classification |
Files | / | src | / | Phabstractic | / | Patterns | / | Resource |
File | Role | Description |
---|---|---|
SingletonInterface.php | Class | Main Trait |
SingletonTrait.php | Class | Main Trait |
Files | / | tests | / | Phabstractic | / | Patterns | / | Resource |
File | Role | Description |
---|---|---|
SingletonTrait.php | Test | unit testing |
Version Control | Reuses | Unique User Downloads | Download Rankings | ||||||||||||||||
0% | 1 |
|
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.
Other classes that need this package |
Class | Why it is needed | Dependency |
---|---|---|
PHP Registry with Singleton Trait | Required to make registry a singleton | Required |
Related pages |
Git Hub Location in Git Hub Repository |
OODesign Info on Singleton Pattern |
PHP Manual Traits Explanation |
TutorialsPoint Singleton Class Explanation |