Re: Read last x bytes of a text file?
Re: Read last x bytes of a text file?
- Subject: Re: Read last x bytes of a text file?
- From: "Adam R. Maxwell" <email@hidden>
- Date: Mon, 17 Aug 2009 20:07:51 -0700
On Aug 17, 2009, at 7:57 PM, Alex Kac wrote:
I'm sure there is a great way to do this, but I seem to not find it.
I have a potentially large text file that I wish to only show the
last 32k worth - it could be 200MB. So I was looking at
NSInputStream, but perhaps I'm being dense or its the wrong tool for
the job, but I cannot find a way to tell it to start at byte x of
the file.
Check out NSFileHandle, specifically -seekToFileOffset: and -
readDataToEndOfFile.
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden