开发者

Joining large files into one humongous file

Is there a way in Windows to link multiple fil开发者_开发知识库es together without having to open the target file and read the contents of the source files to append them to the target file? Something like a shell link api?

Background

I have up to 8 seperate processes creating parts of a data file that I want to recombine into one large file.


A less radical solution that should work just fine.

system("copy filefragment.1+filefragmenent.2+filefragment.3+....+filefragment.8 outputfile.bin");


No simple way that I know of. But here's a radical idea.

Use a virtual file system (Dokan, EldoS CBFS, Pismo Technic, etc..) to emulate one logical file that is actually backed by separate files on disk.


I have up to 8 seperate processes creating parts of a data file that I want to recombine into one large file.

How do you want them concatenated? Mixed or one after the other?

If you want them mixed, you can just open() your output file and write() to it from your threads. If you want them one after the other, you're best bet is to write to separate files and join them together at the end.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜