类 DefaultObjectFactory

java.lang.Object
cn.myafx.data.factory.DefaultObjectFactory
所有已实现的接口:
ObjectFactory, Serializable

public class DefaultObjectFactory extends Object implements ObjectFactory, Serializable
作者:
Clinton Begin
另请参阅:
  • 构造器详细资料

    • DefaultObjectFactory

      public DefaultObjectFactory()
  • 方法详细资料

    • create

      public <T> T create(Class<T> type) throws Exception
      从接口复制的说明: ObjectFactory
      Creates a new object with default constructor.
      指定者:
      create 在接口中 ObjectFactory
      类型参数:
      T - the generic type
      参数:
      type - Object type
      返回:
      the t
      抛出:
      Exception
    • create

      public <T> T create(Class<T> type, List<Class<?>> constructorArgTypes, List<Object> constructorArgs) throws Exception
      从接口复制的说明: ObjectFactory
      Creates a new object with the specified constructor and params.
      指定者:
      create 在接口中 ObjectFactory
      类型参数:
      T - the generic type
      参数:
      type - Object type
      constructorArgTypes - Constructor argument types
      constructorArgs - Constructor argument values
      返回:
      the t
      抛出:
      Exception
    • resolveInterface

      protected Class<?> resolveInterface(Class<?> type)
    • isCollection

      public <T> boolean isCollection(Class<T> type)
      从接口复制的说明: ObjectFactory
      Returns true if this object can have a set of other objects. It's main purpose is to support non-java.util.Collection objects like Scala collections.
      指定者:
      isCollection 在接口中 ObjectFactory
      类型参数:
      T - the generic type
      参数:
      type - Object type
      返回:
      whether it is a collection or not