Community
Participate
Working Groups
Currently the VE project provides a 'Java Bean' launcher which extends the Java Launch configuration UI to provide customization for Java Beans. This requires the usage of internal API to create a tab pane etc. It would be great if there could be some public way of extending the Java launch configuration UI.
What are you extending? I.e. which class(es)?
We are subclassing or using: JavaLaunchConfigurationTab - It provides good base function for java launch tabs. JavaLaunchConfigurationUtil - It provides good utils, such as getMainType or findType that are very useful for java launch pages.
In my case, i don't want to create a new type of launch configuration, just extend the capabilities of existing ones. Is that covered by this pr? I was expecting something like two extension points. One for registering new configuration tabs and one for adding some kind of launch configuration processor. The launch configuration processor would be asked to generate a list of program and VM arguments from an ILaunchConfiguration.
Response to comment#3. The extensibility of launch configs is as follows: * you can contribute a launch delegate for a launch mode of an existing config type (for example, a profile launch delegate for the Java application launch config) * you can contribute extra tabs for a specific launch modde (for example, extra profiler tabs) You cannot override the function of an exisiting launcher - you need to provide a new launch type. You can subclass our existing java launcher, which is API: JavaLaunchDelegate.
Response to comment#2. * We can't really open the JavaLaunchConfigurationTab without opening up IEntriesChangedListener (which is not something we want to commit to currently). * Looking at JavaLaunchConfigurationUtils, I'd like to remove the methods we no longer use internally (it turns out, the only method we're using is serializeDocument). The rest can be removed, as we no longer use them.
For now, I've removed the unused code and deleted JavaLaunchConfigurationUtil. Moved the "serialzieDocument" helper to the LaunchingPlugin.
I don't care about exposing the entriesChanged method or the IEntriesChangedListener as public API. They can stay non-API for all I care. The fact that it handles, via your internal code, and causes an update if the classpath changes is one of the reasons we wanted to subclass JavaLaunchConfigurationTab. We would gain that function automatically since there is no way for us to do it ourselves since it is internal code. The listener class itself can stay internal. The others we like are the getContext() method and the intializeJavaProject method are also what we want API from the class.
Not curretly committed as we are in the process of changing the runtime classpath viewer/editor. See bug 34095 and bug 61488.
We can make some form of the JavaLaunchConfigurationTab API to expose these methods: * protected IJavaElement getContext() * protected void initializeJavaProject(IJavaElement javaElement, ILaunchConfigurationWorkingCopy config) We do not intend to expose "IEntriesChangedListener", but will maintain the function. I still need more information regarding requirements from comment#3 (Brock?).
(In reply to comment #9) > I still need more information regarding requirements from comment#3 (Brock?). I was wanting to add extra pages the the Java and JUnit launch configurations without having to create a whole new launch type. In my case i wanted to add one tab for setting assertion properties and another for setting up the JDK logging properties. In both of these cases a list of system properties are being modified. I can't see participants needing to change anything other than system properties and program arguments. This issue was more about creating new 'java like' launches, so perhaps i should create a new PR?
Brock, please enter a new enhancement request for your issue. I believe it is different from the purpose of this request. Thx.
Will create API as stated in comment#9
Fixed. Added new API class JavaLauncTab. Exposes the following API: protected IJavaElement getContext() protected ILaunchConfiguration getCurrentLaunchConfiguration() public void initializeFrom(ILaunchConfiguration config) protected void initializeJavaProject(IJavaElement javaElement, ILaunchConfigurationWorkingCopy config) Does not expose entries changed listener. The listener interface was only used by the classpath tab and deprecated source lookup tab. Since those classes were not previously subclassable, there is no reason to expose the entries changed listener (that and the fact we hope to improve/change classpath editing).
Please verify, Mike. (note typo - new class is JavaLaunchTab, added to component.xml).
verified.