通过NSInputStream读取大文件的指定起始内容

转载自:http://www.cocoachina.com/bbs/read.php?tid-60598.html

 

NSFileHandle *fileHandle = [NSFileHandle fileHandleForReadingAtPath:filePath];
[fileHandle seekToFileOffset:1000];
NSData *data = [fileHandle readDataOfLength:2000];
 

你可能感兴趣的:(html,PHP,bbs)