mardi 15 décembre 2015

How to storage user infos. ArrayList or Database?

Hi guys i'm building an app where the user can annotate the film that have seen, to see, buyed or to buy. The layout is compose whit a pageView with 4 tabs "Buy" - "To Buy" - "Seen" - "To see". Now my doubt is how to save the annotation about the film taht the user have seen, bougth or that have to see or to buy. I Identified 2 methods

The First with 4 ArrayList that populate the 4 ListView.

The second method exploits the app DataBase. In teh app there is a littel DataBase with a lot of film. User can choose a film of the DataBAse to add. I can do that when the user will add a film in a specifc area (Seen - To See - Buyed - to buy) the database will be update adding a new value at the film that the user have choose. The specific listView will be populated only with the film that have the same value. Ad example the user will add Star Wars 7 in the Are "Film to see". When she choose it in the database the column "Value" of the row StarWars is update with the value "To See" (At defult the value is null). Finally the listView serch in the DataBase all the films that have the value column like as "To see" and so add Star Wars 7.

Personally i prefer the second method but i would know the opinion of more expert user. Wich method should i use?

Aucun commentaire:

Enregistrer un commentaire