public static void touch(Path file) throws IOException {
        Objects.requireNonNull(file, "file is null");
        if (Files.exists(file)) {
            if (!Files.isRegularFile(file)) {
                throw new RuntimeException(String.format("File %s is not a regular file",
                        FileUtil.getCanonicalPath(file)));
            }
            Files.setLastModifiedTime(file, FileTime.from(Instant.now()));
        } else {
            Files.createFile(file);
        }
    }
Similar to the unix touch command. Sets the last modified time to now if the file
exists else, creates the file

@throws IOException
stroom-util/src/main/java/stroom/util/io/FileUtil.java