com.cometway.util
Class DefaultClassFactory

java.lang.Object
  extended by com.cometway.util.DefaultClassFactory
All Implemented Interfaces:
ClassFactoryInterface

public class DefaultClassFactory
extends java.lang.Object
implements ClassFactoryInterface

This default implementation of ClassFactoryInterface uses Class.forName() and Class.newInstance() to resolve and instantiate the specified class. Replace this class to handle ClassLoader limitations in your favorite environment.


Constructor Summary
DefaultClassFactory()
           
 
Method Summary
 java.lang.Object createInstance(java.lang.String classname)
          Creates a default instance of an object of the specified class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultClassFactory

public DefaultClassFactory()
Method Detail

createInstance

public java.lang.Object createInstance(java.lang.String classname)
                                throws ClassFactoryException
Creates a default instance of an object of the specified class.

Specified by:
createInstance in interface ClassFactoryInterface
Throws:
ClassFactoryException - If there is a problem.