General InformationThis opening ID is invoked when using the Copy Arrangement command. For more information, see Electrical 3D Design: Arranging Segments: Copying Arrangement between Supports. To verify if Copy Arrangement is allowed on the current segment - support at source and segment - support at target, the business rule validates if the arrangement is to be copied or not. It can either:
The table below provides you with information related to the definition of the Opening ID.
Input ObjectsInput objects must be of the following types:
Note:
This notion is not mandatory but it is used by the electrical command.
Context Object Parameters
SampleThe following sample illustrates the syntax of the business rule. /* CATRule signature (do not edit) : (ThisObject : #In Support,
Parameters : #In RuleContext, Validation : #Out Boolean) : #Void */
let SrcSpt(Support)
let SrcSeg(Segment)
let TgtSpt(Support)
let TgtSeg(Segment)
let SrcName(STRING)
let TgtName(STRING)
let SubType(STRING)
set SrcSpt = Parameters.GetAttributeObject("SourceSupportInstance")
set SrcSeg = Parameters.GetAttributeObject("SegmentAtSource")
set TgtSpt = Parameters.GetAttributeObject("TargetSupportInstance")
set TgtSeg = Parameters.GetAttributeObject("SegmentAtTarget")
if((NULL == SrcSpt) or (NULL == TgtSpt) or (NULL == SrcSeg)
or (NULL == TgtSeg))
{
Validation = false
Parameters.Severity = 2
Parameters.Message = "Param NULL"
}
else
{
set SrcName = SrcSpt.Name
set TgtName = TgtSpt.Name
}
{
if (SrcName == TgtName)
{
Validation = false
Parameters.Severity = 2
Parameters.Message = "Not allowed"
}
else
{
if(SrcSeg.Elec_SubType == TgtSeg.Elec_SubType)
{
Validation = true
Parameters.Severity = 0
Parameters.Message = "Copy Allowed - Both segments have same Subtype"
}
else
{
Validation = true
Parameters.Severity = 1
Parameters.Message = "Copy Allowed with warning- Subtypes of the
segments does not match"
}
}
| |||||||||||||||||||||||||||||||||