Whats the difference between pass the variables like this:
Intent intent = new Intent(mCtx, DetailsActivity.class);
intent.putExtra("pId", id);
intent.putExtra("pType", type);
mCtx.startActivity(intent);
and using the keyword Bundle
?
Intent intent = new Intent(MainActivity.this, DetailsActivity.class);
// Now let's Pass data using Bundle
Bundle bundle = new Bundle();
bundle.putString("pId", id);
bundle.putString("pType", type;
intent.putExtras(bundle);
startActivity(intent);
Im new to Android development and I am curious to which method is better or stadard when doing android development?