RTSQLResultSet


Conforms To:
NSObject
Declared In:
RTSQLResultSet.h


Protocol Description

Protocol for a result set from a server.


Method Types

- database
- haveData
- fetchedAllData
- rowsTouched
- rowsReturned
- columnCount
- columnAtIndex:
- columnWithName:
- indexOfColumnNamed:
- columnEnumerator
- cacheRows
- setCacheRows:
- rowAtIndex:
- fetchRemainingData

Instance Methods

cacheRows

- (BOOL)cacheRows

Returns true if all rows will be cached until the result set is released. Defaults to false.


columnAtIndex:

- (id <RTSQLColumn>)columnAtIndex:(SInt32)inIndex

Retuns requested column (1-based)


columnCount

- (SInt32)columnCount

If haveData, number of columsn returned. Otherwise, -1.


columnEnumerator

- (NSEnumerator*)columnEnumerator

Returns enumerator of columns


columnWithName:

- (id <RTSQLColumn>)columnWithName:(NSString*)name

Returns requested column, or nil if no such column exists


database

- (id <RTSQLDatabase>)database

Database this result set is attached to


fetchRemainingData

- (void)fetchRemainingData

Continutes fetching rows into cache (or discarding if not caching) until they have all been retrieved


fetchedAllData

- (BOOL)fetchedAllData

Has all the data been retreived from the remote source?


haveData

- (BOOL)haveData

Did this result set return data (was it from a select)?


indexOfColumnNamed:

- (SInt32)indexOfColumnNamed:(NSString*)colName

Returns the index of col or 0 if not found


rowAtIndex:

- (id <RTSQLRow>)rowAtIndex:(SInt32)inIndex

returns the RTSQLRow at the specified 1-based index. Returns nil if no row at the requested index or caching is off and the specified row has already been returned. (Without caching, ResultSets are forward iterators only.)


rowsReturned

- (SInt32)rowsReturned

Returns the number of rows that have been retrieved so far by calling rowAtIndex


rowsTouched

- (SInt32)rowsTouched

Returns the number of rows touched/affected by the query, if known. -1 if not know.


setCacheRows:

- (void)setCacheRows:(BOOL)enableCache

Caller can set if row caching is enabled.


Copyright ©2006 by Runtime Labs, Inc.. All Rights Reserved.