我需要将JSON反序列化为对象,我认为使用ObjectMapper会很棒.
遗憾的是,无法导入对象映射器.我收到消息:
No such module 'ObjectMapper'
这是我的podfile
# Uncomment this line to define a global platform for your project platform :ios, '8.0' # Uncomment this line if you're using Swift use_frameworks! target 'OTTSwift' do source 'https://github.com/CocoaPods/Specs.git' platform :ios, '8.0' use_frameworks! pod 'Alamofire', '~> 3.0' use_frameworks! pod "EVReflection", '~> 2.6' use_frameworks! pod 'ObjectMapper', '~> 1.0' end
我甚至尝试过Git导入,但它不起作用
我用过那个,XCode在import语句中显示了同样的错误但是如果你构建你的项目它会构建得很好.似乎XCode需要一些时间来缓存新的更改,因为在下次导入时它不会显示任何错误.