p2 doesn't currently have any API. About the best you can do at the moment 
is to invoke the p2 command that opens the install dialog. This command 
has id "org.eclipse.equinox.p2.ui.sdk.update".  You can hook this command 
to a menu from your plugin.xml, or you can invoke the command 
programmatically with code something like this:

                ICommandService commandService = (ICommandService) 
PlatformUI.getWorkbench().getService(ICommandService.class);
                IHandlerService handlerService = (IHandlerService) 
PlatformUI.getWorkbench().getService(IHandlerService.class);
                Command cmd = 
commandService.getCommand("org.eclipse.equinox.p2.ui.sdk.update");
                ExecutionEvent executionEvent = 
handlerService.createExecutionEvent(cmd, null);
                cmd.executeWithChecks(executionEvent);

HTH,
John




"Matthias Luebken" <[EMAIL PROTECTED]> 
Sent by: [EMAIL PROTECTED]
04/14/2008 02:43 PM
Please respond to
Equinox development mailing list <[email protected]>


To
[email protected]
cc

Subject
[equinox-dev] Small RCP example with p2






Hi

I'm trying to put together a small p2 example: An RCP-App that
triggers an update action and updates a plugin from an update site.
My first question: Is there something like
"UpdateManagerUI.openInstaller()" for p2?
My second: How would a minimal p2-update site look like?

Thanks in advance.
Matthias

-- 
blog: luebken.com
_______________________________________________
equinox-dev mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/equinox-dev

_______________________________________________
equinox-dev mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/equinox-dev

Reply via email to