• 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: Get size of folder
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get size of folder


  • Subject: Re: Get size of folder
  • From: Rainer Brockerhoff <email@hidden>
  • Date: Wed, 19 Aug 2009 14:28:10 -0300

At 21:54 -0700 18/08/09, email@hidden wrote:
>From: PCWiz <email@hidden>
>Date: Tue, 18 Aug 2009 21:17:30 -0700
>Message-ID: <email@hidden>
>
>I need a good method to find the size of a file or folder exactly as displayed in Finder. I've tried every method I could find on the internet, from using the du shell utility with NSTask to using the Carbon file manager. I need something that will work under heavy load (processing hundreds or thousands of files). The methods I've tried, some of them work but fail under load. Others just don't return a accurate file size, or they work for some files/folders and mess up on others. What's the easiest way to go about doing this?

Somewhat belatedly, you may want to try out the FolderSweep code at:
http://www.brockerhoff.net/src/index.html
or at:
http://mattgemmell.com/2008/04/10/foldersweep-source-code

You can directly get the data and resource fork sizes for every scanned file.
--
Rainer Brockerhoff  <email@hidden>
Belo Horizonte, Brazil
"In the affairs of others even fools are wise
 In their own business even sages err."
Weblog: http://www.brockerhoff.net/bb/viewtopic.php
_______________________________________________

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

  • Prev by Date: Re: Core Data dog-slow when using first time after boot
  • Next by Date: Starting editing for a Row as soon as it is Added. (More Detail)
  • Previous by thread: Re: Get size of folder
  • Next by thread: NSTableColumn loses 'value' binding when data cell set to NSButtonCell?
  • Index(es):
    • Date
    • Thread