I'm running the following code:
import org.eclipse.core.resources.IWorkspace;
import org.eclipse.core.resources.ResourcesPlugin;
public class WorkspaceTest {
public static void main(String[] args) {
IWorkspace workspace = ResourcesPlugin.getWorkspace();
}
}
and I get the following error:
Exception in thread "main" java.lang.IllegalStateException: Workspace is closed.
How can I get a reference to the workspace for a non-eclipse plugin?
(To be able to run the code here:)
http://www.ssw.uni-linz.ac.at/Teaching/Lectures/KompTech/JDT.pdf