, src fstream, . , src ifstream, . ( !)
( sbi), , , . ( ofstream) , , rdbuf() , .
, , , , , . , , . . (, 1 , , ) , . , , , .
And you will probably find that your OS is even more efficient at copying files if you use your own APIs, but then it becomes less portable. You can look at the Boost file system module for a portable solution.
source
share