I have created an app with two activities
as the activities with two separate lists.
Let's call them: Activity1
and Activity2
.
With the home screen of the app called the MainActivity
.
As soon as the app is launched, the MainActivity
is created and notifications
appear in the notification bar based on the list item's statuses.
I've had a look at the lifecycle of Android but I can't understand and figure out where to load the lists and when to save the lists. Also, what is the best way to save large list data in Android to internal storage? Json? Csv?
File type basically? :)
For example, would I load both lists when the MainActivity is first created, onCreate()
. And then save the list of(for example) Activity1 when the user navigates away from Activity1, onPause()
?
To reiterate, this is what I need help on:
I've had a look at the lifecycle of Android but I can't understand and figure out where to load the lists and when to save the lists. Also, what is the best way to save large list data in Android to internal storage? Json? Csv?
File type basically? :)
Thank you for any help! :)