Re: Obtaining the size of a directory
Re: Obtaining the size of a directory
- Subject: Re: Obtaining the size of a directory
- From: Jacob Chapa <email@hidden>
- Date: Tue, 19 Oct 2004 09:38:30 -0500
the dictionary holds a lot more than that. take a look at NSFileManager
NSNumber *fsize;
NSDictionary *fattrs = [manager fileAttributesAtPath:@"/tmp/List"
traverseLink:YES];
if (!fattrs) {
NSLog(@"Path is incorrect!");
return;
}
if (fsize = [fattrs objectForKey:NSFileSize])
NSLog(@"File size: %d\n", [fsize intValue]);
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden