Re: large documents with doc based app

2008-03-06 Thread ajb . lists
True, the usefulness is reduced to being a performance optimization in certain circumstances. On Mar 6, 2008, at 11:53 AM, Alastair Houghton wrote: 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(). Unl

Re: large documents with doc based app

2008-03-06 Thread Alastair Houghton
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.

Re: large documents with doc based app

2008-03-06 Thread Alastair Houghton
On 6 Mar 2008, at 00:13, Kyle Sluder wrote: On Wed, Mar 5, 2008 at 6:40 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: I though NSData would handle the access just transparently. Otherwise that would be good to keep in mind also for files slightly smaller than 2GB :) While NSData certainly has

Re: large documents with doc based app

2008-03-06 Thread Torsten Curdt
On 06.03.2008, at 01:13, Kyle Sluder wrote: On Wed, Mar 5, 2008 at 6:40 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: I though NSData would handle the access just transparently. Otherwise that would be good to keep in mind also for files slightly smaller than 2GB :) While NSData certain

RE: large documents with doc based app

2008-03-05 Thread Gary L. Wade
Try overriding readFromFile:ofType: and other similar messages for unique file needs. >Hey guys, > >Using the document based skeleton there is the method > >- (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType >or >- (BOOL)readFromData:(NSData *)data ofType:(NSString *)typeName

Re: large documents with doc based app

2008-03-05 Thread Kyle Sluder
On Wed, Mar 5, 2008 at 6:40 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: > I though NSData would handle the access just transparently. Otherwise > that would be good to keep in mind also for files slightly smaller > than 2GB :) While NSData certainly has the capability to do memory-mapped IO, i

Re: large documents with doc based app

2008-03-05 Thread Nick Zitzmann
On Mar 5, 2008, at 4:19 PM, Torsten Curdt wrote: But according to the docs NSData is limited to 2GB. What I am wondering is... How can one handle files larger than 2GB? In addition to what has been said, if you can afford to target only Leopard and only 64-bit Macs, then this limitation do

Re: large documents with doc based app

2008-03-05 Thread Torsten Curdt
On 06.03.2008, at 00:22, j o a r wrote: On Mar 6, 2008, at 12:19 AM, Torsten Curdt wrote: But according to the docs NSData is limited to 2GB. What I am wondering is... How can one handle files larger than 2GB? Override the path / URL based methods from NSDocument instead, and read the i

Re: large documents with doc based app

2008-03-05 Thread j o a r
On Mar 6, 2008, at 12:19 AM, Torsten Curdt wrote: But according to the docs NSData is limited to 2GB. What I am wondering is... How can one handle files larger than 2GB? Override the path / URL based methods from NSDocument instead, and read the interesting portions of the files piece-by-p

large documents with doc based app

2008-03-05 Thread Torsten Curdt
Hey guys, Using the document based skeleton there is the method - (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType or - (BOOL)readFromData:(NSData *)data ofType:(NSString *)typeName error: (NSError **)outError; that gets called when files get loaded. But according to the d