Android Key Value Database quickkv

Source: Internet
Author: User

Quickkv
A lightweight and easy-to-use key-value database for Android projects.

In Android development, complex maps and lists are cumbersome and time-consuming to persist and deserialize. In fact, according to Qkxue.net, it is enough to focus on the key and the value. So, Quickkv was born!

HashMap with JSON

Put data in a hashmap and save it to the local storage.
The data is placed in the HashMap and stored to the local memory.
Map<object, object> map = new Hashmap<object, object> ();
Map.put ("Key", "Value");
Jsonobject json = new Jsonobject ();
Iterator iter = Map.entryset (). Iterator ();
while (Iter.hasnext ())
{
Map.entry Entry = (map.entry) iter.next ();
Object key = Entry.getkey ();
Object value = Entry.getvalue ();
Json.put (Key.tostring (), value.tostring ());
}
FileOutputStream fos = this.openfileoutput ("Data.json", context.mode_private);
Fos.write (Json.tostring (). GetBytes ());
Fos.close ();
Load saved data from the local storage and parse it, then convert it to a HashMap are more complex.
It is more complicated to load the saved data from memory and parse and convert it into HashMap.

More Android Key Values database QUICKKV Introduction: please click here

Android Key Value Database quickkv

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.