/*! * * 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 MTreatmentAdjustUltrafiltrationStateResponse.h * \author (last) Behrouz NematiPour * \date (last) 13-Aug-2020 * \author (original) Behrouz NemaiPour * \date (original) 02-Jul-2020 * */ #pragma once // Qt #include // Project #include "MAbstract.h" #include "types.h" // forward declarations class tst_models; namespace Model { /*! * \brief The MAdjustUltrafiltrationStateResponse class * \details The ultrafiltration adjustment state response model * * | MSG | CAN ID | M.Box | Type | Ack | Src | Dest | Description | #1:(U08) | * |:----:|:------:|:-----:|:----:|:---:|:---:|:----:|:-----------: |:--: | * |0x1000| 0x100 | 9 | Rsp | N | HD | UI | Generic response ACK/NAK | mAccepted | * * \sa Data * */ class MAdjustUltrafiltrationStateResponse : public MAbstract { // friends friend class ::tst_models; QVariantList parameters() const override; struct { Types::U08 mAccepted ; // IMPORTANT : This is a response of AcknowGeneric which has a data of 1 byte for the accepted/rejected state. } _data; public: // coco begin validated : manually validated. // this message has been inherited from MAbstract and should use notify but since the response message is not standard can't use notify yet. Type_Enum typeText () const override { return Type_Enum::eEvent ; } // coco end Unit_Enum unitText () const override { return Unit_Enum::eHD ; } QString infoText () const override { return QString("AdjustUFState"); } struct Data { bool mAccepted = 0; /*!< Accepted value of type quint32 extracted out */ }; MAdjustUltrafiltrationStateResponse() { } bool fromByteArray (const QByteArray &vByteArray , int *vIndex = nullptr) override; Data data ( ) const ; }; } typedef Model::MAdjustUltrafiltrationStateResponse::Data AdjustUltrafiltrationStateResponseData;