Bug 520207 - Mechanism to do specific project operations after standard project import
Summary: Mechanism to do specific project operations after standard project import
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.7   Edit
Hardware: PC Windows 10
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-26 07:38 EDT by Alain Bernard CLA
Modified: 2017-07-26 08:40 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alain Bernard CLA 2017-07-26 07:38:44 EDT
When working on project with specific natures, it is sometimes useful to perform operations just after importing an existing project into workspace (modifying config files, etc.)

In some cases, there is no need to redefine a specific wizard, as the "Import Existing Projects into Workspace" does the job perfectly apart from the fine-grained configurations just after import. 

So, if we want to extend it to add specific custom behavior, we can:
- extend the o.e.ui.wizard.datatransfer.ExternalProjectImportWizard but it is idenfified as @noextend
- reimplement this wizard, reusing the page o.e.ui.internal.wizards.datatransfer.WizardProjectsImportPage, which is internal so it seems to be a bad idea too (and even with that we don't have access to the list of created IProject as it is not API)
- reimplement our own wizard by copy-pasting all the code, therefore not benefitting from potential bug fixes or improvements in the standard import wizard.

So is there a mechanism to be informed when projects are imported inside the workspace so that we can do our stuff there, is there a good method to do so that I didn't notice or is there a chance to open the API of the projects import wizard a bit?
Comment 1 Olivier Prouvost CLA 2017-07-26 08:40:45 EDT
It seems to be such a mechanism implemented in the CDT in the interfaces and classes : 

IProjectSettingsWizardPageStrategy
ProjectSettingsImportStrategy