I am creating a media player app where users can play a list of songs from either their local library or remotely. I have stored the songs they would obtain from either location in an Arraylist of songs object. What I want is to allow users the ability to save a list of songs as their playlist in Share Preference and be able to add more playlist to existing playlist. How to I achieve this, thank you.
store list [
playlist: {
id: 1,
name: My Playlist,
songs:
[
{ name: 'Song 1', album: 'Album', ...}
{ name: 'Song 2', album: 'Album', ...}
{ name: 'Song 3', album: 'Album', ...}
]
},
playlist: {
id: 2,
name: My Playlist Two,
songs:
[
{ name: 'Song 1', album: 'Album', ...}
{ name: 'Song 2', album: 'Album', ...}
{ name: 'Song 3', album: 'Album', ...}
]
}
]