填写这份《一分钟调查》,帮我们(开发组)做得更好!去填写Home

ComponentFactoryResolver

一个简单的注册表,它将 Components 映射到生成的 ComponentFactory 类,该类可用于创建组件的实例。用于获取给定组件类型的工厂,然后使用工厂的 create() 方法创建该类型的组件。

A simple registry that maps Components to generated ComponentFactory classes that can be used to create instances of components. Use to obtain the factory for a given component type, then use the factory's create() method to create a component of that type.

      
      abstract class ComponentFactoryResolver {
  static NULL: ComponentFactoryResolver
  abstract resolveComponentFactory<T>(component: Type<T>): ComponentFactory<T>
}
    

参见

静态属性

属性说明
static NULL: ComponentFactoryResolver

方法

检索能创建给定类型的组件的工厂对象。

Retrieves the factory object that creates a component of the given type.

      
      abstract resolveComponentFactory<T>(component: Type<T>): ComponentFactory<T>
    
参数
component Type

组件类型。

The component type.

返回值

ComponentFactory<T>