static void Main() { var elementA = new ElementA(); var elementB = new ElementB(); elementA.VisitConcreteElementA(); elementB.VisitConcreteElementB(); }
public static void VisitConcreteElementA(this ElementA element) { element.OperationA(); }