org.apache.commons.collections.functors
Class InstantiateFactory
java.lang.Objectorg.apache.commons.collections.functors.InstantiateFactory
- Factory, Serializable
public class InstantiateFactory
extends java.lang.Object
Factory implementation that creates a new object instance by reflection.
$Revision: 348444 $ $Date: 2005-11-23 14:06:56 +0000 (Wed, 23 Nov 2005) $InstantiateFactory(Class classToInstantiate)- Constructor that performs no validation.
|
InstantiateFactory(Class classToInstantiate, Class[] paramTypes, Object[] args)- Constructor that performs no validation.
|
Object | create()- Creates an object using the stored constructor.
|
static Factory | getInstance(Class classToInstantiate, Class[] paramTypes, Object[] args)- Factory method that performs validation.
|
InstantiateFactory
public InstantiateFactory(Class classToInstantiate)
Constructor that performs no validation.
Use getInstance if you want that.
classToInstantiate - the class to instantiate
InstantiateFactory
public InstantiateFactory(Class classToInstantiate,
Class[] paramTypes,
Object[] args) Constructor that performs no validation.
Use getInstance if you want that.
classToInstantiate - the class to instantiateparamTypes - the constructor parameter types, not clonedargs - the constructor arguments, not cloned
create
public Object create()
Creates an object using the stored constructor.
- create in interface Factory
getInstance
public static Factory getInstance(Class classToInstantiate,
Class[] paramTypes,
Object[] args) Factory method that performs validation.
classToInstantiate - the class to instantiate, not nullparamTypes - the constructor parameter typesargs - the constructor arguments
- a new instantiate factory
Copyright © 2001-2008 Apache Software Foundation. All Rights Reserved.