I'm taking the developing android app's course on udacity.
I was wondering if I am right in an alternative solution for Lesson5: Handle List Item Click.
the challenge when we have 2 panels and we clicked an item from the List, Uri should pass directly to DetailFragment from MainActivity without calling DetailActivity
I've seen that the official solution is: use Bundle and pass it as argument in fragment.setArguments(args);
But instead of above Why not create a public method?, I tried with creating a public method such as setmUri(Uri uri) to set member variable mUri in DetailFragment and then call it from MainActivity, and this worked well
But my final question is: What are the pro's on passing variables using Bundle instead of publics methods for this particular case?
thanks a lot.