谷歌通过我的iOS应用程序登录
我要在整合谷歌加号来我app.But我想使用谷歌SDK不使用可可豆荚,如果任何人都用这个的iOS SDK,请给我的步骤登录并获取用户的详细信息,因为我没有得到适当的文件。我使用谷歌登录在该委托方法SDK 4.0.1谷歌通过我的iOS应用程序登录
没有得到调用。
我用以下结构:
- (void)viewDidLoad {
[super viewDidLoad];
[GIDSignIn sharedInstance].clientID = @"842331483294-ofk2cbhhfjoga35u1575t4hbq9ek87ii.apps.googleusercontent.com";
[GIDSignIn sharedInstance].delegate = self;
[GIDSignIn sharedInstance].uiDelegate = self;
// Do any additional setup after loading the view, typically from a nib.
}
- (void)signIn:(GIDSignIn *)signIn
didSignInForUser:(GIDGoogleUser *)user
withError:(NSError *)error {
// Perform any operations on signed in user here.
NSString *userId = user.userID; // For client-side use only!
NSString *idToken = user.authentication.idToken; // Safe to send to the server
NSString *fullName = user.profile.name;
NSString *givenName = user.profile.givenName;
NSString *familyName = user.profile.familyName;
NSString *email = user.profile.email;
}
- (void)signIn:(GIDSignIn *)signIn
didDisconnectWithUser:(GIDGoogleUser *)user
withError:(NSError *)error {
// Perform any operations when the user disconnects from app here.
// ...
}
- (void)signInWillDispatch:(GIDSignIn *)signIn error:(NSError *)error {
}
但任何这种委托方法是没有得到调用。
任何帮助将不胜感激。 谢谢
是的,我已经完成钥匙串共享,但仍然无法工作。 – puja
我得到 “类PLBuildVersion在/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices(0x11de34998)中实现)和/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/PhotoLibraryServices.framework/PhotoLibraryServices(0x11dc59d38)。两条之一将被使用。哪一个是未定义的。“ – puja
你在appdelegate中处理了url方案吗? – KKRocks
你配置谷歌开发者信息中心您的应用程序? –
这个问题是否发生在ios 10? – KKRocks
是, 在火力控制台我的项目是Android管理,以便在iOS设备上也将是同一个项目,但只有iOS应用应该管理我已经配置我的应用程序,但使用火力控制台,并且我已经做 – puja