Hi All,
I am working on Mac OS 10.4.10 on my Mac Intel.
I can get the list of all the Disk on my MAC by following..
CFMutableDictionaryRef classesToMatch;
kern_return_t kernResult = KERN_FAILURE;
classesToMatch = IOServiceMatching( kIOMediaClass );
if ( classesToMatch == NULL ) goto Bail;
CFDictionarySetValue( classesToMatch, CFSTR(kIOMediaWholeKey), kCFBooleanTrue );
kernResult = IOServiceGetMatchingServices( kIOMasterPortDefault, classesToMatch, mediaIterator );
then Iterate through the mediaIterator.
Now I want to search the volume on my Mac through programming.
I have search for the APIs for the same but with no luck thus I have found the function to get the properties of the Volume by FSGetVolumeInfo but I donot know how to get the list of volumes.
Thanks.
Vishal
I am working on Mac OS 10.4.10 on my Mac Intel.
I can get the list of all the Disk on my MAC by following..
CFMutableDictionaryRef classesToMatch;
kern_return_t kernResult = KERN_FAILURE;
classesToMatch = IOServiceMatching( kIOMediaClass );
if ( classesToMatch == NULL ) goto Bail;
CFDictionarySetValue( classesToMatch, CFSTR(kIOMediaWholeKey), kCFBooleanTrue );
kernResult = IOServiceGetMatchingServices( kIOMasterPortDefault, classesToMatch, mediaIterator );
then Iterate through the mediaIterator.
Now I want to search the volume on my Mac through programming.
I have search for the APIs for the same but with no luck thus I have found the function to get the properties of the Volume by FSGetVolumeInfo but I donot know how to get the list of volumes.
Thanks.
Vishal