#ifndef _CAP_FIELDS_H_ #define _CAP_FIELDS_H_ #include "fields.h" #include using namespace std; class Fields { public: Fields(); // implements new_inputstruct for stdin Fields(const string filename); // implements new_inputstruct for a file ~Fields(); // implements jettison_inputstruct int get_line(); // implements get_line int get_line_number(); // return the current line number int get_NF(); // return the number of fields in the string get_name(); // return the name of the file // current line string get_current_line(); // returns the current line string get_field(int i); // return the ith field in the current line protected: IS file; string name; }; #endif