PHPackages                             ehough/iconic - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. ehough/iconic

AbandonedArchivedLibrary[Utility &amp; Helpers](/categories/utility)

ehough/iconic
=============

Fork of Symfony's Dependency Injection component compatible with PHP 5.2+.

v2.5.4(11y ago)094111MITPHPPHP &gt;=5.2.0

Since Jul 17Pushed 9y ago1 watchersCompare

[ Source](https://github.com/ehough/iconic)[ Packagist](https://packagist.org/packages/ehough/iconic)[ Docs](https://github.com/ehough/iconic)[ RSS](/packages/ehough-iconic/feed)WikiDiscussions develop Synced 3w ago

READMEChangelog (10)Dependencies (4)Versions (13)Used By (1)

iconic
------

[](#iconic)

[![Build Status](https://camo.githubusercontent.com/afebb1ef73ee9a0a0c523590d4a6b9e414717212e2d6588ece63de806e609b11/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f65686f7567682f69636f6e69632e706e67)](http://travis-ci.org/ehough/iconic)[![Project Status: Unsupported - The project has reached a stable, usable state but the author(s) have ceased all work on it. A new maintainer may be desired.](https://camo.githubusercontent.com/baae56ff2a4e564adcf10fe13a639b7e4aaf1d62054fd5086a2e570ecc3637e5/687474703a2f2f7777772e7265706f7374617475732e6f72672f6261646765732f6c61746573742f756e737570706f727465642e737667)](http://www.repostatus.org/#unsupported)[![Latest Stable Version](https://camo.githubusercontent.com/9abaf4b749b1663c3a5d9c31f090471fe885dcc21c2845f49e0ce50452789908/68747470733a2f2f706f7365722e707567782e6f72672f65686f7567682f69636f6e69632f762f737461626c65)](https://packagist.org/packages/ehough/iconic)[![License](https://camo.githubusercontent.com/f5e48034e11b2f6d3ae9c039dd18dbedff434a1c2b31769337e00e2c3c84e23b/68747470733a2f2f706f7365722e707567782e6f72672f65686f7567682f69636f6e69632f6c6963656e7365)](https://packagist.org/packages/ehough/iconic)

**This library is no longer supported or maintained as PHP 5.2 usage levels have finally dropped below 10%**

Fork of [Symfony's Dependency Injection component](https://github.com/symfony/DependencyInjection) compatible with PHP 5.2+.

### Motivation

[](#motivation)

[Symfony's Dependency Injection component](https://github.com/symfony/DependencyInjection) is a powerful DI library, but it's only compatible with PHP 5.3+. While 97% of PHP servers run PHP 5.2 or higher, **32% of all servers are still running PHP 5.2 or lower** ([source](http://w3techs.com/technologies/details/pl-php/5/all)). It would be a shame to exempt this library from nearly a third of the world's servers just because of a few version incompatibilities.

### Differences from [Symfony's Dependency Injection component](https://github.com/symfony/DependencyInjection)

[](#differences-from-symfonys-dependency-injection-component)

The primary difference is naming conventions of the Symfony classes. Instead of the `\Symfony\Component\DependencyInjection` namespace (and sub-namespaces), prefix the Symfony class names with `ehough_iconic` and follow the [PEAR naming convention](http://pear.php.net/manual/en/standards.php)

A few examples of class naming conversions:

```
\Symfony\Component\DependencyInjection\ContainerBuilder           ----->    ehough_iconic_ContainerBuilder
\Symfony\Component\DependencyInjection\Compiler\Compiler          ----->    ehough_iconic_compiler_Compiler
\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag  ----->    ehough_iconic_parameterbag_ParameterBag

```

Other gotchas when using iconic instead of Symfony's Dependency Injection component

- Most of the loaders and dumpers can only be used with PHP 5.3+
- The expression language feature is only available with PHP 5.3+

### Usage

[](#usage)

Here is a simple example that shows how to register services and parameters:

```
$sc = new ehough_iconic_ContainerBuilder();
$sc
    ->register('foo', '%foo.class%')
    ->addArgument(new ehough_iconic_Reference('bar'))
;
$sc->setParameter('foo.class', 'Foo');

$sc->get('foo');
```

Method Calls (Setter Injection):

```
$sc = new ehough_iconic_ContainerBuilder();

$sc
    ->register('bar', '%bar.class%')
    ->addMethodCall('setFoo', array(new ehough_iconic_Reference('foo')))
;
$sc->setParameter('bar.class', 'Bar');

$sc->get('bar');
```

Factory Class:

If your service is retrieved by calling a static method:

```
$sc = new ehough_iconic_ContainerBuilder();

$sc
    ->register('bar', '%bar.class%')
    ->setFactoryClass('%bar.class%')
    ->setFactoryMethod('getInstance')
    ->addArgument('Aarrg!!!')
;
$sc->setParameter('bar.class', 'Bar');

$sc->get('bar');
```

File Include:

For some services, especially those that are difficult or impossible to autoload, you may need the container to include a file before instantiating your class.

```
$sc = new ehough_iconic_ContainerBuilder();

$sc
    ->register('bar', '%bar.class%')
    ->setFile('/path/to/file')
    ->addArgument('Aarrg!!!')
;
$sc->setParameter('bar.class', 'Bar');

$sc->get('bar');
```

### Releases and Versioning

[](#releases-and-versioning)

Releases are synchronized with the upstream Symfony repository. e.g. `ehough/iconic v2.3.2` has merged the code from `symfony/DependencyInjection v2.3.2`.

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community24

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 63.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~43 days

Recently: every ~24 days

Total

11

Last Release

4294d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/53b269d929f6ba572a15e4b069d9b59e0e99af74db1be60cbac7a56adfea9221?d=identicon)[ehough](/maintainers/ehough)

---

Top Contributors

[![fabpot](https://avatars.githubusercontent.com/u/47313?v=4)](https://github.com/fabpot "fabpot (389 commits)")[![schmittjoh](https://avatars.githubusercontent.com/u/197017?v=4)](https://github.com/schmittjoh "schmittjoh (45 commits)")[![stof](https://avatars.githubusercontent.com/u/439401?v=4)](https://github.com/stof "stof (19 commits)")[![Seldaek](https://avatars.githubusercontent.com/u/183678?v=4)](https://github.com/Seldaek "Seldaek (16 commits)")[![lsmith77](https://avatars.githubusercontent.com/u/300279?v=4)](https://github.com/lsmith77 "lsmith77 (14 commits)")[![vicb](https://avatars.githubusercontent.com/u/248818?v=4)](https://github.com/vicb "vicb (13 commits)")[![pborreli](https://avatars.githubusercontent.com/u/77759?v=4)](https://github.com/pborreli "pborreli (13 commits)")[![jmikola](https://avatars.githubusercontent.com/u/244663?v=4)](https://github.com/jmikola "jmikola (12 commits)")[![kriswallsmith](https://avatars.githubusercontent.com/u/33886?v=4)](https://github.com/kriswallsmith "kriswallsmith (11 commits)")[![hason](https://avatars.githubusercontent.com/u/288535?v=4)](https://github.com/hason "hason (9 commits)")[![igorw](https://avatars.githubusercontent.com/u/88061?v=4)](https://github.com/igorw "igorw (8 commits)")[![jakzal](https://avatars.githubusercontent.com/u/190447?v=4)](https://github.com/jakzal "jakzal (6 commits)")[![weaverryan](https://avatars.githubusercontent.com/u/121003?v=4)](https://github.com/weaverryan "weaverryan (6 commits)")[![romainneutron](https://avatars.githubusercontent.com/u/137574?v=4)](https://github.com/romainneutron "romainneutron (6 commits)")[![realityking](https://avatars.githubusercontent.com/u/628508?v=4)](https://github.com/realityking "realityking (5 commits)")[![lyrixx](https://avatars.githubusercontent.com/u/408368?v=4)](https://github.com/lyrixx "lyrixx (5 commits)")[![avalanche123](https://avatars.githubusercontent.com/u/83289?v=4)](https://github.com/avalanche123 "avalanche123 (4 commits)")[![Tobion](https://avatars.githubusercontent.com/u/610090?v=4)](https://github.com/Tobion "Tobion (4 commits)")[![cordoval](https://avatars.githubusercontent.com/u/328359?v=4)](https://github.com/cordoval "cordoval (3 commits)")[![GromNaN](https://avatars.githubusercontent.com/u/400034?v=4)](https://github.com/GromNaN "GromNaN (3 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ehough-iconic/health.svg)

```
[![Health](https://phpackages.com/badges/ehough-iconic/health.svg)](https://phpackages.com/packages/ehough-iconic)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
