Xamarin 的 GCM 到 FCM [英] GCM to FCM for Xamarin

查看:21
本文介绍了Xamarin 的 GCM 到 FCM的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Xamarin 具有对 GCM(Google 云消息传递)的预定义支持,这在 中进行了解释https://developer.xamarin.com/guides/cross-platform/application_fundamentals/notifications/android/remote_notifications_in_android/

Xamarin has the predefined support to GCM (Google Cloud Messaging) which was explained in https://developer.xamarin.com/guides/cross-platform/application_fundamentals/notifications/android/remote_notifications_in_android/

由于目前 Google 从 GCM 迁移到 FCM(Firebase Cloud Messaging),它是否可以使用相同的指令与 Xamarin 一起使用,或者是否有任何其他文档可以将 FCM 与 Xamarin 集成?

As currently Google migrated from GCM to FCM (Firebase Cloud Messaging) does it work with Xamarin with same instruction or there any other Docs for integrating FCM with Xamarin?

Firebase 中提供的所有功能是否都可以在 Xamarin 应用中使用?

Does all features provided in Firebase can be used in Xamarin App?

推荐答案

它是否适用于具有相同指令的 Xamarin?

does it work with Xamarin with same instruction?

不,没有.但是您仍然可以使用 GCM,因为 Google 尚未宣布 GCM 支持将停止.他们刚刚发布了 FCM 是 GCM 的最新版本.

No, it doesn't. But you can still work with GCM since Google hasn't announced that GCM support will stop just now. They just posted that FCM is the newest version of GCM.

是否还有其他文档可以将 FCM 与 Xamarin 集成?

there any other Docs for integrating FCM with Xamarin?

不仅如此,Xamarin 还没有关于如何将 FCM 与 Xamarin.Android 应用程序集成的指南.

Not just yet, Xamarin doesn't have a guide about how to integrate FCM with your Xamarin.Android app.

Firebase 中提供的所有功能是否都可以在 Xamarin 应用中使用?

Does all features provided in Firebase can be used in Xamarin App?

是的,它们可以与 Xamarin 一起使用.但此时我们必须等到 Xamarin 为我们提供 FCM java 库(jar)的官方绑定(dll),他们可能会在 他们的博客 关于如何将其与我们的应用程序集成.

Yes, they can be used with Xamarin. But at this moment we have to wait until Xamarin provides us with official bindings(dlls) for FCM java libraries(jars) and probably they will post something in their blog about how to integrate this with our apps.

此时,使用 Xamarin 进行开发时可以做的最好的事情是使用 GCM.您可以做的另一件事是创建您的自己的绑定 使用 FCM java 库 并使用 Google 的 android 教程(在 Java 中)

At this point, the best thing you can do while developing with Xamarin is use GCM. The other thing you can do, is create your own bindings with FCM java libraries and use Google's tutorial for android (in java)

虽然最后一个选项可能会起作用,但当正式的 Xamarin 绑定出现时,您将不得不更改大量代码,以使其与来自 Google 和 Xamarin 的即将发布的更新兼容.

While the last option will probably work, when the official Xamarin bindings come you will have to change a lot of code in order to make it work with upcoming updates from Google and Xamarin.

正如@SørenBoisen 所指出的,Xamarin 已开始通过 nugget 推出官方(预发布)绑定:https://www.nuget.org/packages/Xamarin.Firebase.Common/

as pointed out by @SørenBoisen Xamarin has started to rollout official(pre-release) bindings via nugget: https://www.nuget.org/packages/Xamarin.Firebase.Common/

更多信息,请访问:对 Google Firebase 的支持 — Xamarin 论坛

这篇关于Xamarin 的 GCM 到 FCM的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆