Click or drag to resize
ObjectFactoryT Class
Class that provides construction of the objects of given class
Inheritance Hierarchy

Namespace: CMS.Core
Assembly: CMS.Core (in CMS.Core.dll) Version: 9.0.0
public class ObjectFactory<T> : IObjectFactory

Type Parameters


The ObjectFactoryT type exposes the following members.

Public propertyStatic memberCanReplaceCurrent
If true, the default object factory can be replaced by other factory
Protected propertyConstructor
Constructor used for dependency injection
Public propertyCreatedType
Returns the type created by this factory
Public propertyStatic memberCurrentFactory
Current factory to create objects, includes initialization of the core if interface factory is not initialized
Public propertyInitializer
Object initialization function
Public propertyStatic memberIsInitialized
Returns true if the default factory is initialized
Public propertySingleton
Singleton instance of the created object type
Protected propertyUseCompiledLambda
If true, the compiled lambda expression is used to create new objects. Set to true if the factory will be creating a lot of objects
Public methodCanCreateObject
Returns true if the factory is able to create the object based on the given parameter
Protected methodCreateActivator
Creates an object activator for the created type
Protected methodCreateInstance
Creates a new instance of the object
Public methodCreateNewObject
Creates and returns a new object
Public methodCreateNewTypedObject
Creates and returns a new object
Public methodStatic memberChangeCreatedTypeTo(Type)
Replaces the creation of the given original type by the new type
Public methodStatic memberChangeCreatedTypeToNewType
Replaces the creation of the given original type by the new type
Public methodStatic memberNew
Creates a new object of the given type
Public methodStatic memberReset
Resets the factory to a default state
Public methodStatic memberSetDefaultObjectTypeToNewType
Sets the default object type created by the factory to the given type
Public methodStatic memberStaticSingleton
Provides a static singleton instance of the object implementing this interface
Public methodStatic memberStaticSingletonTParent
Returns static singleton for the given object type
See Also
Inheritance Hierarchy