Re: How to get user configutration
Re: How to get user configutration
- Subject: Re: How to get user configutration
- From: Michael Hall <email@hidden>
- Date: Wed, 14 Apr 2004 08:31:55 -0500
On Wednesday, April 14, 2004, at 04:14 AM, Stephane Sudre wrote:
On mercredi, avril 14, 2004, at 06:40 AM, Scott Anguish wrote:
On Apr 13, 2004, at 11:17 PM, Dustin Voss wrote:
On 13 Apr, 2004, at 2:16 PM, Denis Vaillant wrote:
Hi,
I didn't figure out which class to use to get user configuration :
OS
version, ram, video card, kind of Mac.... Is their a class or
method in
cocoa that gives access to these information ?
Not in Cocoa, but you can use Carbon managers:
Gestalt Manager for OS version, RAM, etc. --
http://developer.apple.com/documentation/Carbon/Reference/
Gestalt_Manager/gestalt_refchap/function_group_1.html
Display Manager for monitors and video cards --
http://developer.apple.com/documentation/Carbon/Reference/
Display_Manager/index.html
System Configuration Framework for networking stuff --
http://developer.apple.com/documentation/Networking/Conceptual/
SysConfigOverview926/index.html
you could also just use system_profiler
man system_profiler
Does not work on 10.2
/usr/sbin/AppleSystemProfiler
Involves a full application launch though. I used to indicate it would
be a nice to have if you could get the information without that.
You can AppleScript it but again a full GUI application launch is
involved.
on run
tell app "Apple System Profiler${APP}"
set theInfo to model name & ", " & processor type & " " & rated speed
& ", " & physical RAM size & "\r" ,
& "logic board num " & logic board num & " unique logic board num "
& unique logic board num & "\r" ,
& "ROM version " & boot ROM version & " Serial number " & serial
number
quit
end tell
return theInfo
end run
Mike Hall <mikehall at spacestar dot net>
<
http://www.spacestar.net/users/mikehall>
_______________________________________________
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.