我尝试运行适用于 iOS Swift 的 Google Calendar API 示例代码,并根据指南执行步骤 1 到 5 https://developers.google.com/google-apps/calendar/quickstart/ios?ver=swift
但是,我遇到了以下错误:
1) 导入桥接头失败 2) 找不到文件
我按照步骤操作。我有一个桥接头,其中包括#import
其中的陈述。还有什么我想念的吗?
最佳答案
Ryan Heitner 的以下回答帮助解决了我的问题:Google Objective-C API 'GTL' with Swift
基本上,我的桥接 header 中应该包含以下导入语句:
#import "GTMOAuth2ViewControllerTouch.h"
#import "GTLCalendar.h"
代替:
#import "GTMOAuth2ViewControllerTouch/GTMOAuth2ViewControllerTouch.h"
#import "GTLCalendar/GTLCalendar.h"
关于ios - 无法为 iOS Swift 运行 Google Calendar API 示例代码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32380797/