org.dbunit.dataset
Class ColumnFilterTable

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

public class ColumnFilterTable
extends Object
implements ITable

A table that filters some columns out from the original table.

Since:
2.4.0
Version:
$Revision: 850 $ $Date: 2008-10-31 19:39:59 +0100 (Fri, 31 Oct 2008) $
Author:
gommma (gommma AT users.sourceforge.net), Last changed by: $Author: gommma $

Field Summary
 
Fields inherited from interface org.dbunit.dataset.ITable
NO_VALUE
 
Constructor Summary
ColumnFilterTable(ITable table, IColumnFilter columnFilter)
           
 
Method Summary
 ITableMetaData getOriginalMetaData()
           
 int getRowCount()
          Returns this table row count.
 ITableMetaData getTableMetaData()
          Returns this table metadata.
 Object getValue(int row, String column)
          Returns this table value for the specified row and column.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ColumnFilterTable

public ColumnFilterTable(ITable table,
                         IColumnFilter columnFilter)
                  throws DataSetException
Parameters:
table - The table from which some columns should be filtered
columnFilter - The filter defining which columns to be filtered
Throws:
DataSetException
Method Detail

getRowCount

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

Specified by:
getRowCount in interface ITable

getTableMetaData

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

Specified by:
getTableMetaData in interface ITable

getValue

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

Specified by:
getValue in interface ITable
Parameters:
row - The row index, starting with 0
column - The name of the column
Returns:
The value
Throws:
NoSuchColumnException - if specified column name do not exist in this table
RowOutOfBoundsException - if specified row is less than zero or equals or greater than getRowCount
DataSetException

getOriginalMetaData

public ITableMetaData getOriginalMetaData()


Copyright © 2002-2012. All Rights Reserved.