How to setup a ProcessFactory? [message #1414617] |
Sun, 31 August 2014 22:53 |
|
It's my first time here, and i'm trying to create my first "really usefull" plugin.
I'm making a plugin that requires to setup a ProcessFactory for creating the IProcess to be launch.
I wrote the entry in plugin.xml, as well as the IProcessFactory.
Now, I figured out that I need the LaunchConfigurationInfo to include the attribute:
process_factory_id=my.process.factory.id
I tried to change the attributes of existing LaunchConfiguration at the start of my plugin, but didn't managed to make it... the interface doesn't give me any way to change the content of the attributes, and i cannot access the implementation methods, due to OSGI per-bundle classloader (and using the implementation is a bad idea anyway...)
How can i make the LaunchConfiguration being created with my custom attributes?
In the help page about ProcessFactory, the only clue they give is the last sentence:
"It is the responsibility of the registering plug-in to store the process factory id in the proper launch configuration attribute."
But... how??
|
|
|
Re: How to setup a ProcessFactory? [message #1414874 is a reply to message #1414617] |
Mon, 01 September 2014 13:45 |
|
Nevermind, finally got the official answer.
Before posting my question, i read the entire javadoc about org.eclipse.debug, and the one related to java in org.eclipse.jdt.debug.
The answer where elsewhere, in the Eclipse Debug Project articles "We Have Lift-off: The Launching Framework in Eclipse"
ILaunchConfiguration source = ...;
ILaunchConfigurationWorkingCopy workingCopy = source.getWorkingCopy();
workingCopy.setAttribute(
DebugPlugin.ATTR_PROCESS_FACTORY_ID,
"org.jslain.eclipse.stackfilter.process_factory_id");
workingCopy.doSave();
|
|
|
Powered by
FUDForum. Page generated in 0.02714 seconds