1#ifndef _value_producer_H_
2#define _value_producer_H_
4#include <ArduinoJson.h>
12template <
typename C,
typename P>
58 template <
typename CT>
76 template <
typename T2>
97 template <
typename TT,
typename T2>
A base class which allow observers to attach callbacks to themselves. The callbacks will be called wh...
void attach(std::function< void()> observer)
A base class for any sensor or piece of code that outputs a value for consumption elsewhere.
void connect_to(ValueConsumer< T > *consumer, uint8_t input_channel=0)
virtual const T & get() const
Transform< T, T2 > * connect_to(Transform< T, T2 > *consumer_producer, uint8_t input_channel=0)
void connect_to(ValueConsumer< CT > *consumer, uint8_t input_channel=0)
Connect a producer to a consumer of a different type.
Transform< TT, T2 > * connect_to(Transform< TT, T2 > *consumer_producer, uint8_t input_channel=0)
Connect a producer to a transform with a different input type.
ValueProducer< bool > BoolProducer
ValueProducer< float > FloatProducer
ValueProducer< int > IntProducer
ValueProducer< String > StringProducer