This is my Activity
When the ASynkTask executes the postExcute I want to pass an array of objects to the fragment and have them load into it.
@Override
protected void onPostExecute(Receta s) {
super.onPostExecute(s);
tvNombreRecetaVer.setText(s.getNombre());
tvDescripcionRecetasVer.setText(s.getDescripcion());
tvComensalesVerReceta.setText(String.valueOf(s.getComensales()));
tvTiempoVerReceta.setText(String.valueOf(s.getTiempo()+ " min"));
tvDificultadVerReceta.setText(s.getDificultad());
Glide.with(VerRecetasActivity.this).load(s.getImagen()).into(iVImagenRecetaVer);
}
Inside
onPostExecute()
you can send the array of objects through a bundle, in this way you can load the Fragment and send the array of objects.inside the Fragment you would get the values like this: