예제 #1
0
 public virtual void Visit(Camshaft camshaft)
 {
     Console.WriteLine(@"diagnosing camshaft");
 }
예제 #2
0
 public virtual void Visit(Camshaft camshaft)
 {
     _camshaftCount++;
 }
예제 #3
0
 protected AbstractEngine(int size, bool turbo)
 {
     _size = size;
     _turbo = turbo;
     _running = false;
     _power = 0;
     _camshaft = new Camshaft();
     _piston = new Piston();
     _sparkPlugs = new SparkPlug[]
                   {
                       new SparkPlug(),
                       new SparkPlug(),
                       new SparkPlug()
                   };
 }