com.fdsapi
Class TabularDataEmpty

java.lang.Object
  |
  +--com.fdsapi.TabularDataBase
        |
        +--com.fdsapi.TabularDataEmpty
All Implemented Interfaces:
java.io.Serializable, TabularData

public class TabularDataEmpty
extends TabularDataBase

Null TabularData object. Null objects allow code to be written the same way whether an object exists or doesn't (i.e. the null object). This is a refactoring mentioned in Martin Fowler's Refactoring book.

View Code

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.fdsapi.TabularDataBase
colIterator, rowIterator
 
Fields inherited from interface com.fdsapi.TabularData
NOTUSED
 
Constructor Summary
  TabularDataEmpty()
           
protected TabularDataEmpty(int numRows, int numCols)
           
 
Method Summary
static TabularData createInstance()
           
 TabularData createInstance(java.lang.Object data)
          Factory method that returns a TabularData instance.
 java.lang.Object getCellData()
          Return current cell data (the current row and current column)
 java.lang.Object getCellData(int col)
          Return cell data in the current rows specified column
 
Methods inherited from class com.fdsapi.TabularDataBase
createColIterator, createRowIterator, getColIterator, getHeader, getRowIterator, setHeader
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TabularDataEmpty

public TabularDataEmpty()

TabularDataEmpty

protected TabularDataEmpty(int numRows,
                           int numCols)
Method Detail

createInstance

public static TabularData createInstance()

getCellData

public java.lang.Object getCellData(int col)
Description copied from interface: TabularData
Return cell data in the current rows specified column

Specified by:
getCellData in interface TabularData
Specified by:
getCellData in class TabularDataBase

getCellData

public java.lang.Object getCellData()
Description copied from interface: TabularData
Return current cell data (the current row and current column)

Specified by:
getCellData in interface TabularData
Specified by:
getCellData in class TabularDataBase

createInstance

public TabularData createInstance(java.lang.Object data)
Description copied from interface: TabularData
Factory method that returns a TabularData instance. The passed object is the underlying data that will be iterated (i.e. ResultSet, Object[][] etc)

Specified by:
createInstance in interface TabularData
Specified by:
createInstance in class TabularDataBase