edit this page - page history - about editing

Listing all files contained in an Eclipse plugin

Eclipse

Within a Plugin instance, the following code will return all files (*) within the "src" directory (and recursively):

Enumeration<?> e = getBundle().findEntries("src", "*", true);
while (e.hasMoreElements()) {
  System.out.println(e.nextElement()); // returns URLs of type bundleentry://
}

Categories: Eclipse | Code Snippets | Java
edit this page - what links to here? - page history - top
Last edited by jevon jevon 102 months ago