Android 系统架构组件--Room Persistence Library

Room持久化类库

官方

The Room persistence library provides an abstraction layer over SQLite to allow fluent database access while harnessing the full power of SQLite.

The library helps you create a cache of your app's data on a device that's running your app. This cache, which serves as your app's single source of truth, allows users to view a consistent copy of key information within your app, regardless of whether users have an internet connection.

To import Room into your Android project, see adding components to your project.

For a guide on applying Room's capabilities to your app's data storage persistence solution, see the Room training guide.

翻译下:

概要:Room持久化类库是为我们提供了访问一个抽象层 ,能够让我们流畅的使用数据库全部的功能

说明:这个类库能够帮助我们再运行app的设备上创建应用数据缓存。无论有没有网络连接,这个作为app数据唯一的真实来源的缓存是允许用户查看应用程序的唯一副本信息(也就是我们所说的key )

关于使用:

关于使用我就不在这里做更多讲解  直接参照完整demo中的SimpleActivity中的使用即可

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值