com.sas.table
Interface StaticColumnTemplateTableInterface

All Superinterfaces:
StaticTableInterface
All Known Subinterfaces:
ColumnTemplateTableInterface

public interface StaticColumnTemplateTableInterface
extends StaticTableInterface

Defines an interface for accessing column template tables. Column template tables are tables where the set of row classes defines a template for each column. In other words, the class of each cell is restricted to the class, or a subclass, of its corresponding row. A transposed SAS data set is an example of such a table.

See Also:
ColumnTemplateTableInterface, StaticRowTemplateTableInterface

Method Summary
 java.lang.Class getRowClass(int index)
          Returns the class of a row.
 java.lang.Class[] getRowClasses(int startIndex, int count)
          Returns the classes for a range of rows.
 
Methods inherited from interface com.sas.table.StaticTableInterface
countColumns, countRows, getCell, getCellClass, getCellClasses, getCells, getColumn, getColumnCount, getRow, getRowCount
 

Method Detail

getRowClass

java.lang.Class getRowClass(int index)
                            throws com.sas.table.TableException
Returns the class of a row. The row is identified by the given index. Null will be returned for rows that do not contain cells of a single class.

Parameters:
index - A one-based index that identifies the row.
Returns:
The specified row's class.
Throws:
TableException - Provides a catch-all for all non-RuntimeExceptions.
java.lang.IndexOutOfBoundsException - Thrown if index is negative, zero, or greater than the number of rows.

getRowClasses

java.lang.Class[] getRowClasses(int startIndex,
                                int count)
                                throws com.sas.table.TableException
Returns the classes for a range of rows. The range of rows is identified by the given index which serves to identify a starting row and by the given row count which defines the extent of the range. The set of classes is returned as an array with each element of the array corresponding to a row in the range. The class of rows that do not contain cells of a single class should be expressed as null.

Parameters:
startIndex - A one-based index which identifies the start of the range.
count - The number of classes to return; defines the extent of the range.
Returns:
The specified rows' classes.
Throws:
TableException - Provides a catch-all for all non-RuntimeExceptions.
java.lang.IndexOutOfBoundsException - Thrown if startIndex or count is negative, zero, or greater than the number of rows except when getRowCount has returned -1. In that case, the implementation should return an array whose length is less than count and the caller should be prepared for this.



Copyright © 2009 SAS Institute Inc. All Rights Reserved.