Instance Method

application:handleOpenURL:

Asks the delegate to open a resource identified by URL.

Declaration

- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url;

Parameters

application

Your singleton app object.

url

A object representing a URL (Universal Resource Locator). See the appendix of App Programming Guide for iOS for Apple-registered schemes for URLs.

Return Value

YES if the delegate successfully handled the request; NO if the attempt to handle the URL failed.

Discussion

If the delegate also implements the application:openURL:sourceApplication:annotation: method, that method is called instead of this one.

This method is not called if the delegate returns NO from both the application:willFinishLaunchingWithOptions: and application:didFinishLaunchingWithOptions: methods. (If only one of the two methods is implemented, its return value determines whether this method is called.) If your app implements the applicationDidFinishLaunching: method instead of application:didFinishLaunchingWithOptions:, this method is called to open the specified URL after the app has been initialized.

If a URL arrives while your app is suspended or running in the background, the system moves your app to the foreground prior to calling this method.

There is no equivalent notification for this delegation method.

See Also

Deprecated Symbols

- application:didRegisterUserNotificationSettings:

Called to tell the delegate the types of local and remote notifications that can be used to get the user’s attention.

Deprecated
- application:didReceiveLocalNotification:

Sent to the delegate when a running app receives a local notification.

Deprecated
- application:didReceiveRemoteNotification:

Called when your app has received a remote notification.

Deprecated
- application:handleActionWithIdentifier:forLocalNotification:completionHandler:

Called when your app has been activated because user selected a custom action from the alert panel of a local notification.

Deprecated
- application:handleActionWithIdentifier:forLocalNotification:withResponseInfo:completionHandler:

Called when your app has been activated by the user selecting an action from a local notification.

Deprecated
- application:handleActionWithIdentifier:forRemoteNotification:completionHandler:

Tells the app delegate to perform the custom action specified by a remote notification.

Deprecated
- application:handleActionWithIdentifier:forRemoteNotification:withResponseInfo:completionHandler:

Called when your app has been activated by the user selecting an action from a remote notification.

Deprecated
- application:openURL:sourceApplication:annotation:

Asks the delegate to open a resource identified by a URL.

Deprecated