java - Saving hash map into SharedPreferences -


this question has answer here:

how can save , hashmap in android using below format in sharedpreference

hashmap<string, list<string>> mchildmap = new hashmap<>();     

the easiest way use google's gson save hashmap json. create wrapper class hashmap the getter , setter methods. refer below answer.

https://stackoverflow.com/a/11931812/5425930


Comments

Popular posts from this blog

ruby on rails - ActiveRecord order not working -

javascript - How do you prevent nested queries/catches in sequelize? -

java - ConcurrentModificationException upon committing transaction with Hibernate -