title: error C2248: cannot access private member declared in class
body: <p>I´m getting this error in a c++ application:</p>
  
  <pre><code>error C2248: 'std::basic_ios&lt;_Elem,_Traits&gt;::basic_ios' :
                cannot access private member declared in class '
  </code></pre>
  
  <p>I have seen similar questions in stackoverflow, but I couldn't figure out what's wrong with my code. Can someone help me?</p>
  
  <pre><code>    //header file
  class batchformat {
      public:
          batchformat();
          ~batchformat();
          std::vector&lt;long&gt; cases;        
          void readBatchformat();
      private:
          string readLinee(ifstream batchFile);
          void clear();
  };
  
  
      //cpp file
  void batchformat::readBatchformat() 
  {
      ifstream batchFile; 
      //CODE HERE
      line = batchformat::readLinee(batchFile);
  
  }
  
  
  string batchformat::readLinee(ifstream batchFile)
  {
      string thisLine;
      //CODE HERE
      return thisLine;
  }
  </code></pre>