Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

As of 2021.01 the new WhatIf Editor functionality is being introduced with the intention to remove the outdated WhatIf functionality by 2023. This new WhatIf functionality uses WhatIfTemplates which can be populated in the WhatIf Editor, i.e. the display to create whatif-instances that can be applied to a workflow. The connection between WhatIfs-instances and workflows is established via the IFD, the Interactive Forecasting Displays, where a <whatIfTemplateId> can be defined after the <workflowId> in the Topology.

Code Block
titleConnecting a WhatIf-template to a workflow in the Topology.xml or TopologyGroup.xml
        <node id="run_whatif_properties" name="wf1 t1 Properties">
            <workflowId>Test_WhatIfSettings</workflowId>
            <whatIfTemplateId>whatif_properties</whatIfTemplateId>....

The This WhatIf Editor uses the whatifTemplates.xsd schema. This schema allows the configuration of a whatif-template, which is used in the WhatifEditor GUI to allows the specification of properties and modifiers to be applied in a whatif-instance.

...

  • only apply the modifier if referenced in a whatif
  • always apply the modifier (i.e. the default behaviour)
  • never apply the modifier in a whatif workflow (= always apply unless running a whatif workflow)

Note: Modifiers need to be committed (i.e. non-local) to become available for application in a whatif-instance. It may therefore be useful to turn on the <autoCommit>-flag in the ModifierTypes.xml

Code Block
titleSpecifying modifier behavior in relation to the whatif in the ModifierTypes.xml.
    <timeSeriesModifier id="modify_timeseries_only_applied_in_whatif" name="Modify time series (only applied in whatif)">
        <whatIfModifierType>apply if referenced in what-if workflow</whatIfModifierType>
        <timeSeries>....

The whatIfTemplates-schema

The whatifTemplates-schema contains two main sections:

  • valueTypes: to specify the kinds of properties and their limitations
  • whatifTemplates: to compose which properties and modifiers can be specified in the template. whatifTemplates can be nested (but not unlimited)