2017 © Pedro Peláez
 

library injector

Inject dependencies into constructors and methods

image

interophp/injector

Inject dependencies into constructors and methods

  • Sunday, July 10, 2016
  • by joostfaassen
  • Repository
  • 1 Watchers
  • 1 Stars
  • 853 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 5 % Grown

The README.md

Injector

Simple constructor and method argument injector., (*1)

You can pass a context to the injector to resolve parameters into injectable values., (*2)

Supported contexts:

  • ArrayContext: Resolves by a simple associative array's key/value
  • RequestContext: Uses a PSR7 ServerRequest to resolve values from request attributes
  • InteropContainerContext: Add support for DI containers implementing Interop\Container\ContainerInterface
  • PsrContainerContext: Add support for DI containers implementing Psr\Container\ContainerInterface
  • MultiContext: Pass an array of one or more of the above contexts to resolve from multiple contexts.

It's simple to add your own contexts by implementing InteroPhp\Injector\Context\ContextInterface, (*3)

Examples and usage

Please check the included example/ directory for usage examples., (*4)

License

MIT (see LICENSE.md), (*5)

Brought to you by the LinkORB Engineering team


Check out our other projects at linkorb.com/engineering., (*6)

Btw, we're hiring!, (*7)

The Versions

10/07 2016

dev-master

9999999-dev http://www.github.com/interophp/injector

Inject dependencies into constructors and methods

  Sources   Download

MIT

The Requires

  • php >=5.5.0

 

The Development Requires

by LinkORB Engineering

php injection injector inject dependencies linkorb auto-resolve

10/07 2016

v1.0.0

1.0.0.0 http://www.github.com/interophp/injector

Inject dependencies into constructors and methods

  Sources   Download

MIT

The Requires

  • php >=5.5.0

 

The Development Requires

by LinkORB Engineering

php injection injector inject dependencies linkorb auto-resolve