Is it possible to read a file using multiple streams to access different portions of data in it at the same time, using Qt?
Is it possible to read a file using multiple streams to access different portions
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Note that a stream (QTextStream / QDataStream) in Qt doesn’t handle the position in the underlying device. A stream class is only a wrapper for easier parsing of the binary data within the device (QFile instance).
So two streams for the same device (QFile) will not work.
You can, however, have multiple devices (QFile) for the same underlying file, and each of them can then be read using another stream instance.