• 2021-04-14
    当在Activity中使用时,可以直接使用this.getSharedPreferences(),并且this可以省略。反之,则需要传入一个Context对象获取上下文,即context. getSharedPreferences()。( )