<macro>
One macro definition in a mashup script or another macro, or by itself or in a macro library. Macros define custom statements that can be used in mashup scripts, another macro or as custom blocks in Wires.
Note: Limitations in previous releases that prevented macros from calling or declaring other macros no longer apply.
Macros can contain any EMML declaration and any EMML statement.
Macros allow behavior to be parameterized. They support both input parameters and an output parameter. Macros have access only to the variables defined within the macro plus their own input parameters.
Access to macros depends on where they are defined:
Macros declared in a mashup script or another macro are
inner macros that are only accessible within that mashup or macro.
Reusable macros can also be defined as global macros that have no domain, but are accessible in any mashup script or macro. See
Creating and Registering Macros for more information on global macros and macro domains.
Macros must have a name. You then add any EMML statements or declarations needed to accomplish the processing that the macro performs. For more information and examples, see:
Can Contain | |
Allowed In | mashup | operation | macros | macro |
Attributes
Name | Required | Description |
name | yes | The name for this macro definition. This becomes the custom statement name within the calling EMML script or macro, so macro names must be valid XML names. This is also the default block name if the macro is used as a custom block in Wires. Macro names must be unique within the domain they belong to. They can contain ASCII letters, numerals, periods (.), underscores (_) or dashes (-). Names must start with a letter. |