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

Bug 343842

Summary: [M2x IDE Integration] Provide hander service for XtendJob result objects
Product: [Automotive] Sphinx Reporter: Stephan Eberle <stephaneberle9>
Component: CoreAssignee: Stephan Eberle <stephaneberle9>
Status: CLOSED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: ali.akar82, idydieng, quoclan, r.sezestre, yannick7777
Version: 0.7.0   
Target Milestone: 0.7.0   
Hardware: All   
OS: All   
Whiteboard:

Description Stephan Eberle CLA 2011-04-26 09:35:29 EDT
= Problem description = 
XtendJob provides a convenient API for executing M2M transformation in the Eclipse workspace. Currently, the resulting objects are exposed in the XtendJob#getResultObjects() list but not handled any further in any way. In order to simplify processing of M2M transformation results in applications using XtendJob and appropriate result object hander services should be provided.

= Resolution proposal = 
* Define an interface and abstract implementation of a result object handler that can be registered on XtendJob, gets invoked when the latter completes and lets the handler process the XtendJob#getResultObjects(). They should be based on/extend IJobChangeListener/JobChangeAdapter so as to benefit from job change event support in Eclipse as much as possible.
* Provide a result object handler implementation that saves each resulting object tree as a new resource in the workspace if possible and derives resulting file name and location from corresponding target object on which the M2M transformation has been invoked.
* For that purpose, XtendJob#getResultObjects() needs to be transformed from a list to a map that is keyed by the XtendEvaluationRequest#getTargetObject() corresponding to the result object trees provided by the values in the map.
Comment 1 Stephan Eberle CLA 2011-05-02 03:39:04 EDT
Fixed as proposed in description.
Comment 2 Balazs Grill CLA 2021-07-14 02:16:34 EDT
Mass-closing Resolved tickets