ArcGIS Runtime SDK for iOS: <AGSAuthenticationManagerDelegate> Protocol Reference
ArcGIS Runtime SDK for iOS  100.15
<AGSAuthenticationManagerDelegate> Protocol Reference

Description

A delegate for AGSAuthenticationManager.

A protocol which must be adopted by a class wishing to be notified of authentication challenges issued or handled by the AGSAuthenticationManager. An instance of the class must then be set as AGSAuthenticationManager::delegate .

All of the methods of this protocol are optional.

Since
100

Instance Methods

(void) - authenticationManager:didReceiveAuthenticationChallenge:
 
(void) - authenticationManager:wantsToDismissViewController:
 
(void) - authenticationManager:wantsToShowViewController:
 

Method Documentation

◆ authenticationManager:didReceiveAuthenticationChallenge:

- (void) authenticationManager: (AGSAuthenticationManager *)  authenticationManager
didReceiveAuthenticationChallenge: (AGSAuthenticationChallenge *)  challenge 
optional

Tells the delegate that the AGSAuthenticationManager received an authentication challenge. It then becomes the delegate's responsibility to handle the challenge.

If this method is not implemented by the delegate, the authentication manager will try to resolve the challenge using its own default challenge handler instead.

Since
100

◆ authenticationManager:wantsToDismissViewController:

- (void) authenticationManager: (AGSAuthenticationManager *)  authenticationManager
wantsToDismissViewController: (UIViewController *)  viewController 
optional

Tells the delegate that the AGSAuthenticationManager wants to dismiss the provided view controller as part of handling the authentication challenge using its own default handler. This method is optional, but if you want to dismiss view controller in different way than the standard modal way, then you need to implement this method. Currently, this method is called only while displaying the OAuth login page. All other prompts are being displayed in standard alert which is always presented and dismissed modally.

If this method is not implemented by the delegate, the authentication manager will dismiss the view controller.

Since
100
Deprecated:
100.11. The ASWebAuthenticationSession is used instead of SFSafariViewController for out-of-app authentication workflow and view controller is dismissed by ASWebAuthenticationSession.

◆ authenticationManager:wantsToShowViewController:

- (void) authenticationManager: (AGSAuthenticationManager *)  authenticationManager
wantsToShowViewController: (UIViewController *)  viewController 
optional

Tells the delegate that the AGSAuthenticationManager wants to show the provided view controller as part of handling the authentication challenge using its own default handler. This method is optional, but if you want to show view controller in different way than the standard modal way, then you need to implement this method. Currently, this method is called only while displaying the OAuth login page. All other prompts are being displayed in standard alert which is always presented and dismissed modally.

If this method is not implemented by the delegate, the authentication manager will present the view controller.

Since
100
Deprecated:
100.11. The ASWebAuthenticationSession is used instead of SFSafariViewController for out-of-app authentication workflow and view controller is presented by ASWebAuthenticationSession.