direct process output to console view [message #534100] |
Tue, 18 May 2010 03:17 |
James Messages: 2 Registered: May 2010 |
Junior Member |
|
|
It is a common question, but I can't work out after searching a long time on Google.
Here http:// wiki.eclipse.org/Eclipse_Plug-in_Development_FAQ#How_do_I_in voke_a_process_and_have_its_output_managed_by_the_.27Console .27_view.3F
In my ILaunchConfigurationDelegate implementation,
Process p = DebugPlugin.exec(..........................);
IProcess process = DebugPlugin.newProcess(launch, p, "My Process");
Now, how can I capture the output of Process p?
Any comments are appreciated.
And here http:// wiki.eclipse.org/FAQ_How_do_I_write_to_the_console_from_a_pl ug-in_%3F
says how to write to the console, But It seems a little different of capture output from another process
Anybody help me, it is my priority of work. Thanks, thanks, thanks!!
[Updated on: Tue, 18 May 2010 03:20] Report message to a moderator
|
|
|
Re: direct process output to console view [message #534103 is a reply to message #534100] |
Tue, 18 May 2010 04:13 |
David Wegener Messages: 1445 Registered: July 2009 |
Senior Member |
|
|
On Mon, 2010-05-17 at 23:17 -0400, James wrote:
> It is a common question, but I can't work out after searching a long time on Google.
>
> Here http://wiki.eclipse.org/Eclipse_Plug-in_Development_FAQ#How_ do_I_invoke_a_process_and_have_its_output_managed_by_the_.27 Console.27_view.3F
>
> In my ILaunchConfigurationDelegate implementation,
>
> Process p = DebugPlugin.exec(..........................);
> IProcess process = DebugPlugin.newProcess(launch, p, "My Process");
>
>
> Now, how can I capture the output of Process p?
> Any comments are appreciated.
>
> And here http://wiki.eclipse.org/FAQ_How_do_I_write_to_the_console_fr om_a_plug-in_%3F
> says how to write to the console, But It seems a little different of capture output from another process
>
> Anybody help me, it is my priority of work. Thanks, thanks, thanks!!
Have you looked at the Java Doc for the IProcess.getStreamsProxy method?
You can use the IStreamProxy to get access to the streams and their
data.
|
|
|
Powered by
FUDForum. Page generated in 0.03376 seconds