Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

For Windows there is Win32 API, what about for Mac?

For Windows there is Win32 API, what about for Mac? On Wikipedia

http://en.wikipedia.org/wiki/Cocoa_(API)

it is said that Cocoa is "one of" the API... what about the full story?

like image 485
nonopolarity Avatar asked Sep 02 '25 16:09

nonopolarity


2 Answers

At what level? The low level API is largely but not entirely FreeBSD, and below that there is still a Mach API (some things still use Mach ports for IPC, I believe; at least, launchd supports them). At the upper level are two APIs: Cocoa and Carbon. Cocoa is the native API; Carbon is intended for programs ported from older MacOS. (Which includes parts of OSX itself; for a long time Finder was a Carbon app.)

The Windows situation isn't all that different, actually; there was for a long time a Win16 emulation API present in 32-bit Windows, and in the early days of Windows NT it had both POSIX and 16-bit OS/2 APIs.

like image 188
geekosaur Avatar answered Sep 04 '25 06:09

geekosaur


That pretty much is the full story. Mac OS X does support other APIs, but they're either deprecated (Carbon), or intended primarily to support "foreign" software (Java, X11, POSIX). The native API is Cocoa.

like image 39
Sherm Pendley Avatar answered Sep 04 '25 05:09

Sherm Pendley