/*! * * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. * \copyright * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. * * \file VTreatmentAdjustmentFlows.h * \author (last) Behrouz NematiPour * \date (last) 07-Sep-2020 * \author (original) Behrouz NematiPour * \date (original) 26-Aug-2020 * */ #pragma once // Qt #include // Project #include "main.h" // Doxygen : don't remove #include "VView.h" #include "VTreatmentAdjustmentResponseBase.h" namespace View { /*! * \brief The VTreatmentAdjustmentFlows class * \details View for Model's Data representation. * * \sa Model::MAdjustBloodDialysateResponse * */ class VTreatmentAdjustmentFlows : public VTreatmentAdjustmentResponseBase { Q_OBJECT // friends friend class ::tst_views; AdjustBloodDialysateRequestData _data; // coco begin validated: // The property adjustment_Triggered has to be always true // and to always trigger the change event to work as a notifier for GUI // has been manually tested that it works perfectly fine TRIGGER( bool , adjustment , 0) // coco end // Treatment Blood/Dialysate Flow data PROPERTY( quint32 , bloodFlow_FlowSetPoint , 0) PROPERTY( quint32 , dialysateFlow_FlowSetPoint , 0) VIEW_DEC_CLASS_ADJUSTMENT(VTreatmentAdjustmentFlows, AdjustBloodDialysateResponseData) // ----- Adjust Blood/Dialysate Flows public slots: /*! * \brief doAdjustment * \details the invocable slot to adjust the treatment blood and dialysate flow rates * \param vBloodFlow * \param vDialysateFlow */ void doAdjustment(quint32 vBloodFlow, quint32 vDialysateFlow) { _data. bloodFlow = vBloodFlow; _data.dialysateFlow = vDialysateFlow; emit didAdjustment(_data); } signals: /*! * \brief didAdjustment * \details the notification signal to adjust the blood and dialysate flow rates * \param vData - data model for the blood and dialysate adjustment request */ void didAdjustment(const AdjustBloodDialysateRequestData &vData); }; }