TypeBasedContainer.set

Save an object factory in TypeBasedContainer by identity.

Save an object factory in TypeBasedContainer by identity. The object factory, and subsequent objects are registered as candidates for use for any interface or base class they implement, when no suitable solution is found in decorated container.

class TypeBasedContainer
set

Parameters

identity string

identity of object factory in TypeBasedContainer.

factory ObjectFactory

object factory which is to be saved in TypeBasedContainer.

Return: TypeBasedContainer

Meta