/* * ControlSystemTie.hh * * Created on: 30 мая 2020 г. * Author: LeonidTitov */ #ifndef UMLIBRARY_TECHNOLOGICAL_ADAPTER_CONTROLSYSTEMTIE_HH_ #define UMLIBRARY_TECHNOLOGICAL_ADAPTER_CONTROLSYSTEMTIE_HH_ #include "ControlSystemWrapper.hpp" namespace technological { namespace adapter { template struct OnControlUnitConnect { void operator()( Interconnect * control_unit, Output * output ) { control_unit->set_output(output); control_unit->reset(); } }; template struct OnControlUnitDisconnect { void operator()( Interconnect * control_unit ) { control_unit->reset(); control_unit->set_output( nullptr ); } }; }} #endif /* UMLIBRARY_TECHNOLOGICAL_ADAPTER_CONTROLSYSTEMTIE_HH_ */