PHP Classes

FContainer: Simple dependency injection container

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 221 All time: 8,265 This week: 455Up
Version Licenses PHP version Categories
fcontainer 1.0Artistic License, B...5PHP 5, Language, Design Patterns
Description 

Author

This class implements a simple dependency injection container.

It extends the ArrayObject class to store values with given keys that can be either callable functions or scalar values.

When retrieving a value with a given key from the class, it checks if it is a callable and will call it when it is the case. Otherwise it will return the value as is.

Picture of goo
  Performance   Level  
Name: goo <contact>
Classes: 2 packages by
Country: Japan Japan

  Files folder image Files (2)  
File Role Description
Plain text file FContainer.php Class DI container class
Accessible without login Plain text file testCest.php Test unittest with codeception

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:221
This week:0
All time:8,265
This week:455Up