Im no expert of C++ but I have a preety general understanding. Sometimes I try and make effecent code and others I just want to experiment and reevent the wheel. Right now Im trying to take, by take I mean hide all the ugly fstream code, by creating an object, FileStream, that holds various functions ie, textOpenRead that would open a text file for reading. I thought the best way to do this would be to create two vectors, one that olds an int(ID), and another that holds the fstream object.
The ID would serve the purpose of when calling, lets say getLine(int ID). Then the object would match the ID with the correct fstream object and apply getLine to that file. I hope I was able to make myself clear enough, but just for safety's sake Im gonna show an example and source.

Code:
//Header
#include <fstream>
#include <vector>
using namespace std;

class FileStream
{
    private:
        vector<int> ID;
        vector<fstream>streams;
    public:
        FileStream(){}
        ~FileStream(){}
        int textOpenRead(char*);
        void getLine(int id);
};

//This is suppose to return the id that is used for later functions for editing
int FileStream::textOpenRead(char *fName)
{
    fstream file(fName,ios::out);//Create the fstream object
    streams.push_back(file); //Here is where I get errors
    ID.push_back(ID.size());
    return ID.size()-1;
}

void getLine(int id)
{
   char ch;
   while(streams[i].get(ch)!=null or enter or endOfFile)
   {
        cout<<ch;
    }
}
//End Header
The getline code I just wrote and is obviously just there for the sake of understanding. For some reason I ger errors at the "streams.push_back(file);" line.
The errors are as follows according to Log:

In copy constructor
`std::basic_ios<char, std::char_traits<char> >::basic_ios(const
std::basic_ios<char, std::char_traits<char> >&)':
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_construct.h:78: instantiated from `void std::_Construct(_T1*, const _T2&) [with _T1 = std::fstream, _T2 = std::basic_fstream<char, std::char_traits<char> >]'
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_vector.h:599: instantiated from `void std::vector<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::fstream, _Alloc = std::allocator<std::fstream>]'
FileStream.h:21: instantiated from here
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/ios_base.h:668: error: `
std::ios_base::ios_base(const std::ios_base&)' is private
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_construct.h:78: error: within
this context

C:/Program Files/Dev-Cpp/include/c++/3.3.1/streambuf: In copy constructor `
std::basic_filebuf<char, std::char_traits<char> >::basic_filebuf(const
std::basic_filebuf<char, std::char_traits<char> >&)':
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_construct.h:78: instantiated from `void std::_Construct(_T1*, const _T2&) [with _T1 = std::fstream, _T2 = std::basic_fstream<char, std::char_traits<char> >]'
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_vector.h:599: instantiated from `void std::vector<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::fstream, _Alloc = std::allocator<std::fstream>]'
FileStream.h:21: instantiated from here
C:/Program Files/Dev-Cpp/include/c++/3.3.1/streambuf:922: error: `
std::basic_streambuf<_CharT, _Traits>::basic_streambuf(const
std::basic_streambuf<_CharT, _Traits>&) [with _CharT = char, _Traits =
std::char_traits<char>]' is private
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_construct.h:78: error: within
this context

C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/ios_base.h: In member function
`std::basic_ios<char, std::char_traits<char> >& std::basic_ios<char,
std::char_traits<char> >::operator=(const std::basic_ios<char,
std::char_traits<char> >&)':

C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/vector.tcc:230: instantiated from `void std::vector<_Tp, _Alloc>::_M_insert_aux(__gnu_cxx::__normal_iterator<_Tp*, std::vector<_Tp, _Alloc> >, const _Tp&) [with _Tp = std::fstream, _Alloc = std::allocator<std::fstream>]'

C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/stl_vector.h:603: instantiated from `void std::vector<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::fstream, _Alloc = std::allocator<std::fstream>]'
FileStream.h:21: instantiated from here
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/ios_base.h:671: error: `
std::ios_base& std::ios_base::operator=(const std::ios_base&)' is private
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/vector.tcc:230: error: within
this context

C:/Program Files/Dev-Cpp/include/c++/3.3.1/streambuf: In member function `
std::basic_filebuf<char, std::char_traits<char> >& std::basic_filebuf<char,
std::char_traits<char> >::operator=(const std::basic_filebuf<char,
std::char_traits<char> >&)':
C:/Program Files/Dev-Cpp/include/c++/3.3.1/streambuf:925: error: `
std::basic_streambuf<_CharT, _Traits>& std::basic_streambuf<_CharT,
_Traits>::operator=(const std::basic_streambuf<_CharT, _Traits>&) [with

_CharT = char, _Traits = std::char_traits<char>]' is private
C:/Program Files/Dev-Cpp/include/c++/3.3.1/bits/vector.tcc:230: error: within
this context

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

Any help you can give me on how to properly get a fstream vector. Maybe I shouldn't be using fstream as the ojbect or maybe it just can't be done.
Any light you can shine on the subject is greatly appreciated.
Thank you.

[gorregisguy]