Skip to content

ENH: Added the concept of Required Analyses

Robert M. O'Bara requested to merge bob.obara/smtk:addingRequiredAnalyses into master

A smtk::attribute::Analyses::Analysis can now be marked as required. A required Analysis indicates that it is not optional and is considered active if its parent analysis is active (or the analysis is at the top level). The following methods have been added to smtk::attribute::Analyses::Analysis:

  • setRequired(bool)
  • bool isRequired() const

The following is a example setting an Analysis to be required via a sbt file:

    <Analysis Type="Required Analysis" Required="true"/>

See smtk/data/attribute/attribute_collection/SimpleAnalysisTest.sbt for a complete example.

Note that an Analysis's parent has Exclusive Children then the Analysis' required property is ignored.

Also fixed the following issues:

  • Exclusive Analyses were not always displaying their labels
  • An non-excljusive analysis with exclusive children was never adding its categories in the method smtk::attribute::Analyese::getAnalysisAttributeCategories

Addresses Issues #288 (closed) #289 (closed) and #290 (closed)

Backport: release

Merge request reports