compiling error

From: Edo (eddod_at_eddododod.dod)
Date: 07/30/04


Date: Fri, 30 Jul 2004 10:12:41 -0700

Hello
Seams like those errors never end with me.
after spending 4 hrs, can't find the problem.

thanks

////////////////////////fileCleaning.h////////////////////
#ifndef FILECLEANING_H
#define FILECLEANING_H

//fileCleaning.h
#include <iostream>
#include <string>
#include <fstream>

class clean {

clean(std::string, std::string); //constructor

     private:
         std::string _oFile;
         std::string _iFile;
}; /////notice the ";" at the end of the class declaration

#endif
//////////////////////////////fileCleaning.cpp////////////
#include "fileCleaning.h"
//fileCleaning.cpp
#include <iostream>
using std::cout;
using std::cin;
using std::endl;

#include <string>
using std::string;

#include <fstream>
using std::ofstream;
using std::ifstream;

#include <sstream>
using std::ostringstream;

clean::clean(string is, string os): _oFile(os), _iFile(is) {}

//open an output stream and varify
std::ofstream oFile(_oFile.std::c_str());
if (! oFile){ // Always test file open
      std::cout << "Error opening output file" << std::endl;
     return -1;
}

//open an input stream and varify
std::ifstream iFile(_iFile.std::c_str());
if (! iFile){
     std::cout << "error opening file" << std::endl;
     return -1;
}

void clean::scan(ifstream iFile, ofstream oFile){...}
/////////////////main.cpp////////////////////////////
#include <iostream>
#include <string>
#include "fileCleaning.h"

using namespace std;
int main(){
        clean files("C:\\IBMDRV\\out.txt", "C:\\IBMDRV\\out2.txt");
        
      cin.sync(); getchar(); return 0;

}

////////////////////error/////////////////////////
Compiler: Default compiler
Building Makefile: "C:\IBMDRV\C++\work\bhp\Makefile.win"
Executing make clean
rm -f main.o parse.o fileCleaning.o bph.exe

g++.exe -D__DEBUG__ -c main.cpp -o main.o -I"C:/Dev-Cpp/include/c++"
-I"C:/Dev-Cpp/include/c++/mingw32" -I"C:/Dev-Cpp/include/c++/backward"
  -I"C:/Dev-Cpp/include" -pg -g3

fileCleaning.h: In function `int main()':
fileCleaning.h:12: `clean::clean(std::basic_string<char,
    std::char_traits<char>, std::allocator<char> >, std::basic_string<char,
    std::char_traits<char>, std::allocator<char> >)' is private

main.cpp:7: within this context

make.exe: *** [main.o] Error 1

Execution terminated