Unite and split files.
-
I need to unite files in one file and then split this file to many. Also I need to restore all filenames and extensions after splitting like it done in WinRar, WinZip applications. So is there a simple way to solve it using qt ? The first idea is to read all bytes from all files and store it in one but next I need to do some record in which I hold number of files, it's lengths and filenames and extensions. So is there any simplest way ?
-
I would recommend reading the QIODevice class documentation. In that class all file related options are described. You might want to use the .pos and .count etc to get all the parameters you need.
Then think of a way to have a sort of MBR in the beginning of the file which lists the current files imported and what position the data bytes of the file are.
greetz