I\'m trying to remove metadata from a .jpg file and replace it with nothing. Can anyone provide an example of how I might do this?
Metadata isn't read when you read in the image. So just read it in and write it back.
BufferedImage image = ImageIO.read(new File("image.jpg")); ImageIO.write(image, "jpg", new File("image.jpg"));