imageio read returns null
952145Jul 27 2012 — edited Jul 27 2012I have a program that reads an image from inside a jar (buillt dynamically in code) using ImageIO.read(URL);
This works fine and I can read the image as many times as I like. However, if I rebuild the jar in code and try to read the image of the same name a second time the read returns null without throwing any Exceptions.
It's as if java has cached the stream to the original file even though I have created a new URL.
Any ideas anyone?