org.tm4j.tologx
Interface TologResultsSet


public interface TologResultsSet

This interface represents a collection of results from a single Tolog query. The collection is somewhat similar to a JDBC results set and can be thought of as a table consisting of a number of named columns with one row for each distinct match to the Tolog query.


Method Summary
 int getNumCols()
          Returns the number of variables listed in each match in this results set.
 int getNumRows()
          Returns the number of distinct matches in this results set.
 java.util.List getRow(int rowNum)
          Returns a single match from the results set.
 java.lang.String getVar(int colNum)
          Returns the name of the variable in the colNum'th position of the results set match.
 

Method Detail

getNumRows

public int getNumRows()
Returns the number of distinct matches in this results set. (i.e. the number of "rows" in the set).


getNumCols

public int getNumCols()
Returns the number of variables listed in each match in this results set. (i.e. the number of "columns" in the set).


getVar

public java.lang.String getVar(int colNum)
Returns the name of the variable in the colNum'th position of the results set match. (equivalent to the column name in a JDBC query). The index starts at 0.


getRow

public java.util.List getRow(int rowNum)
Returns a single match from the results set. The index starts at 0. The row is returned at a list containing the results in colum order. Each list entry is a (Topic object.