30 lines
587 B
C#
30 lines
587 B
C#
namespace CarEngineFacade;
|
|
|
|
public class Facade
|
|
{
|
|
private readonly AirFlowController _air = new();
|
|
private readonly CatalyticConverter _cat = new();
|
|
private readonly CoolingController _cool = new();
|
|
private readonly FuelInjector _fuel = new();
|
|
private readonly Starter _start = new();
|
|
|
|
public void Start()
|
|
{
|
|
_air.TakeAir();
|
|
_fuel.On();
|
|
_fuel.Inject();
|
|
_start.Start();
|
|
_cool.Run();
|
|
_cat.On();
|
|
}
|
|
|
|
public void Stop()
|
|
{
|
|
_fuel.Off();
|
|
_cat.Off();
|
|
_cool.Cool();
|
|
_cool.Stop();
|
|
_air.Off();
|
|
}
|
|
}
|