1. 首页
  2. 移动开发
  3. 其他
  4. Android代码 SharedPreferences实用工具类可直接保存与读取实例对象SharedPreferences中的ORM

Android代码 SharedPreferences实用工具类可直接保存与读取实例对象SharedPreferences中的ORM

上传者: 2020-07-18 18:25:11上传 ZIP文件 111.9KB 热度 24次
一个SharedPreferences工具类 在工程根目录build.gradle添加jitpack: allprojects { repositories { maven { url "https://jitpack.io" } } } 在使用AnyPref的模块中添加: dependencies { compile 'com.github.NashLegend:AnyPref:1.2.6' } 在应用的Application的onCreate()中添加如下代码(主要是为了省却后面要传入Context参数的麻烦) AnyPref.init(t
下载地址
用户评论