views:

26

answers:

2

Hi I want to create a Eclipse Plugin which search in all open projects/EFS for a specific file. The first aproach was, to walk over the full filesystemtree, what is not very fast.

Now I want to reuse the mechanism behind the "Open Resource" Dialog (CTRL+SHIFT+R) ~ OpenResourceDialog . But how it is possible to access the mechanism/fileindex?

Is there something like the following?

List<IFileStore> result = eclipseIndex.search("myConfig.xml", monitor);
+1  A: 

Maybe this post will help.

VinAy
A: 
ResourcesPlugin.getWorkspace().getRoot().accept(new IResourceProxyVisitor() {
    @Override
    public boolean visit(IResourceProxy proxy) throws CoreException {
        return true;
    }
}, IResource.FILE);
01