SpaIot Library
Loading...
Searching...
No Matches
ledsettings.h
1/*
2 SpaIot Library (c) by epsilonrt - epsilonrt@epsilonrt.fr
3 This file is part of SpaIot library <https://github.com/epsilonrt/spaiot-lib>
4
5 SPDX-License-Identifier: BSD-3-Clause
6
7 SpaIot library is distributed in the hope that it will be useful,
8 but WITHOUT ANY WARRANTY;
9*/
10#pragma once
11
12#include <map>
13#include <initializer_list>
14#include "global.h"
15
16namespace SpaIot {
17
27
28 public:
35
39 virtual ~LedSettings();
40
48 LedSettings (const uint8_t order);
49
53 LedSettings (const LedSettings &other);
54
60
65
71
76 void clear();
77
81 bool isNull() const;
82
86 bool isEmpty() const;
87
96 bool operator== (const LedSettings &other) const;
97
106 bool operator!= (const LedSettings &other) const;
107
113 uint8_t order() const;
114
120 uint16_t frame() const;
121
127 void setOrder (const uint8_t order);
128
129 protected:
130 class Private;
131 LedSettings (Private &dd);
132 std::unique_ptr<Private> d_ptr;
133 private:
134 PIMPL_DECLARE_PRIVATE (LedSettings)
135 };
136
158 extern const std::map<int, LedSettings> SspLeds;
159
177 extern const std::map<int, LedSettings> SjbLeds;
178
181}
SPI 2840X Led settings.
Definition ledsettings.h:26
virtual ~LedSettings()
Destructor.
void clear()
Clears the LedSettings object After the call to this function, the LedSettings object is the same as ...
LedSettings(const LedSettings &other)
Copy Constructor.
bool isNull() const
Returns true if the object is null (i.e. it has not been initialized, d_ptr is null)
bool operator!=(const LedSettings &other) const
bool isEmpty() const
Checks if all attributes are set to their default values (same as the default constructor)
LedSettings & operator=(const LedSettings &other)
Sets the LedSettings object to be equal to other.
LedSettings(LedSettings &&other)
Move Constructor after the move, other is null, other.clear() must be called if it is to be used agai...
bool operator==(const LedSettings &other) const
LedSettings(const uint8_t order)
uint16_t frame() const
void setOrder(const uint8_t order)
uint8_t order() const
const std::map< int, LedSettings > SspLeds
Leds settings for the Ssp SPA.
const std::map< int, LedSettings > SjbLeds
Leds settings for the Sjb SPA.
SpaIot name space.
Definition bussettings.h:15