e4 plug-in perspective creation [message #1063296] |
Wed, 12 June 2013 22:43 |
Ozgur Cagdas Messages: 32 Registered: May 2013 |
Member |
|
|
Hi,
I have an e4 plug-in and trying to add a perspective to it so I can switch to it after installing it to Eclipse. I added the following perspective extension to the plugin.xml file.
<extension point="org.eclipse.ui.perspectives">
<perspective
name="MyPerspective"
class="com.oz.perspective.MyPerspective"
id="com.oz.myperspective">
</perspective>
</extension>
And com.oz.perspective.MyPerspective class implements IPerspectiveFactory. Within my Application.e4xmi file there is already a Perspective Stack -> Perspective defined. So, how can I make the MyPerspective class launch the Perspective defined in the e4xmi file?
As a second question, is there a way to by pass MyPerspective class and directly point at the Perspective within e4xmi from the plugin.xml extension?
Regards,
O.
[Updated on: Fri, 14 June 2013 08:37] Report message to a moderator
|
|
|
Re: e4 plug-in perspective creation [message #1063638 is a reply to message #1063296] |
Thu, 13 June 2013 14:55 |
Ozgur Cagdas Messages: 32 Registered: May 2013 |
Member |
|
|
Hi again,
I've started with a test plugin (and a feature accompanying it) and adding the org.eclipse.ui dependency avoids the application to be launched by giving below errors.
I've also attached the the sample plugin and feature which is currently broken the way it is. If I remove the mentioned dependency and the org.eclipse.ui.perspectives entry from the plugin.xml, application launches.
So;
1- Is there a way to fix this issue and make the OzTestPerspective activate the Perspective defined under the Application.e4xmi file?
2- Can I bypass implementing the IPerspectiveFactory and 'magically' point at the Perspective within e4xmi as the perspective contribution by this plugin, so the perspective looks identical to what I see when the application is launched on its own?
Errors;
!SESSION 2013-06-13 15:38:11.542 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.7.0_09
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_GB
Framework arguments: -product org.oz.test.plugin.product -clearPersistedState
Command-line arguments: -product org.oz.test.plugin.product -data /home/ocagdas/rcp/../runtime-org.oz.test.plugin.product -dev file:/home/ocagdas/rcp/.metadata/.plugins/org.eclipse.pde.core/org.oz.test.plugin.product/dev.properties -os linux -ws gtk -arch x86_64 -consoleLog -clearPersistedState
!ENTRY org.eclipse.equinox.app 0 0 2013-06-13 15:38:13.085
!MESSAGE Product org.oz.test.plugin.product could not be found.
!ENTRY org.eclipse.osgi 2 0 2013-06-13 15:38:13.212
!MESSAGE One or more bundles are not resolved because the following root constraints are not resolved:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-06-13 15:38:13.213
!MESSAGE Bundle reference:file:/home/ocagdas/codebase/sysmon_graph/org.oz.test.plugin/ was not resolved.
!SUBENTRY 2 org.oz.test.plugin 2 0 2013-06-13 15:38:13.213
!MESSAGE Missing required bundle org.eclipse.ui_0.0.0.
!ENTRY org.eclipse.osgi 2 0 2013-06-13 15:38:13.215
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-06-13 15:38:13.216
!MESSAGE Bundle org.oz.test.plugin_1.0.0.qualifier [67] was not resolved.
!SUBENTRY 2 org.oz.test.plugin 2 0 2013-06-13 15:38:13.216
!MESSAGE Missing required bundle org.eclipse.ui_0.0.0.
!ENTRY org.eclipse.osgi 2 0 2013-06-13 15:38:13.243
!MESSAGE One or more bundles are not resolved because the following root constraints are not resolved:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-06-13 15:38:13.243
!MESSAGE Bundle reference:file:/home/ocagdas/codebase/sysmon_graph/org.oz.test.plugin/ was not resolved.
!SUBENTRY 2 org.oz.test.plugin 2 0 2013-06-13 15:38:13.244
!MESSAGE Missing required bundle org.eclipse.ui_0.0.0.
!ENTRY org.eclipse.osgi 2 0 2013-06-13 15:38:13.246
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-06-13 15:38:13.246
!MESSAGE Bundle org.oz.test.plugin_1.0.0.qualifier [67] was not resolved.
!SUBENTRY 2 org.oz.test.plugin 2 0 2013-06-13 15:38:13.247
!MESSAGE Missing required bundle org.eclipse.ui_0.0.0.
!ENTRY org.eclipse.osgi 4 0 2013-06-13 15:38:13.248
!MESSAGE Application error
!STACK 1
java.lang.RuntimeException: No application id has been found.
at org.eclipse.equinox.internal.app.EclipseAppContainer.startDefaultApp(EclipseAppContainer.java:242)
at org.eclipse.equinox.internal.app.MainApplicationLauncher.run(MainApplicationLauncher.java:29)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
gogo: CommandNotFoundException: Command not found: gosh
org.apache.felix.gogo.runtime.CommandNotFoundException: Command not found: gosh
at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:466)
at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:395)
at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)
at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)
at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
at org.apache.felix.gogo.shell.Activator.run(Activator.java:75)
at java.lang.Thread.run(Thread.java:722)
An error has occurred. See the log file
/home/ocagdas/rcp/.metadata/.plugins/org.eclipse.pde.core/org.oz.test.plugin.product/1371134291805.log.
Regards,
O.
[Updated on: Fri, 14 June 2013 08:39] Report message to a moderator
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03615 seconds