The right way to maintain an advanced multimedia database for Android a la MediaStore?

Based on the results of my query in this thread , I decided that I need to save my own metadata database for the media that I will be accessing. MediaStore seems to be a very good start for this, as it will give me a lot of information and is updated regularly by MediaScanner. In an ideal world, I would add several columns to the MediaStore database and modify MediaScanner to scan the appropriate metadata sources to update these columns (ideal for me - maybe not ideal in terms of resource allocation).

For those who understand how media is stored in Android - what are my options? Should I create my own ContentProvider database or is there a way to do something similar to adding a table to the MediaStore database (i.e. a new table with entries corresponding to each corresponding identifier and columns for each new piece of information that I would like keep )? Is there any way to ask MediaScanner to update my database when it updates a regular multimedia database, and if so it will be considered bad form (i.e. Should I wait while my application is open to update my database)? What are the best methods for something like this?

+3
source share
1 answer

Performing the same thing, so far I have decided to go not easy (I did not find anything easier): regularly synchronize my own database with the media store.

I'm struggling with genres right now . But I manage to get good results for synchronization (you still need to check the performance more hastily, though).

+1
source

Source: https://habr.com/ru/post/1770399/


All Articles