Example #1
0
 public void Accept(ICarPartVisitor CarPartVisitor)
 {
     foreach (var part in parts)
     {
         part.Accept(CarPartVisitor);
     }
     CarPartVisitor.Visit(this);
 }
Example #2
0
 public void Accept(ICarPartVisitor visitor)
 {
     for (int i = 0; i < carParts.Lengh; i++)
     {
         carParts[i].Accept(visitor);
     }
     visitor.Visit(this);
 }
Example #3
0
 public void Accept(ICarPartVisitor CarPartVisitor)
 {
     CarPartVisitor.Visit(this);
 }
 void Accept(ICarPartVisitor visitor)
 {
     visitor.Visit(this);
 }
Example #5
0
 static void Accept(this Seat seat, ICarPartVisitor visitor)
 {
     //   visitor.VisitSeat(seat.name, seat.capacity);
     visitor.Visit(seat);
 }
Example #6
0
 static void Accept(this Engine engine, ICarPartVisitor visitor)
 {
     // visitor.VisitEngine(engine.power, engine.cylinderVolume, engine.temperatureC);
     visitor.Visit(engine);
 }