LCOV - code coverage report
Current view: top level - include/qtpokit - calibrationservice.h (source / functions) Hit Total Coverage
Project: QtPokit Lines: 2 2 100.0 %
Version: Functions: 0 0 -

          Line data    Source code
       1             : // SPDX-FileCopyrightText: 2022-2023 Paul Colby <git@colby.id.au>
       2             : // SPDX-License-Identifier: LGPL-3.0-or-later
       3             : 
       4             : /*!
       5             :  * \file
       6             :  * Declares the CalibrationService class.
       7             :  */
       8             : 
       9             : #ifndef QTPOKIT_CALIBRATIONSERVICE_H
      10             : #define QTPOKIT_CALIBRATIONSERVICE_H
      11             : 
      12             : #include "abstractpokitservice.h"
      13             : 
      14             : #include <QBluetoothAddress>
      15             : #include <QBluetoothUuid>
      16             : #include <QVersionNumber>
      17             : 
      18             : QTPOKIT_BEGIN_NAMESPACE
      19             : 
      20             : class CalibrationServicePrivate;
      21             : 
      22             : class QTPOKIT_EXPORT CalibrationService : public AbstractPokitService
      23             : {
      24          17 :     Q_OBJECT
      25             : 
      26             : public:
      27             :     static const QBluetoothUuid serviceUuid;
      28             : 
      29             :     struct QTPOKIT_EXPORT CharacteristicUuids {
      30             :         static const QBluetoothUuid temperature;
      31             :     };
      32             : 
      33             :     CalibrationService(QLowEnergyController * const pokitDevice, QObject * parent = nullptr);
      34             :     ~CalibrationService() override;
      35             : 
      36             :     bool readCharacteristics() override;
      37             : 
      38             :     // Temperature characteristic (BLE write only).
      39             :     bool calibrateTemperature(const float ambientTemperature);
      40             : 
      41             : signals:
      42             :     void temperatureCalibrated();
      43             : 
      44             : protected:
      45             :     /// \cond internal
      46             :     CalibrationService(CalibrationServicePrivate * const d, QObject * const parent);
      47             :     /// \endcond
      48             : 
      49             : private:
      50          51 :     Q_DECLARE_PRIVATE(CalibrationService)
      51             :     Q_DISABLE_COPY(CalibrationService)
      52             :     friend class TestCalibrationService;
      53             : };
      54             : 
      55             : QTPOKIT_END_NAMESPACE
      56             : 
      57             : #endif // QTPOKIT_CALIBRATIONSERVICE_H

Generated by: LCOV version 1.14