-
Key: MOFM2T11-4
-
Legacy Issue Number: 14031
-
Status: open
-
Source: Obeo ( Laurent Goubet)
-
Summary:
The current version of the specification doesn't allow for any "post-processing" of the generated text. I can see two potential needs of post-processing : 1) template level. As well as users can specify guards and overrides, They should be offered the possibility to specify a "post" action in the form of a template or operation call that would be executed on the whole generated text (except for those nested within [file] blocks, see point 2)). For example, I could be defining a template that generates the text pertaining to the body of a Java Class. I might want to trim this text from all surrounding whitespaces before generating and returning it. This would make something like (on UML Class) : [template public classBody(clazz : Class) post (trim())] ... [/template] Such a feature would allow for more readable templates as the user wouldn't be forced to trim() everywhere this template is used. 2) file level. Users might want to call something as a post-processing of a file generation. The most obvious example is the call for a code formatter after a code generation. As above, this would give something like : [file ('Class.java', false) post (format())/] ... [/file]
-
Reported: MOFM2T 1.0 — Thu, 25 Jun 2009 04:00 GMT
-
Updated: Fri, 6 Mar 2015 20:58 GMT
MOFM2T11 — current version of the specification doesn't allow for any "post-processing" of the generated text.
- Key: MOFM2T11-4
- OMG Task Force: MOF Model to Text RTF 1.1