org.eclipse.higgins.configuration.common
Class ConfigurableComponentFactoryHelper

java.lang.Object
  extended byorg.eclipse.higgins.configuration.common.ConfigurableComponentFactoryHelper

public class ConfigurableComponentFactoryHelper
extends Object

Convenience class that implements code required to get a singleton instance from an ObejctFactory.

Author:
mikemci at us dot ibm dot com

Constructor Summary
ConfigurableComponentFactoryHelper()
           
 
Method Summary
static org.eclipse.higgins.configuration.api.IConfigurableComponent getFromFactory(String factoryClassName)
          Load the class by name then creates an instance
static org.eclipse.higgins.configuration.api.IConfigurableComponent getInstanceFromClassName(String className)
          Load the class by name
static org.eclipse.higgins.configuration.api.IConfigurableComponent getSingletonFromClassName(String className)
          Load the class by name
static org.eclipse.higgins.configuration.api.IConfigurableComponent getSingletonFromFactory(String factoryClassName)
          Load the class by name then creates an instance
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfigurableComponentFactoryHelper

public ConfigurableComponentFactoryHelper()
Method Detail

getInstanceFromClassName

public static org.eclipse.higgins.configuration.api.IConfigurableComponent getInstanceFromClassName(String className)
                                                                                             throws Exception
Load the class by name

Parameters:
className - the name of the class to load and create an instance of
Returns:
the new instance
Throws:
Exception

getSingletonFromClassName

public static org.eclipse.higgins.configuration.api.IConfigurableComponent getSingletonFromClassName(String className)
                                                                                              throws Exception
Load the class by name

Parameters:
className - the name of the class to load and create an instance of
Returns:
the singleton instance
Throws:
Exception

getSingletonFromFactory

public static org.eclipse.higgins.configuration.api.IConfigurableComponent getSingletonFromFactory(String factoryClassName)
                                                                                            throws Exception
Load the class by name then creates an instance

Parameters:
factoryClassName - the name of the class to load and create an instance from
Returns:
the singleton instance
Throws:
Exception

getFromFactory

public static org.eclipse.higgins.configuration.api.IConfigurableComponent getFromFactory(String factoryClassName)
                                                                                   throws Exception
Load the class by name then creates an instance

Parameters:
factoryClassName - the name of the class to load and create an instance from
Returns:
the new instance
Throws:
Exception