Saving and Reading Bitmaps/Images from Internal memory in Android

前端 未结 7 1354
傲寒
傲寒 2020-11-22 02:59

What I want to do, is to save an image to the internal memory of the phone (Not The SD Card).

How can I do it?

I have got the image directly

7条回答
  •  爱一瞬间的悲伤
    2020-11-22 03:20

    // mutiple image retrieve

     File folPath = new File(getIntent().getStringExtra("folder_path"));
     File[] imagep = folPath.listFiles();
    
     for (int i = 0; i < imagep.length ; i++) {
         imageModelList.add(new ImageModel(imagep[i].getAbsolutePath(), Uri.parse(imagep[i].getAbsolutePath())));
     }
     imagesAdapter.notifyDataSetChanged();
    

提交回复
热议问题