-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDeeplinkingManager.swift
More file actions
32 lines (23 loc) · 906 Bytes
/
DeeplinkingManager.swift
File metadata and controls
32 lines (23 loc) · 906 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//
// DeeplinkingManager.swift
// DeepLinkingManager
//
// Created by N.A Shashank on 29/11/18.
//
import UIKit
class DeeplinkingManager:DeeplinkCredentialManagerDelegate {
static let retainedInstance = DeeplinkingManager()
var deeplinkingCredentialsManager = DeeplinkCredentialManager()
init() {
self.deeplinkingCredentialsManager.delegate = self
}
func parseDeeplink(url:URL,options:[UIApplication.OpenURLOptionsKey : Any]) {
self.deeplinkingCredentialsManager.handleSchemeWith(host: url.host, path: url.path, options: options)
}
func key(defaultValue:String) -> String {
return self.deeplinkingCredentialsManager.valueFrom(keyPath: \DeeplinkCredentialManager.key, defaultValue: defaultValue)
}
func failedToParseUrl(error: DeeplinkingError) {
assertionFailure("failed to parse url")
}
}