找回密码
 立即注册
PreferencesAndroidStringkey进阶教程 | android开发 2022-10-29 63 0star收藏 版权: . 保留作者信息 . 禁止商业使用 . 禁止修改作品
Android高手进阶教程(七)之----Android中Preferences的使用pdf,这一节讲的是AndroidPreferences的学习,Preferences在Android当中被用来记录使用,以及用户喜欢等等,它可以用来保存简单的数据类型,如Int,Double,Boolean等。Preferences中保存的数据可以理解为Map型。大家通过PreferenceManager以及getDefaultSharedPreferences(Context)来获取它,比方当大家想取得整数大家可以用getInt(Stringkey,intdefVal).获取里边的某个键值,当大家想修复时候大家用putInt(Stringkey,intnewVal),最后用edit(),方法提交!千万不要忘记了哦~本资料共包括以下附件:
codefans\Android高手进阶教程(七)之----Android中Preferences的使用.pdf
.....

(Advanced tutorial for Android experts (7) -- The use of Android Preferences pdf. This section is about learning Android Preferences. Preferences are used to record usage and user Preferences in Android. It can be used to save simple data types, such as Int, Double, Boolean, etc. The data saved in Preferences can be interpreted as Map type. You can get it through the PreferenceManager and getDefaultSharedPreferences (Context). For example, if you want to get an integer, you can use getInt (Stringkey, intdefVal) Get a key value inside. When you want to repair it, you can use putInt (Stringkey, intnewVal), and finally use edit () to submit! Don't forget the following attachments:
Codefins  Advanced Course for Android Masters (7) -- Use of Preferences in Android. pdf
.....)

[下载]14333011977.rar




上一篇:使用MenuInflater布局定义Android菜单
下一篇:android2.2源码编译