On Sep 14, 2014, at 2:57 AM, Aandi Inston <aa...@quite.com> wrote: >> No one should be using path-based API any more, generally. >> You should use URL-based equivalents. > > Why? Really, why? Certainly there are APIs where we have to use URL's and > we have to convert the path into a URL, but where a non-deprecated > path-based URL exists, what current or future obstacles do you foresee? The > URL doesn't seem to be more predicable or persistent, for example. > > Thanks for any insight. I've been really happy to see the last of the > old-style colon-separated names and move to something I can understand, a > pathname.
In addition to what others have said, NSURL can know it represents a file URL and therefore can do smart things like cache file metadata (called resource values in the API). A string can "look" like a path even when it isn't and it can not look like a path when it is, so NSString can't have any file-specific smarts built into it. Regards, Ken _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com