• 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: reading in text files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: reading in text files


  • Subject: Re: reading in text files
  • From: Lance Bland <email@hidden>
  • Date: Fri, 1 Feb 2002 07:11:32 -0500

On Friday, February 1, 2002, at 06:45 AM, jgo wrote:

If you need more impressive services, check NSScanner.

myFile is large (can be up to 16000 bytes), so I don't think
reading the whole thing into an NSString would be good.

That's not large, that's small. Such files can be read into
memory and worked on there without any caveats.

I'll bite. What if the file were 160MB... or 1.6GB?

How would one have it read in only a continuous series
of chunks and have it parse them, while minimizing monkeying
around with chunk boundary conditions?

There is no class in Cocoa that can efficiently (effectively?) handle that size of data (at least, not to my satisfaction). You have to roll your own. Fortunately, you can do that easily because you can access ANSI-C file methods and roll Obj-C methods and classes around them.

- lance
_______________________________________________
Lance Bland
System Administrator at VVI
mailto:email@hidden
http://www.vvi.com
Realtime, bulk and web data reporting and visualization


  • Follow-Ups:
    • Re: reading in text files
      • From: Malte Tancred <email@hidden>
References: 
 >Re: reading in text files (From: jgo <email@hidden>)

  • Prev by Date: Re: reading in text files
  • Next by Date: Re: reading in text files
  • Previous by thread: Re: reading in text files
  • Next by thread: Re: reading in text files
  • Index(es):
    • Date
    • Thread