PCB Matrix Format
by Numerical Innovations, Inc. (www.numericalinnovations.com)
IF array

MATRIX Array Level: 1

The IF conditional array executes the internal martix element(s) when the specified condition result is evaluated to true

Fields in the FOREACH array
Description
TEST Assign a condition that is evaluated during code execution. If the result evaluates to True, the following elements will be processed.

XML example:

<!-- If attribute Test is true, execute the rest of the element. -->
<if test="@top_side==true">
<FILTER>
<NAME>top_filter</NAME>
<JOB>@active</JOB>
<LAYERS>[Top_Components]</LAYERS>
<NewLayer result="@top_silk">Silkscreen Top,GRAPHIC</NewLayer>
</FILTER>
<SELECTION>
<Name>top_set</Name>
<FILTER>top_filter</FILTER>
<JOB>@active</JOB>
<SELECT_ALL/>
</SELECTION>
<foreach select="top_set">
<get type="all" />
<MESSAGE>#{{__index+1}}: __object (__refdes), __layer, Center: __center_pt</MESSAGE>
<matrix_ref name="top_silk_object" />
</foreach>
</if>