Zip file system provider only works with default file system
mik3hall at gmail.com
Sat Dec 8 12:18:15 PST 2012
It's a demo.
Couldn't you just temporarily put your own ZipFileSystem in classpath some place before the default version jar?
With something like…
// Creates a new empty temporary file in the same directory as the
// specified file. A variant of File.createTempFile.
private Path createTempFileInSameDirectoryAs(Path path)
Path parent = path.toAbsolutePath().getParent();
Path tmpPath = Files.createTempFile(dir,"zipfstmp", null);
Assumes it'll use the correct FileSystem as the parameter's Path all the way through, I haven't tested it at all.
Not sure if there are any complications with a com.sun class. You could change the demo package.
Are you just trying this out or do you intend to use the demo code in something production?
trz nio.2 for OS X http://www195.pair.com/mik3hall/index.html#trz
HalfPipe Java 6/7 shell app http://www195.pair.com/mik3hall/index.html#halfpipe
AppConverter convert Apple jvm to openjdk apps http://www195.pair.com/mik3hall/index.html#appconverter
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the nio-dev