ANML Documentation

Macro Reference and Instantiation

Instantiation involves taking a macro definition and assigning specific automata network elements to implement that macro definition. The macro reference provides a way for other network resources to address this specific macro instantiation.

Required attributes:

  • ID
  • path

Optional clauses:

  • activations
  • substitutions
Figure 1. Macro Reference
Railroad macro reference

ID Attribute

The ID attribute is a user-defined unique identifier (name) that is used by other network resources to refer to this macro instance.

Path Attribute

The path attribute is the filesystem location where the macro definition can be found. The path is a relative location in the current filesystem.


The activations statement is the mechanism that connects a macro’s output to the outside world. Any number of activate-from-macro statements can exist within the activate-out statement.

Each of these statements connects a macro output port to an element in the automata network. The element="ID" parameter is where the automata network resource is specified. This is the resource that receives the activation output from the macro output port. The source="SRC" parameter specifies the macro output port from where the activation signal originates.

The activations statement may be repeated any number of times, including zero times.

Figure 2. Activations
Railroad macro activations


The substitutions statement is the way in which parameter values can be set when a macro is instantiated.

A substitutions statement may be repeated any number of times, including zero times.

Figure 3. Substitutions
Railroad macro substitutions