public override void ExecuteCommand(Quadrant quadrant) { if (_enterprise.IsDocked) { _output.WriteLine(Strings.ShieldsDropped); } if (Condition < 0) { _output.WriteLine(Strings.ShortRangeSensorsOut); } _output.WriteLine("---------------------------------"); quadrant.GetDisplayLines() .Zip(GetStatusLines(), (sectors, status) => $" {sectors} {status}") .ToList() .ForEach(l => _output.WriteLine(l)); _output.WriteLine("---------------------------------"); }
protected override CommandResult ExecuteCommandCore(Quadrant quadrant) { if (_enterprise.IsDocked) { _io.WriteLine(Strings.ShieldsDropped); } if (Condition < 0) { _io.WriteLine(Strings.ShortRangeSensorsOut); } _io.WriteLine("---------------------------------"); quadrant.GetDisplayLines() .Zip(GetStatusLines(), (sectors, status) => $" {sectors} {status}") .ToList() .ForEach(l => _io.WriteLine(l)); _io.WriteLine("---------------------------------"); return(CommandResult.Ok); }