pycatia.general_knowledge_interfaces.expert_rule_base_component_runtimes¶
Module initially auto generated using V5Automation files from CATIA V5 R28 on 2020-09-25 14:34:21.593357
Warning
The notes denoted “CAA V5 Visual Basic Help” are to be used as reference only. They are there as a guide as to how the visual basic / catscript functions work and thus help debugging in pycatia.
- class pycatia.general_knowledge_interfaces.expert_rule_base_component_runtimes.ExpertRuleBaseComponentRuntimes(com_object)¶
Note
CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357)
System.IUnknownSystem.IDispatchSystem.CATBaseUnknownSystem.CATBaseDispatchSystem.CollectionExpertRuleBaseComponentRuntimesRepresents the collection of ExpertRuleBase (ExpertChecks, ExpertRules, andExpertRuleSets) components.This collection can be seen flattened (with Item/Count) or hierarchised (withShallowItem/ShallowCount).Be careful : the flattened view can be misleading. For instance, if there aretwo ExpertChecks with the same name, you will be able to access only one ofthem (with the methods ExpertRuleBaseComponentRuntimes.Item andExpertRuleBaseComponentRuntimes.Remove )- item(i_index: cat_variant) ExpertRuleBaseComponentRuntime ¶
Note
- CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357))
- o Func Item(CATVariant iIndex) AsExpertRuleBaseComponentRuntimeReturns a RuleBase component using its index or its name from the entireRuleBase collection.If several Expert components have the same name, the use of name isunpredicted.Parameters:iIndexThe index or the name of the Rule Base component to retrieve fromthe collection of Rule Base Components. As a numerics, this index is the rankof the Rule Base Component in the collection. The index of the first componentin the collection is 1, and the index of the last component is Count. As astring, it is the name you assigned to the component using theAnyObject.Name property or when creating the component.Returns:The retrieved Rule base component.Example:This example retrieves the last component in a RuleSetcollection.Dim lastRuleBaseComponent asExpertRuleBaseComponentRuntimeSet lastRuleBaseComponent = RuleSet.Item(RuleCollection.Count)
- Parameters:
i_index (cat_variant) –
- Return type:
- remove(i_index: cat_variant) None ¶
Note
- CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357))
- o Sub Remove(CATVariant iIndex)Removes an Expert component from the Rule Base collection. If the expertcomponent is a RuleSet all the rules, checks and rulesets embedded in theRuleset will be also removed.If several Expert components have the same name, the use of name isunpredicted.Parameters:iIndexThe index or the name of the component to retrieve from thecollection. As a numerics, this index is the rank of the expert component inthe collection. The index of the first component in the collection is 1, andthe index of the last component is Count. As a string, it is the name youassigned to the component using theAnyObject.Name property or when creating the Expert component.Example:This example removes the Expert component named density from the relationscollection.Dim CATDocs As DocumentSet CATDocs = CATIA.DocumentsDim partdoc As PartDocumentSet partdoc = CATDocs.Add(“CATPart”)Dim part As PartSet part = partdoc.PartSet massCheck = part.Relations.Item(“RuleBase”).RuleSet.ExpertRuleBaseComponentRuntimes.Remove(“density”)
- Parameters:
i_index (cat_variant) –
- Return type:
None
- shallow_count() int ¶
Note
- CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357))
- o Func ShallowCount() As longReturns the number of first-level-depth objects in the collection. This ishandy to scan the objects in a collection.Example:This example retrieves in ObjectNumber the number of objects currentlygathered in MyCollection.ObjectNumber = MyCollection.ShallowCount
- Return type:
int
- shallow_item(i_index: cat_variant) ExpertRuleBaseComponentRuntime ¶
Note
- CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357))
- o Func ShallowItem(CATVariant iIndex) AsExpertRuleBaseComponentRuntimeReturns a first-level-depth RuleBase component using its index or its namefrom the RuleBase collection.Parameters:iIndexThe index or the name of the Rule Base component to retrieve fromthe collection of Rule Base Components. As a numerics, this index is the rankof the Rule Base Component in the collection. The index of the first componentin the collection is 1, and the index of the last component is ShallowCount. Asa string, it is the name you assigned to the component using theAnyObject.Name property or when creating the component.Returns:The retrieved Rule base component.Example:This example retrieves the last component in a RuleSetcollection.Dim lastRuleBaseComponent asExpertRuleBaseComponentRuntimeSet lastRuleBaseComponent = RuleSet.ShallowItem(RuleCollection.ShallowCount)
- Parameters:
i_index (cat_variant) –
- Return type:
- shallow_remove(i_index: cat_variant) None ¶
Note
- CAA V5 Visual Basic Help (2020-09-25 14:34:21.593357))
- o Sub ShallowRemove(CATVariant iIndex)Removes an first-level-depth Expert component from the Rule Basecollection. If the expert component is a RuleSet all the rules, checks andrulesets embedded in the Ruleset will be also removed.Parameters:iIndexThe index or the name of the component to retrieve from thecollection. As a numerics, this index is the rank of the expert component inthe collection. The index of the first component in the collection is 1, andthe index of the last component is ShallowCount. As a string, it is the nameyou assigned to the component using theAnyObject.Name property or when creating the Expert component.Example:This example removes the Expert component named density from the relationscollection.Dim CATDocs As DocumentSet CATDocs = CATIA.DocumentsDim partdoc As PartDocumentSet partdoc = CATDocs.Add(“CATPart”)Dim part As PartSet part = partdoc.PartSet massCheck = part.Relations.Item(“RuleBase”).RuleSet.ExpertRuleBaseComponentRuntimes.ShallowRemove(“density”)
- Parameters:
i_index (cat_variant) –
- Return type:
None