ConstructorBasedFactory

Instantiates component using it's constructor with args.

Encapsulates construction of component using a constructor, with args. Arguments from argument list that are RuntimeReferences, are automatically replaced with component extracted from locator.

  1. class ConstructorBasedFactory(T, Args...)
    @safe
    class ConstructorBasedFactory : InstanceFactory!T(
    T
    Args...
    ) if (
    isObjectConstructorCompatible!(T, Args)
    ) {}
  2. auto constructorBasedFactory(Args args)

Constructors

this
this(Args args)

Constructor for ConstructorBasedFactory!(T, Args)

Members

Functions

factory
T factory()

See InstanceFactory interface

Mixins

__anonymous
mixin AllocatorAwareMixin!(typeof(this))
Undocumented in source.
__anonymous
mixin ParameterHolder!Args
Undocumented in source.
__anonymous
mixin LocatorAwareMixin!(typeof(this))
Undocumented in source.

Parameters

T

component type

Args

type tuple of args that are passed to T's constructor

Meta