I have the following code which handles files upload on the server. But how to save the file to a specific location on the server
import gwtupload.server
You should use File#createTempFile() which takes a directory instead.
File file = File.createTempFile("upload-", ".bin", new File("/path/to/your/uploads"));
item.write(file);
Or if you actually want to move the temp file to another location afterwards, use File#renameTo().
File destination = new File("/path/to/your/uploads", file.getName());
file.renameTo(destination);
In your java application, you can create file with giving specific path.
Like; "new File("c:/files/filename)" etc.
See Java Documents to learn about New IO package's Files class' createFile method.