org.dbunit.dataset
Class CompositeTable

java.lang.Object
  extended by org.dbunit.dataset.AbstractTable
      extended by org.dbunit.dataset.CompositeTable
All Implemented Interfaces:
ITable

public class CompositeTable
extends AbstractTable

Since:
Feb 17, 2002
Version:
$Revision: 679 $
Author:
Manuel Laflamme

Field Summary
 
Fields inherited from interface org.dbunit.dataset.ITable
NO_VALUE
 
Constructor Summary
CompositeTable(ITable table1, ITable table2)
          Creates a composite table that combines the specified specified tables.
CompositeTable(ITableMetaData metaData, ITable table)
          Creates a composite table that combines the specified metadata with the specified table.
CompositeTable(ITableMetaData metaData, ITable[] tables)
          Creates a composite table that combines the specified metadata with the specified tables.
CompositeTable(java.lang.String newName, ITable table)
          Creates a composite dataset that encapsulate the specified table with a new name.
 
Method Summary
 int getRowCount()
          Returns this table row count.
 ITableMetaData getTableMetaData()
          Returns this table metadata.
 java.lang.Object getValue(int row, java.lang.String columnName)
          Returns this table value for the specified row and column.
 
Methods inherited from class org.dbunit.dataset.AbstractTable
assertValidColumn, assertValidRowIndex, assertValidRowIndex, getColumnIndex
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompositeTable

public CompositeTable(ITableMetaData metaData,
                      ITable table)
Creates a composite table that combines the specified metadata with the specified table.


CompositeTable

public CompositeTable(ITableMetaData metaData,
                      ITable[] tables)
Creates a composite table that combines the specified metadata with the specified tables.


CompositeTable

public CompositeTable(ITable table1,
                      ITable table2)
Creates a composite table that combines the specified specified tables. The metadata from the first table is used as metadata for the new table.


CompositeTable

public CompositeTable(java.lang.String newName,
                      ITable table)
               throws DataSetException
Creates a composite dataset that encapsulate the specified table with a new name.

Throws:
DataSetException
Method Detail

getTableMetaData

public ITableMetaData getTableMetaData()
Description copied from interface: ITable
Returns this table metadata.


getRowCount

public int getRowCount()
Description copied from interface: ITable
Returns this table row count.


getValue

public java.lang.Object getValue(int row,
                                 java.lang.String columnName)
                          throws DataSetException
Description copied from interface: ITable
Returns this table value for the specified row and column.

Throws:
NoSuchColumnException - if specfied column name do not exist in this table
RowOutOfBoundsException - if specfied row is less than zero or equals or greater than getRowCount
DataSetException


Copyright © 2002-2008. All Rights Reserved.