supla-device
Loading...
Searching...
No Matches
remote_output_interface.h
1/*
2 Copyright (C) AC SOFTWARE SP. Z O.O
3
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public License
6 as published by the Free Software Foundation; either version 2
7 of the License, or (at your option) any later version.
8
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
13
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17*/
18
19#ifndef SRC_SUPLA_CONTROL_REMOTE_OUTPUT_INTERFACE_H_
20#define SRC_SUPLA_CONTROL_REMOTE_OUTPUT_INTERFACE_H_
21
22#include <supla/control/output_interface.h>
23
24namespace Supla {
25namespace Control {
26
35 public:
42 explicit RemoteOutputInterface(bool onOffOnly);
43 ~RemoteOutputInterface() override;
44
51 void setOutputValueFromRemote(int value);
52
58 int getOutputValue() const override;
59
66 void setOutputValue(int value) override;
67
73 bool isOnOffOnly() const override;
74
80 bool isControlledInternally() const override;
81
82 private:
83 int outputValue = 0;
84 bool onOffOnly = false;
85};
86
87} // namespace Control
88} // namespace Supla
89
90#endif // SRC_SUPLA_CONTROL_REMOTE_OUTPUT_INTERFACE_H_
RemoteOutputInterface(bool onOffOnly)
Contructor.
Definition remote_output_interface.cpp:23
Definition output_interface.h:26
void setOutputValue(int value) override
Override base class method in order to disable setting output value by HvacBase.
Definition remote_output_interface.cpp:45
int getOutputValue() const override
Returns current output value.
Definition remote_output_interface.cpp:41
bool isControlledInternally() const override
Returns false - output is not controlled internally.
Definition remote_output_interface.cpp:37
bool isOnOffOnly() const override
Returns if output is on/off only or 0-100%.
Definition remote_output_interface.cpp:50
RemoteOutputInterface(bool onOffOnly)
Contructor.
Definition remote_output_interface.cpp:23
void setOutputValueFromRemote(int value)
Set output value from a remote device.
Definition remote_output_interface.cpp:30