Good Morning,
I am reviewing how to implement Dynamic Links in an Xamarin Forms application but I can't find a way to translate the implementation that Google offers on its website to the Xamarin code.
To carry out the implementation on android, I added the Xamarin.Firebase.Dynamic.Links plugin, the intent was created with the Host URL correctly, but according to google we must add:
FirebaseDynamicLinks.getInstance()
.getDynamicLink(getIntent())
.addOnSuccessListener(this, new OnSuccessListener() {
@Override
public void onSuccess(PendingDynamicLinkData pendingDynamicLinkData) {
// Get deep link from result (may be null if no link is found)
Uri deepLink = null;
if (pendingDynamicLinkData != null) {
deepLink = pendingDynamicLinkData.getLink();
}
// Handle the deep link. For example, open the linked
// content, or apply promotional credit to the user's
// account.
// ...
// ...
}
})
.addOnFailureListener(this, new OnFailureListener() {
@Override
public void onFailure(@NonNull Exception e) {
Log.w(TAG, "getDynamicLink:onFailure", e);
}
});
The problem I find is when creating the AddOnSuccessListener methods since I cannot find the OnSuccessListener implementation method.
could someone assure me if Dynamic links can be integrated into xamarin forms? I have the feeling of wasting time with this and then arrive and that the implementation cannot be carried out ...
Many thanks.