What are you replacing it all with. That looks like a finished example.
The function must be called with a File object. since
getBytesFromFile(File file)
declares the argument as a File object named "file". I think when you create a new file object you just call the File constructor with a string containing the path to the file.
I would use the header java.io.*, unless you are wanting to go for efficiency than only use what you need and call java.io.File.