检查 CIFilter 在当前 iOS 中是否可用
我想使用 iOS5 的一些功能,但仍然兼容 iOS4,但我遇到了问题。通常我会使用 respondsToSelector:
但我不确定这是否是正确的方法,或者它是否是我应该插入的内容。
我正在尝试使用 CIFilter,据我了解,它仅在 iOS5+ 中可用,如何检查它是否在当前安装的操作系统中可用?
提前致谢。
I would like to use some of the functionality of iOS5 but still build for iOS4 compaitibly but i'm having an issue. Typically i would use the respondsToSelector:
but i'm not exactly sure whether this is the correct method, or if it is what exactly i should insert.
I'm trying to use CIFilter which, from what i understand, is only available within iOS5+, how would check to see whether this is available within the currently installed OS?
Thanks in advanced.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
尝试使用 NSClassFromString() 来确定当前版本的 iOS 中是否存在该类。
Try using
NSClassFromString()
to determine if the class exists in the current version of iOS.迅速:
Swift: