CuteHMI - Modbus (CuteHMI.Modbus.2)
PollingIterator.hpp
1 #ifndef H_EXTENSIONS_CUTEHMI_MODBUS_2_INCLUDE_CUTEHMI_MODBUS_INTERNAL_POLLINGITERATOR_HPP
2 #define H_EXTENSIONS_CUTEHMI_MODBUS_2_INCLUDE_CUTEHMI_MODBUS_INTERNAL_POLLINGITERATOR_HPP
3 
4 #include "common.hpp"
5 #include "IterableTasks.hpp"
6 
7 #include <QUuid>
8 
9 namespace cutehmi {
10 namespace modbus {
11 
12 class AbstractDevice;
13 
14 namespace internal {
15 
16 class CUTEHMI_MODBUS_PRIVATE PollingIterator:
17  public IterableTasks
18 {
19  public:
21 
22  bool runNext() override;
23 
24  void reset() override;
25 
26  QUuid & requestId();
27 
28  const QUuid & requestId() const;
29 
30  private:
32 
33  TasksCointainer::iterator m_currentTask;
34  TasksCointainer m_tasks;
35  QUuid m_requestId;
36 };
37 
38 }
39 }
40 }
41 
42 #endif
43 
44 //(c)C: Copyright © 2019, Michał Policht <michal@policht.pl>. All rights reserved.
45 //(c)C: This file is a part of CuteHMI.
46 //(c)C: CuteHMI is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
47 //(c)C: CuteHMI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
48 //(c)C: You should have received a copy of the GNU Lesser General Public License along with CuteHMI. If not, see <https://www.gnu.org/licenses/>.
cutehmi::modbus::internal::PollingIterator
Definition: PollingIterator.hpp:16
std::vector
QUuid
cutehmi::modbus::AbstractDevice
Abstract Modbus device.
Definition: AbstractDevice.hpp:32
cutehmi::modbus::internal::IterableTasks
Definition: IterableTasks.hpp:16
cutehmi
std::internal
T internal(T... args)