/*
 * Created on 2004-5-29
 *
 * To change the template for this generated file go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
package workflow.store.spi;

import workflow.WorkflowException;
import workflow.services.WorkflowService;
import workflow.store.SchemaContext;

import com.zosatapo.commons.store.Store;

/**
 * @author Administrator
 *
 * To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Generation - Code and Comments
 */
public interface SpiDatabase extends Cloneable
{
//------------------------------------------------------------------------------------
// WorkflowService utilities   
//------------------------------------------------------------------------------------                                        
	public  WorkflowService      getWorkflowService();	
	public  void                 setWorkflowService(WorkflowService workflowService);

//------------------------------------------------------------------------------------
// Store utilities
//------------------------------------------------------------------------------------ 
	public Store                getStore();  
	public void                 setStore(Store store);
		
//------------------------------------------------------------------------------------
// SchemaContext utilities
//------------------------------------------------------------------------------------ 
	public SchemaContext        getSchemaContext();
	public void                 setSchemaContext(SchemaContext schemaContext);
	
	/**
	 * Initialize access to this  database.
	 *
	 * @exception WorkflowException if any exception is thrown during opening
	 */
	public void start() throws WorkflowException;  
      
	/**
	 * Finalize access to this  database.
	 *
	 * @exception WorkflowException if any exception is thrown during closing
	 */
	public void stop() throws WorkflowException;
	
  public Object clone()throws CloneNotSupportedException;
}
