public void HandleVisitor(IVisitFoo visitor) { //this will allow for _component1 to be visible to the visitor _component1.HandleVisitor(visitor); //this will give a reference of all of the public members to the visitor visitor.Visit(this); }
public void HandleVisitor(IVisitFoo visitor) { //this exposes the public methods of this class to the visitor visitor.Visit(this); }