Sparx Systems Forum

Enterprise Architect => General Board => Topic started by: novikovigor on January 17, 2014, 03:58:36 am

Title: Iteration over array
Post by: novikovigor on January 17, 2014, 03:58:36 am
Hello!
I'm working with transformation script.
Is there the way to split string value to array and then iterate over this array?
Title: Re: Iteration over array
Post by: Aaron B on January 17, 2014, 11:18:33 am
Not within the transformation / code generation template framework.

The best way to handle more complex operations at this time (E.g. string manipulations, math or retrieving model information not accessible via the templates) is to pass control to a custom EA Add-In using the EXEC_ADD_IN() macro, which can then return the appropriate string result back to your templates.
 
For more information on the EXEC_ADD_IN() macro, see:
http://www.sparxsystems.com/enterprise_architect_user_guide/10/extending_uml_models/functionmacros.html
 
If you wish to write an Add-In, some basic example Add-In projects can be downloaded from our website to help you get started:
http://www.sparxsystems.com/resources/developers/autint.html
Title: Re: Iteration over array
Post by: novikovigor on January 17, 2014, 04:21:27 pm
Thank you, Aaron B!