Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 343847 - [M2x IDE Integration] Use Xtend MetaModels configured in project settings when running BasicM2xAction or M2xConfigurationWizard
Summary: [M2x IDE Integration] Use Xtend MetaModels configured in project settings whe...
Status: CLOSED FIXED
Alias: None
Product: Sphinx
Classification: Automotive
Component: Core (show other bugs)
Version: 0.7.0   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 0.7.0   Edit
Assignee: Stephan Eberle CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 343844
Blocks:
  Show dependency tree
 
Reported: 2011-04-26 10:09 EDT by Stephan Eberle CLA
Modified: 2021-07-14 02:15 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Eberle CLA 2011-04-26 10:09:50 EDT
= Problem description =
Currently the BasicM2MAction, BasicM2TAction, M2MConfigurationWizard, and M2TConfigurationWizard use an instance of SphinxManagedEmfMetaModel as basis for running M2x transformation operations. This is good for automatically determining the Xtend MetaModels required for processing the model files in the project from where the M2x transformation operation is invoked. If this is not sufficient, e.g., when transforming an existing model file to a metamodel where no instances exist as files in the same project yet, applications must subclass BasicM2xAction and programatically provide the required Xtend MetaModel(s). As this can become necessary quite quickly - in particular in the case of M2M transformation operations - a more intelligent Xtend MetaModel provision strategy should be provided at generic level. 

This can be easily achieved by retrieving and using the Xtend MetaModels that are configured via the Xtend/Xpand settings of the underlying project. BasicM2xAction and M2xConfigurationWizard will then automatically be initialized with the same Xtend MetaModels as the user has selected to get her Xtend extenstions and/or Xpand templates compiled.

= Resolution approach =
* Enhance BasicM2MAction and BasicM2TAction so as to retrieve the MetamodelContributorRegistry#getActiveMetamodelContributors() of underlying project and use the Xtend MetaModels exposed by the same.
* Use SphinxManagedEmfMetaModel only if no such can be found.
Comment 1 Stephan Eberle CLA 2011-05-02 12:17:41 EDT
Fixed as proposed in description.
Comment 2 Balazs Grill CLA 2021-07-14 02:15:23 EDT
Mass-closing Resolved tickets