Guest User

Untitled

a guest
May 22nd, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. new File(getClass.getResource("/images/sprites").getPath).listFiles()
  2.  
  3. URI uri = MainApp.class.getResource("/images/sprites").toURI();
  4. Map<String, String> env = new HashMap<>();
  5. try (FileSystem zipfs = FileSystems.newFileSystem(uri, env)) {
  6. //Path path = zipfs.getPath("/images/icons16");
  7. for (Path path : zipfs.getRootDirectories()) {
  8. Files.list(path.resolve("/images/sprites"))
  9. .forEach(p -> System.out.println("* " + p));
  10. }
  11. }
Add Comment
Please, Sign In to add comment