Object containing definitions for a single class

category Zend
package Zend_Di

 Methods

Add injection method

addInjectionMethod(\Zend\Di\Definition\Builder\InjectionMethod $injectionMethod) : \Zend\Di\Definition\Builder\PhpClass

addSuperType()

addSuperType(string $superType) : \Zend\Di\Definition\Builder\PhpClass

Parameters

$superType

string

Returns

Create and register an injection method

createInjectionMethod(null | string $name) : \Zend\Di\Definition\Builder\InjectionMethod

Optionally takes the method name.

This method may be used in lieu of addInjectionMethod() in order to provide a more fluent interface for building classes with injection methods.

Parameters

$name

nullstring

Returns

getInstantiator()

getInstantiator() : array | \Callable | string

Returns

array\Callablestring

Determine what class will be used by {@link createInjectionMethod()}

getMethodBuilder() : string

Mainly to provide the ability to temporarily override the class used.

Returns

string

Get name

getName() : string

Returns

string

Get super types

getSuperTypes() : array

Returns

array

setInstantiator()

setInstantiator(string | \Callable | array $instantiator) : \Zend\Di\Definition\Builder\PhpClass

Parameters

$instantiator

string\Callablearray

Returns

Override which class will be used by {@link createInjectionMethod()}

setMethodBuilder(string $class) : \Zend\Di\Definition\Builder\PhpClass

Parameters

$class

string

Returns

Set name

setName(string $name) : \Zend\Di\Definition\Builder\PhpClass

Parameters

$name

string

Returns

 Properties

 

$defaultMethodBuilder

$defaultMethodBuilder : string

 

$injectionMethods

$injectionMethods : \Zend\Di\Definition\Builder\InjectionMethod[]

 

$instantiator

$instantiator : string | \Callable | array

 

$name

$name : null | string

 

$superTypes

$superTypes : array