CVS: plexus-container-new/src/java/org/apache/plexus/service/repository/factory ComponentFactory.java,NONE,1.1 JavaComponentFactory.java,NONE,1.1 JavaServiceFactory.java,1.1.1.1,NONE ServiceFactory.java,1.2,NONE

[email protected] Thu, 1 May 2003 14:35:39 -0500
Newsgroups gmane.comp.java.plexus.devel
Message-ID <[email protected]>
Update of /cvsroot/plexus/plexus-container-new/src/java/org/apache/plexus/service/repository/factory
In directory eng.werken.com:/tmp/cvs-serv18124/src/java/org/apache/plexus/service/repository/factory

Added Files:
	ComponentFactory.java JavaComponentFactory.java 
Removed Files:
	JavaServiceFactory.java ServiceFactory.java 
Log Message:
o This will require a separate message as more than a few changes have
occurred in order to support handling for various instantiation strategies
and scriptable components.



--- NEW FILE: ComponentFactory.java ---
package org.apache.plexus.service.repository.factory;

/** A <code>ServiceFactory</code> is responsible for instantiating a service.
 *
 *  @author <a href="mailto:[email protected]">Jason van Zyl</a>
 *
 *  @version $Id: ComponentFactory.java,v 1.1 2003/05/01 19:35:36 jvanzyl Exp $
 */
public interface ComponentFactory
{
    /** Component role. */
    static String ROLE = ComponentFactory.class.getName();

    Object newInstance( String name, ClassLoader classLoader )
        throws ClassNotFoundException, InstantiationException, IllegalAccessException;
}

--- NEW FILE: JavaComponentFactory.java ---
package org.apache.plexus.service.repository.factory;


public class JavaComponentFactory
    implements ComponentFactory
{
    public Object newInstance( String name, ClassLoader classLoader )
        throws ClassNotFoundException, InstantiationException, IllegalAccessException
    {
        Object instance = classLoader.loadClass( name ).newInstance();

        return instance;
    }
}

--- JavaServiceFactory.java DELETED ---

--- ServiceFactory.java DELETED ---