I want to write a Gradle plugin that can check the eclipse workspace directory and iterate over open projects in the workspace and locate each of them.
Something like
Workspace workspace = EclipseUtils.parseWorkspace("c:/myEclipseWorkspace"); Collection<Project> projects = workspace.getProjects(); for (Project project : projects) { System.out.println(String.format("name=%s, location=%s, open=%s", project.getName(), project.getLocation(), project.isOpen())); }
I looked at my workspace and see some .location files under c:\myEclipseWorkspace\.metadata\.plugins\org.eclipse.core.resources\.projects\
But these files are a custom binary format. 
Is there an eclipse API I can call to parse them? Or some other solution for iterating open projects in the workspace.
Please note that I want to do this from outside to outshine and NOT inside the eclipse plugin.
java eclipse parsing workspace
lance-java Nov 20 '15 at 10:04 2015-11-20 10:04
source share