/*! * * Copyright (c) 2021-2025 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 MPostTreatmentAdjustTreatmentLogResponse.h * \author (last) Behrouz NematiPour * \date (last) 10-Feb-2025 * \author (original) Behrouz NematiPour * \date (original) 11-Apr-2021 * */ #pragma once // Qt #include // Project #include "MAbstract.h" #include "types.h" // forward declarations class tst_models; namespace Model { /*! * \brief The MAdjustTreatmentLogResponse class * \details The TreatmentLog adjustment response model * * | MSG | CAN ID | M.Box | Type | Ack | Src | Dest | Description | * |:----:|:------:|:-----:|:----:|:---:|:---:|:----:|:---------: | * |0x7600| 0x020 | 6 | Rsp | Y | HD | UI | TreatmentLog Response | * * | Payload || * | || * | 01 - (U32) | \ref Data::mAccepted | The accept or reject bool flag | | * | 02 - (U32) | \ref Data::mReason | The rejection reason | | * | 03 - (U32) | \ref Data::mBloodFlowRate | Blood Flow Rate | (mL/min) | * | 04 - (U32) | \ref Data::mDialysateFlowRate | Dialysate Flow Rate | (mL/min) | * | 05 - (U32) | \ref Data::mTreatmentDuration | Treatment Duration | (sec) | * | 06 - (U32) | \ref Data::mActualTreatmentDuration | Actual Treatment Duration | (sec) | * | 07 - (U32) | \ref Data::mAcidConcentrateType | Acid Concentrate Type | | * | 08 - (U32) | \ref Data::mBicarbonateConcentrateType | Bicarbonate Concentrate Type | | * | 09 - (F32) | \ref Data::mPotassiumConcentration | Potassium Concentration | (mEq/L) | * | 10 - (F32) | \ref Data::mCalciumConcentration | Calcium Concentration | (mEq/L) | * | 11 - (U32) | \ref Data::mBicarbonateConcentration | Bicarbonate Concentration | (mEq/L) | * | 12 - (U32) | \ref Data::mSodiumConcentration | SodiumConcentration | (mEq/L) | * | 13 - (F32) | \ref Data::mDialysateTemperature | Dialysate Temperature | (Celsius | * | 14 - (U32) | \ref Data::mDialyzerType | Dialyzer Type | | * | 15 - (U32) | \ref Data::mTreatmentStartEpoch | Treatment Start Date and Time | (epoch) | * | 16 - (U32) | \ref Data::mTreatmentEndEpoch | Treatment End Date and Time | (epoch) | * | 17 - (F32) | \ref Data::mAverageBloodFlow | Average Blood Flow | (mL/min) | * | 18 - (F32) | \ref Data::mAverageDialysateFlow | Average Dialysate Flow | (mL/min) | * | 19 - (F32) | \ref Data::mDialysateVolumeUsed | Dialysate Volume Used | (L) | * | 20 - (F32) | \ref Data::mAverageDialysateTemp | Average Dialysate Temp | (Celsius | * | 21 - (F32) | \ref Data::mOriginUFVolume | Origin UF Volume | (L) | * | 22 - (F32) | \ref Data::mTargetUFVolume | Target UF Volume | (L) | * | 23 - (F32) | \ref Data::mActualUFVolume | Actual UF Volume | (L) | * | 24 - (F32) | \ref Data::mOriginUFRate | Origin UF Rate | (mL/min) | * | 25 - (F32) | \ref Data::mTargetUFRate | Target UF Rate | (mL/min) | * | 26 - (F32) | \ref Data::mActualUFRate | Actual UF Rate | (mL/min) | * | 27 - (U32) | \ref Data::mSalineBolusVolume | Saline Bolus Volume | (mL) | * | 28 - (F32) | \ref Data::mHeparinBolusVolume | Heparin Bolus Volume | (mL) | * | 29 - (F32) | \ref Data::mHeparinDispenseRate | Heparin Dispense Rate | (mL/hr) | * | 30 - (U32) | \ref Data::mHeparinStop | Heparin Stop | (min) | * | 31 - (F32) | \ref Data::mHeparinDeliveredVolume | Heparin Delivered Volume | (mL) | * | 32 - (U32) | \ref Data::mHeparinType | Heparin Type | | * | 33 - (F32) | \ref Data::mAverageArterialPressure | Average Arterial Pressure | (mmHg) | * | 34 - (F32) | \ref Data::mAverageVenousPressure | Average Venous Pressure | (mmHg) | * | 35 - (U32) | \ref Data::mDeviceID | Device ID | | * | 36 - (U32) | \ref Data::mWaterSampleTestResult | Water Sample Test Result | | * \sa Data * \sa MAdjustTreatmentLogReq : TreatmentLog Request * \sa MTreatmentTreatmentLog : TreatmentLog Data * *

Logging info

* | || * | || * | typeText | Event | * | unitText | HD | * | infoText | AdjustTreatmentLog | * */ class MAdjustTreatmentLogResponse : public MAbstract { // friends friend class ::tst_models; QVariantList parameters() const override; struct { Types::U32 mAccepted ; ///< 01 - (U32) The accept or reject bool flag Types::U32 mReason ; ///< 02 - (U32) The rejection reason Types::U32 mBloodFlowRate ; ///< 03 - (U32) Blood Flow Rate (mL/min) Types::U32 mDialysateFlowRate ; ///< 04 - (U32) Dialysate Flow Rate (mL/min) Types::U32 mTreatmentDuration ; ///< 05 - (U32) Treatment Duration (sec) Types::U32 mActualTreatmentDuration ; ///< 06 - (U32) Actual Treatment Duration (sec) Types::U32 mAcidConcentrateType ; ///< 07 - (U32) Acid Concentrate Type Types::U32 mBicarbonateConcentrateType ; ///< 08 - (U32) Bicarbonate Concentrate Type Types::F32 mPotassiumConcentration ; ///< 09 - (F32) Potassium Concentration (mEq/L) Types::F32 mCalciumConcentration ; ///< 10 - (F32) Calcium Concentration (mEq/L) Types::U32 mBicarbonateConcentration ; ///< 11 - (U32) Bicarbonate Concentration (mEq/L) Types::U32 mSodiumConcentration ; ///< 12 - (U32) SodiumConcentration (mEq/L) Types::F32 mDialysateTemperature ; ///< 13 - (F32) Dialysate Temperature (Celsius) Types::U32 mDialyzerType ; ///< 14 - (U32) Dialyzer Type Types::U32 mTreatmentStartEpoch ; ///< 15 - (U32) Treatment Start Date and Time (epoch) Types::U32 mTreatmentEndEpoch ; ///< 16 - (U32) Treatment End Date and Time (epoch) Types::F32 mAverageBloodFlow ; ///< 17 - (F32) Average Blood Flow (mL/min) Types::F32 mAverageDialysateFlow ; ///< 18 - (F32) Average Dialysate Flow (mL/min) Types::F32 mDialysateVolumeUsed ; ///< 19 - (F32) Dialysate Volume Used (L) Types::F32 mAverageDialysateTemp ; ///< 20 - (F32) Average Dialysate Temp (Celsius) Types::F32 mOriginUFVolume ; ///< 21 - (F32) Origin UF Volume (L) Types::F32 mTargetUFVolume ; ///< 22 - (F32) Target UF Volume (L) Types::F32 mActualUFVolume ; ///< 23 - (F32) Actual UF Volume (L) Types::F32 mOriginUFRate ; ///< 24 - (F32) Origin UF Rate (mL/min) Types::F32 mTargetUFRate ; ///< 25 - (F32) Target UF Rate (mL/min) Types::F32 mActualUFRate ; ///< 26 - (F32) Actual UF Rate (mL/min) Types::U32 mSalineBolusVolume ; ///< 27 - (U32) Saline Bolus Volume (mL) Types::F32 mHeparinBolusVolume ; ///< 28 - (F32) Heparin Bolus Volume (mL) Types::F32 mHeparinDispenseRate ; ///< 29 - (F32) Heparin Dispense Rate (mL/hr) Types::U32 mHeparinStop ; ///< 30 - (U32) Heparin Stop (min) Types::F32 mHeparinDeliveredVolume ; ///< 31 - (F32) Heparin Delivered Volume (mL) Types::U32 mHeparinType ; ///< 32 - (U32) Heparin Type Types::F32 mAverageArterialPressure ; ///< 33 - (F32) Average Arterial Pressure (mmHg) Types::F32 mAverageVenousPressure ; ///< 34 - (F32) Average Venous Pressure (mmHg) Types::U32 mDeviceID ; ///< 35 - (U32) Device ID Types::U32 mWaterSampleTestResult ; ///< 36 - (U32) Water Sample Test Result Types::U32 mHeparinConcentration ; ///< Heparin Concentration (IU/mL) // is filled by UI, for now } _data; public: Type_Enum typeText () const override { return Type_Enum::eEvent ; } Unit_Enum unitText () const override { return Unit_Enum::eHD ; } QString infoText () const override { return QString("AdjustTreatmentLog") ; } struct Data { bool mAccepted = 0; ///< 01 - (U32) The accept or reject bool flag quint32 mReason = 0; ///< 02 - (U32) The rejection reason quint32 mBloodFlowRate = 0; ///< 03 - (U32) Blood Flow Rate (mL/min) quint32 mDialysateFlowRate = 0; ///< 04 - (U32) Dialysate Flow Rate (mL/min) quint32 mTreatmentDuration = 0; ///< 05 - (U32) Treatment Duration (sec) quint32 mActualTreatmentDuration = 0; ///< 06 - (U32) Actual Treatment Duration (sec) quint32 mAcidConcentrateType = 0; ///< 07 - (U32) Acid Concentrate Type quint32 mBicarbonateConcentrateType = 0; ///< 08 - (U32) Bicarbonate Concentrate Type float mPotassiumConcentration = 0; ///< 09 - (F32) Potassium Concentration (mEq/L) float mCalciumConcentration = 0; ///< 10 - (F32) Calcium Concentration (mEq/L) quint32 mBicarbonateConcentration = 0; ///< 11 - (U32) Bicarbonate Concentration (mEq/L) quint32 mSodiumConcentration = 0; ///< 12 - (U32) SodiumConcentration (mEq/L) float mDialysateTemperature = 0; ///< 13 - (F32) Dialysate Temperature (Celsius) quint32 mDialyzerType = 0; ///< 14 - (U32) Dialyzer Type quint32 mTreatmentStartEpoch = 0; ///< 15 - (U32) Treatment Start Date and Time (epoch) quint32 mTreatmentEndEpoch = 0; ///< 16 - (U32) Treatment End Date and Time (epoch) float mAverageBloodFlow = 0; ///< 17 - (F32) Average Blood Flow (mL/min) float mAverageDialysateFlow = 0; ///< 18 - (F32) Average Dialysate Flow (mL/min) float mDialysateVolumeUsed = 0; ///< 19 - (F32) Dialysate Volume Used (L) float mAverageDialysateTemp = 0; ///< 20 - (F32) Average Dialysate Temp (Celsius) float mOriginUFVolume = 0; ///< 21 - (F32) Origin UF Volume (L) float mTargetUFVolume = 0; ///< 22 - (F32) Target UF Volume (L) float mActualUFVolume = 0; ///< 23 - (F32) Actual UF Volume (L) float mOriginUFRate = 0; ///< 24 - (F32) Origin UF Rate (mL/min) float mTargetUFRate = 0; ///< 25 - (F32) Target UF Rate (mL/min) float mActualUFRate = 0; ///< 26 - (F32) Actual UF Rate (mL/min) quint32 mSalineBolusVolume = 0; ///< 27 - (U32) Saline Bolus Volume (mL) float mHeparinBolusVolume = 0; ///< 28 - (F32) Heparin Bolus Volume (mL) float mHeparinDispenseRate = 0; ///< 29 - (F32) Heparin Dispense Rate (mL/hr) quint32 mHeparinStop = 0; ///< 30 - (U32) Heparin Stop (min) float mHeparinDeliveredVolume = 0; ///< 31 - (F32) Heparin Delivered Volume (mL) quint32 mHeparinType = 0; ///< 32 - (U32) Heparin Type float mAverageArterialPressure = 0; ///< 33 - (F32) Average Arterial Pressure (mmHg) float mAverageVenousPressure = 0; ///< 34 - (F32) Average Venous Pressure (mmHg) quint32 mDeviceID = 0; ///< 35 - (U32) Device ID quint32 mWaterSampleTestResult = 0; ///< 36 - (U32) Water Sample Test Result quint32 mHeparinConcentration = 0; ///< UI - Heparin Concentration (IU/mL) // is filled by UI, for now }; MAdjustTreatmentLogResponse () { } bool fromByteArray (const QByteArray &vByteArray , int *vIndex = nullptr) override; Data data ( ) const ; }; } typedef Model::MAdjustTreatmentLogResponse::Data AdjustTreatmentLogResponseData;