As "Stijn de Witt" said in the comments of "haventchecked"'s answer, the solution based on Runtime.getRuntime()
doesn't work with UNC paths, and with paths containing consecutive spaces. Here is the solution that also works with these special paths:
new ProcessBuilder("rundll32", "url.dll,FileProtocolHandler", path).start();