9.5 Parameters in catalogs

Catalog files are designed for reuse. For this reason, they can store their own set of parameters. All parameters used within a catalog shall be declared within their ParameterDeclaration, which sets a default value for each parameter. When a catalog is referenced, the ParameterAssignment element within CatalogReference may be used to override these defaults.

For example, a catalog definition may contain the following ParameterDeclaration:

    <ParameterDeclaration name="x" value="5" parameterType="integer" />
    <ParameterDeclaration name="y" value="7" parameterType="integer" />

When referenced in the main scenario, the value of x is overridden by using a ParameterAssignment within the CatalogReference:

<CatalogReference catalogName="eg_catalog" entryName="eg_entry">
        <ParameterAssignment parameterRef="x" value="0" />

This means that, for this use of the catalog, any reference to "$x" should be replaced with "0", and any reference to "$y" should be replaced with the default value of "7". No other parameters may be referenced from within the catalog.

The value attribute of a ParameterAssignment may itself reference a parameter.