Introduction
Usage : Involved when you use a group of components from the catalog and let you define if you instantiate, duplicate, or replace the objects from a group of components
Note: Routable objects are never replaced. If the rule indicates replace, the routable objects are instantiated
possible value for List_Operations :
- 1 = Instantiate
- 2 = Duplicate
- 3 = Replace
Datasetup Resource Set :
- Diagram Resource
Datasetup Resource : Rule to compute options for component group
Rule Example 1
Description
For each instance of the component group , the rule will do for :
- Equipment : Duplicate
- Piping Part : Duplicate
- others : Instantiate
Rule
// ThisObject --> NULL /* possible value for List_Operations : 1 = Instantiate 2 = Duplicate 3 = Replace */ let ListPLMInstances(LIST) set ListPLMInstances = Parameters.GetAttributeObject ("List_Instances_From_ComponentGroup") let OutListOfOperations(List) Let ReferenceObject(RFLVPMLogicalReference) Let InstanceObject(RFLVPMLogicalInstance) let sDiscipline (String) Let j = 1 for j while j<=ListPLMInstances->Size() { set InstanceObject = ListPLMInstances->GetItem(j) set ReferenceObject = InstanceObject.Reference sDiscipline = ReferenceObject.V_discipline if(sDiscipline == "EnsLogicalEquipment") { OutListOfOperations.Append(2) } else if(sDiscipline == "Piping_Logical_Part") { OutListOfOperations.Append(2) } else { OutListOfOperations.Append(1) } j = j+1 } /* output parameters write */ Parameters.SetAttributeObject("List_Operations", OutListOfOperations)
3DXML