javaeclipseeclipse-plugin

ResourcesPlugin - Is it possible to change workspace?


When launching a plugin, I have some code that calls

getWorkspace()

method of class ResourcesPlugin. This returns the current workspace. However, is it possible to specify a workspace instead?


Solution

  • Only one workspace can be loaded in Eclipse at a time. There is no facilities to gain programmatic access to another workspace. You have to restart Eclipse with that workspace to gain access to it.