问题 I'm trying to find an easy way to map a URI to a Path without writing code specific to any particular file system. The following seems to work but requires a questionable technique: public void process(URI uri) throws IOException { try { // First try getting a path via existing file systems. (default fs) Path path = Paths.get(uri); doSomething(uri, path); } catch (FileSystemNotFoundException e) { // No existing file system, so try creating one. (jars, zips, etc.) Map<String, ?> env =