-3

I am implementing Universal links in my Objective-C app.

Please, help me to translate this Swift method into Objective-C:

func application(_ application: UIApplication,
                 continue userActivity: NSUserActivity,
                 restorationHandler: @escaping ([UIUserActivityRestoring]?) -> Void) -> Bool
Philalex
  • 1
  • 2

1 Answers1

3

This is a built-in method, which is documented both in Swift and Objective-C. The Obj-C function signature is

- (BOOL)application:(UIApplication *)application 
continueUserActivity:(NSUserActivity *)userActivity 
 restorationHandler:(void (^)(NSArray<id<UIUserActivityRestoring>> *restorableObjects))restorationHandler;
Dávid Pásztor
  • 51,403
  • 9
  • 85
  • 116
  • 1
    thank you, @dávid-pásztor. It solved my problem – Philalex May 11 '21 at 14:12
  • @Philalex Glad I could help. If you found my answer useful, please consider accepting it. If you're unsure how to do that, you can read [What should I do when someone answers my question?](https://stackoverflow.com/help/someone-answers). – Dávid Pásztor May 11 '21 at 14:13