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 and left with reference visitor. Uses the associated visitor to really visit an element.
new ModelElementUniqueVisitor(
refVisitor
):ModelElementUniqueVisitor
Reference visitor that defines actual logic that will be invoked for model elements.
visitAssemblyEnter(
assembly
):boolean
Enters an assembly. Invokes visitAssemblyEnter() of the reference visitor if the assembly
has not been already visited. Thus children of already visited assembly won't be visited again.
Visited assembly.
boolean
ModelElementVisitor
.visitAssemblyEnter
visitAssemblyLeave(
assembly
):void
Leaves an assembly. Invokes visitAssemblyLeave() of the reference visitor if the assembly
is being visited for the first time.
Visited assembly.
void
ModelElementVisitor
.visitAssemblyLeave
visitInstanceEnter(
instance
):boolean
Enters an instance. Invokes visitInstanceEnter() of the reference visitor if the instance
has not been already visited. Thus referred element of already visited instance won't be visited again.
Visited instance.
boolean
ModelElementVisitor
.visitInstanceEnter
visitInstanceLeave(
instance
):void
Leaves an instance. Invokes visitInstanceLeave() of the reference visitor.
Visited instance.
void
ModelElementVisitor
.visitInstanceLeave
visitPart(
part
):void
Invokes visitPart() of the reference visitor if the part has not been already visited.
Visited part.
void