public static void saveImageToPath(Bitmap bitmap,String imagePath){
  try {
    File imageFile=new File(imagePath);
    FileOutputStream fos=new FileOutputStream(imageFile);
    bitmap.compress(Bitmap.CompressFormat.PNG,100,fos);
    fos.flush();
    fos.close();
  }
 catch (  IOException e) {
    Log.d(IMAGE_HELPER,e.toString());
  }
}

public static void saveImageToPath ( Bitmap bitmap , String imagePath ) { try { File imageFile = new File ( imagePath ) ; FileOutputStream fos = new FileOutputStream ( imageFile ) ; bitmap . compress ( Bitmap . CompressFormat . PNG , 100 , fos ) ; fos . flush ( ) ; fos . close ( ) ; } catch ( IOException e ) { Log . d ( IMAGE_HELPER , e . toString ( ) ) ; } }
save the bitmap to the local path
