Changed provider to use mime-types and lookup tables.
Moved internal structure away from static KIND values to
using mime-type strings. This offers exact resolution of
getType() and saves us from using magic numbers across
the platform.
We store a mime-type for each row, allocating them in an
internal lookup table with in-memory cache. We also added
the same lookup table approach for storing package names.
Tested by creating dozens of random contacts and various
data types under each of them, including common types like
phone and E-mail, and a custom "profile" type. Verified
that the internal mime-type allocation and caching service
worked as expected.
Also did some random cleanup by moving table and field
names into static variables to help prevent typo errors.
4 files changed