org.unitils.dbunit.datasetfactory.impl
Class MultiSchemaXmlDataSetFactory

java.lang.Object
  extended by org.unitils.dbunit.datasetfactory.impl.MultiSchemaXmlDataSetFactory
All Implemented Interfaces:
DataSetFactory

public class MultiSchemaXmlDataSetFactory
extends Object
implements DataSetFactory

A data set factory that can handle data set definitions for multiple database schemas.

Author:
Filip Neven, Tim Ducheyne

Field Summary
protected  String defaultSchemaName
          The schema name to use when no name was explicitly specified.
 
Constructor Summary
MultiSchemaXmlDataSetFactory()
           
 
Method Summary
 MultiSchemaDataSet createDataSet(File... dataSetFiles)
          Creates a MultiSchemaDataSet using the given file.
 String getDataSetFileExtension()
           
 void init(Properties configuration, String defaultSchemaName)
          Initializes this DataSetFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

defaultSchemaName

protected String defaultSchemaName
The schema name to use when no name was explicitly specified.

Constructor Detail

MultiSchemaXmlDataSetFactory

public MultiSchemaXmlDataSetFactory()
Method Detail

init

public void init(Properties configuration,
                 String defaultSchemaName)
Initializes this DataSetFactory

Specified by:
init in interface DataSetFactory
Parameters:
configuration - The configuration, not null
defaultSchemaName - The name of the default schema of the test database, not null

createDataSet

public MultiSchemaDataSet createDataSet(File... dataSetFiles)
Creates a MultiSchemaDataSet using the given file.

Specified by:
createDataSet in interface DataSetFactory
Parameters:
dataSetFiles - The dataset files, not null
Returns:
A MultiSchemaDataSet containing the datasets per schema, not null

getDataSetFileExtension

public String getDataSetFileExtension()
Specified by:
getDataSetFileExtension in interface DataSetFactory
Returns:
The extension that files which can be interpreted by this factory must have


Copyright © 2011. All Rights Reserved.