I am creating a file explorer to synchronize an ftp directory on my phone, I would like that at each synchronization I can know which files is new, and this even after closing my app and resume at the next session. I thought of saving a Array with all my new files and compare it in the adapter to know if it has already been open or not. But for this I need to store this array somewhere, can I store it in SharedPreferences? Is it this the best way to go?
Thanks
No, you can only store boolean, int, float, long, string, and sets (not arrays, sets so no duplicate entries) of strings. If you need more than that, you need to use your own serialization method.
Shared preference docs: https://developer.android.com/reference/android/content/SharedPreferences