集成 xamarin、CouchBaseLite、MVVMCross 和 SyncGateway,View 随数据库变化

Integrating xamarin, CouchBaseLite, MVVMCross and SyncGateway such that View changes with database

我正在做一个 xamarin 项目,我使用 CouchBase Lite 作为我的本地数据库。我也想使用 MVVMCross 库。任何人都可以指定我应该在哪里包含 couchbase-Lite 库,MVVMCross - 热金枪鱼库(如 class 库或便携式 class 库或平台特定项目),以便通知视图模型有关 Couchdatabase 中的更改。

基本上我想在数据库发生变化时更改视图我想用 mvvmcross 更改视图。我正在使用 syncgateway 与服务器 Couchbase 存储桶同步。

我是 Xamarin、MVVM 和 CouchBaselite 的新手。 我找不到所有这一切的具体例子。

提前致谢。

我可能会使用 CouchBaseLite Xamarin Component. If you are wanting to access this in your PCL Core project you will probably have to create some sort of wrapper around the component and inject it properly into each platform. You can use the MvvmCross plugins wiki 来帮助您入门。

我知道这是一个旧线程,但是 Couchbase 有一个新的 MvvmCross 插件,基本上可以满足您的所有需求。在 Nuget 上撰写本文时,它处于 alpha 阶段,并在 Github 上开源。我实际上也在寻找同样的东西,很高兴找到了它! :)

https://www.nuget.org/packages/MvvX.Plugins.CouchBaseLite.ForestDB

https://github.com/mathieumack/MvvX.CouchBaseLite