C/C++ Reference
FileCspReader Struct Reference

Example code that shows you how to write a CspReader driver object. More...

#include <FileCspReader.h>

Inheritance diagram for FileCspReader:
Collaboration diagram for FileCspReader:

List of all members.

Public Member Functions

 FileCspReader (const char *pathName)
 The FileCspReader constructor opens the "dat" file for reading.

Detailed Description

Example code that shows you how to write a CspReader driver object.

The Web-Server uses the CspReader driver object when requesting data from the "dat" file generated by HttpLink.

This example code uses the file system for reading the "dat" file. The constructor opens the "dat" file and method "diskRead" uses the Posix function fseek for setting the file pointer to the requested offset position and function fread for reading the actual data.


Constructor & Destructor Documentation

FileCspReader::FileCspReader ( const char *  pathName)

The FileCspReader constructor opens the "dat" file for reading.

You must call CspReader::isValid, which informs you if the constructor successfully opened the "data" file for reading.

Parameters:
pathNameis the path and name to the "data" file.