net.sf.jasperreports.engine.data
Interface IndexedDataSource

All Superinterfaces:
JRDataSource
All Known Implementing Classes:
ColumnValuesDataSource, SortedDataSource

public interface IndexedDataSource
extends JRDataSource

JRDataSource extension that can provide the record index at the current position.

Version:
$Id: IndexedDataSource.java 5050 2012-03-12 10:11:26Z teodord $
Author:
Lucian Chirita (lucianc@users.sourceforge.net)

Method Summary
 int getRecordIndex()
          Returns the index of the current record in the data source.
 
Methods inherited from interface net.sf.jasperreports.engine.JRDataSource
getFieldValue, next
 

Method Detail

getRecordIndex

int getRecordIndex()
Returns the index of the current record in the data source. Note that this would not necessarily be the same as the index of the record in the order in which the data appears in the report, as after sorting or filtering a data source the original index of the record will be returned.

Returns:
the index of the current record


© 2001-2010 Jaspersoft Corporation www.jaspersoft.com