Package org.dbunit.dataset
Class CompositeDataSet
java.lang.Object
org.dbunit.dataset.AbstractDataSet
org.dbunit.dataset.CompositeDataSet
- All Implemented Interfaces:
IDataSet
Combines multiple datasets into a single logical dataset.
- Since:
- Feb 19, 2002
- Version:
- $Revision$
- Author:
- Manuel Laflamme
-
Field Summary
Fields inherited from class org.dbunit.dataset.AbstractDataSet
_orderedTableNameMap -
Constructor Summary
ConstructorsConstructorDescriptionCompositeDataSet(IDataSet dataSet) Creates a composite dataset that combines duplicate tables of the specified dataset.CompositeDataSet(IDataSet[] dataSets) Creates a composite dataset that combines specified datasets.CompositeDataSet(IDataSet[] dataSets, boolean combine) Creates a composite dataset that combines specified datasets.CompositeDataSet(IDataSet[] dataSets, boolean combine, boolean caseSensitiveTableNames) Creates a composite dataset that combines specified datasets.CompositeDataSet(IDataSet dataSet, boolean combine) Deprecated.CompositeDataSet(IDataSet dataSet1, IDataSet dataSet2) Creates a composite dataset that combines the two specified datasets.CompositeDataSet(IDataSet dataSet1, IDataSet dataSet2, boolean combine) Creates a composite dataset that combines the two specified datasets.CompositeDataSet(ITable[] tables) Creates a composite dataset that combines tables having identical name.CompositeDataSet(ITable[] tables, boolean caseSensitiveTableNames) Creates a composite dataset that combines tables having identical name. -
Method Summary
Modifier and TypeMethodDescriptionprotected ITableIteratorcreateIterator(boolean reversed) Creates an iterator which provides access to all tables of this datasetMethods inherited from class org.dbunit.dataset.AbstractDataSet
createTableNameMap, getTable, getTableMetaData, getTableNames, getTables, initialize, isCaseSensitiveTableNames, iterator, reverseIterator, toString
-
Constructor Details
-
CompositeDataSet
Creates a composite dataset that combines specified datasets. Tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
Creates a composite dataset that combines specified datasets.- Parameters:
dataSets- list of datasetscombine- iftrue, tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
public CompositeDataSet(IDataSet[] dataSets, boolean combine, boolean caseSensitiveTableNames) throws DataSetException Creates a composite dataset that combines specified datasets.- Parameters:
dataSets- list of datasetscombine- iftrue, tables having the same name are merged into one table.caseSensitiveTableNames- Whether or not table names are handled in a case sensitive way over all datasets.- Throws:
DataSetException- Since:
- 2.4.2
-
CompositeDataSet
Creates a composite dataset that combines the two specified datasets. Tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
public CompositeDataSet(IDataSet dataSet1, IDataSet dataSet2, boolean combine) throws DataSetException Creates a composite dataset that combines the two specified datasets.- Parameters:
dataSet1- first datasetdataSet2- second datasetcombine- iftrue, tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
Deprecated.This constructor is useless when the combine parameter isfalse. Use overload that doesn't have the combine argument.Creates a composite dataset that combines duplicate tables of the specified dataset.- Parameters:
dataSet- the datasetcombine- iftrue, tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
Creates a composite dataset that combines duplicate tables of the specified dataset.- Parameters:
dataSet- the dataset- Throws:
DataSetException
-
CompositeDataSet
Creates a composite dataset that combines tables having identical name. Tables having the same name are merged into one table.- Throws:
DataSetException
-
CompositeDataSet
Creates a composite dataset that combines tables having identical name. Tables having the same name are merged into one table.- Parameters:
tables- The tables to merge to one datasetcaseSensitiveTableNames- Whether or not table names are handled in a case sensitive way over all datasets.- Throws:
DataSetException- Since:
- 2.4.2
-
-
Method Details
-
createIterator
Description copied from class:AbstractDataSetCreates an iterator which provides access to all tables of this dataset- Specified by:
createIteratorin classAbstractDataSet- Parameters:
reversed- Whether the created iterator should be a reversed one or not- Returns:
- The created
ITableIterator - Throws:
DataSetException
-
false.