Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | Related Pages | Examples

WhipExamples/FileRead.cpp

#include "whiptk/whip_toolkit.h"

void FileRead(const WT_String& filename)
{
    WT_File        whip_file;
    //Set the filename and open mode.    
    whip_file.set_filename (filename);
    whip_file.set_file_mode (WT_File::File_Read);
    //Setup action handlers to respond to the "process" actions, if desired.

    if (WT_Result::Success == whip_file.open())
    {
        //Process the file.
        WT_Result result;
        do {
            result = whip_file.process_next_object();
            //Let the action handlers do stuff or 
            //Do something here with whip_file.current_object();
        } while (result == WT_Result::Success);

        whip_file.close();
    }
}

Generated on Tue May 17 12:07:43 2005 for Autodesk DWF Whip 2D Toolkit by  doxygen 1.4.1