Context Object Parameters
Parameter Name | Type | Read/Write | Comments |
---|
L2PPhysicalElement | PLM Entity |
Read | The physical element found synchronization with logical element
(ThisObject ).
|
L2PSynchronizeElement | PLM Entity |
Read | The output Boolean, to indicate the physical element should be
synchronized with the logical element (ThisObject ).
|
L2PSynchronizeChildren | PLM Entity |
Read | The output Boolean, to indicate whether the children of the
physical element should be synchronized with respective logical
children element of ThisObject .
|
Severity messages:
- Severity= 0 the treatment is to be continued (no message).
- Severity= 1 the treatment is to be continued and only a warning
raised.
- Severity= 2 the treatment is supposed to be undone.
If the output L2PSynchronizeElement
is
false, the element will not be analyzed for synchronization.
The analysis of its children will depend on output L2PSynchronizeChildren
. The children will be
analyzed if L2PSynchronizeChildren
is
true. If both the outputs are false, the physical element and all
its children will not be analyzed for synchronization.
Sample
The following sample illustrates the business rule syntax.
let PhysVPMInst(VPMInstance)
let PInstanceName (String)
let LInstanceName (String)
let LDescription (String)
set LDescription = ThisObject.GetAttributeString("V_description")
set PhysVPMInst = Parameters.GetAttributeObject("L2PPhysicalElement")
set LInstanceName = ThisObject.Name
if PhysVPMInst<>NULL
{
set PInstanceName = PhysVPMInst.Name
if PInstanceName <> LInstanceName
{
Parameters.SetAttributeBoolean("L2PSynchronizeElement",FALSE)
Parameters.SetAttributeInteger("Severity", 1)
Parameters.SetAttributeString("Message", "Logical and Physical Instance names are different : No Synchronization ")
}
Else
{
Parameters.SetAttributeBoolean("L2PSynchronizeElement",TRUE)
Parameters.SetAttributeInteger("Severity", 1)
Parameters.SetAttributeString("Message", "No Blocking Conditions : Element Synchronization Accepted")
}
}
Else
{
Parameters.SetAttributeBoolean("L2PSynchronizeElement",TRUE)
Parameters.SetAttributeInteger("Severity", 0)
}
if ThisObject.Reference.IsASortOf("EleLogicalHarness")
{
if (LDescription == "Forbid Children Synchronization")
{
Parameters.SetAttributeBoolean("L2PSynchronizeChildren",FALSE)
Parameters.SetAttributeInteger("Severity", 1)
Parameters.SetAttributeString("Message", "Children Synchronization forbidden")
}
Else
{
Parameters.SetAttributeBoolean("L2PSynchronizeChildren",TRUE)
Parameters.SetAttributeInteger("Severity", 1)
Parameters.SetAttributeString("Message", "No Blocking Conditions : Children Synchronization Accepted")
}
}
Else
{
Parameters.SetAttributeBoolean("L2PSynchronizeChildren",TRUE)
Parameters.SetAttributeInteger("Severity", 0)
}