sparksee.RowReader Class Reference

RowReader interface. More...

Inheritance diagram for sparksee.RowReader:

Inheritance graph

List of all members.

Public Member Functions

def close
 Closes the reader.
def get_row
 The row number for the current row.
def reset
 Moves the reader to the beginning.
def read
 Reads the next row as a string array.


Detailed Description

RowReader interface.

Common interface for those readers which get the data as an string array.

It works as follows: perform as many read operations as necessary and call close once at the end. Once close is called no more read operations can be executed.

Check out the 'Data import' section in the SPARKSEE User Manual for more details on this.

Author:
Sparsity Technologies http://www.sparsity-technologies.com

Member Function Documentation

def sparksee.RowReader.close (   self  ) 

Closes the reader.

Exceptions:
IOError If the close fails.

Reimplemented in sparksee.CSVReader.

def sparksee.RowReader.get_row (   self  ) 

The row number for the current row.

Returns:
The current row number; 0 if there is no current row.
Exceptions:
IOError If it fails.

Reimplemented in sparksee.CSVReader.

def sparksee.RowReader.reset (   self  ) 

Moves the reader to the beginning.

Restarts the reader.

Returns:
true if the reader can be restarted, false otherwise.
Exceptions:
IOError If bad things happen during the restart.

Reimplemented in sparksee.CSVReader.

def sparksee.RowReader.read (   self,
  row 
)

Reads the next row as a string array.

Parameters:
row [out] A string list with each comma-separated element as a separate entry.
Returns:
Returns true if a row had been read or false otherwise.
Exceptions:
IOError If bad things happen during the read.

Reimplemented in sparksee.CSVReader.


Generated on Fri Feb 7 13:22:25 2014 for SparkseePython by  doxygen 1.5.6