Write the given image to the given file.
Parameters: image - The screen image to write to disk. Parameters: file - The File to save the image as. exception: IOException - thrown if there was a problem saving the image tothe file. exception: IllegalArgumentException - if any parameter is null. exception: IllegalStateException - if no appropriate writer could be found.