eclipse-plugin

Eclipse plugin: how to read the “settings.xml” file path which is configured in M2Eclipse plugin

廉价感情. 提交于 2019-12-25 08:00:14
问题 Now I'm developing a new Eclipse plugin, in this plugin I need to get the settings.xml file which is configured in m2Eclipse plugin and update it. I want to know whether the m2eclipse plugin has provided the related extension point so that I can use directly. I've researched its user guide and the website, I cannot find any useful information for resolving my problem. P.s: I'm not saying how to configure the settings.xml in maven plugin but developing a new plugin to read the settings.xml in

Diff two methods in eclipse

隐身守侯 提交于 2019-12-25 07:59:15
问题 I have an eclipse which generates java code. So if a method is there and is regenerated I want to show the old method and the newly generated one so the user can see the difference. Is this possible? 回答1: If your code generator is the one used by default by EMF, you can copy the generated method, and remove the @generated tag to the original one, then simply suffix the copied generated method with Gen and keep the @generated tag. For instance : /* original code */ public String getName() { ..

Eclipse: checkstyle violations icon decoration

倖福魔咒の 提交于 2019-12-25 07:58:56
问题 Although I find the Checkstyle plugin for Eclipse very useful, I find the way they highlight violation too much. I stripped out the yellow background and the overview ruler, but I haven't figured out the following: When there are Checkstyle violations, the files containing them appear in the Project Explorer with the same decoration icon as when they have compiler warnings ( ). All my classes appear infested with warnings, and I can't tell which of them are compiler warnings. The only way I

How to get the active package path in eclipse workspace

一个人想着一个人 提交于 2019-12-25 07:33:58
问题 Im not sure whether it is the right question because i m not able to get the absolute path of the folder which i have selected in eclipse. The following is the code i wrote , can anyone tell me what is missing ? IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow(); if (window != null) { IStructuredSelection selection = (IStructuredSelection) window.getSelectionService().getSelection(); Object firstElement = selection.getFirstElement(); if (firstElement instanceof

Equinox OSGi activating two versions of the same bundle

*爱你&永不变心* 提交于 2019-12-25 06:55:18
问题 I am looking for settung up my RCP and install all of the available applications on it. However; these applications have many internal and external dependencies such as. A -> B [1.0.0, 2.0.0) C -> B [2.0.0, 3.0.0) As a result in order to have both A and C installed on my RCP, I need both versions of B available and running. Assuming that B is not a singleton, what is the behavior of Equinox OSGI? In some places I read that OSGI will catch the latest version and loads that bundle. However, I

Eclipse RCP: How can I bold a folder in Project Explorer?

喜欢而已 提交于 2019-12-25 06:47:47
问题 How can I (programmatically) bold a folder\file in Project Explorer in Eclipse? Just like Visual Studio, which bolds the start-up project: 回答1: Use Resource Decorator Plug-in. You can control the foreground and background color of resources but cannot make them bold . Also Check these posts How can I configure the font size for the tree item in the package explorer in Eclipse? and I cannot change the font size of package explorer in Eclipse choose whichever solution you need. 来源: https:/

Uninstall bundles and force a refresh

拜拜、爱过 提交于 2019-12-25 05:21:13
问题 I have an Eclipse plugin and want to stop, uninstall bundles from the Eclipse instance and then refresh. Stop and uninstall is no problem, but the refresh part of the code is now deprecated and I want to find an alternative. Currently I'm doing this through org.osgi.service.packageadmin . Documentation points to org.osgi.framework.wiring package. And from the JavaDoc org.osgi.framework.wiring.FrameworkWiring.refreshBundles(..) seems to be exactly what I want. But the only class that

Uninstall bundles and force a refresh

余生颓废 提交于 2019-12-25 05:20:18
问题 I have an Eclipse plugin and want to stop, uninstall bundles from the Eclipse instance and then refresh. Stop and uninstall is no problem, but the refresh part of the code is now deprecated and I want to find an alternative. Currently I'm doing this through org.osgi.service.packageadmin . Documentation points to org.osgi.framework.wiring package. And from the JavaDoc org.osgi.framework.wiring.FrameworkWiring.refreshBundles(..) seems to be exactly what I want. But the only class that

How can I get syntax highlighting for my format in an Eclipse text editor?

橙三吉。 提交于 2019-12-25 04:58:45
问题 I need syntax highlighting for text with a specific structure in an Eclipse text editor. The scheme is simple; basically each line has six words separated by white-space, and lines starting with # are comments. Most important is to highlight the comments, but it would be useful to individually color the six elements in the non-commented lines. If it is too complicated to obtain, perhaps I could use an existing plugin meant for something with a similar syntax. Any suggestions? 回答1: If you want

GWT Designer not working with Eclipse 4.2 service release 2?

前提是你 提交于 2019-12-25 04:54:04
问题 I'm trying to do this tutorial after having installed Eclipse Juno 4.2 service release 2 (Java EE distribution) und following exactly the GWT installation instructions over here. However, I neither get the WindowBuilder entry under Preferences, nor is there a WindowBuilder entry in the new projects dialog appearing. What am I doing wrong? I'm running Ubuntu 12.04.02 LTS on amd64, and I have tried oracle jdk 7u17 and Ubuntu's own jdk6 distribution, but to no avail... Just tried the same in