Zend\Di\ServiceLocator\DependencyInjectorProxy
Proxy used to analyze how instances are created by a given Di. Overrides Zend\Di\Di to produce artifacts that represent the process used to instantiate a particular instance
Synopsis
class DependencyInjectorProxy
extends Di
{
- // Inherited constants from Di
- const RESOLVE_EAGER = 1;
- const RESOLVE_STRICT = 2;
- const METHOD_IS_OPTIONAL = 0;
- const METHOD_IS_AWARE = 1;
- const METHOD_IS_CONSTRUCTOR = 3;
- const METHOD_IS_INSTANTIATOR = 3;
- const METHOD_IS_REQUIRED = 3;
- const METHOD_IS_EAGER = 1;
- // members
- protected Di $di;
- // Inherited members from Di
- protected DefinitionList $definitions;
- protected InstanceManager $instanceManager;
- protected array $instanceContext;
- protected array $currentDependencies;
- protected array $currentAliasDependenencies;
- protected array $references;
- // methods
- public void __construct()
- public GeneratorInstance get()
- public GeneratorInstance newInstance()
- public GeneratorInstance createInstanceViaConstructor()
- public GeneratorInstance createInstanceViaCallback()
- public void handleInjectionMethodForObject()
- protected void resolveAndCallInjectionMethodForInstance()
- protected void getClass()
- // Inherited methods from Di
- public void __construct()
- public void configure()
- public self setDefinitionList()
- public DefinitionList definitions()
- public Di setInstanceManager()
- public InstanceManager instanceManager()
- protected array getCallParameters()
- public object|null get()
- public object|null newInstance()
- public void injectDependencies()
- protected void handleInjectDependencies()
- protected createInstanceViaConstructor()
- protected createInstanceViaCallback()
- protected bool resolveAndCallInjectionMethodForInstance()
- protected array resolveMethodParameters()
- protected string getClass()
- protected static bool isSubclassOf()
Hierarchy
Extends
Constants
Name | Value |
---|---|
RESOLVE_EAGER | 1 |
RESOLVE_STRICT | 2 |
METHOD_IS_OPTIONAL | 0 |
METHOD_IS_AWARE | 1 |
METHOD_IS_CONSTRUCTOR | 3 |
METHOD_IS_INSTANTIATOR | 3 |
METHOD_IS_REQUIRED | 3 |
METHOD_IS_EAGER | 1 |
Members
protected
- $currentAliasDependenencies
—
array
All the dependenent aliases - $currentDependencies
—
array
All the class dependencies [source][dependency] - $definitions — Zend\Di\DefinitionList
- $di — Zend\Di\Di
- $instanceContext — string
- $instanceManager — Zend\Di\InstanceManager
- $references
—
array
All the class references [dependency][source]
Methods
protected
- getClass() — {@inheritDoc}
- resolveAndCallInjectionMethodForInstance() — {@inheritDoc}
public
- __construct()
- createInstanceViaCallback() — {@inheritDoc}
- createInstanceViaConstructor() — {@inheritDoc}
- get() — {@inheritDoc}
- handleInjectionMethodForObject() — {@inheritDoc}
- newInstance() — {@inheritDoc}
Inherited from Zend\Di\Di
protected
- createInstanceViaCallback() — Get an object instance from the defined callback
- createInstanceViaConstructor() — Retrieve a class instance based on class name
- getCallParameters()
- getClass() — Utility method used to retrieve the class of a particular instance. This is here to allow extending classes to override how class names are resolved
- handleInjectDependencies()
- isSubclassOf() — Checks if the object has this class as one of its parents
- resolveAndCallInjectionMethodForInstance() — This parameter will handle any injection methods and resolution of dependencies for such methods
- resolveMethodParameters() — Resolve parameters referencing other services
public
- configure() — Provide a configuration object to configure this instance
- definitions()
- get() — Lazy-load a class
- injectDependencies() — Inject dependencies
- instanceManager()
- newInstance() — Retrieve a new instance of a class
- setDefinitionList()
- setInstanceManager() — Set the instance manager