Getting filename (or path) from fstream

后端 未结 2 1060
南笙
南笙 2020-12-16 09:13

Can I get a file name or its path from a fstream object? I looked through the methods of fstream and didn\'t find anything close to it.

2条回答
  •  失恋的感觉
    2020-12-16 09:43

    you may also design a little class which inherits from fstream and behaves like a fstream but also stores its file name.

提交回复
热议问题