Düzenle

Aracılığıyla paylaş


GKLocalPlayer.AuthenticateHandler Property

Definition

Handler used to authenticate the user, triggers authentication when set.

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual Action<AppKit.NSViewController,Foundation.NSError> AuthenticateHandler { [ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)] [Foundation.Export("authenticateHandler", ObjCRuntime.ArgumentSemantic.Copy)] get; [ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 6, 0, ObjCRuntime.PlatformArchitecture.All, null)] [Foundation.Export("setAuthenticateHandler:", ObjCRuntime.ArgumentSemantic.Copy)] set; }
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 9, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual Action<AppKit.NSViewController,Foundation.NSError> AuthenticateHandler { [Foundation.Export("authenticateHandler", ObjCRuntime.ArgumentSemantic.Copy)] [ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 9, ObjCRuntime.PlatformArchitecture.All, null)] get; [Foundation.Export("setAuthenticateHandler:", ObjCRuntime.ArgumentSemantic.Copy)] [ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 9, ObjCRuntime.PlatformArchitecture.All, null)] set; }
member this.AuthenticateHandler : Action<AppKit.NSViewController, Foundation.NSError> with get, set

Property Value

This value can be null.

Attributes

Remarks

This method will be called on demand, and the scenarios are either (a) the user has not authenticated this device, so you should present the view controller that is passed as an argument to this function; (b) the user is either authenticated or not authenticated, and you should use the value of the Authenticated to determine this.

This callback can be called multiple times, for example in response to the user logging off, and another one logging in in GameCenter. Use the state in the GKLocalPlayer to determine the

Applies to