Package com.zendesk.sdk.deeplinking
Class ZendeskDeepLinkingParser
- java.lang.Object
-
- com.zendesk.sdk.deeplinking.ZendeskDeepLinkingParser
-
public class ZendeskDeepLinkingParser extends java.lang.Object
Helper class for parsing links and resolving them into anIntent
-
-
Constructor Summary
Constructors Constructor and Description ZendeskDeepLinkingParser()
This constructor initialise the following parsers in the shown order: HelpCenterParser MailParser HttpParser DefaultParser The order parsers were added defines the order urls get processed.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description Intent
parse(java.lang.String url, Context context)
Resolve the providedurl
into anIntent
.
-
-
-
Method Detail
-
parse
public Intent parse(java.lang.String url, Context context)
Resolve the providedurl
into anIntent
.At the moment the following urls are supported:
- Zendesk HelpCenter link
https://mxssl98.zd-master.com/hc/en-us/articles/123123-Test-article
- Mailto links
mailto:test@example.com
- Web Urls
http://www.zendesk.com
The list above also shows the order in that the urls were handled. Urls that are provided by calling
#parse(String, Context)
will firstly checked if they are a HC Url, secondly if they're amailto:...
link, and so on.If this util isn't able to resolve the Url it will return an
Intent
with the provided url set asdata
andIntent#ACTION_VIEW
set asaction
.This util won't check if the returned
Intent
is resolvable.- Parameters:
url
- An url asString
context
- A valid context- Returns:
- The resolved
Intent
ornull
if one of the arguments isnull
- Zendesk HelpCenter link
-
-