![]() |
WebLVC 1.8 API Documentation
|
Reads in and parses a csv file. More...
Public Member Functions | |
| DtCsvFileReader () | |
| Default CTOR. More... | |
| DtCsvFileReader (const DtString &fileName) | |
| CTOR. More... | |
| virtual | ~DtCsvFileReader () |
| Virtual DTOR. More... | |
| virtual DtCsvFileEntry * | readAndParseNextLine (DtCsvFileEntryCreatorFcn pEntryCreatorFcn) |
Stream Management | |
| virtual bool | openStream () |
| virtual bool | openStream (const DtString &fileName) |
| virtual void | closeStream () |
Status Methods | |
| virtual bool | isEOF () const |
| virtual bool | isOpen () |
Filename Setter/Getter | |
| virtual void | setFilename (const DtString &name) |
| virtual const DtString & | filename () const |
Static Public Member Functions | |
| static DtCsvFileReader * | creator () |
| Creator method. More... | |
Protected Member Functions | |
| virtual bool | readLine (DtString &line) |
| Fills up line with a row from the table. More... | |
| virtual void | parseLine (DtCsvFileEntry *pEntry, DtString &line) |
| Parses the line and stores data in the entry. More... | |
Protected Attributes | |
| DtFilename | myFilename |
| std::ifstream | myInfile |
Private Member Functions | |
| DtCsvFileReader (const DtCsvFileReader &orig) | |
| DtCsvFileReader & | operator= (const DtCsvFileReader &orig) |
Reads in and parses a csv file.
Children classes will hold the parsed entries in sorted lists or hash lists. To use, instantiate the DtCsvFileReader, open a file stream, read and parse the lines from the file, then close the stream and deconstruct the reader.
| DtCsvFileReader::DtCsvFileReader | ( | ) |
Default CTOR.
| DtCsvFileReader::DtCsvFileReader | ( | const DtString & | fileName | ) |
CTOR.
|
virtual |
Virtual DTOR.
|
private |
|
virtual |
|
static |
Creator method.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
private |
|
protectedvirtual |
Parses the line and stores data in the entry.
|
virtual |
|
protectedvirtual |
Fills up line with a row from the table.
|
virtual |
|
protected |
|
protected |