Example #1
0
 public CarriageBlock <T> Hook(CarriageBlock <T> other)
 {
     foreach (T item in other.carriages)
     {
         carriages.AddLast(item);
     }
     return(this);
 }
Example #2
0
 public CargoTrain(ILoco <V8DieselEngine> locomotive, CarriageBlock <CargoVag> carriageBlock)
     : base(locomotive, carriageBlock)
 {
 }
Example #3
0
 public Train <T> Hook(CarriageBlock <T> block)
 {
     carriages = carriages.Hook(block);
     return(this);
 }
Example #4
0
 public Train <T> Unhook(int positionFrom)
 {
     carriages = carriages.Unhook(positionFrom);
     return(this);
 }
Example #5
0
 public Train(ILoco <V8DieselEngine> locomotive, CarriageBlock <T> carriageBlock)
 {
     this.locomotive = locomotive;
     this.carriages  = carriageBlock;
 }