• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: [Q] large flat files usage
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Q] large flat files usage


  • Subject: Re: [Q] large flat files usage
  • From: Phillip Morelock <email@hidden>
  • Date: Wed, 19 Jun 2002 16:44:00 -0700

On 6/19/02 1:53 PM, "Sherm Pendley" <email@hidden> wrote:
>> Now I'm in a situation where I have some enormous flat files to work
>> with
>> (we're talking 5, 10 megs, etc.).
>
> This is 2002... 5 or 10 terabytes is enormous. 5 or 10 megs is merely
> large. :-)

HA! Yes I should have been clearer - - this program needs to run fast on an
iBook.

>> Of course I am hoping there's some "dyno-MITE" Cocoa way of doing this,
>> but
>> a little messy C library stuff is just fine with me.
>
> Check out the NSFileHandle class. It defines the methods you need to
> seek to specific points in the file and read/write data at those points.
> These methods take 64-bit "long long" parameters, so they can be used
> with truly huge files.
>
> As you've correctly pointed out, the equivalent "messy C" functions are
> fopen, fseek, ftell, fread, and fwrite.

Thanks for the help.

I'm leaning toward writing the first go-round as read-only, so I don't even
have to deal with reupdating indices and inserting changes into the middle
of flat files until I absolutely am required to.

Not sure how helpful NSFileHandle will be beyond what can already be done
with the "messies", but I'll give it a crack.

And this is always fun:
-----------------------------------------
file://localhost/Developer/Documentation/Cocoa/TasksAndConcepts/ProgrammingT
opics/FileMgmt/

Discussion

This topic is under construction.
-----------------------------------------

> Hope this helps!
Thanks, sure does.

> sherm--
fillup
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: [Q] large flat files usage
      • From: Douglas Davidson <email@hidden>
References: 
 >Re: [Q] large flat files usage (From: Sherm Pendley <email@hidden>)

  • Prev by Date: keyEquivalentModifierMask problems with Shift
  • Next by Date: Re: [Q] large flat files usage
  • Previous by thread: Re: [Q] large flat files usage
  • Next by thread: Re: [Q] large flat files usage
  • Index(es):
    • Date
    • Thread