Adding Macro Calls Automatically in the Mashup Editor
To use a macro in a mashup script or another macro, you add an <include> statement for the domain the macro belongs to and add the custom statement for that macro. You can automatically generate both the <include> and custom statement for a macro in Mashup Editor.
1. Open the mashup script in theMashup Editorand move the cursor to the line where you want to call the macro.
2. Expand the Macrosmenu and click on the macro you want to call.
This inserts both an <include> statement for the domain that the macro belongs to and the custom statement to invoke the macro itself. For example:
3. If the macro has input parameters, add attributes for each input you want to use with this call to the macro.
You can enter literal values, XPath expressions or references to variables from this mashup for the input parameters. For example:
4. In theoutputvariableattribute, enter a reference to the variable that should receive the results of the macro.