if (!file.isFile())
throw new FileNotFoundException("The specified path is not referring to a file: " + fileAbsPath);
// set to current date/time (millis since 1/1/1970)
file.setLastModified(System.currentTimeMillis());
} else if (!file.createNewFile())
throw new IOException("Could not touch file, because creation of new file failed.");
}
/**
* Touches a file, i.e. creates it if not there, otherwise updates its last write time. Returns true if succeeded. No exception is thrown