Class WorkFactory
- java.lang.Object
-
- edu.isi.pegasus.planner.catalog.work.WorkFactory
-
public class WorkFactory extends java.lang.Object
This factory loads a work catalog, as specified by the properties. Each invocation of the factory will result in a new instance of a connection to the replica catalog.- Version:
- $Revision: 50 $
- Author:
- Karan Vahi, Jens-S. Vöckler
- See Also:
org.griphyn.common.catalog.WorkCatalog
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DEFAULT_PACKAGE
Package to prefix "just" class names with.
-
Constructor Summary
Constructors Constructor Description WorkFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static WorkCatalog
loadInstance(CommonProperties props)
Connects the interface with the work catalog implementation.static WorkCatalog
loadInstance(PegasusProperties props)
Connects the interface with the work catalog implementation.private static WorkCatalog
loadInstance(java.lang.String catalogImplementor, java.util.Properties props)
Connects the interface with the work catalog implementation.
-
-
-
Field Detail
-
DEFAULT_PACKAGE
public static final java.lang.String DEFAULT_PACKAGE
Package to prefix "just" class names with.- See Also:
- Constant Field Values
-
-
Method Detail
-
loadInstance
public static WorkCatalog loadInstance(PegasusProperties props) throws WorkFactoryException
Connects the interface with the work catalog implementation. The choice of backend is configured through properties. This class is useful for non-singleton instances that may require changing properties.- Parameters:
props
- is an instance of properties to use.- Throws:
java.lang.ClassNotFoundException
- if the schema for the database cannot be loaded. You might want to check your CLASSPATH, too.java.lang.NoSuchMethodException
- if the schema's constructor interface does not comply with the database driver API.java.lang.InstantiationException
- if the schema class is an abstract class instead of a concrete implementation.java.lang.IllegalAccessException
- if the constructor for the schema class it not publicly accessible to this package.InvocationTargetException
- if the constructor of the schema throws an exception while being dynamically loaded.WorkFactoryException
- See Also:
org.griphyn.common.util.CommonProperties
-
loadInstance
public static WorkCatalog loadInstance(CommonProperties props) throws WorkFactoryException
Connects the interface with the work catalog implementation. The choice of backend is configured through properties. This class is useful for non-singleton instances that may require changing properties.- Parameters:
props
- is an instance of properties to use.- Throws:
java.lang.ClassNotFoundException
- if the schema for the database cannot be loaded. You might want to check your CLASSPATH, too.java.lang.NoSuchMethodException
- if the schema's constructor interface does not comply with the database driver API.java.lang.InstantiationException
- if the schema class is an abstract class instead of a concrete implementation.java.lang.IllegalAccessException
- if the constructor for the schema class it not publicly accessible to this package.InvocationTargetException
- if the constructor of the schema throws an exception while being dynamically loaded.WorkFactoryException
- See Also:
org.griphyn.common.util.CommonProperties
-
loadInstance
private static WorkCatalog loadInstance(java.lang.String catalogImplementor, java.util.Properties props) throws WorkFactoryException
Connects the interface with the work catalog implementation. The choice of backend is configured through properties. This class is useful for non-singleton instances that may require changing properties.- Parameters:
props
- is an instance of properties to use.- Throws:
java.lang.ClassNotFoundException
- if the schema for the database cannot be loaded. You might want to check your CLASSPATH, too.java.lang.NoSuchMethodException
- if the schema's constructor interface does not comply with the database driver API.java.lang.InstantiationException
- if the schema class is an abstract class instead of a concrete implementation.java.lang.IllegalAccessException
- if the constructor for the schema class it not publicly accessible to this package.InvocationTargetException
- if the constructor of the schema throws an exception while being dynamically loaded.WorkFactoryException
- See Also:
org.griphyn.common.util.CommonProperties
-
-