Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 331030

Summary: Interactive OCL console ID not documented
Product: [Modeling] OCL Reporter: Darie Moldovan <darie-cazimir.moldovan>
Component: CoreAssignee: OCL Inbox <mdt-ocl-inbox>
Status: CLOSED INVALID QA Contact:
Severity: normal    
Priority: P3 CC: adolfosbh
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Darie Moldovan CLA 2010-11-24 10:22:03 EST
Build Identifier: 20100917-0705

The OCL Console View cannot be added to a newly created Eclipse perspective programatically. In the class, which implements IPerspectiveFactory and which defines which views are to be added to the new perspective (see method 

public void createInitialLayout(IPageLayout layout)

), there seems to be no way to specify a string, which represents the ID of the OCL console view, so that it can be automatically loaded when the user opens the perspective (something like org.eclipse.ocl.bla-bla.OCLConsoleView). 

Reproducible: Always

Steps to Reproduce:
1. create a new Eclipse Plugin
2. write a new perspective, with custom views
3. try to add the OCL console view somewhere on the Eclipse workbench automatically (NOT by hand every time you open Eclipse)
4. Run the plugin and open the new perspective
Comment 1 Darie Moldovan CLA 2010-11-24 10:26:36 EST
Example: 

for adding the Project Explorer view to the bottom of the Eclipse Workbench, you just have to write something like:

String editorArea = layout.getEditorArea();
		
layout.addView(
	IPageLayout.ID_PROJECT_EXPLORER,
	IPageLayout.LEFT,
        0.25f,
	editorArea);

where ID_PROJECT_EXPLORER has the value "org.eclipse.ui.navigator.ProjectExplorer". I look for a similar way to add the OCL Console view.
Comment 2 Adolfo Sanchez-Barbudo Herrera CLA 2010-12-02 08:59:52 EST
Darie,

Apologizes for the delayed response.

The "OCL Console View" is not a View provided by MDT/OCL itself. 

OCL provides a Console implementation which is added to the "Console View" (throw the IConsoleManager). 

I've looked for your required "Console View" id:

org.eclipse.ui.console.ConsoleView

Try this ID to make the "Console View" appear in your perspective 

P.S: note that only the "Console View" would appear, you'd then have to switch to the OCL Interactive Console.

Best Regards,
Adolfo.
Comment 3 Ed Willink CLA 2011-05-27 02:59:37 EDT
Closing INVALIDs