Compute Position for Instantiation of 3D Physical (L2P_Compute3DPosition)

An opening ID is an entry point used to customize business logic. The Compute Position for Instantiation of 3D Physical opening ID is available in the Logical to Physical Assistant Resources resource set.

Note: For more information about customization by business rules, see Installation and Setup: Customize: Behavior: Data Setup: Customization by Business Rules.

This page discusses:

General Information

This opening ID is invoked to customize the 3D position computation for the object to be placed using the Auto Place or Manual Place commands.

Definition Description
PLM Opening ID L2P_Compute3DPosition
Customization intent Computation
Execution context Client

Input Objects

Input objects must be of the following types:

  • ThisObject: an L2PItem object, containing the data found during the analysis of the logical object. The 3D component parameter is empty at this stage.
  • Parameters corresponds to the context object.

Context Object Parameters

Parameter Name Type Read or Write Comments
PhysicalX Length Read X coordinates in the absolute context.
PhysicalY Length Read Y coordinates in the absolute context.
PhysicalZ Length Read Z coordinates in the absolute context.

Sample

/* Rule created by BZO 8/20/2018 */ 
let sName (STRING)
let facet2D (LogicalOccurrence)
let FacetInst (VPMInstance ) 
let x (Real)
let y (Real)
let z (Real)
set x = 0.0
set y = 0.0
set z = 0.0
set facet2D = ThisObject.Facet2D
set sName = (facet2D.Instance).PLM_ExternalID
if(sName == "Equ_1")
{
	set x = 0.0
	set y = -1.0
	set z = 0.0
}
else if(sName == "Equ_2")
{
	set x = 0.0
	set y = 1.0
	set z = 0.0
}
Parameters.SetAttributeReal("PhysicalX", x)
Parameters.SetAttributeReal("PhysicalY", y)
Parameters.SetAttributeReal("PhysicalZ", z)