Hide menu
Loading...
Searching...
No Matches
cadex.ModelData.ModelElementUniqueVisitor Class Reference

Defines a visitor that visits each unique element only once. More...

Inherits cadex.ModelData.ModelElementVisitor.

Public Member Functions

 ModelElementUniqueVisitor (global::System.IntPtr cPtr, bool cMemoryOwn)
 
 ModelElementUniqueVisitor ()
 Constructor.
 
 ModelElementUniqueVisitor (cadex.ModelData.ModelElementVisitor theRef)
 
override void Apply (cadex.ModelData.Part thePart)
 
override bool VisitEnter (cadex.ModelData.Assembly theAssembly)
 Enters an assembly.
 
override void VisitLeave (cadex.ModelData.Assembly theAssembly)
 Invokes VisitLeave() of the Ref() visitor if the assembly is being visited for the first time.
 
override bool VisitEnter (cadex.ModelData.Instance theInstance)
 Enters an instance.
 
override void VisitLeave (cadex.ModelData.Instance theInstance)
 Invokes VisitLeave() of the Ref() visitor if the instance is being visited for the first time.
 

Protected Member Functions

override void Dispose (bool disposing)
 

Detailed Description

Defines a visitor that visits each unique element only once.

Children of already visited assemblies or referred element of already visited instances, or already visited parts will never be visited again.

Already visited instances or assemblies will be entered with Ref() visitor VisitEnter() as well as left with VisitLeave().

Uses the associated visitor (Reference()) to really visit an element.

Examples
MTKConverter/Program.cs, MTKConverter/main.cxx, machining/dfm_analyzer/Program.cs, machining/dfm_analyzer/main.cxx, machining/feature_recognizer/Program.cs, machining/feature_recognizer/main.cxx, molding/dfm_analyzer/Program.cs, molding/dfm_analyzer/main.cxx, molding/feature_recognizer/Program.cs, molding/feature_recognizer/main.cxx, sheet_metal/dfm_analyzer/Program.cs, sheet_metal/dfm_analyzer/main.cxx, sheet_metal/feature_recognizer/Program.cs, sheet_metal/feature_recognizer/main.cxx, sheet_metal/unfolder/Program.cs, sheet_metal/unfolder/main.cxx, wall_thickness/analyzer/Program.cs, and wall_thickness/analyzer/main.cxx.

Constructor & Destructor Documentation

◆ ModelElementUniqueVisitor()

cadex.ModelData.ModelElementUniqueVisitor.ModelElementUniqueVisitor ( )
inline

Constructor.

Member Function Documentation

◆ VisitEnter() [1/2]

override bool cadex.ModelData.ModelElementUniqueVisitor.VisitEnter ( cadex.ModelData.Assembly theAssembly)
inline

Enters an assembly.

◆ VisitEnter() [2/2]

override bool cadex.ModelData.ModelElementUniqueVisitor.VisitEnter ( cadex.ModelData.Instance theInstance)
inline

Enters an instance.

◆ VisitLeave() [1/2]

override void cadex.ModelData.ModelElementUniqueVisitor.VisitLeave ( cadex.ModelData.Assembly theAssembly)
inline

Invokes VisitLeave() of the Ref() visitor if the assembly is being visited for the first time.

Leaves an assembly.

◆ VisitLeave() [2/2]

override void cadex.ModelData.ModelElementUniqueVisitor.VisitLeave ( cadex.ModelData.Instance theInstance)
inline

Invokes VisitLeave() of the Ref() visitor if the instance is being visited for the first time.

Leaves an instance.