Skip to content

Choices

Christoffer Fink edited this page Sep 1, 2014 · 1 revision

Note: a better vocabulary is needed to describe these parameters.

A choice is created by nesting one or more SChoice elements inside an SParam element. So a choice is not a third kind of parameter (in addition to numeric and structured parameters). Instead, a choice is a special kind of structured parameter; one that may be initialized in multiple different ways.

Example

    <SParam id="Shape">
      <SChoice id="Circle">
        <NParam id="Radius" type="integer" inclMin="2" />
        <SParam id="Center">
          <NParam id="X" type="integer" />
          <NParam id="Y" type="integer" />
        </SParam>
      </SChoice>
      <!-- More SChoice elements ... -->
    </SParam>

Fixed Values

A choice is fixed by specifying the ID of one of the nested SChoice elements.

Example

    <SParam id="Shape" fixed="Triange">
      <!-- As above. -->
    </SParam>

Clone this wiki locally