CoreFoundation 对于 ios开发的作用

奥西里斯 发布于 2014/07/18 18:02
阅读 1K+
收藏 0

对于corefoundation一直存在疑问,一直感觉他是作为ios开发的底层接口,可是为什么很多开发者习惯于实用corefoundation接口而不是用NS库,比如CFUUIDRef,NSUUID,都可以产生UUID,但是看到的大部分代码都是使用CFUUIDRef,这是为什么呢,直接使用corefoundation接口有什么好处呢?

加载中
1
wzxing55
wzxing55
发现1年都没人回,我回复一下。 核心是和其他加框架和架构方便“沟通”。 

The programming interfaces of Core Foundation objects have been designed for ease of use and reuse. At a general level, Core Foundation:

  • Enables sharing of code and data among various frameworks and libraries

  • Makes some degree of operating-system independence possible 

  • Supports internationalization with Unicode strings

  • Provides common API and other useful capabilities, including a plug-in architecture, XML property lists, and preferences

Core Foundation makes it possible for the different frameworks and libraries on OS X to share code and data. Applications, libraries, and frameworks can define C routines that incorporate Core Foundation types in their external interfaces; they can thus communicate data—as Core Foundation objects—to each other through these interfaces.


返回顶部
顶部