Passer Rating iOS  1.0
iOS demo project for Xcode 4 Unleashed
Public Member Functions
<SimpleCSVDelegate> Protocol Reference

Delegate for SimpleCSVFile. More...

#include <SimpleCSVFile.h>

List of all members.

Public Member Functions

BOOL csvFile:readValues:error: (SimpleCSVFile *file,[readValues] NSDictionary *values,[error] NSError **error)
 Receive key-value data from a line in a CSV file.

Detailed Description

Delegate for SimpleCSVFile.

A SimpleCSVFileDelegate receives a dictionary from -[SimpleCSVFile run:] for each line it parses after the header. The dictionary will be keyed on the names found in the header line, and the values will be drawn from the fields in the corresponding positions.


Member Function Documentation

BOOL csvFile:readValues:error: ( SimpleCSVFile file,
[readValues] NSDictionary *  values,
[error] NSError **  error 
) [virtual]

Receive key-value data from a line in a CSV file.

This method is called once for every line in the file after the first by -[SimpleCSVFie run:]. The receiver can stop parsing by returning NO. If it does, and error is not NULL, you must return nil or an NSError* object in *error.

The dictionary will be keyed on the names found in the header line, and the values will be drawn from the fields in the corresponding positions.

Parameters:
fileThe SimpleCSVFile object doing the parsing.
valuesA dictionary of strings representing the field values in the record line, keyed by the field names supplied in the header line.
[out]errorA pointer to an NSError object pointer. May be NULL. If it is not, and the receiver returns NO, this must be set to a valid NSError object pointer, or at least to nil.
Returns:
YES if parsing may continue, or NO if it may not. If NO, be sure to fill error.

The documentation for this protocol was generated from the following file:
 All Classes Files Functions Variables Properties Defines