Skip to content

Instantly share code, notes, and snippets.

@raystatic
Created July 9, 2022 20:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save raystatic/fd679e94b03d9bff08c771521fcb3e2b to your computer and use it in GitHub Desktop.
Save raystatic/fd679e94b03d9bff08c771521fcb3e2b to your computer and use it in GitHub Desktop.
@Singleton
class Feature01DeeplinkProcessor @Inject constructor(
private val context: Context
) : DeeplinkProcessor {
override fun matches(deeplink: String): Boolean {
return deeplink.contains("/feat01")
}
override fun execute(deeplink: String) {
val intent = Intent(context, Feature01Activity::class.java)
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
context.startActivity(intent)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment