Re: large documents with doc based app
Re: large documents with doc based app
- Subject: Re: large documents with doc based app
- From: Alastair Houghton <email@hidden>
- Date: Thu, 6 Mar 2008 16:53:00 +0000
On 6 Mar 2008, at 16:34, Aaron Burghardt wrote:
If you don't mind working with the POSIX APIs (e.g., Unix system
calls), there is mmap(). Unlike NData, it lets you specify a
"window" onto the file so that you can control how much of your
address space is mapped to the file at a given time.
That's true, though it's equivalent (in approach) to loading the file
in pieces, in that you can only see a small piece of the file's data
in memory at any time.
Again, it depends on the application domain as to whether using
mmap(), [p]read()/[p]write()/NSFileHandle or even fread()/fwrite()
will be the most efficient. Also, you'll need to concern yourself
with the system page size if you use mmap(), which is easy enough,
it's just something you don't normally need to worry about with higher
level routines or the non-memory-mapped I/O routines.
Kind regards,
Alastair.
--
http://alastairs-place.net
_______________________________________________
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