Re: How to use NSWorkspace's getFileSystemInfoForPath?
Re: How to use NSWorkspace's getFileSystemInfoForPath?
- Subject: Re: How to use NSWorkspace's getFileSystemInfoForPath?
- From: Dietrich Epp <email@hidden>
- Date: Sun, 15 Sep 2002 22:05:09 -0700
On Sunday, September 15, 2002, at 08:49 , Yuhui wrote:
Hi,
I'm quite new to Cocoa programming, so please excuse me if this sounds
trivial.
I'm designing an app that handles removable volumes and need an easy
way to figure out what kind of volume each one is, e.g. CD, DVD, etc.
I came across this function -
getFileSystemInfoForPath:isRemovable:isWritable:isUnmountable:descriptio
n:type: in NSWorkspace, but I'm not too sure how to use it. Can anyone
provide any hints please? Sample code would be great too.
BTW I searched the Cocoa archives for "getfilesysteminfo" and
"getfilesysteminfoforpath" but it returned nil, so I guess this has
never been asked before.
Thanks!
Yuhui
A quick scan of the documentation reveals:
file:///System/Library/Frameworks/AppKit.framework/Resources/English.lproj/
Documentation/Reference/ObjC_classic/Classes/NSWorkspace.html#//apple_ref/
occ/instm/NSWorkspace/getFileSystemInfoForPath:isRemovable:isWritable:isUnmountable:
description:type:
(just the appkit docs -> NSWorkspace)
What I would do is test it. Write a program an NSLog all the results.
Apple warns, however, that the values "shouldn't be depended upon by
program logic", which probably means that ten years from now your app
won't work.
_______________________________________________
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.