实施会议室数据库(Android) [英] Implementing the Room Database (Android)

查看:172
本文介绍了实施会议室数据库(Android)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道如何在Android应用程序中正确集成Room Library.我见过的一些文章使用Singleton方法,将资源库用于数据库调用,而另一些则使用某种形式的Dependecy Injection(匕首2).我想知道这个库的正确集成吗?

I like to know how to properly integrate the Room Library within an Android Application. Some articles I have seen uses a Singleton approach using a Respository for database calls, while other uses some form of Dependecy Injection (Dagger 2). I like to know the proper integration of this library?

谢谢

推荐答案

我认为最好的地方是codelabs,它具有

I think the best place is codelabs, it has a simple implementation, as well as a more complex one. All using Room.

这篇关于实施会议室数据库(Android)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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