Erro nesse codigo, nao compila
ImageView imagem = viewCriada.findViewById(R.id.item_imageview_foto);
Resources resources = context.getResources();
Resources.Theme theme = new ListaDePacotes().getTheme();
int idDoDrawable = resources.getIdentifier(pacote.getImagem()
, "drawable", context.getPackageName());
Drawable drawableImagemPacote = ResourcesCompat.getDrawable(resources, idDoDrawable, theme);
imagem.setImageDrawable(drawableImagemPacote);
Assim tambem nao
ImageView imagem = viewCriada.findViewById(R.id.item_imageview_foto);
Resources resources = context.getResources();
// Resources.Theme theme = new ListaDePacotes().getTheme();
int idDoDrawable = resources.getIdentifier(pacote.getImagem()
, "drawable", context.getPackageName());
Drawable drawableImagemPacote = ResourcesCompat.getDrawable(resources, idDoDrawable, null);
imagem.setImageDrawable(drawableImagemPacote);